Imagine you are a 19th century robber baron. You have a McDuck-style vault to swim in, full of gold coins, precious gems, and freshly stolen ancient artifacts. You know that some plucky street urchin is going to burgle you eventually; it’s just a matter of time. What do you do?
Well, 1884 problems require 1884 solutions. Enter the man trap… for vaults!
https://patents.google.com/patent/US304180A/
The drawings are a little light on detail, so I have added some annotations. I hope you find them helpful.

And four: You catch the man.
So the man enters the passageway B, approaches the door C, and opens it. The rope L is attached to the door C and pulls the bar H, which is holding up a heavy barrier E. Without the bar H to support it, the barrier E drops down, trapping the man, and potentially crushing his lookout.
It isn’t clear how authorized users are supposed to enter the vault. Maybe you just have someone on the outside keep the barrier hoisted? Maybe you prop it up before you proceed through? It seems inevitable that this clever Scrooge is eventually going to get trapped in his own vault.