Two people were wounded in a gunfight that broke out at a Tripoli checkpoint between former rebels who fought to overthrow Moamer Kadhafi, a security official said Tuesday.

The fighting erupted after security forces stopped a car with tinted windows carrying members of a brigade that had fought in the city of Misrata during the 2011 uprising, according to Hashem Besher, head of a unit of former rebels under the authority of the interior ministry.

"The unit arrested one of the passengers in the car after a dispute. His friends then came to his rescue," he said.

One man from each side was wounded in the ensuing firefight, including the leader of the Misrata brigade.

An army spokesman contacted by AFP said he had no information about the fighting and a defence ministry spokesman was not immediately available for comment.

Misrata saw some of the most vicious fighting of the 2011 uprising that toppled Kadhafi, and much of the seaside city was reduced to rubble.

Gunfire rang out across Tripoli for more than three hours during the night, witnesses said. Besher said the city's various militias were firing warning shots intended to "maintain pressure."

Libya's post-Kadhafi government has struggled to rein in former rebels who have formed powerful militias that effectively control much of the country.

Recent security efforts include a crackdown on cars with tinted windows and no license plates.