Close

Harsh decision to take

A project log for Picoth - 2FA Auth with Pi Pico

An easy to use yet secure 2FA gadget, using a Raspberry Pi Pico and RGB Keypad, MicroPython.

angainorAngainor 02/18/2021 at 19:140 Comments

My prototype is now working, and usable no matter the mess in the current code.
No encryption and lock/unlock yet but that I know to handle.

The most troublesome issue is the lack of USB_HID with Micropython.
Yes, circuit python has. But circuit python also comes with a virtual USB drive, exposing the device inner files and is targeting education, toy projects, clearly ruling out production or secure devices.

Also, circuit python does not have the Pimoroni libs yet. Not a major obstacle, but would mean a rewrite of some parts.

I would largely prefer to stick with default Micropython, and not rely on a specific fork.

My options are the following:

- Stick with mainstream Micropython, no USB_HID for the moment and hope the feature will be ported soon enough. The device is usable thanks to the screen, but frankly, would be so much more friendly with keyboard emulation... I can't imagine Micropython losing all these Pico USB projects in favor of circuit python.

- Convert the code to circuit python, write wrappers to replicate interfaces similar to the Pimoroni libs I used, to make the port easier.

What's your take?

Here is a video of the current code.

Pages are defined in a config.json file, with TOTP codes to be encrypted.
2 Pages are defined here, one Test and one "Cryptos", with fake info.

Every page has 10 codes (using the pad as a regular numpad, not following the Pimoroni keypad numbers)
Bottom row, left and right of the 0 are previous page/next page.

Every 0-9 touch is defined with a label, a color and the TOTP code.

When selecting an Auth, the label and current code are displayed, with the remaining time shown as horizontal bar.

Discussions