@@ -94,7 +94,7 @@ module CryptographyBase<LocationSig Location, InputSig<Location> Input> {
94
94
*/
95
95
abstract string getAlgorithmName ( ) ;
96
96
97
- /**
97
+ /**
98
98
* Gets the raw name of this algorithm from source (no parsing or formatting)
99
99
*/
100
100
abstract string getRawAlgorithmName ( ) ;
@@ -151,7 +151,6 @@ module CryptographyBase<LocationSig Location, InputSig<Location> Input> {
151
151
abstract THashType getHashType ( ) ;
152
152
153
153
override string getAlgorithmName ( ) { this .hashTypeToNameMapping ( this .getHashType ( ) , result ) }
154
-
155
154
}
156
155
157
156
/**
@@ -199,26 +198,23 @@ module CryptographyBase<LocationSig Location, InputSig<Location> Input> {
199
198
}
200
199
201
200
newtype TEllipticCurveFamilyType =
202
- // We're saying by this that all of these have an identical interface / properties / edges
203
- NIST ( ) or
204
- SEC ( ) or
205
- NUMS ( ) or
206
- PRIME ( ) or
207
- BRAINPOOL ( ) or
208
- CURVE25519 ( ) or
209
- CURVE448 ( ) or
210
- C2 ( ) or
211
- SM2 ( ) or
212
- ES ( ) or
213
- OtherEllipticCurveFamilyType ( )
214
-
201
+ // We're saying by this that all of these have an identical interface / properties / edges
202
+ NIST ( ) or
203
+ SEC ( ) or
204
+ NUMS ( ) or
205
+ PRIME ( ) or
206
+ BRAINPOOL ( ) or
207
+ CURVE25519 ( ) or
208
+ CURVE448 ( ) or
209
+ C2 ( ) or
210
+ SM2 ( ) or
211
+ ES ( ) or
212
+ OtherEllipticCurveFamilyType ( )
215
213
216
214
/**
217
215
* Elliptic curve algorithm
218
216
*/
219
217
abstract class EllipticCurve extends Algorithm {
220
-
221
-
222
218
abstract string getKeySize ( Location location ) ;
223
219
224
220
abstract TEllipticCurveFamilyType getCurveFamilyType ( ) ;
@@ -235,18 +231,18 @@ module CryptographyBase<LocationSig Location, InputSig<Location> Input> {
235
231
// other properties, like field type are possible, but not modeled until considered necessary
236
232
}
237
233
238
- override string getAlgorithmName ( ) { result = this .getRawAlgorithmName ( ) .toUpperCase ( ) }
234
+ override string getAlgorithmName ( ) { result = this .getRawAlgorithmName ( ) .toUpperCase ( ) }
239
235
240
236
/**
241
237
* Mandating that for Elliptic Curves specifically, users are responsible
242
- * for providing as the 'raw' name, the official name of the algorithm.
243
- * Casing doesn't matter, we will enforce further naming restrictions on
244
- * `getAlgorithmName` by default.
238
+ * for providing as the 'raw' name, the official name of the algorithm.
239
+ * Casing doesn't matter, we will enforce further naming restrictions on
240
+ * `getAlgorithmName` by default.
245
241
* Rationale: elliptic curve names can have a lot of variation in their components
246
242
* (e.g., "secp256r1" vs "P-256"), trying to produce generalized set of properties
247
- * is possible to capture all cases, but such modeling is likely not necessary.
248
- * if all properties need to be captured, we can reassess how names are generated.
243
+ * is possible to capture all cases, but such modeling is likely not necessary.
244
+ * if all properties need to be captured, we can reassess how names are generated.
249
245
*/
250
- override abstract string getRawAlgorithmName ( ) ;
246
+ abstract override string getRawAlgorithmName ( ) ;
251
247
}
252
248
}
0 commit comments