Bitcoin Institute

Idea: Portable Bitcoin

3 messages BitcoinTalk Sabunir, Xunie January 24, 2010 — July 13, 2010
Sabunir January 24, 2010 22:48 UTC Link to this message

It occurred to me: Bitcoin is supposed to be about anonymity. Couldn’t one further protect their anonymity if they could use Bitcoin from any random computer, not just their own? In other words, why not make Bitcoin a Portable App (http://en.wikipedia.org/wiki/Portable_app)?

At the moment, the Bitcoin wallet resides in %appdata%\Bitcoin. For a Portable Bitcoin, it’d need to be saved on the flash drive.

This would raise additional security concerns, naturally. Most notably, what if the random computer tried to copy your wallet from the flash drive? The wallet would need to be encrypted. So it would be a good idea if wallet encryption was added, and the user had to enter the wallet’s password to access it. Bitcoin would also have to be careful not to store the plaintext wallet in memory, in case the random computer was spying on its memory.

What do you think?

Sabunir January 26, 2010 02:54 UTC Link to this message

I believe I understand. Can the -datadir path be relative? That is, if the wallet.dat file is in the same directory as bitcoin.exe, would one execute “bitcoin.exe -datadir ./”?

Xunie July 13, 2010 12:16 UTC Link to this message
Quote from: riX on January 26, 2010, 1:00:50 PM UTC

An absolute path is required, at least under windows. You can do something like bitcoin.exe -datadir=“%cd%”

Here is my current batch file for starting bitcoin:

@echo off

set known-peer-address=mybox.myserver.se

for /f "tokens=1,2*" %%a in ( 'nslookup %known-peer-address%' ) do (
	if [%%a]==[Address:] set address=%%b
)

start bitcoin.exe -addnode=%address% -gen -datadir="%cd%\data"

Something similar could be done more elegant in linux.

As demonstrated here by riX, it is possible to run Bitcoin standalone or “portable”, on a USB thumb drive. It is possible to have that USB thumb drive encrypted. Ofcourse it doesn’t have to be a thumb drive but can be an external harddrive too!

It just requires some batch scripting, maybe we should release a batchscript with it called “standalone.bat” which will use -datadir=./.bitcoin and thus search for it on the USB thumb drive?