The attack on a US consulate in Benghazi and protests at the US embassy in Cairo on Tuesday prompted US President Barack Obama to call on Wednesday for increased security at diplomatic facilities. In remarks delivered from the White House Rose Garden, Obama said that he had told his administration "to increase our security at diplomatic posts around the world."

Those measures include dispatching 50 Marines, who headed to Libya on Wednesday to fortify diplomatic compounds there, the Associated Press reported. The Marines are members of an elite group known as FAST, or Fleet Antiterrorism Security Team. They respond quickly to terrorism threats and security threats at US embassies.

In his speech, Obama had said that the Libyan government is also involved in increased security efforts. "We're working with the government of Libya to secure our diplomats," the president said.

How secure are US diplomatic compounds to begin with? That depends on where they are, according to Austin Long, an assistant professor at Columbia University's School of International and Public Affairs who has experience consulting with the US government.

More from GlobalPost: Who was US Ambassador Chris Stevens?

"Measures of security vary, but typically include a detachment of Marine Security Guards (MSG) working with officers from the State Department's Diplomatic Security Service (DSS)," Long wrote in an e-mail to GlobalPost. "The physical protection varies more, from fairly unobtrusive walls and heavy flower planters, much like the protection around federal buildings in DC, to the elaborate layers of checkpoints and barriers surrounding US Embassies in Pakistan and Afghanistan."

Decisions about the levels of security required for a given location are based on perceptions of threat, "balanced by the desire not to make every embassy look like an unapproachable 'Fortress America,'" Long wrote.

A former State Department counterterrorism agent speaking to CNN echoed that idea, emphasizing the calculations officials make to anticipate, but not invite, threats. "It's never a matter of getting rid of risk. It's a matter of managing risk, and that is a very tough thing to do," Fred Burton told CNN.

Security responsibilities are also shared by the US and the host nation, which affects overall risk the US post may face. Security outside embassies is the responsibility of the host country, CNN reported.

According to Long, that has made some US installations vulnerable in the past.

"For example, in 1979 the US embassies in both Pakistan and Libya were burned down by mobs, and neither government made timely moves to stop the mobs. Other times, such as in Greece in 2007, it is simply too difficult to stop all attacks," he wrote.

"In the case of Libya it seems the latter was the case, with the Libyan government too weak to prevent the attack. Egypt seems more mixed, with the Egyptian government responding, but slowly," Long said of the breaches that occured Tuesday.

More from GlobalPost: A clash of civilizations? Not so much

Could the US be doing more to protect foreign service representatives abroad? Some say that the consulate in Benghazi was inadequately protected, especially when compared with the US Embassy in Tripoli.

Reuters has reported that militants even knew where the consulate's supposed safe-house was, prompting a deadly shootout.

But heavily fortified US posts abroad carry their own risks. The US military's most famous protected area is doubtless the Green Zone in Baghdad, a tightly controlled military area set up after the 2003 invasion that still operates to a more limited extent today, albeit under the jurisdiction of Iraqis.

This world-within-a-world contained the US Embassy, facilities for soldiers, and businesses and shops that operated separately from greater Baghdad — a division that would fuel opposition to the US mission in Iraq. The Green Zone mostly did its job, although as an obvious symbol of unwelcome foreign presence in Iraq, it was regularly attacked, sometimes with deadly consequences.

There's also the US Embassy in Kabul, which is closely guarded — but vulnerable to attack, too, as evidenced by Taliban strikes against the facility almost exactly a year ago. Although the attack was stopped within about five hours and no Americans were killed, seven Afghans died in the fighting and a rocket managed to penetrate the Embassy compound.

Suicide bombers also continue to target the facility: last week, an attack killed six near NATO headquarters in Kabul, close to the US Embassy.

Attempts to strike a balance between security and appearance in US diplomatic facilities has been an ongoing concern. The Washington Times reported earlier this year that the State Department has undertaken an "aggressive new overseas building program" to try to merge enhanced security with approachable designs.

More from GlobalPost: Full coverage of the embassy attacks

Sign up for our daily newsletter

Sign up for The Top of the World, delivered to your inbox every weekday morning.