upstream: https://github.com/mirage/mirage-crypto
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

kdf, crypto: rename unused functor parameters to [_]

Warning 67 (unused-functor-parameter). The HMAC/SHA-based functors all
take a [Digestif.S] at functor level but the hash choice is baked into
the resulting module's body; the signature of the returned module has
no reference to the parameter type. Same for Block.Core params in
cipher-block mode functors (ECB_of, CBC_of, GCM_of, CCM16_of).

Files:
- kdf/hkdf/hkdf.mli, kdf/pbkdf/pbkdf.mli: Make
- ocaml-crypto/lib/cipher_block.mli: ECB_of, CBC_of, GCM_of, CCM16_of
- ocaml-crypto/rng/{crypto_rng,hmac_drbg}.mli: Make / Hmac_drbg
- ocaml-crypto/pk/{rsa,dsa,crypto_pk}.mli: OAEP, PSS, K_gen
- ocaml-crypto/ec/crypto_ec.{ml,mli}: K_gen

+14 -14
+1 -1
ec/crypto_ec.ml
··· 58 58 val sign : key:priv -> ?k:string -> string -> string * string 59 59 val verify : key:pub -> string * string -> string -> bool 60 60 61 - module K_gen (H : Digestif.S) : sig 61 + module K_gen (_ : Digestif.S) : sig 62 62 val generate : key:priv -> string -> string 63 63 end 64 64
+1 -1
ec/crypto_ec.mli
··· 131 131 132 132 (** [K_gen] can be instantiated over a hashing module to obtain an RFC6979 133 133 compliant [k]-generator for that hash. *) 134 - module K_gen (H : Digestif.S) : sig 134 + module K_gen (_ : Digestif.S) : sig 135 135 val generate : key:priv -> string -> string 136 136 (** [generate ~key digest] deterministically takes the given private key and 137 137 message digest to a [k] suitable for seeding the signing process. *)
+4 -4
lib/cipher_block.mli
··· 307 307 308 308 (** Constructors for block cipher modes from a core primitive. *) 309 309 module Modes : sig 310 - module ECB_of (Core : Block.Core) : Block.ECB 311 - module CBC_of (Core : Block.Core) : Block.CBC 310 + module ECB_of (_ : Block.Core) : Block.ECB 311 + module CBC_of (_ : Block.Core) : Block.CBC 312 312 313 313 module CTR_of (Core : Block.Core) (Ctr : Counters.S) : 314 314 Block.CTR with type key = Core.ekey and type ctr = Ctr.ctr 315 315 316 - module GCM_of (Core : Block.Core) : Block.GCM 317 - module CCM16_of (Core : Block.Core) : Block.CCM16 316 + module GCM_of (_ : Block.Core) : Block.GCM 317 + module CCM16_of (_ : Block.Core) : Block.CCM16 318 318 end 319 319 320 320 (** {1 Cipher instantiations} *)
+3 -3
pk/crypto_pk.mli
··· 248 248 249 249 Keys must have a minimum of [2 + 2 * hlen + len(message)] bytes, where 250 250 [hlen] is the hash length. *) 251 - module OAEP (H : Digestif.S) : sig 251 + module OAEP (_ : Digestif.S) : sig 252 252 val encrypt : 253 253 ?g:Crypto_rng.g -> ?label:string -> key:pub -> string -> string 254 254 (** [encrypt ~g ~label ~key message] is {b OAEP}-padded and encrypted ··· 278 278 279 279 Keys must have a minimum of [2 + hlen + slen] bytes, where [hlen] is the 280 280 hash length and [slen] is the seed length. *) 281 - module PSS (H : Digestif.S) : sig 281 + module PSS (_ : Digestif.S) : sig 282 282 val sign : 283 283 ?g:Crypto_rng.g -> 284 284 ?crt_hardening:bool -> ··· 413 413 414 414 (** [K_gen] can be instantiated over a hashing module to obtain an RFC6979 415 415 compliant [k]-generator for that hash. *) 416 - module K_gen (H : Digestif.S) : sig 416 + module K_gen (_ : Digestif.S) : sig 417 417 val generate : key:priv -> string -> Z.t 418 418 (** [generate key digest] deterministically takes the given private key and 419 419 message digest to a [k] suitable for seeding the signing process. *)
+1 -1
pk/dsa.mli
··· 44 44 (** [generate ~g size] generates a fresh DSA key pair. *) 45 45 46 46 (** Deterministic nonce generation per RFC 6979. *) 47 - module K_gen (H : Digestif.S) : sig 47 + module K_gen (_ : Digestif.S) : sig 48 48 val z_gen : key:priv -> Z.t -> Z.t 49 49 (** [z_gen ~key z] generates a deterministic nonce for message hash [z]. *) 50 50
+2 -2
pk/rsa.mli
··· 113 113 end 114 114 115 115 (** OAEP encryption (PKCS#1 v2). *) 116 - module OAEP (H : Digestif.S) : sig 116 + module OAEP (_ : Digestif.S) : sig 117 117 val encrypt : ?g:Crypto_rng.g -> ?label:string -> key:pub -> string -> string 118 118 (** [encrypt ~key msg] performs OAEP encryption. *) 119 119 ··· 128 128 end 129 129 130 130 (** PSS signatures (PKCS#1 v2). *) 131 - module PSS (H : Digestif.S) : sig 131 + module PSS (_ : Digestif.S) : sig 132 132 val sign : 133 133 ?g:Crypto_rng.g -> 134 134 ?crt_hardening:bool ->
+1 -1
rng/crypto_rng.mli
··· 219 219 220 220 (** {b HMAC_DRBG}: A NIST-specified RNG based on HMAC construction over the 221 221 provided hash. *) 222 - module Hmac_drbg (H : Digestif.S) : Generator 222 + module Hmac_drbg (_ : Digestif.S) : Generator 223 223 224 224 val v : 225 225 ?g:'a ->
+1 -1
rng/hmac_drbg.mli
··· 3 3 A NIST-specified DRBG built over HMAC, suitable for deterministic signature 4 4 schemes (RFC 6979). *) 5 5 6 - module Make (H : Digestif.S) : Rng.Generator 6 + module Make (_ : Digestif.S) : Rng.Generator