Page 1 of 2

Decoding key cuts from an image

PostPosted: Tue Apr 04, 2017 10:32 am
by pickmonger2
These people invented a system where a photo was taken of a key with a telescope and their software could analyze the cuts on the key.

At the time of releasing this research paper they were not releseing their software.

Does anyone know where one can download this software or an other method to decode the cuts on a key from a photograph?


http://alibaba.sk/images/stories/audio/laxton_wang_savage_ccs2008.pdf

Re: Decoding key cuts from an image

PostPosted: Tue Apr 04, 2017 12:17 pm
by tpark
I don't think it's super hard at all - if you look near the bow of the key, you'll be able to see an area where the key isn't cut, so you have an area on the image with a known width. From that, you'll be able to measure the height of the cuts in relation to that width. This technique is sometimes useful for lockouts where someone else has a key, but they're not in town but they have a cell phone. For house keys, the bitting usually uses standard depth/spacing, so it's relatively easy to make a key from a picture.

At the bow, the key blank width is 155 pixels. I measured a blank here to have a width of 335, so that gives a conversion factor of 335/155 or about 2.161. So the other measured widths (depths) are 101,132,152,133,122 (in pixels) giving depths of 218,285,328,287,263. If we look at the DSD data for Kwikset large pin, it matches reasonably well to 63134, which is what the authors of that article claim.
kwiksetlargepin.png

measure1.png

start.png

Re: Decoding key cuts from an image

PostPosted: Tue Apr 04, 2017 12:23 pm
by Jaakko Fagerlund
And it isn't rocket surgery to to use image processing software to do the transformations automatically once you give it the key make, a known reference dimension and two axes.

I think Matlab could be coded easily to do all of that.

Re: Decoding key cuts from an image

PostPosted: Tue Apr 04, 2017 2:06 pm
by mastersmith
When I worked private sector and ran auto lockouts, many times the keys were laying on a seat where they could be seen. A quick visual decoding and a code clipper were all it took to let them in without risking damage to the vehicle. It was my usual practice to avoid putting tools in the door when possible. If you are familiar with the lock software isn't necessary.

Re: Decoding key cuts from an image

PostPosted: Tue Apr 04, 2017 3:00 pm
by malfunctionjunction
I've successfully decoded schlage, kwikset, and best from pictures, just by looking at the picture and comparing it to a pair of keys with one of each cut (0-5 & 4-9). I don't think it's something to be relied upon, but it is a neat trick. People have brought me bad copies that I've "fixed" by decoding and originating, and some were so far off I couldn't make heads or tails of them and it actually took me a second try after attempting to decode it with a micrometer. Between the potential for that level of variance and how far off the dimensions are on some aftermarket blanks (I'm looking at you, JMA), I'm not sure this is ever something you'd be able to rely on 100%.

Re: Decoding key cuts from an image

PostPosted: Tue Apr 04, 2017 3:18 pm
by Logan
idk about the telescope bit but something like Snap Decoder for android would be like what you're talking about.
https://play.google.com/store/apps/deta ... oder&hl=en

Re: Decoding key cuts from an image

PostPosted: Tue Apr 04, 2017 4:16 pm
by MrWizard
Decoding a key from sight is really easy to do if you are familiar with the depths being used on the type of lock you are working on. As far as doing it from a good picture it's perfect as you can see the side milling and match the depths using them or comparing it to a blank key.

The local news here a number of years back had a story of a few online services that you take a picture from your cell phone send it to them they would mail you out a working key. So the news team tried it on random house that agreed to let them try it. They sent the picture of their key attached to the ring on the table sent it in they got the key a fews days later in the mail went back to the house on camera opened the envelope put the kwikset key it worked perfect. Unfortunately by exposing this online service and how easy it is to do sparked a rash people missing things yet there was no sign of entry.

The news does this all the time telling people how easy it is to do these crimes. Like another story of how many are having their catalectic converters on the vehicles stolen and recycled for big bucks. They actually showed how fast and easy it was for someone to go to home depot or harbor freight and get a battery powered cut off portable grinder and cut the exhaust pipes in 2 places and be gone in less the a few minutes. They even told it was easier to do it to a pickup or SUV that is higher off the ground so easy to get under and get it out faster. Well the next few weeks tons of reports came in of more missing ones than ever before.

A more resent case of the news help promote crimes is the rock bandit story of someone using large landscape rocks readily handy almost on anyone property tossing them through picture windows. I think the news that does this should be held responsible for helping promote these crimes by airing these stories.

Re: Decoding key cuts from an image

PostPosted: Tue Apr 04, 2017 9:10 pm
by tpark
malfunctionjunction wrote:I've successfully decoded schlage, kwikset, and best from pictures, just by looking at the picture and comparing it to a pair of keys with one of each cut (0-5 & 4-9). I don't think it's something to be relied upon, but it is a neat trick. People have brought me bad copies that I've "fixed" by decoding and originating, and some were so far off I couldn't make heads or tails of them and it actually took me a second try after attempting to decode it with a micrometer. Between the potential for that level of variance and how far off the dimensions are on some aftermarket blanks (I'm looking at you, JMA), I'm not sure this is ever something you'd be able to rely on 100%.


Sometimes locks have nonstandard sized pins in them, or you have the Weiser vs. Kwikset situation where the depth increment is different, so that makes it harder. Many of the JMA blanks leave something to be desired as far as precision goes, I agree. Often it's possible to determine the code simply by looking at the key. Some keys are easier to decode than others....
amkey.png

Re: Decoding key cuts from an image

PostPosted: Wed Apr 05, 2017 6:16 am
by dontlook
TeamStarlet did some research on what was out there a year ago.

He found something (I believe in these forums) called KeyDepthPhotoAnalyzer that works kind of. It was a proof of concept Windows application.

Learning to use photo tools to measure the difference and then using manufacturer references for depths is probably better, as you have more flexibility in re-different keys.

Re: Decoding key cuts from an image

PostPosted: Wed Apr 05, 2017 4:12 pm
by jimu57
Take a good pic with your smart phone. Either measure the the image as is using the blade width as reference or zoom in and out until the image is exactly the same size as a key blank. Measure the image with calipers in either case. Simple and easy. I have done it several several times.

jimu57

Re: Decoding key cuts from an image

PostPosted: Wed Apr 05, 2017 9:09 pm
by Josephus
Jaakko Fagerlund wrote:And it isn't rocket surgery to to use image processing software to do the transformations automatically once you give it the key make, a known reference dimension and two axes.

I think Matlab could be coded easily to do all of that.


It's been done by some MIT students a few years ago. If I remember they used OpenCV, so really the only "hard" part would be to manually code in all those blank dimensions.

Algorithmically the process is simple. Flatten image to remove angles, measure relative lengths with known depth-cuts, length and bow measurements, lookup table and spit the key code out.

Re: Decoding key cuts from an image

PostPosted: Thu Apr 06, 2017 12:18 pm
by Werewolf
I've made a key from a picture a while back.
I printed the photo (old school) , then drew a line on the back edge of the key and then lines perpendicular to this to the middle of each cut. Then measured the lines to find the relative size and compared it to the width of the shoulder to get the correct sizes.

Worked first time.

Re: Decoding key cuts from an image

PostPosted: Fri Apr 07, 2017 12:50 am
by Anarchy_won
I use Snap Decoder if I need to decode a key (I have used it 4 or 5 times and they all worked out) but almost as much work as using a Caliper.

Re: Decoding key cuts from an image

PostPosted: Fri Apr 07, 2017 5:18 pm
by Jaakko Fagerlund
Anarchy_won wrote:I use Snap Decoder if I need to decode a key (I have used it 4 or 5 times and they all worked out) but almost as much work as using a Caliper.

How do you use calipers on a key which you can only see but not touch?

Re: Decoding key cuts from an image

PostPosted: Fri Apr 07, 2017 7:11 pm
by tpark
Jaakko Fagerlund wrote:
Anarchy_won wrote:I use Snap Decoder if I need to decode a key (I have used it 4 or 5 times and they all worked out) but almost as much work as using a Caliper.

How do you use calipers on a key which you can only see but not touch?


I eyeball it, and say "ahh, that looks about right". It's not as accurate as having the actual key, but quite often it works out. A magnified printout can reduce error somewhat.