Excellent, rate the movie R.
The only problem with this episode is the overall logic, but that's something that can be ignored while its playing.
In reality, if any President got tens of thousands of Americans killed to save a foreign head of state, she would be impeached (or assassinated) asap and replaced by some ranting, vengeance-fuled warmonger who would make George W. Bush look like Michael Moore. That scenario would be a gold-plated gift to the Palin/Beck ticket and Fox News.
And anyone who managed to get herself elected President would be politically savvy enough to know that. The Prez is being depicted as unrealistically idealistic and naive, but I guess the screenwriters like that particular little fantasy, and it's innocuous enough.
Be willing to sacrifice tens of thousands of American citizens in the hope your people can find the terrorists in time and for the first real chance of ending the Middle East Cold War while simultaneously making real headway in the never-ending Terror War.
OR
Hand over an allied head of state to the terrorists in the hope they won't kill those tens of thousands anyway, almost certainly torpedo the peace process when they execute Hassan and plunge the world into further decades of war, undermining your relationship with every other allied nation, who all now question whether they'd get thrown under the bus like the IRK if the terrorist threat was big enough.
Neither of those options look like they're the right one to me, really, but the first one feels more right.
Logan faced the very same question on Day 6, chose the second option and very nearly triggered World War III for it. I don't recall anyone defending his actions back in the day. Course, he was a Republican. And Republicans are evil.
Taylor is likely a Republican too. (The Palmers were Democrats and Taylor beat W. Palmer's VP for the presidency.)