Many years ago (actually many decades) Analog had a short story titled, I believed, 'Hilifter' ( the authors term for a starliner hijacker).
In the book the purser gets the idea that the main char is up to no good & locks him in his compartment.
Of course, he finds a way out & the rest is history as they say.
p.s. once he was loose the guy had only a little trouble getting into the bridge & dominating the crew there with just a handgun!
----------------------------------------------------------------------------------------------------------------------------------------------------------------------