Bitcoin Forum

Bitcoin => Electrum => Topic started by: SupZ on May 05, 2017, 07:22:44 PM



Title: cant sign message
Post by: SupZ on May 05, 2017, 07:22:44 PM
Hi,

Im trying to sign a message but get this error:

"Cannot sign messages with this type of address."

And if I try console command I get this error:

"AttributeError: 'Wallet_2fa' object has no attribute 'sign_message'"


What can I do?
Ive used my Electrum wallet to participate in an ICO, and they demand to sign a message for distribution  :-\


Title: Re: cant sign message
Post by: Patatas on May 05, 2017, 07:25:27 PM
Hi,

Im trying to sign a message but get this error:

"Cannot sign messages with this type of address."

And if I try console command I get this error:

"AttributeError: 'Wallet_2fa' object has no attribute 'sign_message'"


What can I do?
Ive used my Electrum wallet to participate in an ICO, and they demand to sign a message for distribution  :-\
Following error has been discussed several times on/off bitcointalk.Had you read their documentation,you'd get required help.Anyway follow this thread : https://bitcointalk.org/index.php?topic=1149503.0 Worked for me,should work for you too.
Lock the thread once sorted.


Title: Re: cant sign message
Post by: SupZ on May 05, 2017, 07:29:18 PM
Hi,

Im trying to sign a message but get this error:

"Cannot sign messages with this type of address."

And if I try console command I get this error:

"AttributeError: 'Wallet_2fa' object has no attribute 'sign_message'"


What can I do?
Ive used my Electrum wallet to participate in an ICO, and they demand to sign a message for distribution  :-\
Following error has been discussed several times on/off bitcointalk.Had you read their documentation,you'd get required help.Anyway follow this thread : https://bitcointalk.org/index.php?topic=1149503.0 Worked for me,should work for you too.
Lock the thread once sorted.

I tried that and it works for encrypting, but I dont really know if signing and encrypting is the same thing, they're two different options.  ???


Title: Re: cant sign message
Post by: SupZ on May 06, 2017, 10:29:30 AM

I tried that and it works for encrypting, but I dont really know if signing and encrypting is the same thing, they're two different options.  ???

Encrypting and Signing are two different actions.

For Encrypting; the origin uses the Public Key to encrypt, and the destination uses the Private key to decrypt.  Use case, someone wants to send you an encrypted message that only you can decrypt.  You send them your Public Key (bitcoin address) and they send you the encrypted message.

For Signing; the origin uses the Private Key to sign, and the destination uses the Public Key to validate the signature.  Use case, the ICO you are talking about.  They want to verify that you are the owner of the bitcoin address, so they ask you to sign a message and forward them the signature (along with the public key -- bitcoin address).

Therefore, in your case, you only have to:

1. Copy to the clipboard the bitcoin address you want to sign your message with.  (Addresses tab, select Address, right-click and select Copy Address).  
2. Tools --> Sign/Verify Message
3. Paste your bitcoin address in the appropriate field, and write down your message
4. Click the Sign button (Electrum may ask you to enter your password to access the private key associated with your bitcoin address).

 The "signature" should appear in the bottom window.  

Provide both the message, the bitcoin address and the signature to the destination.

EDIT:  I read again your opening message and it looks like you are trying to sign a message with a 2FA wallet.  If that is the case, it is not possible to sign a message directly with your wallet.   The reason is simple, you don't have full control of the private keys associated with the bitcoin address, it is a 2 out of 3 multi signature address. Therefore, you would need all the 3 private keys to sign with this type of bitcoin address.  And this is exactly what the message is telling you: "Cannot sign messages with this type of address."

For your ICO, it seems that you would have to use a bitcoin address that starts with a "1" (not a "3").



Got it, thanks for the explication.
Ill see if I can talk with them in that case...  :-\

Thanks.