Bitcoin Forum
November 02, 2024, 09:01:52 PM *
News: Latest Bitcoin Core release: 28.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: How to sign a transaction ?  (Read 571 times)
upal (OP)
Full Member
***
Offline Offline

Activity: 165
Merit: 102


View Profile
December 26, 2013, 10:55:42 AM
 #1

In bitcoin protocol can I sign a transaction ? If yes, how ? Any example is highly appreciated.
AldenHurley
Newbie
*
Offline Offline

Activity: 12
Merit: 0


View Profile
December 26, 2013, 10:59:21 AM
 #2

Every transaction you send is signed using your wallet's private key. This ensures the transaction in fact came from your wallet.
upal (OP)
Full Member
***
Offline Offline

Activity: 165
Merit: 102


View Profile
December 26, 2013, 11:01:27 AM
 #3

Every transaction you send is signed using your wallet's private key. This ensures the transaction in fact came from your wallet.

Yes, but that is not public on a transaction. I need a public message to verify the ownership from vendor's end.
escrow.ms
Legendary
*
Offline Offline

Activity: 1274
Merit: 1004


View Profile
December 26, 2013, 11:08:00 AM
 #4

Which wallet you are using?
upal (OP)
Full Member
***
Offline Offline

Activity: 165
Merit: 102


View Profile
December 26, 2013, 11:20:23 AM
 #5

Which wallet you are using?

It is not about my wallet. Its about transaction from any wallet to my wallet that is to be read... and my wallet can be on the web or on my machine.
escrow.ms
Legendary
*
Offline Offline

Activity: 1274
Merit: 1004


View Profile
December 26, 2013, 11:27:05 AM
 #6

Which wallet you are using?

It is not about my wallet. Its about transaction from any wallet to my wallet that is to be read... and my wallet can be on the web or on my machine.

You just said this.


Yes, but that is not public on a transaction. I need a public message to verify the ownership from vendor's end.
edit: Sorry I am not able to understand you. You want to sign a message from some wallet or what?

or are you talking about this kind of messages in transactions.
upal (OP)
Full Member
***
Offline Offline

Activity: 165
Merit: 102


View Profile
December 26, 2013, 11:34:44 AM
 #7

An user is in my app and making a transaction to my BTC address and claiming that he has made the transaction. Now I have to verify whether it is his transaction or someone else's that he is claiming to be his. So I'll generate an order no. from my app which he can attach with the transaction and I can read through API. I am looking for this way...

How he can attach my order no. in his transaction and how can I read that through an API ?

escrow.ms
Legendary
*
Offline Offline

Activity: 1274
Merit: 1004


View Profile
December 26, 2013, 11:53:20 AM
 #8

Well I doubt there's any other way except signing a message from that address

He can sign a message (Order number) from his address (from which payment was sent) and provide you address, signature and message.  You can then use Blockchain.info's api to verify that message.

https://blockchain.info/api/json_rpc_api  (Scroll to bottom)


   
Quote
Method: verifymessage
    Parameters: (String bitcoinaddress, String signature, String message)
    Description: Verifies the signature and message matches the bitcoin address provided (See signmessage)
    Returns: Boolean


upal (OP)
Full Member
***
Offline Offline

Activity: 165
Merit: 102


View Profile
December 26, 2013, 01:51:10 PM
 #9

Thank u. Can u plz help me out on this topic => https://bitcointalk.org/index.php?topic=385733.0 ?
DannyHamilton
Legendary
*
Offline Offline

Activity: 3472
Merit: 4801



View Profile
December 26, 2013, 11:20:00 PM
 #10

An user is in my app and making a transaction to my BTC address and claiming that he has made the transaction. Now I have to verify whether it is his transaction or someone else's that he is claiming to be his. . .

You should be generating a new receiving address for every transaction.

This way you know exactly who made the payment, since you only provided the payment address to a single person.  You know exactly what theya re paying for, because you supplied that address for a specific payment of a specific set of products or services.

If this is not how you coded your app, then you are doing it wrong.
infinitybo
Newbie
*
Offline Offline

Activity: 28
Merit: 0


View Profile
December 27, 2013, 03:04:21 PM
 #11

@Upal Yes you can sign a transaction furthermore that's possible by using the Bitcoin client.
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!