dsa_ameth.c (306195) | dsa_ameth.c (325337) |
---|---|
1/* 2 * Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL project 3 * 2006. 4 */ 5/* ==================================================================== 6 * Copyright (c) 2006 The OpenSSL Project. All rights reserved. 7 * 8 * Redistribution and use in source and binary forms, with or without --- 244 unchanged lines hidden (view full) --- 253 DSAerr(DSA_F_DSA_PRIV_DECODE, ERR_R_MALLOC_FAILURE); 254 goto dsaerr; 255 } 256 if (!(ctx = BN_CTX_new())) { 257 DSAerr(DSA_F_DSA_PRIV_DECODE, ERR_R_MALLOC_FAILURE); 258 goto dsaerr; 259 } 260 | 1/* 2 * Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL project 3 * 2006. 4 */ 5/* ==================================================================== 6 * Copyright (c) 2006 The OpenSSL Project. All rights reserved. 7 * 8 * Redistribution and use in source and binary forms, with or without --- 244 unchanged lines hidden (view full) --- 253 DSAerr(DSA_F_DSA_PRIV_DECODE, ERR_R_MALLOC_FAILURE); 254 goto dsaerr; 255 } 256 if (!(ctx = BN_CTX_new())) { 257 DSAerr(DSA_F_DSA_PRIV_DECODE, ERR_R_MALLOC_FAILURE); 258 goto dsaerr; 259 } 260 |
261 BN_set_flags(dsa->priv_key, BN_FLG_CONSTTIME); |
|
261 if (!BN_mod_exp(dsa->pub_key, dsa->g, dsa->priv_key, dsa->p, ctx)) { 262 DSAerr(DSA_F_DSA_PRIV_DECODE, DSA_R_BN_ERROR); 263 goto dsaerr; 264 } 265 266 EVP_PKEY_assign_DSA(pkey, dsa); 267 268 ret = 1; --- 410 unchanged lines hidden --- | 262 if (!BN_mod_exp(dsa->pub_key, dsa->g, dsa->priv_key, dsa->p, ctx)) { 263 DSAerr(DSA_F_DSA_PRIV_DECODE, DSA_R_BN_ERROR); 264 goto dsaerr; 265 } 266 267 EVP_PKEY_assign_DSA(pkey, dsa); 268 269 ret = 1; --- 410 unchanged lines hidden --- |