When security officials tried to enter, they came under fire from gunmen and a woman barricaded in the basement. Three intelligence officials were killed in the ensuing battle. The security forces finally set off explosives, which killed all those inside  two men, a woman and a child  Mr. Saleh said.

In addition to the militant Homayoun, the two other adults killed in the house were a married couple and were not Afghan, Mr. Saleh said. He said he suspected that the child would have also been used in a suicide attack they were planning in Kabul. The group had been armed with guns, rocket-propelled grenades, mines and suicide vests, he said.

Six others suspects were arrested in a village on the eastern edge of the capital, he said, adding that another raid in a suburb of eastern Kabul was under way.

Interior Minister Zarar Ahmad Muqbil said that his ministry had been watching a group of police officers suspected of involvement in the attack on the Serena Hotel and that they had been arrested. Mr. Saleh said none of the suspects arrested were from the intelligence service.

The group members killed inside the house had been in telephone contact with people in Miram Shah, the capital of North Waziristan, as well as Bajaur, another tribal region of Pakistan, and with people in Peshawar, the capital of Pakistan’s North-West Frontier Province. They were using Pakistani subscriber identity module cards in their cellphones, Mr. Saleh said.

“Some contacts were made back and forth, and we have some evidence that they were receiving orders from the other side of the border until the last moments,” he said. “Whether these orders were given through the government of Pakistan, we have no evidence,” he added.

On Monday, Mr. Saleh told Parliament that the group of three gunmen who fired on the parade just as Mr. Karzai was preparing to speak had also been in contact with a central base through text messages, and that they were being urged to carry out their task.