A hospital official in Benghazi said the eight were killed when the bomb exploded as people were leaving a graduation ceremony for officers in the army.
All officials spoke on condition of anonymity because they were not authorized to talk to media.
Benghazi, the birthplace of the 2011 uprising that led to the downfall of dictator Moammar Gadhafi, has seen a sharp rise in attacks and assassinations targeting military and police troops.
A weak central government in the capital, Tripoli, has struggled to rein in unruly militias, most of which stem from the former rebels who fought Gadhafi.
RA/NJF