Index: sys/geom/eli/g_eli.h =================================================================== --- sys/geom/eli/g_eli.h +++ sys/geom/eli/g_eli.h @@ -701,12 +701,12 @@ SHA512_CTX outerctx; }; -void g_eli_crypto_hmac_init(struct hmac_ctx *ctx, const uint8_t *hkey, +void g_eli_crypto_hmac_init(struct hmac_ctx *ctx, const char hkey[], size_t hkeylen); void g_eli_crypto_hmac_update(struct hmac_ctx *ctx, const uint8_t *data, size_t datasize); void g_eli_crypto_hmac_final(struct hmac_ctx *ctx, uint8_t *md, size_t mdsize); -void g_eli_crypto_hmac(const uint8_t *hkey, size_t hkeysize, +void g_eli_crypto_hmac(const char hkey[], size_t hkeysize, const uint8_t *data, size_t datasize, uint8_t *md, size_t mdsize); void g_eli_key_fill(struct g_eli_softc *sc, struct g_eli_key *key, Index: sys/geom/eli/g_eli_hmac.c =================================================================== --- sys/geom/eli/g_eli_hmac.c +++ sys/geom/eli/g_eli_hmac.c @@ -44,7 +44,7 @@ #include void -g_eli_crypto_hmac_init(struct hmac_ctx *ctx, const uint8_t *hkey, +g_eli_crypto_hmac_init(struct hmac_ctx *ctx, const char hkey[], size_t hkeylen) { u_char k_ipad[128], k_opad[128], key[128]; @@ -108,7 +108,7 @@ } void -g_eli_crypto_hmac(const uint8_t *hkey, size_t hkeysize, const uint8_t *data, +g_eli_crypto_hmac(const char hkey[], size_t hkeysize, const uint8_t *data, size_t datasize, uint8_t *md, size_t mdsize) { struct hmac_ctx ctx; Index: sys/geom/eli/pkcs5v2.h =================================================================== --- sys/geom/eli/pkcs5v2.h +++ sys/geom/eli/pkcs5v2.h @@ -29,7 +29,7 @@ #ifndef _PKCS5V2_H_ #define _PKCS5V2_H_ void pkcs5v2_genkey(uint8_t *key, unsigned keylen, const uint8_t *salt, - size_t saltsize, const char *passphrase, u_int iterations); + size_t saltsize, const char passphrase[], u_int iterations); #ifndef _KERNEL int pkcs5v2_calculate(int usecs); #endif Index: sys/geom/eli/pkcs5v2.c =================================================================== --- sys/geom/eli/pkcs5v2.c +++ sys/geom/eli/pkcs5v2.c @@ -50,7 +50,7 @@ void pkcs5v2_genkey(uint8_t *key, unsigned keylen, const uint8_t *salt, - size_t saltsize, const char *passphrase, u_int iterations) + size_t saltsize, const char passphrase[], u_int iterations) { uint8_t md[SHA512_MDLEN], saltcount[saltsize + sizeof(uint32_t)]; uint8_t *counter, *keyp; @@ -95,7 +95,7 @@ pkcs5v2_probe(int iterations) { uint8_t key[G_ELI_USERKEYLEN], salt[G_ELI_SALTLEN]; - uint8_t passphrase[] = "passphrase"; + const char passphrase[] = "passphrase"; struct rusage start, end; int usecs;