JERUSALEM -- Just over a month before elections, Israeli Prime Minister Benjamin Netanyahu looks more vulnerable than ever.
Following a dramatic announcement Thursday by Israel's attorney general, Netanyahu almost certainly faces indictment on corruption charges in the coming months. His main challenger leads him in the polls, and he is taking heat even from his supporters for forming an alliance with a racist ultranationalist party.
But when the dust settles after the April 9 vote, the person most likely to emerge as prime minister remains Netanyahu, thanks to a devoted base of supporters and a public that tends to agree with his world view.
Still, a Netanyahu victory is far from certain, and his ability to rule effectively if he does win will be limited.
Here is a look at what lies ahead for the Israeli leader:
WHAT HAPPENED THIS WEEK?
Capping an investigation that began over two years ago, Attorney General Avichai Mandelblit announced his intention on Thursday to indict Netanyahu on corruption charges in a series of scandals .
The most serious charge is bribery, for allegedly promoting regulatory changes that helped Shaul Elovitch, the head of telecom giant Bezeq, reap a hefty financial windfall. In exchange, Elovitch allegedly had Bezeq's popular news site, Walla, publish favorable items about Netanyahu and his family, while promoting negative coverage of some of Netanyahu's rivals.
Perhaps the most embarrassing charge involves breach of trust, for allegedly accepting some $300,000 worth of champagne and cigars as gifts from billionaire friends. The revelations reinforced Netanyahu's image as a hedonist with expensive tastes and a propensity for letting others pick up the tab.
While a sitting Israeli prime minister has never been this close to indictment before, Netanyahu is not obligated to resign at this stage. The planned indictment is still subject to a hearing, during which Netanyahu can plead his case before formal charges are filed. This process is expected to take up to a year to complete.
That means Netanyahu can continue to lead his Likud Party into elections, even with a cloud of scandal over his head.
HOW CAN NETANYAHU WIN?
Like his good friend Donald Trump, Netanyahu enjoys the staunch support of a loyal base that has remained firmly behind him during the past few years of police investigations. In addition, lawmakers in Netanyahu's Likud Party have lined up behind him. Thursday's announcement by Mandelblit is unlikely to change that.
Responding to the attorney general's recommendations, Netanyahu sounded much like Trump, accusing prosecutors, police, the media and his "leftist" opponents of conspiring to oust him. This is a theme that plays well with the base and that he will likely continue to sound throughout the campaign.
Under Israel's political system, the politician who has the best chance of building a majority coalition is chosen to be prime minister.
Even with all his troubles, Netanyahu and his political allies, a mixture of hard-line religious and nationalist parties, appear to be best positioned to form the next parliamentary coalition, reflecting a broader shift toward the right in public opinion over the past two decades.
SO WHAT COULD GO WRONG?
Netanyahu, who is seeking a fourth consecutive term, faces a challenger unlike any he has seen before.
Political newcomer Benny Gantz, a popular former military chief, has surged in opinion polls with a message stressing his army background — an essential credential in security-obsessed Israel — along with an untarnished image.
Gantz's partnership with Yair Lapid, another popular centrist figure, has been welcomed by the public, and their new "Blue and White" alliance has jumped ahead of Likud in opinion polls.
Netanyahu has also come under heavy criticism, even from allies like the pro-Israel lobby group AIPAC, for an alliance struck with the political heirs of the "Kach" movement, banned in Israel and the U.S. for its racist ideology.
Even so, polls forecast an extremely tight race in which Gantz could struggle to cobble together a majority coalition with his centrist and leftist allies, particularly if Arab parties, which have never sat in government, are excluded.
Gantz is now likely to turn the remaining weeks of the campaign into a referendum on Netanyahu's character. On Thursday, Gantz called on Netanyahu to resign while he fights his legal battle.
"Unfortunately, today you chose a path that isn't befitting a prime minister of Israel," Gantz said. "Instead of choosing the good of the country, you chose your own well-being. It's the wrong choice and one we must be a part of."
The picture will become clearer in the coming days as opinion polls indicate whether support for Netanyahu has eroded.
In order to win, Gantz will have to lure moderate Likud supporters who may be willing to give a more centrist candidate a chance to govern. If Gantz can maintain a solid lead, he will likely be given the first crack at putting together a coalition.
Yohanan Plesner, president of the Israel Democracy Institute, an independent think tank, said such a scenario isn't impossible.
"I don't expect any dramatic shift in public opinion," said Plesner, a former centrist lawmaker. "But even a relatively small shift of a few percentage points moving from bloc to bloc can make a significant difference in the election."
WHAT IF HE WINS?
If Netanyahu ekes out a victory, he will face persistent questions about his ability to govern.
His legal troubles will provide both a major distraction and a potential conflict of interest. Netanyahu's job includes professional consultations with the same bodies that are prosecuting him.
Any major decision, including domestic legislation, military action or diplomatic activity, will raise questions about Netanyahu's motives. This will be an important concern if Trump's Mideast team follows through on its promise to release a peace plan after the election. Netanyahu's ability to maneuver will likely be hampered.
"Mandelblit's decision is not yet the final indictment. But it is a new millstone hung around Netanyahu's neck, a weight no previous Israeli prime minister has ever experienced," wrote Anshel Pfeffer, a columnist for the Haaretz daily and author of a recent biography about Netanyahu.
"He will now have to carry it around wherever he goes, and it will drag him down," Pfeffer wrote.
Isabel DeBre contributed to this report.