Originally Posted by
ATOBTTR
As a simpler example and one that impacts you, when you hand over your keys to a valet or an auto-mechanic at the shop, besides the threat of legal consequences or job termination, what actually stops them from taking your car for a joy ride or doing something bad with your car? Certainly nothing within the car itself. They already have been given the technical access necessary to misuse your car. They could easily then take your car and use it do bad things.
Google "Tesla Valet Mode" 
(and don't say "yes, but that's Tesla" -- now google "Nissan LEAF Valet Mode" -- basically, the technology exists and is being used to implement usage restrictions)
And what about people who do have the access to do their job?
Don't let perfection be the enemy of the good? Obviously people who have to have access to the cockpit need to have access. Did this guy have to have access? Not sure, but I assume we will find out.
As I noted above, a "two person in the cockpit" rule may work in the air, but would have additional costs associated with it on the ground.
A lot of things in aviation are expensive
because we want aviation to be safe. Some of it may be safety or security theater. I don't claim to be an expert in airport and airline operations, so I don't know what is current standard or could be implemented. Any money spent on measures to prevent a reoccurrence of this scenario might also have a better use elsewhere (prevent other/more likely issues). Don't think anyone here can really discuss this authoritatively

All of us other than LarryJ are presumably sitting in our armchair.