From ad110f3f2f3fa3daf2776f77c7adb6d3e866e18a Mon Sep 17 00:00:00 2001 From: schwarze Date: Mon, 6 Dec 2021 19:45:27 +0000 Subject: [PATCH] In the next major bump, some BN macros will become functions. In order to not forget it, already remove the statements that these APIs are currently implemented as macros: Not saying that doesn't make the documentation wrong. --- lib/libcrypto/man/BN_cmp.3 | 11 ++--------- lib/libcrypto/man/BN_copy.3 | 6 +++--- lib/libcrypto/man/BN_mod_mul_montgomery.3 | 7 ++----- lib/libcrypto/man/BN_set_flags.3 | 9 ++------- lib/libcrypto/man/BN_set_negative.3 | 5 ++--- 5 files changed, 11 insertions(+), 27 deletions(-) diff --git a/lib/libcrypto/man/BN_cmp.3 b/lib/libcrypto/man/BN_cmp.3 index 8064b7e90d5..5c1fad64a00 100644 --- a/lib/libcrypto/man/BN_cmp.3 +++ b/lib/libcrypto/man/BN_cmp.3 @@ -1,4 +1,4 @@ -.\" $OpenBSD: BN_cmp.3,v 1.7 2021/11/30 18:34:35 tb Exp $ +.\" $OpenBSD: BN_cmp.3,v 1.8 2021/12/06 19:45:27 schwarze Exp $ .\" OpenSSL b97fdb57 Nov 11 09:33:09 2016 +0100 .\" .\" This file was written by Ulf Moeller . @@ -48,7 +48,7 @@ .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED .\" OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.Dd $Mdocdate: November 30 2021 $ +.Dd $Mdocdate: December 6 2021 $ .Dt BN_CMP 3 .Os .Sh NAME @@ -108,13 +108,6 @@ equals 0, 1, or respectively. .Fn BN_is_odd tests if a is odd. -.Pp -.Fn BN_is_zero , -.Fn BN_is_one , -.Fn BN_is_word , -and -.Fn BN_is_odd -are macros. .Sh RETURN VALUES .Fn BN_cmp returns -1 if diff --git a/lib/libcrypto/man/BN_copy.3 b/lib/libcrypto/man/BN_copy.3 index 956b368dec4..383255e382f 100644 --- a/lib/libcrypto/man/BN_copy.3 +++ b/lib/libcrypto/man/BN_copy.3 @@ -1,4 +1,4 @@ -.\" $OpenBSD: BN_copy.3,v 1.9 2018/03/27 17:35:50 schwarze Exp $ +.\" $OpenBSD: BN_copy.3,v 1.10 2021/12/06 19:45:27 schwarze Exp $ .\" OpenSSL b97fdb57 Nov 11 09:33:09 2016 +0100 .\" .\" This file was written by Ulf Moeller @@ -49,7 +49,7 @@ .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED .\" OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.Dd $Mdocdate: March 27 2018 $ +.Dd $Mdocdate: December 6 2021 $ .Dt BN_COPY 3 .Os .Sh NAME @@ -97,7 +97,7 @@ in It places significant restrictions on the copied data. Applications that do not adhere to these restrictions may encounter unexpected side effects or crashes. -For that reason, use of this macro is discouraged. +For that reason, use of this function is discouraged. .Pp Any flags provided in .Fa flags diff --git a/lib/libcrypto/man/BN_mod_mul_montgomery.3 b/lib/libcrypto/man/BN_mod_mul_montgomery.3 index d87b50d6a8a..963ba8fcd46 100644 --- a/lib/libcrypto/man/BN_mod_mul_montgomery.3 +++ b/lib/libcrypto/man/BN_mod_mul_montgomery.3 @@ -1,4 +1,4 @@ -.\" $OpenBSD: BN_mod_mul_montgomery.3,v 1.12 2021/11/30 18:34:35 tb Exp $ +.\" $OpenBSD: BN_mod_mul_montgomery.3,v 1.13 2021/12/06 19:45:27 schwarze Exp $ .\" OpenSSL 6859cf74 Sep 25 13:33:28 2002 +0000 .\" .\" This file was written by Ulf Moeller . @@ -48,7 +48,7 @@ .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED .\" OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.Dd $Mdocdate: November 30 2021 $ +.Dd $Mdocdate: December 6 2021 $ .Dt BN_MOD_MUL_MONTGOMERY 3 .Os .Sh NAME @@ -195,9 +195,6 @@ typedef struct bn_mont_ctx_st { } BN_MONT_CTX; .Ed .Pp -.Fn BN_to_montgomery -is a macro. -.Pp .Sy Warning : The inputs must be reduced modulo .Fa m , diff --git a/lib/libcrypto/man/BN_set_flags.3 b/lib/libcrypto/man/BN_set_flags.3 index 8b2c4044521..2baa990787f 100644 --- a/lib/libcrypto/man/BN_set_flags.3 +++ b/lib/libcrypto/man/BN_set_flags.3 @@ -1,4 +1,4 @@ -.\" $OpenBSD: BN_set_flags.3,v 1.4 2021/03/12 05:18:00 jsg Exp $ +.\" $OpenBSD: BN_set_flags.3,v 1.5 2021/12/06 19:45:27 schwarze Exp $ .\" .\" Copyright (c) 2017 Ingo Schwarze .\" @@ -14,7 +14,7 @@ .\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF .\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. .\" -.Dd $Mdocdate: March 12 2021 $ +.Dd $Mdocdate: December 6 2021 $ .Dt BN_SET_FLAGS 3 .Os .Sh NAME @@ -114,11 +114,6 @@ The .Fa flags argument has the same syntax as for .Fn BN_set_flags . -.Pp -These functions are currently implemented as macros, but they are -likely to become real functions in the future when the -.Vt BIGNUM -data type will be made opaque. .Sh RETURN VALUES .Fn BN_get_flags returns zero or more of the above constants, OR'ed together. diff --git a/lib/libcrypto/man/BN_set_negative.3 b/lib/libcrypto/man/BN_set_negative.3 index b47fa22670a..6cdff5c974e 100644 --- a/lib/libcrypto/man/BN_set_negative.3 +++ b/lib/libcrypto/man/BN_set_negative.3 @@ -1,4 +1,4 @@ -.\" $OpenBSD: BN_set_negative.3,v 1.5 2019/06/03 14:43:15 schwarze Exp $ +.\" $OpenBSD: BN_set_negative.3,v 1.6 2021/12/06 19:45:27 schwarze Exp $ .\" .\" Copyright (c) 2016 Ingo Schwarze .\" @@ -14,7 +14,7 @@ .\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF .\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. .\" -.Dd $Mdocdate: June 3 2019 $ +.Dd $Mdocdate: December 6 2021 $ .Dt BN_SET_NEGATIVE 3 .Os .Sh NAME @@ -45,7 +45,6 @@ are non-zero, otherwise it sets it to positive. .Fn BN_is_negative tests the sign of .Fa b . -It is currently implemented as a macro. .Sh RETURN VALUES .Fn BN_is_negative returns 1 if -- 2.20.1