By remaining calm despite Israeli bluster over Iran. Barack Obama has helped himself, and also helped Israel's Benjamin Netanyahu.
Obama walks line between Israel, war and a nuclear Iran
President Barack Obama insisted on Sunday that his track record in the White House has proved beyond doubt "that when the chips are down, I have Israel's back". And then he proved the point, not only through the litany of examples he offered in that speech to the Israel lobby, but by the position he took on Iran.
Mr Obama vowed to use military action, if necessary, to prevent Iran obtaining a nuclear weapon, yet made clear that the situation was nowhere near that point. And in doing so, he may have pulled Prime Minister Benjamin Netanyahu's chestnuts out of the fire at the same time as reducing the risk of war.
Hype notwithstanding, Mr Netanyahu came to Washington on Sunday having painted himself into a corner on Iran. Israeli officials spinning the media ahead of his arrival portrayed a confident and determined Israeli leader coming to demand - with the support of the watching Israel lobby, while jeering Republicans tried to use the Iran issue to weaken Mr Obama's reelection prospects - that the American president either man up to Iran or step aside and let Israel do it.
Mr Netanyahu had for years used apocalyptic language and sabre rattling to press the US and other western powers to harden their stance on Iran, always telling them that each new round of sanctions wouldn't be sufficient and that Israel would launch a military attack if western powers failed to bring Tehran to heel.
But the more Israel has amped up its threat of war, the more diplomatically isolated it has become. None of the western powers most active in pressing sanctions back Israel starting a war over Iran's nuclear work, and as the sabre-rattling has grown more shrill in recent months they have devoted increasing diplomatic attention to restraining Mr Netanyahu from doing something stupid.
Opinion polls show only one in five Israelis supports attacking Iran without US backing, while Israel's top military and intelligence leaders believe it would be a mistake to go to war under present circumstances. But Mr Netanyahu can't easily dial back his belligerence without, in his own mind, showing Iran that Israel is not serious about military action - and without endangering his domestic political position.
Having recklessly inflated the threat of Iran's nuclear programme to Israelis with wild talk of a new Holocaust, he has created pressure on himself to take action. Yet Mr Netanyahu is a risk-averse leader, who has never started a war and is unlikely to roll the dice on military action involving such deep risk, and such limited gain, against the advice of his military chiefs, who are well aware of the limits of Israeli air power against Iran's nuclear facilities.
Mr Netanyahu would prefer the US to do the job, but the Obama administration has made clear there's no chance of that happening on the basis of Israel's timeframe and red lines. Mr Obama, in his Aipac speech, vowed to take military action if necessary to keep nuclear weapons out of Iran's hands, but at the same time he pointed out that Tehran - by common US-Israeli assessment - hasn't yet decided to build nuclear weapons. Israel's best interests, he argued, were better served by a strategy of pressure and engagement than by launching a potentially disastrous strike that could slow Iran but make it more likely to launch a covert weapons programme.
"Already, there is too much loose talk of war," Mr Obama warned in an unmistakable rebuke to Mr Netanyahu, pointing out that it was driving up oil prices and benefiting Iran. "For the sake of Israel's security, America's security, and the peace and security of the world, now is not the time for bluster."
Mr Netanyahu, in his own speech, mocked the Obama administration's reasoning, and offered plenty of blood-and-fire bluster. But that may simply be an effort to keep domestic pressure on the US president, whose focus in the months ahead will be on sanctions and diplomacy. "The only way to truly solve this problem," Mr Obama said, "is for the Iranian government to make a decision to forsake nuclear weapons".
Mr Netanyahu demanded that Mr Obama state his red line; Mr Obama said he'd use military force to prevent Iran obtaining a nuclear weapon, not before.
Israel's red line is different; it has insisted that Iran can't be allowed to possess even the civilian nuclear infrastructure that would enable it to build a bomb - infrastructure Iran already has. Denying Iran infrastructure to which it is entitled under the Nuclear Non-Proliferation Treaty once it has satisfied concerns (over its intent and met safeguard requirements against weaponisation) is an implausible diplomatic outcome.
Mr Netanyahu didn't get what he wanted. But he may have walked away with what he needed: Political cover for refraining from starting a war that he has good reason to want to avoid.
He left his White House meeting with Mr Obama expressing satisfaction that he'd managed to "put the Iran issue on the international order of priorities". He also made much of the idea that it's up to him to decide, that Israel won't seek permission from the US to strike Iran.
At the same time, Mr Netanyahu stressed, Israel hasn't decided to do so, and says simply - once again - that time is running out. But of course, Mr Netanyahu doesn't want to act alone against Iran, right now at least, as much as to keep alive the idea that he might do so for the pressure that puts on all the key players.
And in a quiet moment the Israeli leader might permit himself a little chuckle of contentment, recalling the old days when the key topics of discussion on his visits to the Obama White House were settlements, 1967 borders and the Palestinians. Back then, Mr Netanyahu insisted Iran should top their agenda. Now, they're not talking about much else.
Tony Karon is an analyst based in New York
Follow on Twitter: @TonyKaron