ISLAMABAD, Pakistan - A suicide bomber who killed five staffers at the U.N. food agency's headquarters in Pakistan yesterday was dressed as a security officer and allowed to enter the heavily guarded building after he asked to use the bathroom.

The United Nations announced it was temporarily closing all its offices in Pakistan after the noontime bombing, which blew out windows and left victims lying in pools of blood in the lobby of the three-story World Food Program compound.

"This is a heinous crime committed against those who have been working tirelessly to assist the poor and vulnerable on the front lines of hunger and other human suffering in Pakistan," U.N. Secretary-General Ban Ki-moon said in Geneva, Switzerland.

Despite the office closures, the U.N. said its Pakistani partner organizations would continue distributing food, medicine, and other humanitarian assistance.

Pakistani authorities launched an investigation into the major security lapse, saying they would question guards who failed to stop the bomber from carrying out the first suicide attack in Islamabad in four months.

The attack came a day after the new Pakistani Taliban leader met reporters close to the Afghan border, vowing more attacks in response to U.S. missile strikes on militant targets in Pakistan. Ending speculation he had been killed, Hakimullah Mehsud denied government claims the militants were in disarray and said his fighters would repel any offensive on their stronghold in South Waziristan.

Authorities blamed Islamic militants for the bombing but did not single out the Taliban. It was unclear whether militants targeted the World Food Program because of its work in Pakistan or were simply looking to kill foreigners or those working with them. The dead were four Pakistanis and an Iraqi.

Extremists in Pakistan, Afghanistan and Iraq seeking to attack high-profile Western targets have shown no hesitation in striking foreign humanitarian agencies, including the U.N., regardless of the work they are doing in relieving the suffering in the countries. A blast in June on a luxury hotel housing many foreign aid workers in Peshawar killed two U.N. staffers.

Sometimes the very nature of their work invites attack. In yesterday's bombing, insurgents may have believed that by feeding refugees from the fighting in the Swat valley, the WFP is propping up a Pakistani government they see as a U.S. puppet.

The U.N. and various humanitarian agencies, including those funded by the U.S., expanded in Pakistan over the last year to help support its elected government.

The U.N. considers itself a major target in Pakistan. Many of its offices are surrounded by 12-foot-high blast walls. Its staff members are driven in bulletproof cars and not allowed to bring their families with them on assignment in the country.

"This was one of the best-protected U.N. centers in all of Pakistan," said U.N. spokeswoman Michele Montas.

Taliban and allied militants have carried out scores of suicide attacks in Pakistan over the last 21/2 years. Under U.S. pressure, Pakistani security forces have had some success combatting the extremists. Hakimullah's predecessor, Baitullah Mehsud, was killed in a U.S. drone strike in August.

Yesterday's bombing was one of at least four major strikes in the last three weeks appear to show Pakistani militants are regrouping and have the capacity to carry out attacks. It took place in a well guarded, upscale residential area close to where President Asif Ali Zardari has a home.

Hassan Abbas, a former official in the Bhutto and Musharraf governments, said the attack is significant because it shows militants can still breach high security zones.