Dozens of reporters and a horde of photographers turned out for Attorney General Jeff Sessions’ news conference Friday to announce a crackdown on leaks, but the most important target for his message wasn’t in the room: President Donald Trump.

Sessions’ eight-minute broadside against leaks and his stern warning to leakers seemed to be aimed at trying to repair his badly frayed relationship with Trump, who has expressed regret for selecting Sessions and who has specifically complained that he was doing too little to fight the tidal wave of leaks that have swamped the Trump White House.

“First, let me say that I strongly agree with the president and condemn in the strongest terms the staggering number of leaks undermining the ability of our government to protect our country,” Sessions declared. “We are taking a stand. This culture of leaking must stop. … Cases will be made and leakers will be held accountable.”

If Sessions’ desire to address the leaks of most concern to Trump wasn’t sufficiently apparent, the attorney general offered unsolicited outrage toward the leak that roiled the West Wing this week: the publication of transcripts of Trump’s confidential conversations with Mexico’s president and Australia’s prime minister earlier this year.

“Just yesterday, we saw media reports about conversations the president had with foreign leaders,” Sessions said. “No one is entitled to surreptitiously fight to advance battles in the media by revealing sensitive government information.”

Even Sessions’ thinly veiled threat toward the press seemed intended to curry favor with the occupant of the Oval Office, who regularly castigates the news media on Twitter over “FAKE NEWS.”

“We respect the important role that the press plays and we will give them respect, but it is not unlimited,” the attorney general warned. “They cannot place lives at risk with impunity. We must balance the press’s role with protecting national security and the lives of those who serve in the intelligence community and all law-abiding Americans.”

Sessions also got in two digs at another part of the Washington establishment that Trump seems to be sour on at the moment: Congress. The attorney general suggested, without providing specifics, that lawmakers or their aides are responsible for some of the recent leaks.

Sessions’ long-distance missive to the president comes as their relationship seems to be settling into a chilly detente.

Interventions from Sessions’ Senate friends, from his allies in the White House and from conservative leaders appear to have stemmed the near-daily taunts that Trump directed toward his attorney general last month.

Trump has now gone more than a week without publicly attacking Sessions. Trump’s new White House chief of staff, John Kelly, also called Sessions last weekend with reassurances that his job was safe. (Sessions and Trump were face to face at a Cabinet meeting Monday, but there are no signs the men have sorted out their issues.)

Trump has calmed down on Sessions, several senior administration officials said, after having conversations with a number of people who arranged to see him and defend the attorney general, officials said. The president was also distracted by the other problems in his administration and has talked less about Sessions, one aide said.

Kelly has also told the president that it would be a mistake to cut ties with Sessions, and Trump has told others privately he has no plans to make a change, said one person who spoke with the presidentlast weekend.

The public silence from Trump has Sessions’ aides and allies breathing a sigh of relief but it is an uneasy peace, marked by concern that the president’s ire could surface again at any moment. While Trump is no longer publicly mocking his attorney general, the president has offered no public praise for Sessions nor even any acknowledgement of his work to advance the administration’s priorities.

But Trump’s anger could be triggered at any point by the ongoing Russia probe, these people said, because he still blames Sessions for those headaches.

“If they’re going to look into business deals and start looking into his family and this or that, he’s going to blame Sessions,” one adviser said. “He’s going to associate his problems with Sessions.”

Friday’s event at Justice Department headquarters was carefully structured to ensure that Sessions’ message reached Trump with the fewest distractions possible. If reporters had the chance to question the attorney general about the Russia investigation, he might have demurred because he has recused from the probe. But with the recusal at the core of Trump’s complaints about Sessions, any televised scene of the attorney general broaching the subject could send the president into a blue rage.

So, Sessions filed out after he spoke. Cameras were then shut off at Justice officials’ insistence before Deputy Attorney General Rod Rosenstein returned to take reporters’ questions about the nitty-gritty of the leak crackdown.

One question the deputy attorney general got: whether Friday’s press event was arranged at the instigation of the White House.

“The answer to that is, everybody in the intelligence community recognizes that we’ve been dealing with an increased number of leaks,” Rosenstein said, not answering directly. “So, I think we’ve heard that from many senior government representatives. We’ve also heard it from congressmen and senators.”

Asked whether the Justice Department was out to “appease” the president, Rosenstein replied: “I’m not going to comment on that other than to say … I think it is appropriate for everyone to be concerned.”

Friday’s public fusillade against leaks is just the latest example of efforts to use the media to let Trump know Sessions and his department are putting their shoulder to the wheel on issues near and dear to the president, like fighting drugs, gangs and illegal immigration. Last week, a top Justice Department officialmade an unusual appearance in the White House briefing room — just feet from the Oval Office — to talk about the battle against the violent gang MS-13.

One challenge for Sessions in trying to win the president over on the leaks issue is that Trump gets much of his information through Fox News.

While the network’s pro-defense, national security bent might ordinarily make it an ally in the war on leaks, Sessions’ talk of making more aggressive efforts toward the media could raise hackles at the network.

Fox and many on the right erupted in anger in 2013 after it was disclosed that during a leak investigation the Justice Department obtained a warrant to search Fox reporter James Rosen’s emails — and that prosecutors got the warrant by branding Rosen as a co-conspirator in an effort to violate federal law.

While Rosen’s source was indicted and ultimately pleaded guilty, Rosen was never charged with a crime. However, the episode was one of two prominent cases that led Obama to promise that reporters would not be jailed for doing their jobs. It also prompted Obama’s attorney general, Eric Holder, to make it harder for prosecutors to subpoena reporters or seek their phone or email records — tightening the very policies that Sessions is now threatening to loosen again.

Rosen declined to comment on Sessions’ proposal. A Fox News spokeswoman had no immediate response to a request for comment.

Another topic that seemed to get little attention Friday was the fact that leak prosecutions broke records during the Obama administration. There were some allusions to the fact that the issue has been one the government has tried to crack down on before.

Sessions noted that an “insider threat” task force was set up in 2011 to address leaks. “Progress has been made and we intend to reach new levels of effectiveness,” the attorney general said.

Rosenstein did mention that he handled a couple of the cases brought in recent years, including the prosecution of Gen. James “Hoss” Cartwright.

Rosenstein acknowledged that the hurdle in getting clearance to proceed with that case was not clearance to probe media communications, but rather the intelligence community’s reluctance to sign off on making details about the case public. (Israel reportedly objected to potential disclosure of its involvement with using the so-called Stuxnet virus against Iran’s nuclear program.)

Cartwright entered a guilty plea last October to a single felony count of lying in the course of the investigation, although prosecutors made clear that they believed he had leaked top secret information to the New York Times and Newsweek.

In the off-camera briefing, Rosenstein also passed up a chance to take what could have been an easy shot at Obama. The veteran prosecutor did not note the ultimate outcome of the Cartwright case. Three days before leaving office, Obama granted the Marine general a pardon that wiped out his conviction and eliminated a sentence that could have ranged up to five years in prison.