Peshawar, Pakistan (CNN) -- A confrontation between gunmen and security forces near the U.S. Consulate in Peshawar, Pakistan, ended Saturday after the militants surrendered, a Pakistan military spokesman said.
Maj. Gen. Athar Abbas said the militants were taken into custody and two Pakistani security guards who were taken hostage have been freed. There were no casualties in the incident.
The gunfire started sometime between 5 a.m. and 6 a.m. (8 p.m. and 9 p.m. ET Friday) about 100 meters from the U.S. consulate, near military barracks and several other military and intelligence buildings.
All consulate employees are fine and the consulate did not appear to be the target of the attack, said Rick Snelsire, a spokesman for the U.S. Embassy in Pakistan.
Security forces cordoned off the area where the standoff was taking place, intelligence officials said
Later Saturday, the militants were holed up in a building and surrounded by security forces, Provincial Minister Bashir Bilour said in comments broadcast on several Pakistani television networks.
It was not clear how many gunmen were involved.
The consulate tightened security Saturday morning as a precaution, Snelsire said.
CNN's Reza Sayah contributed to this report.