summaryrefslogtreecommitdiff
path: root/src/lib/libcrypto/ec/ecp_mont.c
diff options
context:
space:
mode:
authortb <>2021-04-20 17:38:02 +0000
committertb <>2021-04-20 17:38:02 +0000
commit1d11b9178d76ad4f080a805db2648af7bd8e6775 (patch)
tree989d48df03f6b94e8b2cf288abee911e3827bb0d /src/lib/libcrypto/ec/ecp_mont.c
parent7da6fb59aaf57e5a5e5b728fbbacba2a8762843b (diff)
downloadopenbsd-1d11b9178d76ad4f080a805db2648af7bd8e6775.tar.gz
openbsd-1d11b9178d76ad4f080a805db2648af7bd8e6775.tar.bz2
openbsd-1d11b9178d76ad4f080a805db2648af7bd8e6775.zip
Fix indent of EC_METHODs as requested by jsing.
While there zap trailing whitespace from a KNF approximation gone wrong.
Diffstat (limited to 'src/lib/libcrypto/ec/ecp_mont.c')
-rw-r--r--src/lib/libcrypto/ec/ecp_mont.c32
1 files changed, 16 insertions, 16 deletions
diff --git a/src/lib/libcrypto/ec/ecp_mont.c b/src/lib/libcrypto/ec/ecp_mont.c
index 7160692e9e..f371e3ec8f 100644
--- a/src/lib/libcrypto/ec/ecp_mont.c
+++ b/src/lib/libcrypto/ec/ecp_mont.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: ecp_mont.c,v 1.18 2021/04/20 17:28:18 tb Exp $ */ 1/* $OpenBSD: ecp_mont.c,v 1.19 2021/04/20 17:38:02 tb Exp $ */
2/* 2/*
3 * Originally written by Bodo Moeller for the OpenSSL project. 3 * Originally written by Bodo Moeller for the OpenSSL project.
4 */ 4 */
@@ -80,20 +80,20 @@ EC_GFp_mont_method(void)
80 .group_get_curve = ec_GFp_simple_group_get_curve, 80 .group_get_curve = ec_GFp_simple_group_get_curve,
81 .group_get_degree = ec_GFp_simple_group_get_degree, 81 .group_get_degree = ec_GFp_simple_group_get_degree,
82 .group_check_discriminant = 82 .group_check_discriminant =
83 ec_GFp_simple_group_check_discriminant, 83 ec_GFp_simple_group_check_discriminant,
84 .point_init = ec_GFp_simple_point_init, 84 .point_init = ec_GFp_simple_point_init,
85 .point_finish = ec_GFp_simple_point_finish, 85 .point_finish = ec_GFp_simple_point_finish,
86 .point_clear_finish = ec_GFp_simple_point_clear_finish, 86 .point_clear_finish = ec_GFp_simple_point_clear_finish,
87 .point_copy = ec_GFp_simple_point_copy, 87 .point_copy = ec_GFp_simple_point_copy,
88 .point_set_to_infinity = ec_GFp_simple_point_set_to_infinity, 88 .point_set_to_infinity = ec_GFp_simple_point_set_to_infinity,
89 .point_set_Jprojective_coordinates = 89 .point_set_Jprojective_coordinates =
90 ec_GFp_simple_set_Jprojective_coordinates, 90 ec_GFp_simple_set_Jprojective_coordinates,
91 .point_get_Jprojective_coordinates = 91 .point_get_Jprojective_coordinates =
92 ec_GFp_simple_get_Jprojective_coordinates, 92 ec_GFp_simple_get_Jprojective_coordinates,
93 .point_set_affine_coordinates = 93 .point_set_affine_coordinates =
94 ec_GFp_simple_point_set_affine_coordinates, 94 ec_GFp_simple_point_set_affine_coordinates,
95 .point_get_affine_coordinates = 95 .point_get_affine_coordinates =
96 ec_GFp_simple_point_get_affine_coordinates, 96 ec_GFp_simple_point_get_affine_coordinates,
97 .add = ec_GFp_simple_add, 97 .add = ec_GFp_simple_add,
98 .dbl = ec_GFp_simple_dbl, 98 .dbl = ec_GFp_simple_dbl,
99 .invert = ec_GFp_simple_invert, 99 .invert = ec_GFp_simple_invert,
@@ -117,7 +117,7 @@ EC_GFp_mont_method(void)
117} 117}
118 118
119 119
120int 120int
121ec_GFp_mont_group_init(EC_GROUP * group) 121ec_GFp_mont_group_init(EC_GROUP * group)
122{ 122{
123 int ok; 123 int ok;
@@ -129,7 +129,7 @@ ec_GFp_mont_group_init(EC_GROUP * group)
129} 129}
130 130
131 131
132void 132void
133ec_GFp_mont_group_finish(EC_GROUP * group) 133ec_GFp_mont_group_finish(EC_GROUP * group)
134{ 134{
135 BN_MONT_CTX_free(group->field_data1); 135 BN_MONT_CTX_free(group->field_data1);
@@ -140,7 +140,7 @@ ec_GFp_mont_group_finish(EC_GROUP * group)
140} 140}
141 141
142 142
143void 143void
144ec_GFp_mont_group_clear_finish(EC_GROUP * group) 144ec_GFp_mont_group_clear_finish(EC_GROUP * group)
145{ 145{
146 BN_MONT_CTX_free(group->field_data1); 146 BN_MONT_CTX_free(group->field_data1);
@@ -151,7 +151,7 @@ ec_GFp_mont_group_clear_finish(EC_GROUP * group)
151} 151}
152 152
153 153
154int 154int
155ec_GFp_mont_group_copy(EC_GROUP * dest, const EC_GROUP * src) 155ec_GFp_mont_group_copy(EC_GROUP * dest, const EC_GROUP * src)
156{ 156{
157 BN_MONT_CTX_free(dest->field_data1); 157 BN_MONT_CTX_free(dest->field_data1);
@@ -185,7 +185,7 @@ ec_GFp_mont_group_copy(EC_GROUP * dest, const EC_GROUP * src)
185} 185}
186 186
187 187
188int 188int
189ec_GFp_mont_group_set_curve(EC_GROUP *group, const BIGNUM *p, const BIGNUM *a, 189ec_GFp_mont_group_set_curve(EC_GROUP *group, const BIGNUM *p, const BIGNUM *a,
190 const BIGNUM *b, BN_CTX *ctx) 190 const BIGNUM *b, BN_CTX *ctx)
191{ 191{
@@ -237,7 +237,7 @@ ec_GFp_mont_group_set_curve(EC_GROUP *group, const BIGNUM *p, const BIGNUM *a,
237} 237}
238 238
239 239
240int 240int
241ec_GFp_mont_field_mul(const EC_GROUP *group, BIGNUM *r, const BIGNUM *a, 241ec_GFp_mont_field_mul(const EC_GROUP *group, BIGNUM *r, const BIGNUM *a,
242 const BIGNUM *b, BN_CTX *ctx) 242 const BIGNUM *b, BN_CTX *ctx)
243{ 243{
@@ -249,7 +249,7 @@ ec_GFp_mont_field_mul(const EC_GROUP *group, BIGNUM *r, const BIGNUM *a,
249} 249}
250 250
251 251
252int 252int
253ec_GFp_mont_field_sqr(const EC_GROUP *group, BIGNUM *r, const BIGNUM *a, 253ec_GFp_mont_field_sqr(const EC_GROUP *group, BIGNUM *r, const BIGNUM *a,
254 BN_CTX *ctx) 254 BN_CTX *ctx)
255{ 255{
@@ -261,7 +261,7 @@ ec_GFp_mont_field_sqr(const EC_GROUP *group, BIGNUM *r, const BIGNUM *a,
261} 261}
262 262
263 263
264int 264int
265ec_GFp_mont_field_encode(const EC_GROUP *group, BIGNUM *r, const BIGNUM *a, 265ec_GFp_mont_field_encode(const EC_GROUP *group, BIGNUM *r, const BIGNUM *a,
266 BN_CTX *ctx) 266 BN_CTX *ctx)
267{ 267{
@@ -273,7 +273,7 @@ ec_GFp_mont_field_encode(const EC_GROUP *group, BIGNUM *r, const BIGNUM *a,
273} 273}
274 274
275 275
276int 276int
277ec_GFp_mont_field_decode(const EC_GROUP *group, BIGNUM *r, const BIGNUM *a, 277ec_GFp_mont_field_decode(const EC_GROUP *group, BIGNUM *r, const BIGNUM *a,
278 BN_CTX *ctx) 278 BN_CTX *ctx)
279{ 279{
@@ -285,7 +285,7 @@ ec_GFp_mont_field_decode(const EC_GROUP *group, BIGNUM *r, const BIGNUM *a,
285} 285}
286 286
287 287
288int 288int
289ec_GFp_mont_field_set_to_one(const EC_GROUP *group, BIGNUM *r, BN_CTX *ctx) 289ec_GFp_mont_field_set_to_one(const EC_GROUP *group, BIGNUM *r, BN_CTX *ctx)
290{ 290{
291 if (group->field_data2 == NULL) { 291 if (group->field_data2 == NULL) {