In a scene early on in the latest "Avengers" film, Tony Stark and the rest of his superhero squad challenge themselves to see who can lift Thor's legendary hammer, Mjölnir. After all failing miserably, Stark concludes that the hammer's handle has some kind of fingerprint scanning technology.

The world of comic books will tell you it has more to do with who is worthy of wielding the weapon, but here in the real world, Stark's reasoning is the basis behind an actual working version of Thor's hammer. Created by electrical engineer Allen Pan, his replica of the Norse weapon can only be lifted by the authorized, not necessarily the worthy.

Pan Allen Thor's HammerA look at what makes Allen Pan's brilliant working 'Thor's Hammer' replica possible. (Photo: Pan Allen)

Because Pan isn't Odin's son, he needs to employ some science to make this whole thing actually work. To that end, his Thor's hammer will only work on a metallic surface. To create the illusion of some mystical force at work, Pan placed powerful magnets inside that, when triggered, create a magnetic field most mortals cannot break. When someone grasps the handle, embedded capacitive touch sensors (similar to the ones on your smartphone touchscreen) turn on the magnets. When Pan grasps it, an embedded thumb print reader recognizes him and disables the system. And voila! In at least presentation, Allen Pan is suddenly a worthy superhero.

Check out Pan and his hammer pranking some unsuspecting people down at Venice Beach, California in the video below.