Bitcoin Forum
November 10, 2024, 07:05:01 PM *
News: Latest Bitcoin Core release: 28.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: Can I use the Bitcoin client to send a transaction to a raw ECDSA pub address?  (Read 787 times)
Sergio_Demian_Lerner (OP)
Hero Member
*****
expert
Offline Offline

Activity: 555
Merit: 654


View Profile WWW
April 26, 2013, 10:24:22 PM
 #1

If I want the output script to look like: <pubKey> OP_CHECKSIG

By looking at the code I see no way if doing it.

Is there a way?

Thanks, Sergio.
scintill
Sr. Member
****
Offline Offline

Activity: 448
Merit: 254


View Profile WWW
April 26, 2013, 10:31:36 PM
 #2

You can craft a raw transaction yourself and send it with an RPC command, but I assume you mean you want the stock client to build it for you?  AFAICT that kind of script is only made for generation transactions.

1SCiN5kqkAbxxwesKMsH9GvyWnWP5YK2W | donations
etotheipi
Legendary
*
expert
Offline Offline

Activity: 1428
Merit: 1093


Core Armory Developer


View Profile WWW
April 27, 2013, 01:23:54 AM
 #3

If I want the output script to look like: <pubKey> OP_CHECKSIG

By looking at the code I see no way if doing it.

Is there a way?

Thanks, Sergio.


I don't know what you mean by "is there a way to do it?"    Yes, it's a valid script.  In fact, it used to be the standard script for coinbase transactions:  miners would actually use the script instead of the hash160 form for the generation output.  I don't know why, but that's what showed up in this diagram because that's what all coinbases looked like when I made the diagram (two years ago).

As for whether it's standard, I don't know.  It didn't matter back then because it didn't need to propagate.  It was only used by miners for their own reward, so the only person that needed to see it before it showed up in a block was themselves.  So propagation was irrelevant, as long as it was valid.

I wonder if the general perception that "hidden" public keys is a more long-term viable security position, has something to do with it (i.e. in case those coins aren't moved for the next 30 years, then they don't have to worry about QCs).

Founder and CEO of Armory Technologies, Inc.
Armory Bitcoin Wallet: Bringing cold storage to the average user!
Only use Armory software signed by the Armory Offline Signing Key (0x98832223)

Please donate to the Armory project by clicking here!    (or donate directly via 1QBDLYTDFHHZAABYSKGKPWKLSXZWCCJQBX -- yes, it's a real address!)
scintill
Sr. Member
****
Offline Offline

Activity: 448
Merit: 254


View Profile WWW
April 27, 2013, 03:42:49 AM
 #4

In fact, it used to be the standard script for coinbase transactions:  miners would actually use the script instead of the hash160 form for the generation output.

It still seems to be the default, although perhaps modern pools are using the hash160.  A quick survey of recent blocks showed at least one using just the pubkey, though.

As for whether it's standard, I don't know.

It is recognized by the script solver, so should be accepted as a relayable tx type.  The comment even says pubkey-only is "standard", and the more familiar type is "Bitcoin address"*.

Feel free to correct me; you two know your way around the code a lot better than I do.

* Trivia I stumbled on: In the earliest commit it was "short account number".

1SCiN5kqkAbxxwesKMsH9GvyWnWP5YK2W | donations
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!