Islamic State suicide bombers attacked key oil facilities in northern Libya on Monday but were pushed back, army officials said.
The attacks targeted the Al-Sidra oil export terminal, killing two soldiers.
IS has been trying to push east from Sirte for several weeks to reach the country's "oil crescent," where its main oil terminals such as Al-Sidra and Ras Lanouf are based.
IS announced on Twitter that its fighters had led an "attack on the Al-Sidra area followed by violent clashes with the enemies of God."