No amount of lipstick applied to the data retention legislation will cosmetically improve this porker.

The hasty amendments that created “journalist information warrants” were designed to lock-in Labor support and hasten the passage of the legislation, not to protect people who leak government information to journalists.

Just look at the faux legal process that lumbers into action once a prescribed agency wants to snoop into a journalist’s communications.

The agency has to apply for a warrant to an “issuing authority” comprised of judicial officers approved by the minister. They could be judges or members of the Administrative Appeals Tribunal, or lawyers who are friends of the minister. Appointments can be terminated at the minister’s pleasure.

Hand picked “public interest advocates” – chosen by the prime minister, no less – are on tap to make submissions. The journalist whose information is being sought by the warrant is not informed and cannot make submissions to the issuing authority.

The authority has to weigh the public interest in knowing the identity of a source with the public interest in protecting the identity of a source.

In the hunt for the correct public interest the authority should have regard to a small list of things: the source’s privacy, whether the agency has reasonably attempted to obtain the information by other means – ie without a warrant – whether the matter being investigated is serious, and any submissions from the public interest advocate.

The role of the advocates is unclear. Whose side are they actually on – or are they just there to “assist” the issuing authority? They can also make submissions directly to the minister about any conditions that should apply to a journalist information warrant.

The weighing of competing public interests is a cute, but hopeless exercise. Just take the example of the Court Suppression and Non-Publication Orders Act in NSW, where judges are supposed to weigh the principle of open justice against the interest of the “proper administration of justice”.

It’s not much of a contest because, in this struggle, open justice and the journalists’ right to report court proceedings invariably come off second best.

Don’t stay up late wondering whether it will be any different when the government is hell bent on tracking down leakers. We know how committed law enforcement authorities are in tracking leaking sources, both here and in Blighty.

The journalists’ warrants apparatus also can be sidestepped because Asio’s director general of security has the power, in certain circumstances, to issue warrants directly.

“Journalist information warrants” are warrants in name only. They are designed to give the appearance of having an independent mind applied to a request for private information. In reality, this is a home-town prosecutor, judge, jury and executioner.

The “protections” are corralled by political trapdoors and if I were a source (or a journalist trying to protect a source) I’d be reaching for my encryption kit. And, it’s two years’ porridge if a journalist discloses information about a warrant.

In any event, policing agencies need not even bother to apply for a journalist warrant in order to discover the identity of a source.

Say a draft of an important piece of legislation is leaked from a government department, all the AFP has to do is examine the data of the half-dozen or so public servants who worked on the draft legislation and start narrowing down the field. No warrant required there.

Nor are they required if the government looks at the communications of lawyers working for the media organisation, to see what they have been up to in advising on relevant recent stories.

Which brings us to the idea of who or what is a “journalist”. According to the legislation a journalist is “a person who is working in a professional capacity as a journalist”. That would exclude someone who wrote occasionally on interesting and sensitive matters, critical of the government and was, for example, a lawyer or a policy advisor. No warrants are required to discover who they might have been talking to.

The “professional capacity” journalist is a much narrower breed than the journalist in the shield law provisions of the Evidence Act. That journalist is defined is “a person who is engaged and active in the publication of news”. Nothing “professional” about it and so would include bloggers and occasional writers.

Lawyers have now woken up to what is at stake here, because there is no judicial oversight of government accessing their privileged communications. Similarly, the confidential communications of other professional service providers or corporate entities engaged in sensitive negotiations, or the poor mug citizen.

Nowhere, despite the smooth blandishments of Malcolm Turnbull or the confusions of George Brandis, has the case been made that mass mandatory data retention is necessary, reasonable or proportionate.

There is no threshold to the information deemed necessary. It is not confined to cases of serious crime, but conceivably extends to offences like shoplifting or nicking hubcaps.

Lawyer Leanne O’Donnell, who has expertise in the place where law and technology intersect, points out that this is not just a data retention scheme - it’s also a data creation scheme, because service providers are required to capture and retain location information, which had not previously been a requirement.

The government has predicated the law on the need to patch holes left gaping by telcos’ changing business models, allegedly, no longer retain customer data for longer periods.

According to ISP sources this claim should be taken with a large dose of salt. Telstra, Optus and Vodafone all have lengthy retention obligations in order to handle customer complaints and to do their own market analysis. The major carriers have not changed their retention practices in quite the way the government wants you to believe.

Just bear in mind that Bulgaria, Cyprus, the Czech Republic, Romania, Slovakia and Germany have recently had their mass data retention schemes found to be unconstitutional. The Netherlands’ scheme was struck down earlier this month, as an invasion of privacy.

In the European Union, eleven countries have mandated a judicial oversight regime for access to retained data. Here, we’re told by the prime minister, that if such a filter were applied, “the whole process would absolutely gum up”.