Les Moonves' time as the head of CBS appears to be coming to an end.

CNBC, citing anonymous sources, reported Thursday that the CBS board is "deep in talks" with the chief executive that would result in him leaving the company.

Moonves has also told some confidants about the exit talks, a friend who spoke with him about it told CNN.

It is unclear if he is trying to fight the board. Moonves did not respond to a request for comment. Spokespeople for the CBS board and the company declined to comment on the reports.

Moonves is a legendary broadcasting executive and one of the most prominent CEO's in the country. This is not the way he wanted to go. Last year he extended his contract through 2021.

But two developments this year have rewritten the script of his career.

The first development was a dispute over the future of CBS. Moonves and most members of the CBS board have been locked in an ugly legal battle for months with Shari Redstone, who has a controlling stake in CBS and its corporate cousin Viacom.

The second development was the bombshell report in The New Yorker detailed allegations of sexual harassment and misconduct against Moonves. One month ago the CBS board hired outside counsel to investigate those claims. The investigation is ongoing.

Moonves has acknowledged that he "may have made some women uncomfortable," calling those moments "mistakes." He also insisted that he respected women and that he "abided by the principle that 'no' means 'no,' and I have never misused my position to harm or hinder anyone's career."

In the meantime, Moonves has been keeping a relatively low profile, inside and outside CBS (CBS). But he was seen at Senator John McCain's funeral service in Washington last Saturday.

The misconduct claims sparked speculation in the TV business that Moonves might reach a hefty financial settlement and step down from CBS.

That's what appears to be in the works now.

The Los Angeles Times reported on Wednesday night that CBS board members were talking about his potential exit. Discussions have focused on the size of a severance package, and on whether Moonves would move to a producer role, the Times reported.

Under the terms of his contract, Moonves may be owed a $180 million severance package. But if he is removed "for cause," relating to the harassment allegations, such an eye-popping severance package would not be in play.

CNBC reported that the board "is offering a roughly $100 million exit package made up almost entirely of CBS stock." Furthermore, "the board also wants the right to claw back some of the compensation if it's determined that sexual harassment allegations against Moonves are confirmed."

These exit talks are happening in secret, and the details could not be immediately confirmed.

At the same time -- whether linked or not -- there are talks happening about the future of CBS.

Redstone thought about bringing CBS and Viacom back together as one company earlier this year. But Moonves and CBS resisted the idea in part because Redstone wanted her favored executive, Viacom CEO Bob Bakish, to take a prominent position at the new company. Moonves wanted his own team in charge.

CBS took Redstone and her family's holding company, National Amusements, Inc., to court in May over the spat. A trial date is set for October.

But now there are settlement talks underway on that front as well, according to multiple reports on Wednesday.

CNBC's report suggested that Moonves' team could get a consolation prize if a settlement is reached. The network reported that Moonves' right hand man Joe Ianniello, the COO of CBS, could replace Moonves as interim CEO.

Ianniello has widely been seen as the top choice to succeed Moonves. When talks to merge CBS with Viacom were on the table earlier this year, Team Moonves pushed for Ianniello to be No. 2.

Wall Street analysts prefer Ianniello, too. In the days after the Moonves allegations first came out, Doug Creutz, a senior research analyst at Cowen, called the Ianniello choice the "least bad solution" to the Moonves problem.

CBS stock was up about 4% in trading early Thursday afternoon.