I noticed that, during the recent attempted putsch in Washington, various officers of the law had coloured tape attached to their handguns.
This was probably to help officers discriminate friend from foe (an amazingly small number of people were hurt, so maybe it worked).
Today’s invention is related to this and makes each gun firable by only one identified person.
A small camera unit sits on the rear of the weapon. This has a bar which extends between hammer and firing pin.
The camera takes both an image forwards and backwards when the trigger is lightly pressed. If the rearwards image matches the designated user of the gun, then the bar withdraws and the weapon can be fired. An image is taken too of the person being fired at, for evidence.
This system could be improved by having officers receive a pattern of eg UV dyespots applied to their face before a shift and having the camera grab a face image at the same time.
This has the additional benefit of ruling out the possibility of firing without aiming.