The ministry gave no further details.
A Nato spokesman confirmed the shooting and the casualties.
"We can confirm there was small arms fire during this incident, we're also aware that there are some Isaf casualties," said International Security Assistance Force spokesman Maj Tim James.
"We believe the incident has now concluded and we don't know how the shooting started."
Witnesses reported hearing sirens and seeing a heavy military presence near the facility, which generally has tight security.
The Taliban claimed responsibility for the incident in a text to the Associated Press news agency, but the authorities have not confirmed any insurgent activity.
Correspondents say rapid recruitment into the Afghan military has raised fears of Taliban infiltration into the police and army.
Nato's exit strategy for Afghanistan involves progressively handing over to the local security forces.
But there have been a number of attacks recently on foreign forces by Afghan security personnel.
The deadliest was last November when an Afghan policeman killed six US soldiers.
And two Nato soldiers were shot dead by an Afghan border policeman in northern Faryab province on 4 April, local officials said.
The BBC's Quentin Sommerville in Kabul says foreign troops broadly but not totally trust their Afghan colleagues and feel they have to keep half an eye on them.