Gunmen killed Libya's Deputy Industry Minister Hassan al-Drowi late on Saturday as he was visiting shops in the coastal city of Sirte, official sources said.
"Unknown people shot him dead while he was coming out of one of the shops in the city," a member of Libya's General National Congress (GNC), or parliament, told Reuters.
A security source said Drowi had been assassinated.
No group claimed responsibility for the attack, but two years after the fall of Muammar Gaddafi, Libya is struggling with militias and former rebel fighters who often use force to impose demands on the fragile central government.
Sirte is about 460 km (290 miles) east of the coastal capital of Tripoli, and was the last bastion of Gaddafi loyalists in the civil war. Gaddafi was killed there on October 20, 2011.