Bitcoin Forum
May 07, 2024, 09:42:04 AM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: Needing source code to find transactions from the same wallet.  (Read 1505 times)
dwma (OP)
Sr. Member
****
Offline Offline

Activity: 405
Merit: 250


View Profile
November 14, 2014, 02:36:23 PM
 #1


I have an academic exercise where I wish to group a number of addresses to a certain wallet.  I have some transactions with multiple inputs.  From there I want to find all the addresses that are shared as inputs on outputs.  From here I assume I could gather a list of known addresses.

I know blockchain.info does this, but I want actual source code so I can change parameters etc.

Has anyone heard of such a thing.
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction.
1715074924
Hero Member
*
Offline Offline

Posts: 1715074924

View Profile Personal Message (Offline)

Ignore
1715074924
Reply with quote  #2

1715074924
Report to moderator
1715074924
Hero Member
*
Offline Offline

Posts: 1715074924

View Profile Personal Message (Offline)

Ignore
1715074924
Reply with quote  #2

1715074924
Report to moderator
1715074924
Hero Member
*
Offline Offline

Posts: 1715074924

View Profile Personal Message (Offline)

Ignore
1715074924
Reply with quote  #2

1715074924
Report to moderator
DannyHamilton
Legendary
*
Offline Offline

Activity: 3388
Merit: 4623



View Profile
November 14, 2014, 02:54:47 PM
 #2

You're first going to need to parse the entire blockchain and load all the transaction data into some sort of query-able database.

Then you'll need a program that can interface with your database that can search for addresses that match your criteria.

Note that due to "shared send" features provided by some services and the ability of individuals to create shared transactions, you can't necessarily assume that two addresses that are both referenced by inputs from the same transaction are controlled by the same entity.  You can make an educated guess in some circumstances that they might both be controlled by the same entity, but there is always a risk that your guess is wrong.

There are block explorers (such as blockchain.info and blockr.io) that have already parsed the blockchain and loaded it into a database.  If your needs are small enough you can use an API to access their database to search for the addresses you're interested in rather than needing to create and search your own database.  If you're going to be trying to match up every possible address that has ever existed with every other address that it is "linked to" it through inputs to transactions, then you're probably going to be exceeding the limitations of their APIs and you'll need to invest in a more custom designed system.
dwma (OP)
Sr. Member
****
Offline Offline

Activity: 405
Merit: 250


View Profile
November 14, 2014, 08:09:30 PM
 #3


I believe I understand what you mean by entity.  I am fine with a private key representing multiple people.  I was hoping someone had written software to readily do this on github etc.
DannyHamilton
Legendary
*
Offline Offline

Activity: 3388
Merit: 4623



View Profile
November 14, 2014, 08:21:22 PM
 #4


I believe I understand what you mean by entity.  I am fine with a private key representing multiple people.  I was hoping someone had written software to readily do this on github etc.

Not that I'm aware of, but if you find anything, let me know.
shorena
Copper Member
Legendary
*
Offline Offline

Activity: 1498
Merit: 1499


No I dont escrow anymore.


View Profile WWW
November 14, 2014, 09:06:07 PM
 #5


I believe I understand what you mean by entity.  I am fine with a private key representing multiple people.  I was hoping someone had written software to readily do this on github etc.

A private key may not only be used by several people but a TX may also include several signatures by different private keys. This is might be the case when there are more than a single input, depending on their origin. This however does not let you conclude that these private keys are controlled by the same person/wallet or even by a number of people that know eachother. Not sure what you want to research here.

A simple list of all known addresses -or rather those that have been used at least once- however would be possible.

Im not really here, its just your imagination.
DannyHamilton
Legendary
*
Offline Offline

Activity: 3388
Merit: 4623



View Profile
November 14, 2014, 09:21:02 PM
 #6


I believe I understand what you mean by entity.  I am fine with a private key representing multiple people.  I was hoping someone had written software to readily do this on github etc.

A private key may not only be used by several people but a TX may also include several signatures by different private keys. This is might be the case when there are more than a single input, depending on their origin. This however does not let you conclude that these private keys are controlled by the same person/wallet or even by a number of people that know eachother. Not sure what you want to research here.

A simple list of all known addresses -or rather those that have been used at least once- however would be possible.

As an example of what Shorena is describing...

Imagine that I have an unspent output valued at 2 BTC and I want to send 1 BTC to a business.
Imagine that Shorena has an unspent output valued at 1 BTC and wants to send 0.5 BTC to another business.

It is possible for Shorena and I to agree to share a transaction.  I can tell Shorena which output I intend to spend, what address I want the 1 BTC to go to, and what change address I want the 1 BTC of change to go to, without telling Shorena my private key at all.

Shorena can then create a single transaction that spends as inputs both his 1 BTC output and my 2 BTC output (providing a total of 3 BTC of value to the single transaction).  Shorena can create 4 outputs in the transaction, 0.5 BTC to the business he wants to pay, 1 BTC to the business that I want to pay, 0.5 BTC to his change address, and 1 BTC to my change address.

Shorena can now sign the transaction with his private key, and send the partially signed transaction to me without telling me his private key at all.

I can look at the transaction and verify that it is spending the input that I want to spend and that it is both paying the correct amount to the business that I want to pay, and sending my change back to my address.  I can then sign the transaction with my private key and broadcast it.  Shorena doesn't need to worry about me modifying the transaction and stealing his bitcoins, because if I tried to do that then the signature he provided would no longer be valid.

Now, there is a single transaction that has 2 inputs.  I am the only person in the world that knows the private key used for the signature on one of the inputs, and Shorena is the only person in the world that knows the private key used for the signature on the other input.  Yet, the software you are describing will assume that Shorena's address and my address belong to the same wallet (or same person, or same entity).  Furthermore, any other addresses that either Shorena or I have every used along with either of those two addresses will also be linked to that pair.  Suddenly your software thinks that Shorena and I are both the same person (or wallet, or entity).

If I do the exact same thing again with some other person that Shorena has never mey and knows absolutely nothing about, Shorena's addresses will then be linked to that complete stranger's (to Shorena) addresses.

dwma (OP)
Sr. Member
****
Offline Offline

Activity: 405
Merit: 250


View Profile
November 15, 2014, 02:40:34 AM
 #7


This is an interesting discussion.  Is there software that uses transactions structured in such a way or is it more of a possible case that isn't really used ?
DannyHamilton
Legendary
*
Offline Offline

Activity: 3388
Merit: 4623



View Profile
November 15, 2014, 05:15:17 AM
 #8

- snip -
Is there software that uses transactions structured in such a way
- snip -

https://sharedcoin.com/

https://bitcointalk.org/index.php?topic=279249.0
BitCoinDream
Legendary
*
Offline Offline

Activity: 2324
Merit: 1204

The revolution will be digital


View Profile
November 15, 2014, 10:43:18 AM
 #9

- snip -
Is there software that uses transactions structured in such a way
- snip -

https://sharedcoin.com/

https://bitcointalk.org/index.php?topic=279249.0

SharedCoin.com simply takes to blockchain.info. So, I guess, it is not functional...

shorena
Copper Member
Legendary
*
Offline Offline

Activity: 1498
Merit: 1499


No I dont escrow anymore.


View Profile WWW
November 15, 2014, 10:45:38 AM
 #10

- snip -
Is there software that uses transactions structured in such a way
- snip -

https://sharedcoin.com/

https://bitcointalk.org/index.php?topic=279249.0

SharedCoin.com simply takes to blockchain.info. So, I guess, it is not functional...

It is, it just requires you to have a bc.i wallet.

Im not really here, its just your imagination.
DannyHamilton
Legendary
*
Offline Offline

Activity: 3388
Merit: 4623



View Profile
November 15, 2014, 01:41:33 PM
 #11

- snip -
Is there software that uses transactions structured in such a way
- snip -

https://sharedcoin.com/

https://bitcointalk.org/index.php?topic=279249.0

SharedCoin.com simply takes to blockchain.info. So, I guess, it is not functional...

SharedCoin.com is blockchain.info.  The web page simply describes the "SharedSend" process that the blockchain.info wallet uses.  It is completely functional, and many people use it every day.
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!