Connect with us

Door Lock - USB key

Discussion in 'General Electronics Discussion' started by reynonic, Mar 22, 2013.

Scroll to continue with content
  1. reynonic

    reynonic

    3
    0
    Mar 22, 2013
    I have an Idea I would like to try, A front door lock that is unlocked by a encrypted file on a 1gb USB flash drive. It would be cool If I could also make an app that could control the lock remotely too, maybe from my phone or something but that might be to much trouble. I'm not sure where to start :confused:
     
  2. GreenGiant

    GreenGiant

    830
    6
    Feb 9, 2012
    well to start unless you are using some SERIOUS encryption methods you wont need anything nearly as large as a 1GB, in fact you would probably be better with a smaller one since it will be easier to read by a microcontroller.

    On that note, you will need a microcontroller, that has the ability to read a USB stick (PIC or Arduino should be fine). Then it will just be a matter of programming it to read and inspect a text file, and then turn a deadbolt with a motor/servo. I would start with that first before moving into encryptions, though having a specific file on a specific sized flash drive should be enough encryption.

    You are going to need a fairly significant power supply to drive the servo, as deadbolts can be a little tought to turn, and even more so if you want to control it via 3g/text message (much more)

    An interesting thought I just had was if you were to have it set up so that you could plug in a flash drive, have it read the file and use that as the current "password" so to speak, and then have it look for that file when you come back, that way its set everytime you leave, and its "encrypted" essentially.
     
  3. reynonic

    reynonic

    3
    0
    Mar 22, 2013
    Where can I but the parts?
     
  4. CocaCola

    CocaCola

    3,635
    5
    Apr 7, 2012
    Do you have any micro programing experience, and are you setup to program micros? If not it's not as simple as getting the parts, you will need to get an entire development platform up and running, learn to program and learn to design the hardware... Now using an Arduino cuts cost and development a lot as much of that is included for free but only if you choose to learn the Ardunio and use it...

    On that note of the lock system, since the USB stick is 'dumb' you will not have two way communication, meaning the key on the USB stick will be static and anyone that simply copies the USB stick will be able to open the door... Now there are ways to make this harder, one being develop your own USB stick that is 'smart' (aka a USB key dongle) or use a proprietary file system on the USB stick that will complicate (slightly) reading and copying of the information on it on the computer end...

    If you want to explore a more secure setup, look at smart cards that have a micro built in, this way you can have two way key encrypted exchanges and challenges, making it much, much harder to crack...
     
  5. reynonic

    reynonic

    3
    0
    Mar 22, 2013
    Ok how expensive are we talking? I though the usb thing would be cool, if its encrypted no one can copy it anyways and wouldnt see it as a key like you would a smart card. I can get the software we use to encrypt all our usb drives at work. Ive done programing but not any microcontrollers. I always thought it would be fun and kinda cool to make something usefull to me.
     
  6. CocaCola

    CocaCola

    3,635
    5
    Apr 7, 2012
    On the cheap if you luck out, maybe $100 after a few trials and errors realistically more...

    Encryption does not equate to copy protection, trust me it's trivial to copy or clone that USB drive and get a 1:1 copy... The encryption will stop me from easily accessing the data and decrypting it but not copying it... Trust me software companies spent the better part of the 80s and 90s trying to develop copy protection for media, and at the end of the day it was an utter failure on all levels... Come the 2000s media companies tried it all over again with DVD and Bluray, both resulting in failure due to simple exploits...

    Can you write your own software for a micro that can decrypt that data?

    It's a lot of fun, it's just not as easy as it appears sometimes...
     
  7. donkey

    donkey

    1,286
    56
    Feb 26, 2011
    Last edited: Mar 23, 2013
  8. BobK

    BobK

    7,682
    1,686
    Jan 5, 2010
    How would copy protection or encryption help anyway? In order for someone to steal it, they would have to get a hold of the key (the USB flash drive). And if they have that, then, well, they have the key, no need to copy or decrypt it.

    Bob
     
  9. CocaCola

    CocaCola

    3,635
    5
    Apr 7, 2012
    Some criminals are opportunist, this is why you have criminals like cashiers skimming credit cards and returning the original so that they can later make a clone and strike unsuspectingly when they choose without you suspecting a thing... If they simply 'stole' the USB drive you would likely notice in short and change the lock, but if they cloned it you would have no idea and they are open to use it at any time...
     
  10. donkey

    donkey

    1,286
    56
    Feb 26, 2011
  11. BobK

    BobK

    7,682
    1,686
    Jan 5, 2010
    True, but unlike the credit card, you would not be handing this to someone. I suppose, if you put it on the your keychain and handed it all to a valet parker or auto repair shop it might be in danger. However, they would have to be specifically targetting you, since no one else would have a flash drive that opens their house.

    Bob
     
Ask a Question
Want to reply to this thread or ask your own question?
You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.
Electronics Point Logo
Continue to site
Quote of the day

-