JERUSALEM — Twice this year, Israeli Prime Minister Benjamin Netanyahu has failed to secure electoral victory for his Likud party. He faces the likely prospect of indictment within the coming months on corruption charges. And for the first time in more than a decade, someone else — former military chief Benny Gantz — was asked by the Israeli president to try to form a governing coalition and end the country’s months-long political stalemate.

One way to break that deadlock would be for Likud to jettison Netanyahu as party leader, meeting Gantz’s condition for taking his Blue and White party into a national unity government with Likud.

But such a rebellion has never happened in Likud’s long history, and there is little talk of one now.

“Likud has a strong tradition of loyalty to its leaders,” said Yohanan Plesner, president of the Israel Democracy Institute. “Since Israel’s creation 70 years ago, the party has only had four leaders,” he said, including the early years when the party was called Herut. He contrasted that with Israel’s once-dominant Labor Party, which has had 10 leaders just since 2001.

Gantz has less than two weeks left to pull together a coalition in parliament and says he’s willing, even prefers, to join forces with Likud. But he has also made very clear his reluctance to sit in government with a leader facing criminal indictment. If Gantz falls short, Israel could be headed back to a third national election in less than a year.

There are quite a few Likud figures who could vie for the party’s leadership. Yet Plesner says that Netanyahu’s support remains strong among the roughly 120,000 party members. Many view his legal troubles as a sinister attempt by his opponents to oust him undemocratically and say he has brought them far too many victories in the past to abandon him now.

Netanyahu last month dismissed what he calls the “illusion of a Likud rebellion that other parties are longing for,” saying it is hindering them from joining a unity government.

Yuli Edelstein, 61, who is number two in the party and serves as the speaker of the Knesset, Israel’s parliament, said in an interview that talk of ousting Netanyahu is a distraction. “Our goal right now is to form a unity government as soon as possible. Any other discourse diverts attention from the main purpose,” he said.

A veteran Likud member, Edelstein said the reluctance to challenge Netanyahu stems from the party’s DNA. “We stand behind our chosen leader, and today we stand behind Netanyahu,” he said.

The prime minister slightly strengthened his overall position on Friday when he announced he had reached an agreement with Naftali Bennett, a former education minister and onetime political foe, to rejoin the acting government as defense minister.

Still, there have been subtle signs that Netanyahu’s position inside the Likud party is weakening. Present and former Likudniks — as members are known in Hebrew — are beginning to express disillusionment with the direction he is taking the party and asking why he’s still there after a year of failures.

They point to the fierce verbal attacks Netanyahu and his staunchest allies have launched on the police, the judiciary and the media. They say he is engaged in a cynical attempt to discredit a legal system that could soon indict him in three criminal cases, which are centered on fraud, bribery and breach of trust.

“The fact there is unwavering support for the leader of a party is a good trait,” said Dan Meridor, a former Likud minister. “But the problem now is the criminal accusations and the fact he is trying to stop the legal process. You can only support a leader up to a certain point.”

Meridor was one of several iconic Likudniks who did not vote for the party in the September election, saying that it had strayed too far from its roots. Another was Benny Begin, the son of Menachem Begin, founder of Herut and then Likud, the party’s longtime leader and its first prime minister. In the past, said Meridor, Likud was always a great defender of the legal system and human rights, but today that is not the case.

“People are afraid to challenge Netanyahu in this climate because they do not want to be labeled a traitor,” said one senior party member, who spoke on the condition of anonymity because of the sensitivity of the subject.

Likudniks say loyalty is in their blood. They talk with pride and pain of their time in the “wilderness,” when Likud, still headed by Menachem Begin, spent nearly 30 years on the opposition benches. Begin faced few challenges to his leadership, becoming Israel’s sixth prime minister only in 1977.

The same was true for those Likud leaders who followed — including prime ministers Yitzhak Shamir and Ariel Sharon. Each was replaced only after they chose to leave, and at this stage, Netanyahu is showing no sign of stepping down.

There have been few challenges to Netanyahu’s leadership over the years, and each one ultimately failed. Most recently, in 2014, Israel’s current ambassador to the United Nations, Danny Danon, challenged Netanyahu in the party leadership primary but won only 25 percent of the votes.

Netanyahu has consolidated his position further since then, dividing and weakening his opponents. Surveys taken after the Sept. 17 election show that if party primaries were held today, he would again win the top spot.

“Loyalty is definitely in the party’s DNA, but it is only part of this story,” said Gideon Rahat, a professor of political science at Hebrew University. “Netanyahu has created an atmosphere in which he is seen as the only possible leader. He has a firm grip on all Likud institutions and has succeeded in blocking any attempts at challenging him. Because of this there is a fear of challenging him, or challenging him at the wrong moment.”

Gideon Saar, a former education and interior minister, who quit the government in 2014 before returning to politics last year, is the only Likud member who has expressed a willingness to go head to head with Netanyahu. Last month, when Netanyahu said he was considering snap primaries, Saar tweeted that he was ready.

“When primaries are held — sooner or later — I intend to stand,” Saar, 52, said in an interview. “I welcomed it, because I thought it would be a way forward to break the political deadlock.”

Nir Barkat, 60, a former mayor of Jerusalem, said he also plans to make a bid for party leader, but only after Netanyahu has left the post.

“If we thought Netanyahu was a bad leader, then we would be challenging him now,” Barkat said. “He’s been in office for a decade, and he’s 70 years old. We wish him lots of success still, but it is certainly legitimate that some of us, including myself, are eyeing the post-Netanyahu era to see how we can run for office.”

Another likely contender for party leader at some point is Gilad Erdan, 49, a popular and relatively young figure in the party who is minister of public security and strategic affairs.

“Likud spent many years in opposition, and those were hard years for the party. Because of the dangers facing Israel and what happened in the past, when we were not in power, Likud needs to stay united,” he said, referring to the years when the Labor Party reached the Oslo peace agreements with the Palestinians.