A friend and I want to create a simple webservice for ourselves, that can do transactions from our wallets. We want to keep our wallets separate. So how can we exchange the wallet that bitcoin-qt uses without restarting the application? Is that possible? Or is there another bitcoin client with a JSON-RPC or similar that we can use for that?

EDIT: The plan is that we have a simple webinterface (PHP-based) where we enter the receiver, the amount, the username (will correspond to the name of the wallet file) and the wallet password. The script would then send the data to bitcoin-qt (or whatever we use) which will then execute the transaction. Also, it should be possible to view the amount of BTC that each wallet has (After entering the password of course).

We have a dedicated server, everything will run on that.

  • 1
    Is this incoming only? Will the monies be sent based on whose product it is? Because them few ways. Do you have root access? Is it a dedi, Vps, i hope it's not a shared hosting plan. If you are going to host a "hot wallet" on your production server be very careful with security (if it's nix go with mod_security and mod_evasive be very through in your coding you could lose it all on a hot wallet. And most VPS (linode is one) will get compromised by hackers or worse. Now, if you are accessing a remote Wallet, it's possible to do a remote call. Or use a deterministic key seed. I need more info..
    – Joe White
    Oct 18, 2013 at 15:03
  • Added some more information, hope it's enough. What is a VPS?
    – Sibbo
    Oct 18, 2013 at 18:36
  • Thanks, that does help me out. I must go for a dinner, but I will respond in 6 hours. A VPS=Virtual Private Server.(a vm). Thanks for understanding and for adding more info
    – Joe White
    Oct 18, 2013 at 20:41

1 Answer 1


First thing: encrypt that Dedicated server's entire hard drive. Secondly: encrypt that wallet.dat file Thirdly: use EVERY possible method of attack defense you can. Use googleauth for 2 step log in. disable root access. If you must run SSH, run it under a random port. NOT port 22. use tripwire mod_sec/mod_evasive, if you think it might be good... add it. use UFW firewall. Use insane settings. If you only plan to sell to one country: block ALL IP's that are not within that country Disable ALL error notifications and disable any information that may allow the attacker to gain any information about what the server is run on (no "this server run on apache centos" etc). I do assume you do know this, but im just giving fair warning. Host as few applications beyond the bare minimum. (so no minecraft servers). I personally recommend not keeping funds in a hot wallet because ~/.bitcoin/wallet.dat is the most searched for thing by hackers

Now... How can you have two different wallets on the same machine? well. there's a few ways to do it... If you want to keep generating infinite new addresses (using infinite seeds) all the time and have a good contingency plan in place for your wallet.dat file (like hourly back up etc), you could run 2 instances of bitcoind. (commandline version is what you want for this) Two instances can be run by changing the listening ports on one of the two bitcoind instances and running each instance on its own user account. you can then (depending on which user you are paying to) have php connect to the respective bitcoin client and request an address for payment. Another idea i would propose could be using one bitcoin client and having accounts. If you are okay sharing one wallet and one daemon, but need your own account for accounting balances, its a breeze

Side note there are a few projects that actually are pretty good. I started writing a basic bitcoin escrow system based off of my own coding and using "The Bitcoin Shopping Cart Interface package" and "The Bitcoin Shopping Cart Interface package"

http://sourceforge.net/projects/bitscrow/ I use to have a much more advance version i built for FreiCoin but the wonderful people over at FDCServers destroyed my development server on me (thanks guys). So I am pretty far behind again. However you should at least have an idea of maybe a general direction to start This version requires no bitcoind at all which is pretty unique. But if you want a wallet, then you may need to integrate that yourself.

you could also consider installing drupal and modifying the source to have a two different plug ins going to the two different daemons.

there are many options. you can even start from scratch, good documentation is available here. https://en.bitcoin.it/wiki/PHP_developer_intro

Please let me know if this was useful or not, and let me know if there is further clarification needed. If you want to truly have your own page it's a lot of work...

Also, check out https://github.com/Bit-Wasp/BitWasp

I have been playing around with it and its been pretty cool so far.

thanks for giving me the information i needed to try and respond as best i can

  • Thanks for your answer. So there is no bitcoin client that runs as one process and listens to just one port but can handle 2 wallets?
    – Sibbo
    Oct 19, 2013 at 13:00

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.