SPosts: 84 · Reputation: 87
Just made my own BIP38 tool. Didn't wanna just copy what was out there since they're already solid. So I came up with a bash wrapper to work with the Python library, and yes, it works offline too!
Requirements? You’ll need an offline Linux machine for key generation, an online one to grab the libraries, and a USB stick to move everything around.
CPosts: 73 · Reputation: 183
Cool project, nice job! But I’m curious, since I haven’t coded in Python for ages, what about updates to the BIP38 or bitcoinlib libraries when you’re offline?
I guess manual updates would be a must. Also, can we use different sources of entropy? And is it possible to verify everything before installing? Just thinking out loud!
SPosts: 84 · Reputation: 87
Yeah, you can totally follow the same method. If you're set up with both an online and offline device, it's straightforward.
As for entropy, I’m using this line: entropy=$(head -c 32 /dev/urandom | xxd -p -c 32). The bitcoinlib might do the same. About verifying libraries, I'm sure there are ways but I didn’t dig too deep into that. 😅
JPosts: 36 · Reputation: 19
Awesome to see a completely offline setup! A couple of things to consider:
Better to build wheels on the online machine and keep track of hashes. On the offline side, pinning and checking hashes is way safer than just a blind pip install.
Also, instead of passing the passphrase directly as an arg (which ends up in shell history), prompt for it. Like this: read -rsp "Passphrase: " passphrase; echo. Then feed it to Python securely.