goto end;
}
} else {
- char *storepass = NULL;
+ if (skeyuri != NULL) {
+ char *storepass = NULL;
- if (!app_passwd(storepassarg, NULL, &storepass, NULL)) {
- BIO_printf(bio_err,
- "Error getting store password from 'storepass' argument\n");
- }
- mgmt = EVP_SKEYMGMT_fetch(app_get0_libctx(),
- skeymgmt != NULL ? skeymgmt : EVP_CIPHER_name(cipher),
- app_get0_propq());
- if (mgmt == NULL)
- goto end;
+ if (!app_passwd(storepassarg, NULL, &storepass, NULL)) {
+ BIO_printf(bio_err,
+ "Error getting store password from 'storepass' argument\n");
+ }
- if (skeyuri != NULL) {
skey = load_skey(skeyuri, FORMAT_UNDEF, 0, storepass, 0);
OPENSSL_free(storepass);
if (skey == NULL) {
EVP_PKEY **ppkey, EVP_PKEY **ppubkey,
EVP_PKEY **pparams,
X509 **pcert, STACK_OF(X509) **pcerts,
- X509_CRL **pcrl, STACK_OF(X509_CRL) **pcrls.
+ X509_CRL **pcrl, STACK_OF(X509_CRL) **pcrls,
EVP_SKEY **pskey);
EVP_SKEY *load_skey(const char *uri, int format, int maybe_stdin,
const char *pass, int quiet);
SET_EXPECT(val); \
}
/* Provide (error msg) text for some of the credential types to be loaded. */
-#define FAIL_NAME \
- (ppkey != NULL ? "private key" : ppubkey != NULL ? "public key" \
- : pparams != NULL ? "key parameters" \
- : pcert != NULL ? "certificate" \
- : pcerts != NULL ? "certificates" \
- : pcrl != NULL ? "CRL" \
- : pcrls != NULL ? "CRLs" \
- : pskey != NULL ? "symmetric key" : NULL \
+#define FAIL_NAME \
+ (ppkey != NULL ? "private key" : ppubkey != NULL ? "public key" \
+ : pparams != NULL ? "key parameters" \
+ : pcert != NULL ? "certificate" \
+ : pcerts != NULL ? "certificates" \
+ : pcrl != NULL ? "CRL" \
+ : pcrls != NULL ? "CRLs" \
+ : pskey != NULL ? "symmetric key" \
: NULL)
/*
* Load those types of credentials for which the result pointer is not NULL.
An implementation with that input type decodes PVK formatted data.
+=item raw
+
+An implementation with that input type decodes the provided data as raw bytes.
+This is currently used for symmetric keys.
+
=back
=item structure