summaryrefslogtreecommitdiff
path: root/src/lib/libcrypto/gost
diff options
context:
space:
mode:
authortb <>2022-11-26 16:08:57 +0000
committertb <>2022-11-26 16:08:57 +0000
commitd0a21970fdc0fbbfc7ad31bc135f5a8fde1d3d49 (patch)
tree556ebf909e81599dc3d8da585217d1576eabe0e4 /src/lib/libcrypto/gost
parentbcbac728558eebfaa4404c405e7dc22769585345 (diff)
downloadopenbsd-d0a21970fdc0fbbfc7ad31bc135f5a8fde1d3d49.tar.gz
openbsd-d0a21970fdc0fbbfc7ad31bc135f5a8fde1d3d49.tar.bz2
openbsd-d0a21970fdc0fbbfc7ad31bc135f5a8fde1d3d49.zip
Make internal header file names consistent
Libcrypto currently has a mess of *_lcl.h, *_locl.h, and *_local.h names used for internal headers. Move all these headers we inherited from OpenSSL to *_local.h, reserving the name *_internal.h for our own code. Similarly, move dtls_locl.h and ssl_locl.h to dtls_local and ssl_local.h. constant_time_locl.h is moved to constant_time.h since it's special. Adjust all .c files in libcrypto, libssl and regress. The diff is mechanical with the exception of tls13_quic.c, where #include <ssl_locl.h> was fixed manually. discussed with jsing, no objection bcook
Diffstat (limited to 'src/lib/libcrypto/gost')
-rw-r--r--src/lib/libcrypto/gost/gost2814789.c4
-rw-r--r--src/lib/libcrypto/gost/gost89_keywrap.c4
-rw-r--r--src/lib/libcrypto/gost/gost89_params.c4
-rw-r--r--src/lib/libcrypto/gost/gost89imit_ameth.c6
-rw-r--r--src/lib/libcrypto/gost/gost89imit_pmeth.c6
-rw-r--r--src/lib/libcrypto/gost/gost_asn1.c2
-rw-r--r--src/lib/libcrypto/gost/gost_local.h (renamed from src/lib/libcrypto/gost/gost_locl.h)2
-rw-r--r--src/lib/libcrypto/gost/gostr341001.c8
-rw-r--r--src/lib/libcrypto/gost/gostr341001_ameth.c8
-rw-r--r--src/lib/libcrypto/gost/gostr341001_key.c4
-rw-r--r--src/lib/libcrypto/gost/gostr341001_params.c4
-rw-r--r--src/lib/libcrypto/gost/gostr341001_pmeth.c8
-rw-r--r--src/lib/libcrypto/gost/gostr341194.c4
-rw-r--r--src/lib/libcrypto/gost/streebog.c4
14 files changed, 34 insertions, 34 deletions
diff --git a/src/lib/libcrypto/gost/gost2814789.c b/src/lib/libcrypto/gost/gost2814789.c
index 0841a03b1e..1e0f17da43 100644
--- a/src/lib/libcrypto/gost/gost2814789.c
+++ b/src/lib/libcrypto/gost/gost2814789.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: gost2814789.c,v 1.7 2021/11/09 18:40:21 bcook Exp $ */ 1/* $OpenBSD: gost2814789.c,v 1.8 2022/11/26 16:08:53 tb Exp $ */
2/* 2/*
3 * Copyright (c) 2014 Dmitry Eremin-Solenikov <dbaryshkov@gmail.com> 3 * Copyright (c) 2014 Dmitry Eremin-Solenikov <dbaryshkov@gmail.com>
4 * Copyright (c) 2005-2006 Cryptocom LTD 4 * Copyright (c) 2005-2006 Cryptocom LTD
@@ -58,7 +58,7 @@
58#include <openssl/objects.h> 58#include <openssl/objects.h>
59#include <openssl/gost.h> 59#include <openssl/gost.h>
60 60
61#include "gost_locl.h" 61#include "gost_local.h"
62 62
63static inline unsigned int 63static inline unsigned int
64f(const GOST2814789_KEY *c, unsigned int x) 64f(const GOST2814789_KEY *c, unsigned int x)
diff --git a/src/lib/libcrypto/gost/gost89_keywrap.c b/src/lib/libcrypto/gost/gost89_keywrap.c
index a754c4d56e..9bfc5b4ce8 100644
--- a/src/lib/libcrypto/gost/gost89_keywrap.c
+++ b/src/lib/libcrypto/gost/gost89_keywrap.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: gost89_keywrap.c,v 1.3 2014/11/09 19:28:44 miod Exp $ */ 1/* $OpenBSD: gost89_keywrap.c,v 1.4 2022/11/26 16:08:53 tb Exp $ */
2/* 2/*
3 * Copyright (c) 2014 Dmitry Eremin-Solenikov <dbaryshkov@gmail.com> 3 * Copyright (c) 2014 Dmitry Eremin-Solenikov <dbaryshkov@gmail.com>
4 * Copyright (c) 2005-2006 Cryptocom LTD 4 * Copyright (c) 2005-2006 Cryptocom LTD
@@ -57,7 +57,7 @@
57 57
58#include <openssl/gost.h> 58#include <openssl/gost.h>
59 59
60#include "gost_locl.h" 60#include "gost_local.h"
61 61
62static void 62static void
63key_diversify_crypto_pro(GOST2814789_KEY *ctx, const unsigned char *inputKey, 63key_diversify_crypto_pro(GOST2814789_KEY *ctx, const unsigned char *inputKey,
diff --git a/src/lib/libcrypto/gost/gost89_params.c b/src/lib/libcrypto/gost/gost89_params.c
index 35d8f62fe9..9c4a97ee6d 100644
--- a/src/lib/libcrypto/gost/gost89_params.c
+++ b/src/lib/libcrypto/gost/gost89_params.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: gost89_params.c,v 1.2 2014/11/09 23:06:52 miod Exp $ */ 1/* $OpenBSD: gost89_params.c,v 1.3 2022/11/26 16:08:53 tb Exp $ */
2/* 2/*
3 * Copyright (c) 2014 Dmitry Eremin-Solenikov <dbaryshkov@gmail.com> 3 * Copyright (c) 2014 Dmitry Eremin-Solenikov <dbaryshkov@gmail.com>
4 * Copyright (c) 2005-2006 Cryptocom LTD 4 * Copyright (c) 2005-2006 Cryptocom LTD
@@ -57,7 +57,7 @@
57#include <openssl/objects.h> 57#include <openssl/objects.h>
58#include <openssl/gost.h> 58#include <openssl/gost.h>
59 59
60#include "gost_locl.h" 60#include "gost_local.h"
61 61
62/* Substitution blocks from test examples for GOST R 34.11-94*/ 62/* Substitution blocks from test examples for GOST R 34.11-94*/
63static const gost_subst_block GostR3411_94_TestParamSet = { 63static const gost_subst_block GostR3411_94_TestParamSet = {
diff --git a/src/lib/libcrypto/gost/gost89imit_ameth.c b/src/lib/libcrypto/gost/gost89imit_ameth.c
index 3fdfa3eef2..e300b52801 100644
--- a/src/lib/libcrypto/gost/gost89imit_ameth.c
+++ b/src/lib/libcrypto/gost/gost89imit_ameth.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: gost89imit_ameth.c,v 1.3 2021/12/12 21:30:14 tb Exp $ */ 1/* $OpenBSD: gost89imit_ameth.c,v 1.4 2022/11/26 16:08:53 tb Exp $ */
2/* 2/*
3 * Copyright (c) 2014 Dmitry Eremin-Solenikov <dbaryshkov@gmail.com> 3 * Copyright (c) 2014 Dmitry Eremin-Solenikov <dbaryshkov@gmail.com>
4 * Copyright (c) 2005-2006 Cryptocom LTD 4 * Copyright (c) 2005-2006 Cryptocom LTD
@@ -54,8 +54,8 @@
54#ifndef OPENSSL_NO_GOST 54#ifndef OPENSSL_NO_GOST
55#include <openssl/evp.h> 55#include <openssl/evp.h>
56 56
57#include "asn1_locl.h" 57#include "asn1_local.h"
58#include "evp_locl.h" 58#include "evp_local.h"
59 59
60static void 60static void
61mackey_free_gost(EVP_PKEY *pk) 61mackey_free_gost(EVP_PKEY *pk)
diff --git a/src/lib/libcrypto/gost/gost89imit_pmeth.c b/src/lib/libcrypto/gost/gost89imit_pmeth.c
index 1959b36163..63b7ef59ee 100644
--- a/src/lib/libcrypto/gost/gost89imit_pmeth.c
+++ b/src/lib/libcrypto/gost/gost89imit_pmeth.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: gost89imit_pmeth.c,v 1.4 2017/01/29 17:49:23 beck Exp $ */ 1/* $OpenBSD: gost89imit_pmeth.c,v 1.5 2022/11/26 16:08:53 tb Exp $ */
2/* 2/*
3 * Copyright (c) 2014 Dmitry Eremin-Solenikov <dbaryshkov@gmail.com> 3 * Copyright (c) 2014 Dmitry Eremin-Solenikov <dbaryshkov@gmail.com>
4 * Copyright (c) 2005-2006 Cryptocom LTD 4 * Copyright (c) 2005-2006 Cryptocom LTD
@@ -59,8 +59,8 @@
59#include <openssl/gost.h> 59#include <openssl/gost.h>
60#include <openssl/x509v3.h> /* For string_to_hex */ 60#include <openssl/x509v3.h> /* For string_to_hex */
61 61
62#include "evp_locl.h" 62#include "evp_local.h"
63#include "gost_locl.h" 63#include "gost_local.h"
64 64
65struct gost_mac_pmeth_data { 65struct gost_mac_pmeth_data {
66 EVP_MD *md; 66 EVP_MD *md;
diff --git a/src/lib/libcrypto/gost/gost_asn1.c b/src/lib/libcrypto/gost/gost_asn1.c
index 2652162777..d83ded55b1 100644
--- a/src/lib/libcrypto/gost/gost_asn1.c
+++ b/src/lib/libcrypto/gost/gost_asn1.c
@@ -14,7 +14,7 @@
14#include <openssl/x509.h> 14#include <openssl/x509.h>
15#include <openssl/gost.h> 15#include <openssl/gost.h>
16 16
17#include "gost_locl.h" 17#include "gost_local.h"
18#include "gost_asn1.h" 18#include "gost_asn1.h"
19 19
20static const ASN1_TEMPLATE GOST_KEY_TRANSPORT_seq_tt[] = { 20static const ASN1_TEMPLATE GOST_KEY_TRANSPORT_seq_tt[] = {
diff --git a/src/lib/libcrypto/gost/gost_locl.h b/src/lib/libcrypto/gost/gost_local.h
index b2e2c1362a..1b31f7446e 100644
--- a/src/lib/libcrypto/gost/gost_locl.h
+++ b/src/lib/libcrypto/gost/gost_local.h
@@ -1,4 +1,4 @@
1/* $OpenBSD: gost_locl.h,v 1.4 2016/12/21 15:49:29 jsing Exp $ */ 1/* $OpenBSD: gost_local.h,v 1.1 2022/11/26 16:08:53 tb Exp $ */
2/* 2/*
3 * Copyright (c) 2014 Dmitry Eremin-Solenikov <dbaryshkov@gmail.com> 3 * Copyright (c) 2014 Dmitry Eremin-Solenikov <dbaryshkov@gmail.com>
4 * Copyright (c) 2005-2006 Cryptocom LTD 4 * Copyright (c) 2005-2006 Cryptocom LTD
diff --git a/src/lib/libcrypto/gost/gostr341001.c b/src/lib/libcrypto/gost/gostr341001.c
index a6082568ff..13f053dae8 100644
--- a/src/lib/libcrypto/gost/gostr341001.c
+++ b/src/lib/libcrypto/gost/gostr341001.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: gostr341001.c,v 1.9 2022/01/07 09:40:03 tb Exp $ */ 1/* $OpenBSD: gostr341001.c,v 1.10 2022/11/26 16:08:53 tb Exp $ */
2/* 2/*
3 * Copyright (c) 2014 Dmitry Eremin-Solenikov <dbaryshkov@gmail.com> 3 * Copyright (c) 2014 Dmitry Eremin-Solenikov <dbaryshkov@gmail.com>
4 * Copyright (c) 2005-2006 Cryptocom LTD 4 * Copyright (c) 2005-2006 Cryptocom LTD
@@ -58,9 +58,9 @@
58#include <openssl/err.h> 58#include <openssl/err.h>
59#include <openssl/gost.h> 59#include <openssl/gost.h>
60 60
61#include "bn_lcl.h" 61#include "bn_local.h"
62#include "ecs_locl.h" 62#include "ecs_local.h"
63#include "gost_locl.h" 63#include "gost_local.h"
64 64
65/* Convert little-endian byte array into bignum */ 65/* Convert little-endian byte array into bignum */
66BIGNUM * 66BIGNUM *
diff --git a/src/lib/libcrypto/gost/gostr341001_ameth.c b/src/lib/libcrypto/gost/gostr341001_ameth.c
index ce203a6c21..9ef7cdf461 100644
--- a/src/lib/libcrypto/gost/gostr341001_ameth.c
+++ b/src/lib/libcrypto/gost/gostr341001_ameth.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: gostr341001_ameth.c,v 1.19 2021/12/26 15:38:49 tb Exp $ */ 1/* $OpenBSD: gostr341001_ameth.c,v 1.20 2022/11/26 16:08:53 tb Exp $ */
2/* 2/*
3 * Copyright (c) 2014 Dmitry Eremin-Solenikov <dbaryshkov@gmail.com> 3 * Copyright (c) 2014 Dmitry Eremin-Solenikov <dbaryshkov@gmail.com>
4 * Copyright (c) 2005-2006 Cryptocom LTD 4 * Copyright (c) 2005-2006 Cryptocom LTD
@@ -62,9 +62,9 @@
62#include <openssl/gost.h> 62#include <openssl/gost.h>
63 63
64 64
65#include "asn1_locl.h" 65#include "asn1_local.h"
66#include "evp_locl.h" 66#include "evp_local.h"
67#include "gost_locl.h" 67#include "gost_local.h"
68#include "gost_asn1.h" 68#include "gost_asn1.h"
69 69
70static void 70static void
diff --git a/src/lib/libcrypto/gost/gostr341001_key.c b/src/lib/libcrypto/gost/gostr341001_key.c
index d5d885c257..af3a3fcd38 100644
--- a/src/lib/libcrypto/gost/gostr341001_key.c
+++ b/src/lib/libcrypto/gost/gostr341001_key.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: gostr341001_key.c,v 1.9 2021/04/20 17:16:38 tb Exp $ */ 1/* $OpenBSD: gostr341001_key.c,v 1.10 2022/11/26 16:08:53 tb Exp $ */
2/* 2/*
3 * Copyright (c) 2014 Dmitry Eremin-Solenikov <dbaryshkov@gmail.com> 3 * Copyright (c) 2014 Dmitry Eremin-Solenikov <dbaryshkov@gmail.com>
4 * Copyright (c) 2005-2006 Cryptocom LTD 4 * Copyright (c) 2005-2006 Cryptocom LTD
@@ -58,7 +58,7 @@
58#include <openssl/err.h> 58#include <openssl/err.h>
59#include <openssl/gost.h> 59#include <openssl/gost.h>
60#include <openssl/objects.h> 60#include <openssl/objects.h>
61#include "gost_locl.h" 61#include "gost_local.h"
62 62
63struct gost_key_st { 63struct gost_key_st {
64 EC_GROUP *group; 64 EC_GROUP *group;
diff --git a/src/lib/libcrypto/gost/gostr341001_params.c b/src/lib/libcrypto/gost/gostr341001_params.c
index 282a210419..ca8a27d712 100644
--- a/src/lib/libcrypto/gost/gostr341001_params.c
+++ b/src/lib/libcrypto/gost/gostr341001_params.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: gostr341001_params.c,v 1.4 2020/06/05 17:12:09 jsing Exp $ */ 1/* $OpenBSD: gostr341001_params.c,v 1.5 2022/11/26 16:08:53 tb Exp $ */
2/* 2/*
3 * Copyright (c) 2014 Dmitry Eremin-Solenikov <dbaryshkov@gmail.com> 3 * Copyright (c) 2014 Dmitry Eremin-Solenikov <dbaryshkov@gmail.com>
4 * Copyright (c) 2005-2006 Cryptocom LTD 4 * Copyright (c) 2005-2006 Cryptocom LTD
@@ -57,7 +57,7 @@
57#include <openssl/objects.h> 57#include <openssl/objects.h>
58#include <openssl/gost.h> 58#include <openssl/gost.h>
59 59
60#include "gost_locl.h" 60#include "gost_local.h"
61 61
62int 62int
63GostR3410_get_md_digest(int nid) 63GostR3410_get_md_digest(int nid)
diff --git a/src/lib/libcrypto/gost/gostr341001_pmeth.c b/src/lib/libcrypto/gost/gostr341001_pmeth.c
index ae39b05901..38f94ecd81 100644
--- a/src/lib/libcrypto/gost/gostr341001_pmeth.c
+++ b/src/lib/libcrypto/gost/gostr341001_pmeth.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: gostr341001_pmeth.c,v 1.16 2022/03/30 07:17:48 tb Exp $ */ 1/* $OpenBSD: gostr341001_pmeth.c,v 1.17 2022/11/26 16:08:53 tb Exp $ */
2/* 2/*
3 * Copyright (c) 2014 Dmitry Eremin-Solenikov <dbaryshkov@gmail.com> 3 * Copyright (c) 2014 Dmitry Eremin-Solenikov <dbaryshkov@gmail.com>
4 * Copyright (c) 2005-2006 Cryptocom LTD 4 * Copyright (c) 2005-2006 Cryptocom LTD
@@ -62,9 +62,9 @@
62#include <openssl/ecdsa.h> 62#include <openssl/ecdsa.h>
63#include <openssl/x509.h> 63#include <openssl/x509.h>
64 64
65#include "ecs_locl.h" 65#include "ecs_local.h"
66#include "evp_locl.h" 66#include "evp_local.h"
67#include "gost_locl.h" 67#include "gost_local.h"
68#include "gost_asn1.h" 68#include "gost_asn1.h"
69 69
70static ECDSA_SIG * 70static ECDSA_SIG *
diff --git a/src/lib/libcrypto/gost/gostr341194.c b/src/lib/libcrypto/gost/gostr341194.c
index 2a462185aa..63058300a3 100644
--- a/src/lib/libcrypto/gost/gostr341194.c
+++ b/src/lib/libcrypto/gost/gostr341194.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: gostr341194.c,v 1.5 2015/09/10 15:56:25 jsing Exp $ */ 1/* $OpenBSD: gostr341194.c,v 1.6 2022/11/26 16:08:53 tb Exp $ */
2/* 2/*
3 * Copyright (c) 2014 Dmitry Eremin-Solenikov <dbaryshkov@gmail.com> 3 * Copyright (c) 2014 Dmitry Eremin-Solenikov <dbaryshkov@gmail.com>
4 * Copyright (c) 2005-2006 Cryptocom LTD 4 * Copyright (c) 2005-2006 Cryptocom LTD
@@ -58,7 +58,7 @@
58#include <openssl/objects.h> 58#include <openssl/objects.h>
59#include <openssl/gost.h> 59#include <openssl/gost.h>
60 60
61#include "gost_locl.h" 61#include "gost_local.h"
62 62
63/* Following functions are various bit meshing routines used in 63/* Following functions are various bit meshing routines used in
64 * GOST R 34.11-94 algorithms */ 64 * GOST R 34.11-94 algorithms */
diff --git a/src/lib/libcrypto/gost/streebog.c b/src/lib/libcrypto/gost/streebog.c
index b237a2c500..2785fca619 100644
--- a/src/lib/libcrypto/gost/streebog.c
+++ b/src/lib/libcrypto/gost/streebog.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: streebog.c,v 1.7 2021/11/09 18:40:21 bcook Exp $ */ 1/* $OpenBSD: streebog.c,v 1.8 2022/11/26 16:08:53 tb Exp $ */
2/* 2/*
3 * Copyright (c) 2014 Dmitry Eremin-Solenikov <dbaryshkov@gmail.com> 3 * Copyright (c) 2014 Dmitry Eremin-Solenikov <dbaryshkov@gmail.com>
4 * Copyright (c) 2005-2006 Cryptocom LTD 4 * Copyright (c) 2005-2006 Cryptocom LTD
@@ -60,7 +60,7 @@
60#include <openssl/objects.h> 60#include <openssl/objects.h>
61#include <openssl/gost.h> 61#include <openssl/gost.h>
62 62
63#include "gost_locl.h" 63#include "gost_local.h"
64 64
65static const STREEBOG_LONG64 A_PI_table[8][256] = { 65static const STREEBOG_LONG64 A_PI_table[8][256] = {
66 { /* 0 */ 66 { /* 0 */