summaryrefslogtreecommitdiff
path: root/src/regress/lib/libcrypto/bn
diff options
context:
space:
mode:
Diffstat (limited to 'src/regress/lib/libcrypto/bn')
-rw-r--r--src/regress/lib/libcrypto/bn/bn_mod_sqrt.c4
-rw-r--r--src/regress/lib/libcrypto/bn/bn_word.c10
2 files changed, 7 insertions, 7 deletions
diff --git a/src/regress/lib/libcrypto/bn/bn_mod_sqrt.c b/src/regress/lib/libcrypto/bn/bn_mod_sqrt.c
index 7ab7905136..345ab4cb61 100644
--- a/src/regress/lib/libcrypto/bn/bn_mod_sqrt.c
+++ b/src/regress/lib/libcrypto/bn/bn_mod_sqrt.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: bn_mod_sqrt.c,v 1.10 2023/04/11 10:10:52 tb Exp $ */ 1/* $OpenBSD: bn_mod_sqrt.c,v 1.11 2024/08/23 12:56:26 anton Exp $ */
2 2
3/* 3/*
4 * Copyright (c) 2022,2023 Theo Buehler <tb@openbsd.org> 4 * Copyright (c) 2022,2023 Theo Buehler <tb@openbsd.org>
@@ -2865,7 +2865,7 @@ mod_sqrt_test(struct mod_sqrt_test *test, BN_CTX *ctx)
2865 if (!BN_hex2bn(&want, test->sqrt)) 2865 if (!BN_hex2bn(&want, test->sqrt))
2866 errx(1, "BN_hex2bn(%s)", test->sqrt); 2866 errx(1, "BN_hex2bn(%s)", test->sqrt);
2867 if (!BN_mod_sub(diff, want, got, p, ctx)) 2867 if (!BN_mod_sub(diff, want, got, p, ctx))
2868 errx(1, "BN_mod_sub() failed\n"); 2868 errx(1, "BN_mod_sub() failed");
2869 2869
2870 if (!BN_is_zero(diff)) { 2870 if (!BN_is_zero(diff)) {
2871 fprintf(stderr, "a: %s\n", test->a); 2871 fprintf(stderr, "a: %s\n", test->a);
diff --git a/src/regress/lib/libcrypto/bn/bn_word.c b/src/regress/lib/libcrypto/bn/bn_word.c
index 0a543add97..2ec518ed1b 100644
--- a/src/regress/lib/libcrypto/bn/bn_word.c
+++ b/src/regress/lib/libcrypto/bn/bn_word.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: bn_word.c,v 1.1 2023/03/11 14:04:21 jsing Exp $ */ 1/* $OpenBSD: bn_word.c,v 1.2 2024/08/23 12:56:26 anton Exp $ */
2/* 2/*
3 * Copyright (c) 2023 Joel Sing <jsing@openbsd.org> 3 * Copyright (c) 2023 Joel Sing <jsing@openbsd.org>
4 * 4 *
@@ -51,7 +51,7 @@ check_bn_word_test(const char *op_name, const BIGNUM *bn,
51 } 51 }
52 52
53 if ((out_hex = BN_bn2hex(bn)) == NULL) 53 if ((out_hex = BN_bn2hex(bn)) == NULL)
54 errx(1, "BN_bn2hex() failed\n"); 54 errx(1, "BN_bn2hex() failed");
55 55
56 if (strcmp(out_hex, bwt->out_hex) != 0) { 56 if (strcmp(out_hex, bwt->out_hex) != 0) {
57 fprintf(stderr, "FAIL %s: Got hex %s, want %s\n", 57 fprintf(stderr, "FAIL %s: Got hex %s, want %s\n",
@@ -82,7 +82,7 @@ test_bn_word(int (*bn_word_op)(BIGNUM *, BN_ULONG), const char *op_name,
82 int failed = 0; 82 int failed = 0;
83 83
84 if ((bn = BN_new()) == NULL) 84 if ((bn = BN_new()) == NULL)
85 errx(1, "BN_new() failed\n"); 85 errx(1, "BN_new() failed");
86 86
87 for (i = 0; i < num_tests; i++) { 87 for (i = 0; i < num_tests; i++) {
88 bwt = &bwts[i]; 88 bwt = &bwts[i];
@@ -428,7 +428,7 @@ test_bn_div_word(void)
428 int failed = 0; 428 int failed = 0;
429 429
430 if ((bn = BN_new()) == NULL) 430 if ((bn = BN_new()) == NULL)
431 errx(1, "BN_new() failed\n"); 431 errx(1, "BN_new() failed");
432 432
433 for (i = 0; i < N_BN_DIV_WORD_TESTS; i++) { 433 for (i = 0; i < N_BN_DIV_WORD_TESTS; i++) {
434 bwt = &bn_div_word_tests[i]; 434 bwt = &bn_div_word_tests[i];
@@ -574,7 +574,7 @@ test_bn_mod_word(void)
574 int failed = 0; 574 int failed = 0;
575 575
576 if ((bn = BN_new()) == NULL) 576 if ((bn = BN_new()) == NULL)
577 errx(1, "BN_new() failed\n"); 577 errx(1, "BN_new() failed");
578 578
579 for (i = 0; i < N_BN_MOD_WORD_TESTS; i++) { 579 for (i = 0; i < N_BN_MOD_WORD_TESTS; i++) {
580 bwt = &bn_mod_word_tests[i]; 580 bwt = &bn_mod_word_tests[i];