At least 18 Afghans -- including a policeman and several children -- were killed in two deadly suicide attacks, one of which struck the city of Kabul as newly appointed Secretary of Defense Chuck Hagel was visiting a nearby military base.

The first attack happened around 9 a.m. Saturday outside the gate to the Afghan Ministry of Defense headquarters in Kabul.

According to General Zahir Azimi of the Afghan National Army, the suicide attacker rode a bicycle towards the gate before detonating his explosives.

Nine civilians were killed in the attack.

The aftermath of the scene was chaotic. The explosion was so strong it left large shrapnel holes in nearby concrete blast walls.

While ambulances rushed in, sirens wailing, to reach the wounded, Afghan soldiers in full body armor quickly cordoned off the area.

Eyewitnesses report hearing several rounds of gunfire after the initial explosion, though it is unclear whether Afghan soldiers were firing at a specific target.

"I was near the Defense Ministry compound when there was a powerful explosion," Abdul Ghador, an eyewitness, said.

"I saw dead bodies and wounded victims lying everywhere. Then random shooting started," he said. "It was a very powerful explosion and there were a lot of vehicles in the area."

Hagel was in the middle of a security briefing at a nearby military base when the explosion went off.

According to a Pentagon spokesperson, the briefing continued uninterrupted.

Reporters traveling to Kabul to cover Hagel's visit -- his first official visit as Secretary of Defense -- were in the middle of a briefing at Camp Eggers, a different military base from the one where Hagel was at, when the explosion occurred.

They were whisked to a secure room in the basement while the base was put on lockdown.

"We're in a warzone," Hagel later told reporters. "I've been in war, so shouldn't be surprised when a bomb goes off or there's an explosion."

A Taliban spokesman quickly claimed responsibility for the attack.

"The attack was a message to him," Zabiullah Mujahid said in an email.

Half an hour after the Kabul explosion, a suicide bomber struck a joint Afghan patrol in Khost province.

One policeman and eight teenage boys on their way to school were killed in the attack.