Libya has demanded an explanation for the "kidnapping" of one of its citizens by American special forces, hours after a separate US military raid on a terrorist target in Somalia ended in apparent failure and retreat. 
 
 In Tripoli the US army's Delta force seized alleged al-Qaida leader Nazih Abdul-Hamed al-Ruqai, known by his alias Abu Anas al-Liby and wanted for the 1998 bombings of the US embassies in Kenya and Tanzania that killed more than 220 people. 
 
 The New York Times reported that Liby was being held in military custody and interrogated on board a navy ship, the USS Antonio, in the Mediterranean. 
 
 But US navy Seals suffered a major setback when they launched an amphibious assault to capture an Islamist militant leader said to be Ahmed Godane, described as Africa's most wanted man and the architect of last month's attack on the Westgate shopping mall in Kenya. The elite Seals were beaten back by heavy fire and apparently abandoned equipment that the Somali militants photographed and posted on the internet. 
 
 As dramatic details of Saturday's twin operations emerged, US secretary of state John Kerry insisted that terrorists "can run but they can't hide" , but faced growing questions about America's military reach in Africa and the consequences of unilateral aggression. 
 
 Speaking in Indonesia on Monday, Kerry said the seizure of Liby complied with US law, the Associated Press reported. He said the suspect was a "legal and appropriate target" for the US military and would face justice in court. It was important not to "sympathise" with wanted terrorists, Kerry said. 
 
 Liby was captured outside his family home at 6.15am in Noufle'een, a quiet suburb in eastern Tripoli, according to witnesses, but there were conflicting reports over who took him. His brother, Nabih, told the Associated Press that Liby was parking when a convoy of three vehicles encircled his car. Armed gunmen smashed the car's window and seized Liby's gun before grabbing him and taking him away, the report said. The brother said Liby's wife saw the kidnapping from her window and described the abductors as foreign-looking armed "commandos". 
 
 But Liby's son Abdullah insisted Libyan forces were involved. Appearing on Tripoli's Nabir TV station, he said: "The people who took my father were Libyan, not Americans – they spoke with Tripoli accents. 
 
 "My mother was listening to the voices in the street and could see it all through the window. There were two cars and a bus with blacked-out windows and no number plates." 
 
 He said his father was dragged from his car and arrested while it was still moving, and the vehicle, driverless, continued driving empty down the road. 
 
 Liby, who was thought to be a computer specialist for al-Qaida and lived in Manchester in the UK during the 1990s, is believed to be 49 and on the FBI's most-wanted list with a $5m (£3m) bounty on his head. Pentagon spokesman George Little said he is "currently lawfully detained by the US military in a secure location outside of Libya". 
 
 Liby was expected eventually to be sent to New York for criminal prosecution, the New York Times reported. 
 
 Libya's government refused to say whether its forces were involved in the arrest and claimed it had not been informed in advance. A statement from the prime minister, Ali Zaidan, said: "The Libyan government is following the news of the kidnapping of a Libyan citizen who is wanted by US authorities. The Libyan government has contacted US authorities to ask them to provide an explanation." 
 
 Thousands of miles away in Somalia, US special forces carried out a raid that was no less audacious but had a very different outcome. It was reportedly planned a week and a half ago in response to the Nairobi attack and came 20 years to the week after an American mission that infamously went awry when Somali fighters shot down two Black Hawk helicopters. 
 
 Members of Seal Team Six – the unit that killed al-Qaida leader Osama bin Laden in his Pakistan hideout in 2011 – swam ashore from speedboats before members of the Islamist militant group al-Shabaab rose for dawn prayers, officials and witnesses said. They stormed a two-storey beachside house in Barawe said to be occupied by foreign members of al-Shabaab and battled their way inside, a fighter who gave his name as Abu Mohamed told AP. There was a heavy gunbattle at about 2.30am on Saturday, according to locals in Barawe, about 60 miles south of the capital Mogadishu. Mohamed Hassan, a schoolteacher, said: "Nearly an hour before the morning prayer I heard dogs bark and I got up, but within minutes I heard small gun fire towards the direction of the beach. I raised my ears up as the shooting continued and continued. Soon it became like an exchange of fire. Then I heard one big explosion and two other explosions occurred. I could not go outside so I remained in my room to wait what was happening." 
 
 Hassan said the shooting he could hear was that of al-Shaabab's fighters because he understood the US forces were using silencer guns so no one could hear their shooting. "In the morning, we saw people gathering near the house the US forces targeted and there was a lot of blood everywhere. The al-Shabaab fighters told us not to go to the direction of the house. I saw one dead and two others injured but they were not very critical." 
 
 No one in Barawe town could have imagined such an attack, he added, and they kept saying only "white soldiers attacking Barawe town". Local residents said late on Saturday that al-Shabaab deployed additional fighters in Barawe to keep guard at the beach where the navy Seals landed. 
 
 US officials told AP that the Seals encountered fiercer resistance than expected, so after a 15- to 20-minute firefight, the unit leader decided to abort the mission and they swam away. 
 
 A local resident, Haji Nur, said he saw military equipment which al-Shabaab claimed to have confiscated from the soldiers. "I saw in the centre of the town a crowd of people gathering and looked at three rounds of M16 ammunition, one US-made hand grenade and one also a bulletproof jacket." 
 
 Al-Shabaab, which has a formal alliance with al-Qaida and claimed responsibility for the Nairobi mall killings that killed at least 67 people, posted what it claimed were pictures of the equipment on the web. 
 
 Sheikh Abdiasis Abu Mus'ab, a spokesman for al-Shabaab, said: "Early on Saturday morning, around 2am, white soldiers attacked a house resided in by some members of the Mujahideen leaders in Somalia. They came from a waiting speedboat from warship and as they were approaching the house, our Mujahideen fighters repulsed them. They ran away. We chased them until they have reached the seaside where they urgently boarded their speedboats." 
 
 Mus'ab said one al-Shabaab member had died and claimed that the Seals lost a "senior officer". US officials said there were no US casualties in either the Somali or Libyan operation. 
 
 A resident of Barawe who gave his name as Mohamed Bile told the AP that militants closed down the town in the hours after the assault, and that all traffic and movements have been restricted. Militants were carrying out house-to-house searches, likely to find evidence that a spy had given intelligence to a foreign power used to launch the attack, he said. 
 
 A Somali intelligence official was quoted as saying that Godane, the al-Shabaab leader also known Mukhtar Abu Zubeyr, was the target of Saturday's raid. Mohamed Ansari, a former al-Shabaab member now working with Somalia's counter-terrorism unit in Mogadishu, said: "Godane is the only big fish in Barawe to hunt. Godane as the top leader of al-Shabaab and the only planner of the group's operations is seen as the mastermind of Westgate mall siege in Nairobi." 
 
 Unlike his Libyan counterpart, Somali prime minister Abdi Farah Shirdon welcomed the US intervention. "We have close cooperation with the world, especially the western countries in the fight against al-Shabaab," he said in Mogadishu on Sunday. "We welcome any operation to hunt the terrorist leaders and we are at the forefront. Al-Shabaab is a Somali problem, a regional problem and world problem." 
 
 The dual raids were a vivid of expression of how the US has quietly been building its military capacity in Africa. Kerry, who is in Indonesia for an economic summit, said: "We hope that this makes clear that the United States of America will never stop in the effort to hold those accountable who conduct acts of terror. Members of al-Qaida and other terrorist organisations literally can run but they can't hide." 
 
 But a diplomatic source focused on Somalia said: "This is knee-jerk stuff and smacks of a massive failure of intelligence. Are extrajudicial killings and covert kidnapping raids the best way of dealing with the problem? Why is the international response so feeble?" 
 
 But Dr Adekeye Adebajo, executive director of the Centre for Conflict Resolution in South Africa, said that while it was in the interest of African governments to fight terrorism, he does not "think the heavy-handed and unilateral way the US acts is helpful and it risks causing further instability, especially where there are weak governments like in Libya and Somalia". ||||| The capture of an alleged al-Qaeda operative outside his home by Special Operations forces in Tripoli on Saturday and his secret removal from Libya was a rare instance of U.S. military involvement in “rendition,” the practice of grabbing terrorism suspects to face trial without an extradition proceeding and long the province of the CIA or the FBI. 
 
 U.S. officials hailed the capture of Nazih Abdul-Hamed al-Ruqai, who was wanted in connection with the 1998 bombings of the U.S. embassies in Tanzania and Kenya, as an intelligence coup that will disrupt efforts by al-Qaeda to strengthen its franchise in North Africa. 
 
 The raid in Tripoli came hours after U.S. Navy SEALs stormed a beachside compound in Somalia in a failed attempt to nab a senior militant leader from the East African country’s al-Qaeda franchise, known as al-Shabab. The two operations suggested that the Obama administration, which has been criticized for its heavy use of drone strikes against terrorism suspects, is increasingly willing to deploy ground troops, despite the risks, to seize high-value targets. 
 
 “These operations in Libya and Somalia send a strong message to the world that the United States will spare no effort to hold terrorists accountable, no matter where they hide or how long they evade justice,” Defense Secretary Chuck Hagel said in a statement. “We will continue to maintain relentless pressure on terrorist groups that threaten our people or our interests, and we will conduct direct action against them, if necessary, that is consistent with our laws and our values.” 
 
 The Libyan government on Sunday condemned what it called the “kidnapping” of one of its citizens after Ruqai, known by the alias Anas al-Libi, was forced out of his car and bundled away by men his brother described as foreign-looking “commandos.” 
 
 U.S. forces announced that they captured Nazih Abdul-Hamed al-Ruqai, known as Abu Anas al-Liby, who was indicted in 2000 in the 1998 bombings of the U.S. embassies in Kenya and Tanzania. (Handout/Getty Images) 
 
 Addressing the Libyan complaints, Secretary of State John F. Kerry called Ruqai “a key al-Qaeda figure.” 
 
 “He is a legal and an appropriate target for the U.S. military,” Kerry said, and will face trial in an American court. 
 
 Kerry, speaking Monday on the sidelines of the Asia-Pacific Economic Cooperation forum in Bali, Indonesia, gave no details about what the Libyans were told or when. 
 
 “We consult regularly with the Libyan government on a range of security and counterterrorism issues but we don’t get into the specifics of our communication with foreign governments on any kind of operation of this kind,” Kerry said. 
 
 As to the perception that the capture may mark a return to U.S. terrorism policies that were widely reviled around the world, Kerry stressed that Ruqai will be tried and is legally innocent until proven guilty. 
 
 “I hope the perception is in the world that people who commit acts of terror and who have been appropriately indicted by courts of law, by the legal process, will know that United States of America is going to do anything in its power that is legal and appropriate in order to enforce the law and to protect our security,” Kerry said. 
 
 As they celebrated Ruqai’s detention, administration officials on Sunday were largely silent on a strike, which apparently failed, by Navy SEALs on a terrorist target in Somalia. SEALs stormed the suspected hideout of an al-Shabab leader Friday night, seeking to detain a senior operative of the group. 
 
 A U.S. military official, speaking on condition of anonymity to discuss a sensitive mission, said the target of the Somali raid was Abdulkadir Mohamed Abdulkadir, a Kenyan national of Somali descent and a suspected leader of al-Shabab. 
 
 The military official said the goal of the operation was to capture Abdulkadir, but that the Navy SEAL team decided to withdraw after encountering heavy fire and concluding that it would be too difficult to take him alive. The team was also concerned that the risk of inflicting casualties on innocent bystanders had become too high. 
 
 “It was a capture mission, and when it became evident that we couldn’t capture him alive, the team decided” to withdraw, the official said. “If we wanted to kill this guy, we have lots of ways to do that.” 
 
 The operation followed last month’s brazen attack on an upscale mall in Nairobi by al-Shabab that killed dozens of people and raised concerns about the reach of a group that had appeared to be in retreat and focused on Somalia. 
 
 A former U.S. Special Operations operative familiar with Somalia policy said that the seaside town of Baraawe, where Friday’s raid took place, has become a key hub for senior al-Shabab leaders after they lost control of other areas. The group exports charcoal from the town, which represents an important source of revenue. 
 
 “It’s where the leadership hangs out,” said the official, who spoke on the condition of anonymity to describe U.S. intelligence. 
 
 U.S. officials said both operations were lawful under war powers that Congress granted the executive branch after the Sept. 11, 2001, terrorist attacks. 
 
 Officials also noted that Ruqai is on a U.N. sanctions list and has been indicted in federal court in New York. They suggested that intelligence personnel are eager to interrogate him. 
 
 Ruqai is currently being held on the USS San Antonio, an amphibious transport dock ship, in the Mediterranean Sea, according to two U.S. officials, who spoke on condition of anonymity because they were not authorized to speak about the matter. 
 
 The closest historical parallel to Ruqai’s capture, U.S. officials said, was the April 2011 detention of Ahmed Warsame, a Somali who was accused of acting as a liaison between the al-Qaeda branch in his native country and one in Yemen. Warsame, who was seized aboard a fishing vessel in the Gulf of Aden, pleaded guilty in late 2011 in federal court to providing material support to terrorist organizations. 
 
 Warsame was held secretly at sea on a U.S. Navy vessel for 40 days and questioned by an interagency interrogation unit led by the FBI before being flown to New York for arraignment. 
 
 Robert Chesney, an expert in national security law at the University of Texas, said that because Ruqai’s detention was immediately disclosed — unlike Warsame’s — the Obama administration will probably come under pressure to bring him before a judge in New York quickly. 
 
 “The longer you hold him, the trickier it gets,” Chesney said, noting that a prolonged military detention could become problematic for federal prosecutors in a civilian court. 
 
 Libya’s government said in a statement issued Sunday that it had not been consulted before U.S. troops snatched Ruqai. 
 
 “Since hearing the news, the Libyan government has been in contact with American authorities and has asked them to offer clarification,” the government said, arguing that Libyans who face terrorism charges should be tried at home. 
 
 The government noted, though, that it deems its relationship with the United States a “strategic partnership” that would not be imperiled by Saturday’s operation. 
 
 Since the 2011 civil war that toppled the regime of Moammar Gaddafi, Libya has been wracked by lawlessness, growing extremism and sporadic outbreaks of violence between rival militias. The country’s newly elected government wields little authority across the oil-rich country, where militias established during the conflict continue to hold the bulk of weapons and power. 
 
 Even Libya’s military leaders, who have received counterterrorism training and funding from the United States, expressed surprise at an operation that was, in some respects, reminiscent of the CIA’s rendition of terrorism suspects during the years that followed the Sept. 11, 2001, attacks. 
 
 “We found out from media outlets just like everybody else,” said Aly Sheikhi, a spokesman for the Libyan armed forces chief of staff. He said he had no additional information about the incident. 
 
 Unlike former CIA captives, however, Ruqai will be brought before a federal criminal court relatively quickly and will not be held incommunicado indefinitely or turned over to a third country for interrogation, a policy know as “extraordinary rendition.” 
 
 After he assumed office, President Obama barred the use of extraordinary rendition but reserved the right to capture and render some suspects for trial in the United States. 
 
 A U.S. official declined to say whether the Libyan government had been notified in advance of Saturday’s operation, but the official added that Washington considers the new government in Tripoli “a partner in the fight against al-Qaeda.” 
 
 The official, who spoke on the condition of anonymity to discuss a covert operation, said that Ruqai’s capture is seen as a significant victory because he was thought to be pivotal to the resurgence of al-Qaeda’s North Africa branch. The official would not say whether Ruqai was transported out of Libya by sea or air. He also declined to say where Ruqai is being held or when he might be arraigned in federal court. 
 
 “We’re interested in what he has been doing since those times,” said the official, referring to the 1998 attack. “There are concerns that he has attempted to grow al-Qaeda’s capabilities in North Africa.” 
 
 The reemergence of Libya-based jihadists intent on striking Western targets has been a top U.S. intelligence priority since the Sept. 11, 2012, attack on American government installations in the eastern city of Benghazi. 
 
 Craig Whitlock and Rajiv Chandrasekaran in Washington, Abigail Hauslohner and Lara El Gibaly in Cairo, and Anne Gearan in Bali, Indonesia, contributed to this report.
– Has the capture of an al-Qaeda commander damaged relations with Libya? A statement from the Libyan government describes the Tripoli raid that nabbed Nazih Abdul-Hamed al-Ruqai as a "kidnapping" and demanded answers from the US, reports the Washington Post. In response, John Kerry described the Libyan, who is known by his alias Abu Anas al-Libi, as "a key al-Qaeda figure" who is a "legal and an appropriate target for the US military" and will face trial in an American court. The US regularly consults Libya on counterterrorism issues, but "we don’t get into the specifics of our communication with foreign governments on any kind of operation of this kind," said Kerry. Despite the Libyan government's apparent anger, some witnesses, including the suspect's son, say the raid was carried out by Libyan agents, the Guardian reports. "The people who took my father were Libyan, not Americans—they spoke with Tripoli accents," the son says. The suspect, believed to have played a major role in the 1998 embassy bombings, is now believed to be on board a Navy vessel for interrogation.