George Brandis has urged the coalition not to open a political front against Labor on domestic national security, and stick by its liberal principles.
George Brandis has warned the Liberal Party faces a "profound challenge" caused by powerful elements of right-wing politics.
After nearly two decades in federal politics, the former attorney-general made his valedictory speech in the Senate on Wednesday, reflecting on more than four years as the minister responsible for domestic national security.
"I have heard some powerful voices argue that the coalition should open a political front against the Labor Party on the issue of domestic national security. I could not disagree more strongly," the Queensland senator said.
Senator Brandis has been chosen to become Australia's High Commissioner to the United Kingdom and will take up the position next month, to replace former Liberal leader Alexander Downer in London.
He said he entered parliament in 2000 to defend and advance classic liberal values which are increasingly under fire from "belligerent, intolerant populism" on both sides of politics.
"After nearly two decades, I find those values under greater challenge than at any time in my memory," Senator Brandis told parliament.
As the custodian of both liberalism and conservatism, the Liberal Party faces a profound challenge, he said.
Senate Brandis said his fierce condemnation of Pauline Hanson after she entered the Senate wearing a burka in August 2017 was perfectly consistent with liberal values.
He nominated his two major achievements as legalising same-sex marriage and reforming national security laws.
"Most political careers end in defeat, or disillusionment or, in some sad cases, disgrace," Senator Brandis said.
"I had the immense good fortune to be able to bring my parliamentary career to a close at the very time I had seen the fulfilment of two things which, more than any others, I had made my priorities."
As for regrets, he leaves behind the "unfinished business" of reforming the federal judiciary.
Senator Brandis touched on his dramatic falling out with former solicitor-general Justin Gleeson, praising one-time political opponent turned friend LNP senator Ian Macdonald's grilling.
"We may say of your cross-examination, it wasn't pretty, but it was pretty effective," he said, eluding to the campaign slogan of another former Queensland colleague Ron Boswell.
Senator Brandis couldn't resist a parting dig at his former sparring partner, shadow attorney-general Mark Dreyfus.
"There were a couple of controversies over the last four and a half years, but I could always rely on the Member for Isaacs to blunder in and get me out of trouble."
Despite warning about the Liberal Party's challenges, he is "cautiously optimistic" about the Turnbull government's chances of re-election because he sees similarities between Mr Dreyfus and Opposition Leader Bill Shorten.