Image of the glider from the Game of Life by John Conway
Skip to content

{ Category Archives } Scripting

Use /dev/random Instead Of /dev/null

While writing a shell script the other day, I was redirecting some output to /dev/null, as normal, when something dawned on me. Why don't I redirect my output to /dev/random instead? After all, both Linux random devices are writable by everyone on the system: $ ls -l /dev/*random crw-rw-rw- 1 root root 1, 8 Nov […]

Cryptographically Secure Pseudorandom Locally Administered Unicast MAC Addresses

Recently, Apple released the ability for iPhone 5c and newer hardware to create a spoofed software MAC address for 2.4 GHz and 5 GHz wireless access points. The MAC address is locally administered, and a unicast address. This has sparked a small discussion in various forums about how to generate valid locally administered unicast MAC […]

Entropy As A Service

Back in October 2012, I announced hundun.ae7.st. It's an "entropy server" that delivers encrypted random bits that are indistinguishable from true random, directly to your GNU/Linux input entropy pool. Per the Linux CSPRNG source code, the bits in the input entropy pool are then cryptographically hashed with SHA1 before sending the bits to the blocking […]

Cryptographically Secure Passphrases In d-note

A couple nights ago, while coming home from work, I started thinking about the button you press on the d-note web application (an instance running at https://secrets.xmission.com) for generating passphrases used to encrypt your note. Each passphrase is a 22-character base 64 passphrase. Initially, I was using the following code in JavaScript: 123456789function make_key() { […]

OpenPGP Key Random Art, Now With ANSI Color Support

I just recently committed support for my OpenPGP key random art Python script to support ANSI color. The idea is to create a "heat map" of which squares the drunken bishop has traversed during his dizzying travels. So not only can you see what your key "looks" like, but now you can sense what your […]

The Drunken Bishop For OpenPGP Keys

Almost a year ago, I blogged about the drunken bishop algorithm for OpenSSH key random art. Towards the end of the post, I mentioned that I would be building an OpenPGP implementation. I started doing so in Python, but eventually got sidetracked with other things. Well, I hosted the Scale 12x PGP keysigning party, and […]

Create Your Own Graphical Web Of Trust- Updated

A couple years ago, I wrote about how you can create a graphical representation of your OpenPGP Web of Trust. It's funny how I've been keeping mine up-to-date for these past couple years as I attend keysigning parties, without really thinking about what it looks like. Well, I recently returned from the SCaLE 11x conference, […]

Obsure Email Addresses In HTML

I recently put up a web page with my email address. I'm confident in email provider's ability to filter spam, so I don't worry about it too much, to be honest. However, I started thinking about different ways I could obscure the email address in the source. Of course, this isn't offering any sort of […]

Automated Diceware Passwords

For those unfamiliar, Diceware.com is a way of picking truly random passphrases from a predefined dictionary list of words. The idea is that each word has a 5 digit number attached to it. Each digit in the number holds the values 1-6, in numerical order. So, the first password starts with 11111, then 11112, 11113, […]

IRC Notifications Over SMS

Recently, I pinged my boss about a networking question, and got the following response: I am away but your message is being sent to my phone. Well, there are a few things he could be doing here: Logged in 24/7 with a local IRC client on his phone. Easiest, but will drain his battery quickly. […]

A Note About Removing Files With find(1)

I've seen on the internet, and elsewhere, that when there are too many arguments for rm(1) to handle, that the following command will suffice: % find /path -exec rm -rf {} \; While certainly functional, it's not optimal. If there are thousands of files (as is often the case at my job), this command is […]

Steganography

I have been familiar with steganography for a number of years. In fact, back when I was in middle school, I developed a fascination for encryption, and hiding messages, mostly so I could pass notes back and forth to classmates during class. It wasn't long before I found "invisible ink", which is a form of […]

Rejected And Legal

Some of the roles I fill at work are: storage architecture, cloud engineering, system administration and backend coding. When approaching my tasks head on, it's always important to me that standards are adhered to. From PEP coding style to adhering to an RFC for mail server. Unfortunately, I think I'm a dying breed, or something, […]

Use wget(1) To Expand Shortened URLs

I'm a fan of all things microblogging, but let's face it: until URLs become part of the XML, and not part of your character count (which is ridiculous anyway), shortened URLs are going to be a way of life. Unfortunately, those shortened URLs can be problematic. They could host malicious scripts and/or software that could […]

How To Properly Create And Burn CD/DVD ISO Images From The Command Line

Too often, I see the recommendation on forums, IRC, and elsewhere across the internet to use improper tools for creating ISO images. For example, consider the following two commands, both of which are not the correct way to build a CD/DVD image: $ dd if=/dev/scd0 of=cdimage.iso # NO! Or worse yet: $ cat /dev/scd0 > […]