Press Button, Receive Hackspace WiFi Code

When you are running a hackspace, network security presents a particular problem. All your users will expect a wireless network, but given the people your space will attract, some of them are inevitably going to be curious enough to push at its edges. Simply plugging in a home WiFi router isn’t going to cut it.

At Santa Barbara Hackerspace they use Unifi access points on their wireless network, and their guest network has a system of single-use codes to grant a user 24-hour access. The system has the ability to print a full sheet of codes that can be cut individually, but it’s inconvenient and messy. So the enterprising hackspace members have used a Raspberry Pi and a receipt printer to deliver a single code on-demand at the press of a button.

The hardware is simple enough, just a pull-up and a button to a GPIO on the Pi. Meanwhile the software side of the equation has a component on both client and server. At the server end is a Python script that accesses the Unifi MongoDB database and extracts a single code, while at the client end is another Python script that reacts to a button press by calling the server script and printing the result.  It’s a simple arrangement that was put together in an evening, but it’s an effective solution to their one-time WiFi access needs.

It’s a temptation as a hackspace to view all of your problems as solvable in one go with the One Piece Of Software To Rule Them All, and as a result some spaces spend a lot of time trying to hack another space’s effort to fit their needs or even to write their own. But in reality it is the small things like this one that make things work for members, and in a hackspace that’s important.

Does your space have any quick and simple projects that have automated a hackspace process? Let us know in the comments.

Thanks [Swiss] for the tip.

18 thoughts on “Press Button, Receive Hackspace WiFi Code

  1. Ehmmm.. should the code on the receipt not be *****-***** instead of numbers?

    But seriously now, automating and dispensing personal codes on paper using a receipt-like printer, brilliant and I assume very effective. Thumbs up.

    1. I’ve never had the guts to try but would running the back of your hand over the head as it ‘prints’ at the right speed leave a visible mark on the skin to have a semi-permanent record of the code?

      1. I really doubt it. The paper’s coated in heat-sensitive “ink” with a pretty clear changing temperature. The head is a row of tiny heaters that are in direct contact (just about) with the paper, across a gap only large enough to fit paper through.

        But if you pulled half the printer apart, so you could get to the heaters, and it somehow still functioned, and you moved your hand at precisely the right rate… you might say “ow!” as it ever so slightly burns you. With nowhere near enough thermal energy to leave a mark or visibly damage tissue. The temperature of each element is fairly high, but the overall amount of energy is low.

        I suppose you could cover your hand in the ink compound. Which is so full of horrible organic chemicals you’d notice the fish gonads growing under your arms before any sort of printing on your hands.

        And it wouldn’t burn numbers into your skin if you fed yourself into a laser printer either, so knock that idea on the head before you start.

  2. How do different hackerspaces handle the “wifi for everyone/guests”?
    The most popular version in germany seems to be “Here is our WPA2 PSK” followed by the Congress-style “Here is our WPA Enterprise wifi, just use any user/pass combination”. Usually there is no different ESSID for guests.

    1. We just have a single WLAN with WPA2 PSK key printed on the wall. Everyone threats it like they would any other public WLAN. After all, if someone wanted to maliciously hack, they wouldn’t go into a place where people are tech savvy. And a bit of inverted images through airpwn is just harmless fun.

  3. Plus it looks like the WPA password is static and they are using the Unifi controllers hotspot access control… You’d think hackers would be spoofing macs left and right… I’m surprised they didn’t just make the Raspi with the printer run a radius server and use real one time passwords instead of a pre-shared key/portal login…

Leave a Reply

Please be kind and respectful to help make the comments section excellent. (Comment Policy)

This site uses Akismet to reduce spam. Learn how your comment data is processed.