summaryrefslogtreecommitdiff
path: root/src/lib/libcrypto/man/BN_new.3
diff options
context:
space:
mode:
authorschwarze <>2018-04-29 15:58:21 +0000
committerschwarze <>2018-04-29 15:58:21 +0000
commita60c20fc32aa2f822c683424f5bd90611e4d452f (patch)
treef067081374e9045588229a0f9af9373361fb2cbe /src/lib/libcrypto/man/BN_new.3
parent0a991f6de98776a2cd65f3529adb8948b51c275a (diff)
downloadopenbsd-a60c20fc32aa2f822c683424f5bd90611e4d452f.tar.gz
openbsd-a60c20fc32aa2f822c683424f5bd90611e4d452f.tar.bz2
openbsd-a60c20fc32aa2f822c683424f5bd90611e4d452f.zip
In view of the recent BN_FLG_CONSTTIME vulnerabilities in OpenSSL,
carefully document constant time vs. non-constant time operation of BN_div(3), BN_mod_exp(3), and BN_mod_inverse(3). Until the work that is required on the ill-designed BN_exp(3) and BN_gcd(3) interfaces can be undertaken, also document the imperfections in their behaviour, for now. Finally, mention BN_mod_exp(3) behaviour for even moduli. Delete the vague statement about some functions automatically setting BN_FLG_CONSTTIME. It created a false sense of security. Do not rely on it: not all relevant functions do that. Topic brought up by beck@, significant feedback and OK jsing@.
Diffstat (limited to 'src/lib/libcrypto/man/BN_new.3')
-rw-r--r--src/lib/libcrypto/man/BN_new.310
1 files changed, 7 insertions, 3 deletions
diff --git a/src/lib/libcrypto/man/BN_new.3 b/src/lib/libcrypto/man/BN_new.3
index e27a83e042..ed2910e645 100644
--- a/src/lib/libcrypto/man/BN_new.3
+++ b/src/lib/libcrypto/man/BN_new.3
@@ -1,4 +1,4 @@
1.\" $OpenBSD: BN_new.3,v 1.13 2018/03/27 17:35:50 schwarze Exp $ 1.\" $OpenBSD: BN_new.3,v 1.14 2018/04/29 15:58:21 schwarze Exp $
2.\" full merge up to: OpenSSL man3/BN_new 2457c19d Mar 6 08:43:36 2004 +0000 2.\" full merge up to: OpenSSL man3/BN_new 2457c19d Mar 6 08:43:36 2004 +0000
3.\" selective merge up to: man3/BN_new 681acb31 Sep 29 13:10:34 2017 +0200 3.\" selective merge up to: man3/BN_new 681acb31 Sep 29 13:10:34 2017 +0200
4.\" full merge up to: OpenSSL man7/bn 05ea606a May 20 20:52:46 2016 -0400 4.\" full merge up to: OpenSSL man7/bn 05ea606a May 20 20:52:46 2016 -0400
@@ -50,7 +50,7 @@
50.\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED 50.\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED
51.\" OF THE POSSIBILITY OF SUCH DAMAGE. 51.\" OF THE POSSIBILITY OF SUCH DAMAGE.
52.\" 52.\"
53.Dd $Mdocdate: March 27 2018 $ 53.Dd $Mdocdate: April 29 2018 $
54.Dt BN_NEW 3 54.Dt BN_NEW 3
55.Os 55.Os
56.Sh NAME 56.Sh NAME
@@ -102,7 +102,11 @@ or accessed directly.
102.Fn BN_new 102.Fn BN_new
103allocates and initializes a 103allocates and initializes a
104.Vt BIGNUM 104.Vt BIGNUM
105structure, in particular setting the value to zero. 105structure, in particular setting the value to zero and the flags to
106.Dv BN_FLG_MALLOCED .
107The security-relevant flag
108.Dv BN_FLG_CONSTTIME
109is not set by default.
106.Pp 110.Pp
107.Fn BN_init 111.Fn BN_init
108initializes an existing uninitialized 112initializes an existing uninitialized