Attacks on the security forces have surged since the army ousted Islamist president Mohamed Morsi in July, and as the military-installed authorities have pressed a deadly crackdown on his supporters.
The attackers shot Lieutenant Colonel Mohamed Eid as he was getting out of his car after travelling to his home in Zagazig, security officials said, adding he later died of his wounds in a hospital.
Eid was in charge of the "extremist groups' file" and he had helped to draft a report accusing several leaders and members of Morsi's Muslim Brotherhood of inciting violence and carrying out attacks, state news agency MENA reported.
Mabruk had been involved in preparing charges against Morsi and the Brotherhood's supreme guide Mohammed Badie ahead of their trials, a security official said at that time.
Also Read
Today's killing came after an Egyptian court adjourned until Monday Morsi's trial over charges related to jailbreaks and attacks on police stations during the uprising that toppled strongman Hosni Mubarak in 2011.
Prosecutors say the attacks on police stations and the jailbreaks, in which Morsi and other political prisoners escaped, were a Brotherhood-led conspiracy to sow chaos in Egypt.
He is also expected to be tried for "insulting the judiciary", but no date has yet been set for the case.