diff options
| author | tb <> | 2021-04-20 17:38:02 +0000 |
|---|---|---|
| committer | tb <> | 2021-04-20 17:38:02 +0000 |
| commit | 32070dad37b67934ecda0c27a9a74f20f48b84af (patch) | |
| tree | 989d48df03f6b94e8b2cf288abee911e3827bb0d /src/lib/libcrypto/ec/ecp_mont.c | |
| parent | 3f027c2eef19e3fbfb52252b5f75fe958ccd8d8c (diff) | |
| download | openbsd-32070dad37b67934ecda0c27a9a74f20f48b84af.tar.gz openbsd-32070dad37b67934ecda0c27a9a74f20f48b84af.tar.bz2 openbsd-32070dad37b67934ecda0c27a9a74f20f48b84af.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.c | 32 |
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 | ||
| 120 | int | 120 | int |
| 121 | ec_GFp_mont_group_init(EC_GROUP * group) | 121 | ec_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 | ||
| 132 | void | 132 | void |
| 133 | ec_GFp_mont_group_finish(EC_GROUP * group) | 133 | ec_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 | ||
| 143 | void | 143 | void |
| 144 | ec_GFp_mont_group_clear_finish(EC_GROUP * group) | 144 | ec_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 | ||
| 154 | int | 154 | int |
| 155 | ec_GFp_mont_group_copy(EC_GROUP * dest, const EC_GROUP * src) | 155 | ec_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 | ||
| 188 | int | 188 | int |
| 189 | ec_GFp_mont_group_set_curve(EC_GROUP *group, const BIGNUM *p, const BIGNUM *a, | 189 | ec_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 | ||
| 240 | int | 240 | int |
| 241 | ec_GFp_mont_field_mul(const EC_GROUP *group, BIGNUM *r, const BIGNUM *a, | 241 | ec_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 | ||
| 252 | int | 252 | int |
| 253 | ec_GFp_mont_field_sqr(const EC_GROUP *group, BIGNUM *r, const BIGNUM *a, | 253 | ec_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 | ||
| 264 | int | 264 | int |
| 265 | ec_GFp_mont_field_encode(const EC_GROUP *group, BIGNUM *r, const BIGNUM *a, | 265 | ec_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 | ||
| 276 | int | 276 | int |
| 277 | ec_GFp_mont_field_decode(const EC_GROUP *group, BIGNUM *r, const BIGNUM *a, | 277 | ec_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 | ||
| 288 | int | 288 | int |
| 289 | ec_GFp_mont_field_set_to_one(const EC_GROUP *group, BIGNUM *r, BN_CTX *ctx) | 289 | ec_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) { |
