DES MOINES, Iowa — Sen. Bernie Sanders has stepped up an undeclared war on his top rivals for the Democratic presidential nomination — and left himself open to counterattack — because it's do-or-die time for him.

Sanders, I-Vt., and his supporters are tangling with former Vice President Joe Biden over foreign policy, trade and race, and with Sen. Elizabeth Warren, D-Mass., over policy purity, elitism and whether he said a woman can't win the presidency. The skirmishes rile up his base at the expense of alienating other Democrats.

While that's a strategy that makes more sense here and in other early primary states, where a relatively small but committed army of supporters can deliver victory, it risks a severe backlash now or over the long run.

Yet Sanders' best shot starts with his taking the Feb. 3 Iowa caucuses, following up with wins in New Hampshire and Nevada and riding a wave to a majority of delegates before the party's convention in Milwaukee in July.

That is, he needs to light a fire now. The question is whether he can control the blaze.

"It becomes more and more likely that he is going to be the nominee" if he wins Iowa, New Hampshire and Nevada, said Nomiki Konst, who was a surrogate for Sanders during his 2016 bid for the nomination and served on the Unity Reform Commission, which rewrote party rules for this election.

"It really does come down to these early states," said Konst, who supports Sanders but considers herself friendly toward Warren. "If one candidate locks down the first early three states, they will most likely have the number of delegates to take the nomination based on momentum."

She added that she doesn't believe Sanders is on offense as much as other Democratic candidates are, "especially behind the scenes."

President Donald Trump seems to sense the moment for Sanders, who has seen a recent bump in polling: Trump has increasingly aimed attacks at Sanders, which could make Sanders look more viable to Democrats.

For Sanders, the basic challenge is mathematical. He is reviled by much of a Democratic Party that he has held at arm's length for most of his career. That means he can't count on forming a coalition to win the nomination if he comes up short of a majority of convention delegates — especially if he turns off Democrats who have warmed to him since his 2016 primary defeat. He has little choice but to go for a shock-and-awe campaign that overwhelms his opponents, and that starts with a fast launch in Iowa.

Let our news meet your inbox. The news and stories that matters, delivered weekday mornings. This site is protected by recaptcha

But that means Sanders' best tactic to energize and mobilize his base now could cost him more down the road.

Josh Putnam, a political scientist who runs the political blog Frontloading HQ, which tracks party nominating rules, said Sanders' strategy could deliver a knockout blow in February.

"Now, should that knockout not come, then yes, it would not exactly be helpful to him long term if he entered a contested convention with only a plurality of delegates," Putnam said. "It would make making a deal with another candidate or candidates in the lead-up to the convention and their delegates at the convention much more difficult."

In the past few weeks, Sanders and his allies have hammered his leading rivals for being too soft in their criticism of Trump's decision to kill Iranian Gen. Qassem Soleimani, placed an op-ed in a South Carolina newspaper accusing Biden of having "repeatedly betrayed black voters" and portrayed Warren as a closet elitist, a false prophet for the progressive movement and a liar.

But it's hard to live in a glass house three weeks from the first votes of 2020.

Warren said Monday that Sanders told her 13 months ago that a woman couldn't win the presidency — a story that could help peel away women who back him and create sympathy for her among 2016 voters for Hillary Clinton who believe Sanders didn't do enough to persuade his backers to stop Trump.

"Bernie and I met for more than two hours in December 2018 to discuss the 2020 election, our past work together and our shared goals," Warren said in a statement. "Among the topics that came up was what would happen if Democrats nominated a female candidate. I thought a woman could win; he disagreed."

Hours earlier, Sanders had accused Warren's aides of lying when CNN first reported that associates of hers had related the story.

"It is ludicrous to believe that at the same meeting where Elizabeth Warren told me she was going to run for president, I would tell her that a woman couldn't win," Sanders said in a statement. "It's sad that, three weeks before the Iowa caucus and a year after that private conversation, staff who weren't in the room are lying about what happened. What I did say that night was that Donald Trump is a sexist, a racist and a liar who would weaponize whatever he could. Do I believe a woman can win in 2020? Of course! After all, Hillary Clinton beat Donald Trump by 3 million votes in 2016."

Before that, the two campaigns tussled over a Politico report about a script, which Sanders' team later disowned, that portrayed Warren as an elitist, as well as the insistence of Sanders' supporters that Warren had abandoned progressive values on "Medicare for All" and other policy matters.

Download the NBC News app for breaking news and politics

That isn't the only Sanders claim of purity to draw scrutiny.

For years, establishment Democrats have raised their eyebrows at Sanders' self-description as an unstinting opponent of "endless wars."

It's true that Sanders was a leader among Democrats opposed to the 2002 resolution that authorized President George W. Bush to invade Iraq, and his record on foreign policy — which includes engagement on Latin American politics as mayor of Burlington, Vermont, in the 1980s — is on the left edge of the political spectrum.

But in 2016 and again in this campaign, his criticism of the wars has been so vociferous that he at times has seemed to suggest that he didn't favor the Afghanistan mission in the first place. In a debate in September, he said the United States should "do everything that we can to rid the world of terrorism, but dropping bombs on Afghanistan and Iraq was not the way to do it."

Sanders voted for the resolution that authorized the war in Afghanistan, which remains far more open-ended than the Iraq resolution. In a subsequent debate, he said he was "wrong" to have voted for the resolution that authorized the Afghanistan war but has given no quarter to Biden on the Iraq War vote, which Biden has called a mistake.

He also voted repeatedly for a U.S. policy of regime change in Iraq, including when he backed the Iraq Liberation Act in October 1998 and again when President Bill Clinton launched airstrikes a few months later, as pointed to by a Democrat familiar with Sanders' record.

"Saddam Hussein is a brutal dictator who should be overthrown, and his ability to make weapons of destruction must be eliminated," Sanders said on the House floor, even as he expressed reservations about civilian casualties and the efficacy of the brief military campaign.

While Sanders' more mixed record on war and peace hasn't yet become an issue, it is something that his critics have long talked about that could bubble up at any time — especially now that he's raised the temperature on the trail.

Matt Paul, who ran Clinton's Iowa caucuses operation in 2016, said candidates' mixing it up more — which would include a more visibly combative Sanders — is predictable.

"Twenty days out. It's close," he said. "No surprise here."