Post
Topic
Board Development & Technical Discussion
Re: Check if your BTC-key is vulnerable
by
itod
on 23/04/2015, 06:44:30 UTC
how to get ( sop1 & sop2 ) these two value,
any formula or any script available...........

Not too easy. You should have good lib for bitcoin transactions to create "a template" and take a sha256d () of it.
Here is a piece of my code. But it will be useless for you. Just a pseudo-code

Code:
const MyKey32 Transaction::getRawHash ( const int n, const QByteArray& scr ) const
{
  MyByteArray ret;                                     // create empty array
  Stream stream ( s );                               
  ret.putInt32 ( stream.readU32 ( ) );                 // version
  ret.putVarInt ( stream.readVar ( ) );                // input count
  for ( int i ( 0 ); i < inputs; i++ )                 // copy all inputs
  {
    ret.append ( stream.readHash ( ) );                // copy 32 byte hash as is
    ret.putInt32 ( stream.readU32 ( ) );               // copy 4 bytes index
    stream.skipVarData ( );                            // skip original script
    ret.putPrefixedCond ( i ^ n, scr );                // script replacement
    ret.putInt32 ( stream.readU32 ( ) );
  }
  ret.putVarInt ( stream.readVar ( ) );                // output count
  for ( int i ( 0 ); i < outputs; i++ )                // copy all outputs byte-by-byte
  {
    ret.putInt64 ( stream.readU64 ( ) );
    ret.putPrefixed ( stream.readVarData ( ) );
  }
  ret.putInt32 ( stream.readU32 ( ) );                 // lock
  ret.putInt32 ( SIGHASH_ALL );                        // append hashcode
  return MyKey32 ( ret.constData ( ), ret.size ( ) );  // create hash256 of array
}

Thank you

http://bitcoin.stackexchange.com/questions/25387/how-to-get-the-z-value-aka-hash-of-the-outputs-to-be-signed

http://bitcoin.stackexchange.com/questions/25814/ecdsa-signature-and-the-z-value

http://bitcoin.stackexchange.com/questions/3374/how-to-redeem-a-basic-tx

here i get explanation, i almost understand but not clear, i need step by step explanation please...

After this things will be clearer:

https://blog.cloudflare.com/a-relatively-easy-to-understand-primer-on-elliptic-curve-cryptography/