Australians could soon find out why a former spy was secretly convicted and sentenced in a case that has wide ranging repercussions for the nation's national security laws.
The trial of Witness J, also given the pseudonym Alan Johns, was conducted in secret without the charges, his guilty plea or sentencing being made public.
The former military intelligence officer was charged with disclosing confidential information.
He was sentenced to two years and seven months imprisonment in early 2019 imposed across an aggregate of five charges, but the reason why has never been publicly disclosed.
The case only came to light after he launched legal proceedings against the prison for tipping off police about a memoir he was writing.
The ACT Chief Justice Lucy McCallum is now set to rule on how much of the sentencing remarks can be made public.
"My preference is to publish the judgment as written by the judge to adhere to the principle of open justice," she told the ACT Supreme Court on Tuesday.
Australia's national security watchdog has chastised the government over the saga and made recommendations to ensure a repeat of the secrecy doesn't happen again.
Independent National Security Legislation Monitor Grant Donaldson said the case showed how the government had the legal power to conduct cases in complete secrecy.
He found it was "unusual" no evidence was given about national security information that needed to be protected and no reasons were given for the gag order to be made.
Mr Donaldson has provided a draft copy of the sentencing remarks with suggested redactions and his summary of the case is also due to be released.
Attorney-General Mark Dreyfus is not opposing the release of the court's judgment, saying that open justice is integral to the Australian judicial system.
But the attorney-general is contending that some national security information in the judgment be redacted before being released.
The attorney-general's legal counsel Andrew Berger KC said information that could harm Australia's national interest contained in the ruling "is likely to endure for many years".
"Therefore, if the court is minded to revisit in the future whether further parts of the sentencing reasons can be published, this should not be for a considerable period of time," he contends in his submission.
A submission to the court on behalf of Johns says the matter is "almost without precedent".
Johns has accepted some parts of the judgment need to remain secret for national security reasons but wants as much of the ruling released as possible.
"The community is entirely in the dark about the facts and circumstances of the offence with which Mr Johns was charged, pleaded guilty to, was convicted of, and was sentenced for," the submission reads.
Any court hearings as to what will be redacted and the argument as to why are set to be held behind closed doors.
Johns' lawyers want a contradictor in the room to put their case as to what should remain secret and while the Commonwealth agreed in principle, they argued there was some evidence they shouldn't be privy too.
Chief Justice McCallum will hand down her decision on April 14.