int PEM_write_PrivateKey(FILE *fp,EVP_PKEY *x,const EVP_CIPHER *enc,
unsigned char *kstr,int klen, pem_password_cb *);
int PEM_write_PKCS8PrivateKey(FILE *fp,EVP_PKEY *x,const EVP_CIPHER *enc,
- unsigned char *kstr,int klen, pem_password_cb *);
+ char *kstr,int klen, pem_password_cb *);
int PEM_write_PKCS7(FILE *fp,PKCS7 *x);
#ifndef NO_DH
int PEM_write_DHparams(FILE *fp,DH *x);
int PEM_write_bio_PrivateKey(BIO *fp,EVP_PKEY *x,const EVP_CIPHER *enc,
unsigned char *kstr,int klen, pem_password_cb *);
int PEM_write_bio_PKCS8PrivateKey(BIO *fp,EVP_PKEY *x,const EVP_CIPHER *enc,
- unsigned char *kstr,int klen, pem_password_cb *);
+ char *kstr,int klen, pem_password_cb *);
int PEM_write_bio_PKCS7(BIO *bp,PKCS7 *x);
#ifndef NO_DH
int PEM_write_bio_DHparams(BIO *bp,DH *x);
static int def_callback(char *buf, int num, int w);
static int load_iv(unsigned char **fromp,unsigned char *to, int num);
+
static int def_callback(char *buf, int num, int w)
{
#ifdef NO_FP_API
*/
int PEM_write_bio_PKCS8PrivateKey(BIO *bp, EVP_PKEY *x, const EVP_CIPHER *enc,
- unsigned char *kstr, int klen, pem_password_cb *cb)
+ char *kstr, int klen,
+ pem_password_cb *cb)
{
X509_SIG *p8;
PKCS8_PRIV_KEY_INFO *p8inf;
kstr = buf;
}
p8 = PKCS8_encrypt(-1, enc, kstr, klen, NULL, 0, 0, p8inf);
- if(kstr == (unsigned char *)buf) memset(buf, 0, klen);
+ if(kstr == buf) memset(buf, 0, klen);
PKCS8_PRIV_KEY_INFO_free(p8inf);
ret = PEM_write_bio_PKCS8(bp, p8);
X509_SIG_free(p8);
}
int PEM_write_PKCS8PrivateKey(FILE *fp, EVP_PKEY *x, const EVP_CIPHER *enc,
- unsigned char *kstr, int klen, pem_password_cb *cb)
+ char *kstr, int klen, pem_password_cb *cb)
{
BIO *bp;
int ret;