Rev

Rev 3345 | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | SVN | Bug Tracker

Rev 3345 Rev 3350
Line 737... Line 737...
737
  }
737
  }
738
738
739
  const BIGNUM* r = nullptr;
739
  const BIGNUM* r = nullptr;
740
  const BIGNUM* s = nullptr;
740
  const BIGNUM* s = nullptr;
741
  ::ECDSA_SIG_get0(signature, &r, &s);
741
  ::ECDSA_SIG_get0(signature, &r, &s);
-
 
742
  loggers::get_instance().log("security_ecc::sign: r size: %d", BN_num_bytes(r));
742
  p_r_sig = int2oct(0, BN_num_bytes(r));
743
  p_r_sig = int2oct(0, BN_num_bytes(r));
743
  ::BN_bn2bin(r, (unsigned char*)static_cast<const unsigned char*>(p_r_sig));
744
  ::BN_bn2bin(r, (unsigned char*)static_cast<const unsigned char*>(p_r_sig));
744
  loggers::get_instance().log_msg("security_ecc::sign: r=", p_r_sig);
745
  loggers::get_instance().log_msg("security_ecc::sign: r=", p_r_sig);
-
 
746
  loggers::get_instance().log("security_ecc::sign: s size: %d", BN_num_bytes(s));
745
  p_s_sig = int2oct(0, BN_num_bytes(s));
747
  p_s_sig = int2oct(0, BN_num_bytes(s));
746
  ::BN_bn2bin(s, (unsigned char*)static_cast<const unsigned char*>(p_s_sig));
748
  ::BN_bn2bin(s, (unsigned char*)static_cast<const unsigned char*>(p_s_sig));
747
  loggers::get_instance().log_msg("security_ecc::sign: s=", p_s_sig);
749
  loggers::get_instance().log_msg("security_ecc::sign: s=", p_s_sig);
748
750
749
  ::ECDSA_SIG_free(signature);
751
  ::ECDSA_SIG_free(signature);