Bitcoin Forum
November 12, 2024, 02:54:19 AM *
News: Check out the artwork 1Dq created to commemorate this forum's 15th anniversary
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: how to create user bitcoin wallet management feature  (Read 2245 times)
jinghuacao (OP)
Newbie
*
Offline Offline

Activity: 4
Merit: 0


View Profile
January 20, 2015, 05:20:40 AM
Last edit: January 20, 2015, 05:42:45 AM by jinghuacao
 #1

Hi there,

I want to develop an application, in which each user has its own wallets and pay each other in bitcoins. Is there a guide that describe the current best practice? or some demo code? I see there are many well developed bitcoin e-comm site. it is my first time. dont know where to start with. if someone points me a direction, or a guide, it will be much appreciated.

Thanks a lot for replies.
coinableS
Legendary
*
Offline Offline

Activity: 1442
Merit: 1186



View Profile WWW
January 20, 2015, 02:56:47 PM
 #2

"I want to develop an application"

"well developed bitcoin e-comm site"

You need to provide more specifics. Are you looking to build a website or an app? Is the app for PC or a cell phone? Android or Apple? What languages do you already know work with?  Nobody can respond to your question since there are too many possible options of what you could be asking.


jinghuacao (OP)
Newbie
*
Offline Offline

Activity: 4
Merit: 0


View Profile
January 21, 2015, 04:26:18 AM
 #3

hi coinableS,

thank you for you reply. This forum has lots lots of resource, i am reading post by post, thread by thread, but since the topic jump quickly, my progress is slow.

Here is my project,

I have an server side app(current code in C#), i want to use a forum software as front end user management and communication tool. Because forum software usually have very rich user management feature, i just need to customize a bit, it will meet my needs.

Then, I want to plug a bitcoin wallet/transaction feature into the forum user management system. all the transaction will be taking place between forum users.

Ideally, I am looking for a good practice demo, so i can go through the architecture and understand quickly. Here I finally find lots of good programmers, some say call blockchain.info api everytime, some say generate 1 million bitcoin address first, then assign to users when they sign-up, and etc. I am not sure what practice is the most common and well adopted. the worst thing is after it go live, I find I have to reimplement certain money management feature while there are more important development needs in the core app. Then everything goes wrong.
coinableS
Legendary
*
Offline Offline

Activity: 1442
Merit: 1186



View Profile WWW
January 21, 2015, 05:44:50 AM
 #4

Something to be aware of when generating addresses for each user with blockchain.info is the wallet will "max out" at 1,000 addresses. They don't tell you this upfront, which is kind of lame if you chose this option for your site only to find out later. Maybe you want to generate the address and keys yourself and then assign the addresses to each new user as they sign up. You can use blockchain.info API for checking balances or using a hot wallet for sending payments.

There's also several options with running bitcoind on a VPS and then use jsonRPC calls.

https://github.com/freewil/node-bitcoin

jinghuacao (OP)
Newbie
*
Offline Offline

Activity: 4
Merit: 0


View Profile
January 23, 2015, 05:35:49 AM
 #5

Something to be aware of when generating addresses for each user with blockchain.info is the wallet will "max out" at 1,000 addresses. They don't tell you this upfront, which is kind of lame if you chose this option for your site only to find out later. Maybe you want to generate the address and keys yourself and then assign the addresses to each new user as they sign up. You can use blockchain.info API for checking balances or using a hot wallet for sending payments.

There's also several options with running bitcoind on a VPS and then use jsonRPC calls.

https://github.com/freewil/node-bitcoin

Thanks a lot
eddilicious
Full Member
***
Offline Offline

Activity: 196
Merit: 100


View Profile
January 24, 2015, 07:15:19 AM
 #6

Something to be aware of when generating addresses for each user with blockchain.info is the wallet will "max out" at 1,000 addresses. They don't tell you this upfront, which is kind of lame if you chose this option for your site only to find out later. Maybe you want to generate the address and keys yourself and then assign the addresses to each new user as they sign up. You can use blockchain.info API for checking balances or using a hot wallet for sending payments.

There's also several options with running bitcoind on a VPS and then use jsonRPC calls.

https://github.com/freewil/node-bitcoin

I always have this question, about how those sites manage bitcoin received. I buy and sell btc in cryptsy, but all I see from blockchain, is the btc go into the deposit address, and the same amount transfered out, final balance is 0. how does this whole thing work behind the scene?
coinpr0n
Hero Member
*****
Offline Offline

Activity: 910
Merit: 1000



View Profile
January 25, 2015, 04:20:52 PM
 #7

I suspect the large sites traditionally used a bitcoind instance and store the user's balances in a database (not on the blockchain). They do their own internal reshuffling of the funds - that's why you see an amount go in and the same amount go out to another wallet under their control. Another option today is to use HD wallets, where you have a tree-structure of keys you can use. And that tree can be subdivided out and shared.

rascal777
Full Member
***
Offline Offline

Activity: 132
Merit: 100


View Profile
January 25, 2015, 10:34:22 PM
 #8

I am currently spending a lot of time researching this out, and I'm finding that there are not very many options out there.
Cross Topic:  https://bitcointalk.org/index.php?topic=22079.0

Current Options:

1.  Run a bitcoin Full node.  Write a program to interact with the JSON RPC API. 
(note that the https://github.com/freewil/node-bitcoin code mentioned by coinableS is actually not an implementation of address accounting software, but a way to communicate that simplifies the JSON-RPC interface a little bit)
Also, I seen this software that doesn't seem to be maintained, but looks like a good start on address management:  https://bitcointalk.org/index.php?topic=408465.0

2.  Use a third Party API such as:     (However, even using a third party api, you should choose to manage your bitcoin private keys yourself, and which user/account these addresses are associated with.)  The API should only used for tracking/sending  payments to addresses. (The transaction should be signed with the address private key using api scripts that run locally on the Application server.  For greater security, the private keys should not be stored on the application server unencrypted, or not at all, because the transactions could be queued, and sent to another more private server for transaction processing.

- http://blockchain.info/: Well of course we all know this one.  Bitcoin only, access is via custom API.   (note the limitation of addresses given by coinableS)
- https://apicoin.io/: "Put the Bitcoin node in the Cloud!"  Bitcoin only, access is via custom API.
- http://www.blockcypher.com/: "Powering block chains in the cloud".  Bitcoin and Litecoin, homepage suggests they may add new coins, access is via custom unified API.
- https://helloblock.io/: "Focus on building Bitcoin apps, not infrastructure."  Bitcoin only, access is via custom API.
- https://chain.com/: "The Block Chain API for Developers"  Bitcoin only, access is via custom API.
- http://blockr.io/: BTC, LTC, TBTC, DGC, QRK, PPC, MEC, access is via custom unified API.
- https://www.blocktrail.com
- http://www.bitcoinmonitor.net/


Third Party API Topic:  https://bitcointalk.org/index.php?topic=655722.0





BTC TIPS  19n2ienyueN4RiC38KFSZMQMgrNLgu9Uuc
coinpr0n
Hero Member
*****
Offline Offline

Activity: 910
Merit: 1000



View Profile
January 26, 2015, 12:56:46 PM
 #9

I am currently spending a lot of time researching this out, and I'm finding that there are not very many options out there.
Cross Topic:  https://bitcointalk.org/index.php?topic=22079.0

Current Options:

1.  Run a bitcoin Full node.  Write a program to interact with the JSON RPC API. 
(note that the https://github.com/freewil/node-bitcoin code mentioned by coinableS is actually not an implementation of address accounting software, but a way to communicate that simplifies the JSON-RPC interface a little bit)
Also, I seen this software that doesn't seem to be maintained, but looks like a good start on address management:  https://bitcointalk.org/index.php?topic=408465.0

2.  Use a third Party API such as:     (However, even using a third party api, you should choose to manage your bitcoin private keys yourself, and which user/account these addresses are associated with.)  The API should only used for tracking/sending  payments to addresses. (The transaction should be signed with the address private key using api scripts that run locally on the Application server.  For greater security, the private keys should not be stored on the application server unencrypted, or not at all, because the transactions could be queued, and sent to another more private server for transaction processing.

- http://blockchain.info/: Well of course we all know this one.  Bitcoin only, access is via custom API.   (note the limitation of addresses given by coinableS)
- https://apicoin.io/: "Put the Bitcoin node in the Cloud!"  Bitcoin only, access is via custom API.
- http://www.blockcypher.com/: "Powering block chains in the cloud".  Bitcoin and Litecoin, homepage suggests they may add new coins, access is via custom unified API.
- https://helloblock.io/: "Focus on building Bitcoin apps, not infrastructure."  Bitcoin only, access is via custom API.
- https://chain.com/: "The Block Chain API for Developers"  Bitcoin only, access is via custom API.
- http://blockr.io/: BTC, LTC, TBTC, DGC, QRK, PPC, MEC, access is via custom unified API.
- https://www.blocktrail.com
- http://www.bitcoinmonitor.net/


Third Party API Topic:  https://bitcointalk.org/index.php?topic=655722.0






Cool links. I'll have to check them out. It really depends on what you're trying to create or need blockchain software for (if at all). Even if you run a full node, it's still not user-friendly to explore the blockchain and probably requires writing some own software. That's why services like Blockr or Blockchain.info are so useful.

jinghuacao (OP)
Newbie
*
Offline Offline

Activity: 4
Merit: 0


View Profile
January 28, 2015, 03:59:35 AM
 #10

I am currently spending a lot of time researching this out, and I'm finding that there are not very many options out there.
Cross Topic:  https://bitcointalk.org/index.php?topic=22079.0

Current Options:

1.  Run a bitcoin Full node.  Write a program to interact with the JSON RPC API.  
(note that the https://github.com/freewil/node-bitcoin code mentioned by coinableS is actually not an implementation of address accounting software, but a way to communicate that simplifies the JSON-RPC interface a little bit)
Also, I seen this software that doesn't seem to be maintained, but looks like a good start on address management:  https://bitcointalk.org/index.php?topic=408465.0

2.  Use a third Party API such as:     (However, even using a third party api, you should choose to manage your bitcoin private keys yourself, and which user/account these addresses are associated with.)  The API should only used for tracking/sending  payments to addresses. (The transaction should be signed with the address private key using api scripts that run locally on the Application server.  For greater security, the private keys should not be stored on the application server unencrypted, or not at all, because the transactions could be queued, and sent to another more private server for transaction processing.

- http://blockchain.info/: Well of course we all know this one.  Bitcoin only, access is via custom API.   (note the limitation of addresses given by coinableS)
- https://apicoin.io/: "Put the Bitcoin node in the Cloud!"  Bitcoin only, access is via custom API.
- http://www.blockcypher.com/: "Powering block chains in the cloud".  Bitcoin and Litecoin, homepage suggests they may add new coins, access is via custom unified API.
- https://helloblock.io/: "Focus on building Bitcoin apps, not infrastructure."  Bitcoin only, access is via custom API.
- https://chain.com/: "The Block Chain API for Developers"  Bitcoin only, access is via custom API.
- http://blockr.io/: BTC, LTC, TBTC, DGC, QRK, PPC, MEC, access is via custom unified API.
- https://www.blocktrail.com
- http://www.bitcoinmonitor.net/


Third Party API Topic:  https://bitcointalk.org/index.php?topic=655722.0






++++++++++++++++++++++.

Thank you, that is pretty much what I was looking for when I start the thread. I am still trying to think how to use that api to sign by private key without storing private key on the app server.
coinableS
Legendary
*
Offline Offline

Activity: 1442
Merit: 1186



View Profile WWW
January 28, 2015, 05:39:42 AM
 #11


Thank you, that is pretty much what I was looking for when I start the thread. I am still trying to think how to use that api to sign by private key without storing private key on the app server.

You don't have to store the private key on your server if you use blockchain's API. Of course you'll need to provide your blockchain wallet ID and password, but you can just store a limited amount on blockchain and keep your "real" bitcoin balance in cold storage. Then just transfer from cold storage to your hot wallet on blockchain API when needed.

countryfree
Legendary
*
Offline Offline

Activity: 3066
Merit: 1047

Your country may be your worst enemy


View Profile
January 28, 2015, 12:53:38 PM
 #12

Just a suggestion:
Some people may hesitate quite a lot before sending BTC to a new forum. This is where blockchain.info looks great, because you could offer your visitors the choice of creating a wallet in your app, or using the e-wallet they may already have at blockchain.info.

I used to be a citizen and a taxpayer. Those days are long gone.
rascal777
Full Member
***
Offline Offline

Activity: 132
Merit: 100


View Profile
January 30, 2015, 04:02:49 AM
Last edit: January 31, 2015, 06:59:18 AM by rascal777
 #13

I would like to add that there is also a third option:


Run a Bitcoin Thin Client such as Electrum.

There are a couple of very real advantages here.
1.  No need to download and maintain the blockchain,  Electrum will use SPV (A Bitcoin implementation that does not verify everything, but instead relies on either connecting to a trusted node)
However, you could download and maintain a your own bitcoind on a separate server, and have all your applications using Electrum communicate back to that server using SPV.

2.  The private key generation is secured using a long series of words (determined per wallet, i think), and other private keys and their BTC addresses are created deterministically.  Meaning, that if you have another instance of Electrum running with the same "wallet" the key generation sequence is identical.  Which is great, because you can place Electrum on the web server, and have a program that talks to it, getting new BTC addresses when necessary.  Note that most of the bitcoin packages these days have deterministic private key generation.

3.  The unspent output of a created transaction can be directed back to the address easily.  This is related to using Electrum as a type of user account BTC tracking software, which I am not sure how recommended that is.

Note this issue tracker on Bitcoin, which lauds people not to be lazy and simply use the accounts feature of bitcoind, but rather create a robust solution.

https://github.com/bitcoin/bitcoin/issues/3816

BTW,  This stuff is not the easiest in the world, and I would love to have plenty of money to guide a development team to create this.


Also:  Added a link to BopShop
https://bitcointalk.org/index.php?topic=285771.msg3797420#msg3797420  ->  this was bought out by Cointerra, then Cointerra went bankrupt.


BTC TIPS  19n2ienyueN4RiC38KFSZMQMgrNLgu9Uuc
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!