NEW YORK — If anyone knows what Michael Cohen is up against, his lawyer figures it’s John Dean, the former White House counsel who turned on President Richard Nixon and helped run him out of office.

Cohen’s lawyer, Lanny Davis, told The Associated Press on Monday that he’s been talking with Dean over the last few months “to hear his wisdom, the lessons that he learned and his reflections on what he saw Michael Cohen going through.”

Davis’ revelation was widely seen as the latest sign that Cohen, who worked as a New York lawyer and fixer for Donald Trump, could be seeking a deal to cooperate against Trump in the Russia probe. It also comes as federal prosecutors appear close to charging Cohen with financial crimes.

Two people familiar with the federal investigation into Cohen told the AP on Monday that Cohen could be charged by the end of the month with crimes including bank fraud in his dealings with the taxi industry. Davis has declined to talk about potential charges or a plea deal.

Davis, a special counsel to President Bill Clinton in the late 1990s, said he’s been close with Dean since appearing regularly with him on MSNBC during Clinton’s impeachment.

“I gained a lot of wisdom from Mr. Dean, especially how he coped and attempted to defend himself from the vicious campaign to discredit him, orchestrated by the Nixon White House,” Davis said.

Through their conversations, Davis said, he and Dean noticed strong parallels between Dean’s experience as the Watergate scandal came to a head in 1974 and Cohen’s pivot from having unfailing loyalty to Trump once boasting he would “take a bullet” for him to looking out for himself.

Dean faced a federal investigation, too, and spent four months in jail after pleading guilty to obstruction of justice. Dean, Nixon’s White House counsel, and Cohen, Trump’s personal lawyer, were questioned by Congress and were skewered by people who remained loyal to the presidents they had abandoned.

Trump on Sunday tweeted that a New York Times story about White House counsel Don McGahn giving hours of testimony to special counsel Robert Mueller’s team implied that “he must be a John Dean type ‘RAT.’”

Dean, a vocal Trump critic, responded, “I doubt you have ANY IDEA what McGahn has told Mueller. Also, Nixon knew I was meeting with prosecutors, b/c I told him. However, he didn’t think I would tell them the truth!”

Davis said he was seeking factual information, not legal advice, from Dean in their conversations and did not share with him information that would be covered by attorney-client privilege. David noted that Dean has not talked to Cohen directly.

Dean, on CNN on Monday, said Davis was seeking to learn more about how Watergate unfolded so he could better “understand that history.”

Davis said he did “not in any way compare the depth of knowledge and the detail, insider information” that Dean had about Nixon’s crimes to what Cohen “may or may not know.”

“If anything,” he said, “I’m doing my best to reduce expectations on that comparison, on the level of knowledge.”