Episode: 3231 Title: HPR3231: USB Key Source: https://hub.hackerpublicradio.org/ccdn.php?filename=/eps/hpr3231/hpr3231.mp3 Transcribed: 2025-10-24 19:13:28 --- This is Haka Public Radio episode 3231 for Monday the 21st of December 2020. Today's show is entitled, USP key and in part of the series, Privacy and Security, it is hosted by Toujet and in about two minutes long and carrying a clean flag. The summer is, turn a thumb drive into a key to lock slash unlock your Linux machine. This episode of HBR is brought to you by AnanasThost.com. Get 15% discount on all shared hosting with the offer code HBR15. That's HBR15. Better web hosting that's honest and fair at AnanasThost.com. Hello Hacker Public Radio. This is Toujet again. Been a while since I did my last podcast, so I thought I was more than overdue. If you like me, you probably have a few USP keys laying around and came up with a little project I did with them just trying to experiment and learn some new technology. I've actually turned a USB thumb drive into a USB key. It's a little script with combo of a Pearl script installation. It uses SS key jam to generate keys for locking and unlocking. It uses UDEV for actions for when you plug and unplug the drives. It uses bash for the actual script for doing locking the unlocking and the key checking. It did run into a little problem with UDEV. I had events set up so that when you plug in the drive, it would unlock and unplug the drive. It would lock, but the problem I was running into is that when it was unlocking, I couldn't access the file system on the drive. I found that there is a change event as well. Using the change event, I'm able to actually have the plug-in of the drive unlock it, but then the change event, which occurs when the drive is actually mounted, it can check the key and if the key is not the right key, then it locks it again. It's short distance and it's unlocked, but that seems to work pretty good. It generates a unique key combination for the server and the USB drive so you can use the same drive on multiple computers or you can use multiple thumb drives on the same computer. The website https.james.tobusacademy.com slash usbkey.html has the installation and links for the script so you can download the scripts. Give it a quick try, let me know what you think and have fun. We are a community podcast network that releases shows every weekday, Monday through Friday. Today's show, like all our shows, was contributed by an hbtr listener like yourself. If you ever thought of recording a podcast and click on our contributing to find out how easy it really is, HECA Public Radio was founded by the digital dog pound and the infonomicum computer club and is part of the binary revolution at binwreff.com. If you have comments on today's show, please email the host directly, leave a comment on the website or record a follow-up episode yourself. Unless otherwise stated, today's show is released on the creative comments, attribution, share a light, 3.0 license.