bdd-predicate icon indicating copy to clipboard operation
bdd-predicate copied to clipboard

How to use in code separate R and S ?

Open Hurd8x opened this issue 4 years ago • 9 comments

assert self.vk.verify_digest(binascii.unhexlify(r + s), binascii. unhexlify(h))
File "/usr/local/lib/python3.8/dist-packages/ecdsa/keys.py", line 7 36, in verify_digest
raise BadSignatureError("Signature verification failed")
ecdsa.keys.BadSignatureError: Signature verification failed

Data:

252 2503c98044978d05e58731b79ede85b20812277abc1fdd357c9b48dbd962c93a 5639dfdc8ebc5bb8e3f1ca5c01c0f72bb8805192b6371fa8f7f4b983c3dc52760324dfe5559f104a992b5afad5a8e4f215ca3d555cef7381dfd9ebe59a20a1d2 16d983757e7d4bed7ed027f1a3c28456ceff746fa7596ef7c7157bd06d7a07c71ea5e685e9fd3e91af9fb3528bdfa5806a106f4f742a246ba7c2994b68966bfa 252 e152b8c19c5305b927baa382de6294e71e2ff82151f7e1f9b1c6a2d3aed2740b 4c84672c7999f9cb7870f026c608615644348a18ea1167ef30bfa60418e22efa51522dcc056b8b4475bf927426f5643646e8807e898fcbba8aaf022601424643 16d983757e7d4bed7ed027f1a3c28456ceff746fa7596ef7c7157bd06d7a07c71ea5e685e9fd3e91af9fb3528bdfa5806a106f4f742a246ba7c2994b68966bfa 252 03af766a01e60fd58a013532a37ea3d75a38a9808e33cd3ac8b3bef68463577e edb78c910bca36b3af5b5e99728994fece11fc69ab01adb7316e5344216decfc3cfd451bb6f4ee2a7caf34705f51f10ae9ede249ae8516dc9cc8f78e1fbbb858 7ca97a3d99daae49c80de2ef5b93e912e7a4b79f915811715508e283f9dc83c3397d39580a74fee77b235745cea31c1af17790385c3aaa7bd8a93d663cc3b0e7 252 264b2271538562e36db7db8b4ff74a275c3c02428c17cd84601382a81ae0a152 b9f3705a8c297af2e2f9ee86dc6fb47adaed3b8953b9dae14849972ab73692c577852e0d4cdc0ed5b20f760e7fdc59bcc34baa8206d06820dd4448e765b5da2c 7ca97a3d99daae49c80de2ef5b93e912e7a4b79f915811715508e283f9dc83c3397d39580a74fee77b235745cea31c1af17790385c3aaa7bd8a93d663cc3b0e7 252 1bf931fad4c91372aa899120e441930709af7186d3436d9083c2b6555ea1b494 f0b029947bd513d1b286827da38b9c496332aa820175aba1643e322848ae07603e8199f895443e33db94cfb2fdcd6bad91217995331764c207f57321562d3a12 fb3b5393dd20eed0b1fe12052ce952ca725f78055ca23ce10e7befe0ef3360aac0f2f08e6e27bff437ecd7cf5b308a0b23b469641962cf29a0b86b7a8732e255 252 c93f45df8970203e72c1a322b7353d3ec4839a135f56f928f2e18cfd64a5d379


((((((

Hurd8x avatar Oct 31 '21 20:10 Hurd8x

Heeelp me please ?😭

Hurd8x avatar Nov 01 '21 00:11 Hurd8x

Help please??? Need a help ASAP GUYS !!!!!

Hurd8x avatar Nov 01 '21 06:11 Hurd8x

What is the question here actually?

Checking your signature and hash they seem to be valid. But why are you using the first pubx,y. There is a second one:

Pub(1): 16d983757e7d4bed7ed027f1a3c28456ceff746fa7596ef7c7157bd06d7a07c71ea5e685e9fd3e91af9fb3528bdfa5806a106f4f742a246ba7c2994b68966bfa Pub(2): 36d370e14bf63c58a49b545b0390b4a3df850424a877f5aa4d8132dae936a58892c4f7e88e7d6aac262f10d3639aefe90e3e981b8eea7744a50ff0335397634a

-e

eychei avatar Nov 18 '21 07:11 eychei

Yes qeschion is actual !!! Noooo !!! This is not actual data, actual data in attached file: 28.txt

Hurd8x avatar Nov 18 '21 07:11 Hurd8x

What kind of bias do you have? LSB zeros? MSB zeros? How many? What is the know bit of the nounce in hex?

eychei avatar Nov 18 '21 07:11 eychei

What kind of bias do you have? LSB zeros? MSB zeros? How many? What is the know bit of the nounce in hex?

MSB, nonce 252, - first 4-16 bits, and bits  are zeroes ?😥

How to run code with my data without errors ? Please.

Hurd8x avatar Nov 18 '21 07:11 Hurd8x

Hi,

I just tried your data and it does not work. I do get the same error with the signature fail.

Did you verify the r/s signature with the hash and public key? Are these all ok? Using input data generated for p192 and also for sek256k1 does work for me.

-e

eychei avatar Nov 18 '21 09:11 eychei

Hi,

I just tried your data and it does not work. I do get the same error with the signature fail.

Did you verify the r/s signature with the hash and public key? Are these all ok? Using input data generated for p192 and also for sek256k1 does work for me.

-e

Hash is s sighnature message hash ? Yes, Z is a sighnatures message hash, but I dont know exact what you mean about hash, maybe this is a sighned message ? But length of sighned message have more bytes then in your example.txt file. Seck256k1 you mean secp256k1 ? Code have a bug, I dont know there...

Hurd8x avatar Nov 18 '21 16:11 Hurd8x

Hi, I just tried your data and it does not work. I do get the same error with the signature fail. Did you verify the r/s signature with the hash and public key? Are these all ok? Using input data generated for p192 and also for sek256k1 does work for me. -e

Hash is s sighnature message hash ? Yes, Z is a sighnatures message hash, but I dont know exact what you mean about hash, maybe this is a sighned message ? But length of sighned message have more bytes then in your example.txt file. Seck256k1 you mean secp256k1 ? Code have a bug, I dont know there...

Am getting same error message. Was wondering which hash is supposed to be used?

cloudkeychain avatar Jul 21 '22 17:07 cloudkeychain