We learned of a startling assault on freedom of the press by the Department of Justice, following the revelation last week of the unprecedented information-gathering foray by that department against The Associated Press.

Then, a few minutes later, the Justice Department’s inspector general released a report declaring that the US attorney in Arizona used the leak of a confidential memo to try to discredit a whistleblower in the notorious “gun-walking” scandal known as Fast and Furious (which got two federal agents killed). The leak was called “egregious.” The US attorney, Dennis Burke, was an Obama political appointee.

A few hours after that, we were told that everybody at the most senior levels of the White House knew about the report revealing the targeting of conservative groups by the Internal Revenue Service — everybody but the president, who maintains he learned about it from watching TV.

By far the most damaging of the stories has to do with the attack on press freedom.

In 2009, Fox News reporter James Rosen got a leak about North Korean policy and ran a story about it. Yesterday, White House press spokesman Jay Carney referred to the aftermath of that single leak nearly four years ago as “an ongoing criminal investigation.”

An ongoing criminal investigation? Into Rosen? Administrations investigate national-security leaks to find the leaker, not to hurl criminal thunderbolts at the reporter. Journalists have found themselves in legal jeopardy, to be sure, but for refusing to name a source in violation of a judge’s order. They are jailed for contempt of court, in other words. They are not punished for seeking or collecting or publishing information.

Until now.

The Obama Justice Department pursued a shocking and outrageous course by seeking and obtaining a warrant to search Rosen’s e-mails, phone calls and even the electronic passes that got him entry into the State Department.

In the request for the warrant, which came out yesterday, the FBI agent investigating the leak said he needed it because there was “probable cause” to believe Rosen had acted as “an aider and abettor and co-conspirator,” a crime punishable by up to 10 years in prison!

And how had Rosen aided and abetted and conspired? By communicating with the leaker. By giving him an e-mail address for contact purposes, along with bits of code so Rosen would be able to identify him. By saying he wanted the information ahead of his competition.

The FBI agent said that Rosen had played on the leaker’s “vanity and ego,” and that Rosen had behaved “like an intelligence officer . . . running a clandestine intelligence source.” In other words, Rosen acted like a reporter. And how a reporter interacts with a source as a social matter is, to put it mildly, as far beyond the scope of an acceptable government inquiry as the moons of Jupiter are from the Earth.

Even more startling, the search warrant makes clear that the FBI already had everything it needed on the leaker, as the request for a search warrant features quotes from an interview that were tantamount to a confession. It asked that the warrant be sealed — in other words, that Rosen not be told — because knowledge might “cause subjects to flee”! Imagine it: Rosen, an on-air reporter on a national news channel with a wife and two small kids in DC, seeking refuge in Cuba . . .

The leak merited investigation, and the investigation was successful. So why go after Rosen? We don’t know, but we can speculate that someone was very mad about the leak, and someone wanted to see if there might be a way to take the reporter down by characterizing his work as a conspiracy that might lead him to flee the United States.

At the end of last week, some hopeful Obama-backers in the media were saying the president’s troubles over the past weeks were a blip on the radar. Opined the liberal Pangloss of The Washington Post, Ezra Klein: “The scandals are falling apart.”