A child inspects the damage at U.N.-run school in Gaza that was struck on Wednesday. (Max Becherer/Max Becherer/Polaris Images For The Washington Post)

David Bosco is an assistant professor of international politics at American University. He is the author of “Five to Rule Them All: The UN Security Council and the Making of the Modern World” and “Rough Justice: The International Criminal Court in a World of Power Politics.”

The mortar shells that struck a United Nations-run school in Gaza on Wednesday, killing at least 20 Gazans — including children — and injuring dozens of others, marked the sixth time that U.N. facilities have been hit during this conflict. U.N. officials have presented these incidents as attacks on the international community as a whole. “This is an affront to all of us, a source of universal shame,” said Pierre Krähenbühl, a senior U.N. refugee official. “Today the world stands disgraced.”

While Israeli officials have never admitted intentionally targeting the United Nations, many Israelis contest the notion that the United Nations is a benign and impartial actor in Gaza, devoted only to ensuring the well-being of refugees in the territory. The Israeli government and the U.N. refugee organization for Palestinians — the U.N. Relief and Works Agency (UNRWA) — regularly trade accusations: U.N. officials have criticized Israel’s economic blockade of the territory, while Israeli officials have routinely accused UNRWA of parroting Hamas’s arguments and even being complicit in some of its activities.

The United Nations’ struggles in Gaza are an extreme version of a dilemma the global body faces in hot spots around the world: how to preserve its prized neutrality as it becomes involved in bitter conflicts with very little middle ground?

In Gaza, the bad blood has some history. During the 2008-2009 Gaza incursion, UNRWA reported that Israeli strikes damaged dozens of its facilities. In one strike, Israeli shells set fire to a U.N. warehouse, and Israel eventually paid compensation. For its part, Israel has accused the United Nations of specific misconduct, including transporting Hamas rockets in a U.N. ambulance — a charge Israeli officials later retracted. The broader Israeli critique is that UNRWA nurses Palestinian grievances and has acquiesced to the militarization of the territory by extremists such as Hamas. In 2002, a spokesman for then-Prime Minister Ariel Sharon called for an investigation of what he described as “30 years of abuse of refugee camps by the Palestinians” and the United Nations’ “bond of silence” toward it.

Animated by similar concerns, the U.S. government has conducted investigations of UNRWA’s operations on its own, and Canada recently redirected some of its funding from UNRWA to other channels. The discovery of Hamas rockets in several UNRWA schools during the current conflict — quickly condemned by U.N. officials — has only deepened the suspicions of Israel’s supporters that UNRWA is, in effect, aligned with Hamas.

The controversy surrounding the United Nations is particularly intense in Gaza but not unique to it. In some conflict zones, the United Nations has come to be seen as a proxy for one side or as the embodiment of an international policy that certain combatants reject. In these cases, the organization serves as a tempting target for extremists looking to make a point and generate headlines. Two U.N. aid workers were shot and killed in Somalia in late 2011. Earlier that year, Boko Haram militants detonated a bomb outside a U.N. building in Abuja, Nigeria, killing 21. In 2009, Taliban operatives killed five U.N. workers in Afghanistan. And most notorious, Iraqi insurgents bombed the U.N. compound in Baghdad in August 2003, an attack that claimed the lives of top official Sergio Vieira de Mello and more than a dozen others.

Of course, all humanitarian actors face challenges in maintaining wartime neutrality. But the agencies of the United Nations, including UNRWA, carry an additional burden. They are attached to a global organization that is, in fact, highly political. U.N. humanitarian operations fall under the very loose purview of the organization’s General Assembly, comprising more than 190 often fractious states. Its peacekeeping operations are directed by the 15-member Security Council. For Israelis, in particular, it is difficult to separate the United Nations’ role as a relief agency in Gaza from the hostility it perceives in the organization as a whole. Every year, the assembly and several of its subsidiary bodies pass a sheaf of resolutions criticizing Israel for its occupation and various other practices. American and Israeli diplomats have regularly complained about what they describe as a skewed and unbalanced view of Israel prevailing in Turtle Bay and Geneva.

If the United Nations struggles to maintain an image of impartiality and neutrality in its humanitarian operations, those qualities can be even more elusive when its personnel don helmets and pick up rifles. Since the late 1940s, generations of U.N. peacekeepers have patrolled conflict areas in an effort to tamp down violence. Sometimes they manage to win the trust of the key parties. But the lightly armed forces can also become a convenient target. Armed men ambushed a convoy of peacekeepers in Sudan last summer, killing seven. During the Bosnian war, Serb forces chained hapless peacekeepers to buildings to help ward off NATO airstrikes. In 1993, a Somali warlord killed two dozen Pakistani peacekeepers, triggering a chain of events that led to the “Black Hawk Down” episode and the collapse of the multinational relief operation in that country.

The seeming impotence of U.N. peacekeepers has sparked occasional efforts to make them more formidable. In a few places, most recently in Congo, U.N. forces have been transformed into combatants. Since last year, a U.N. “intervention brigade” has been rooting out extremist groups in eastern Congo. That more muscular mission has the full blessing of the Security Council, but it has made many U.N. traditionalists uneasy. If U.N. troops are active combatants, can the organization really insist that attacking its forces is beyond the pale? And if U.N. soldiers become legitimate targets, is there a danger that unarmed U.N. personnel will be drawn into the line of fire?

The Gaza crisis demonstrates that the United Nations’ ability to float above politics has long been under strain. Yet, more assertive peacekeeping and the development of the Responsibility to Protect doctrine — which insists that the international community has an obligation to safeguard civilians, even when that means confronting sovereign governments — will make remaining or appearing even-handed that much more difficult.

Twitter: @multilateralist

Read more from Outlook:

The enemy below: Why Hamas tunnels scare Israel so much

Why is the International Criminal Court picking only on Africa?

Follow our updates on Facebook and Twitter.