Several armed men attacked the headquarters of the National Oil Corporation (NOC) in the Libyan capital on Monday and several blasts could be heard, a Reuters witness said.
Gunfire could be heard as a security force allied to the Tripoli-based government arrived at the landmark building located in central Tripoli.
The NOC building is covered mainly in glass, and a witness said several people had been wounded by shattered windows.
Smoke could be seen rising as security forces took up positions around the offices in central Tripoli and surrounding roads were cordoned off.
A Reuters witness saw ambulances leaving the site.
A member of staff from a hotel next to the NOC offices said he had heard about five blasts.
Tripoli was shaken by clashes between rival armed groups at the beginning of this month but the capital has also seen occasional militant attacks.
In May, Islamic State claimed a deadly attack on the national election commission offices in Tripoli.
The group had also claimed an attack in 2015 on the Corinthia hotel, a landmark location in Tripoli.