The attack was linked to the recent detention of a man allegedly involved in last month's assassination of the head of one of the city's security agencies, National Security chief Colonel Farag el-Dersi, according to a police spokesman.
Unknown assailants attacked the security compound in an apparent attempt to break into a nearby detention centre where the suspect in Mr el-Dersi's killing is being held.
In Benghazi, where the revolt that unseated long-time ruler Muammar Gaddafi began last year, security has sharply deteriorated over the past year. An attack in September on the US Consulate killed US ambassador to Libya Chris Stevens and three other Americans.
The decision affects cities such as Kufra and Sabha, which have been the scene of armed clashes this year that have left more than 100 dead. The fighting has been mainly between the African tribe of Tabu and their rivals, the Arab tribe of Zwia.
General National Congress spokesman Omar Humidan said parliament voted to seal Libya's southern borders with its African neighbours to stem the flow of illegal immigration and population changes.
The African Tabu, the original inhabitants of south Libya, were heavily suppressed under the Gaddafi regime. They accuse the new government of continued discrimination.
The GNC did not specify how long border crossings would be sealed or how Libya's military plans to secure the long and porous border. The military does not have a strong presence along the southern border and is struggling to rebuild itself - relying heavily on former rebels as part of its force - after last year's civil war that ousted Gaddafi.
A military source said the government's main concern is not the influx of people but the illegal flow of weapons. A flood of arms, including explosive warheads and small arms ammunition, have been smuggled from Libya to Egypt since the outbreak of revolutions in both countries last year. The weapons have fallen into the hands of Islamist militants in the Sinai Peninsula, or pass through smuggling tunnels to the Gaza Strip.