projects
/
openssl.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Make the RSA structure opaque
[openssl.git]
/
crypto
/
rsa
/
rsa_oaep.c
diff --git
a/crypto/rsa/rsa_oaep.c
b/crypto/rsa/rsa_oaep.c
index 0f742f9969a55e530491f563390b5d08c37242f6..27a6e78823fe14999d1e0c2284a5c0deec623892 100644
(file)
--- a/
crypto/rsa/rsa_oaep.c
+++ b/
crypto/rsa/rsa_oaep.c
@@
-1,4
+1,3
@@
-/* crypto/rsa/rsa_oaep.c */
/*
* Written by Ulf Moeller. This software is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied.
/*
* Written by Ulf Moeller. This software is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied.
@@
-22,10
+21,10
@@
#include <stdio.h>
#include "internal/cryptlib.h"
#include <openssl/bn.h>
#include <stdio.h>
#include "internal/cryptlib.h"
#include <openssl/bn.h>
-#include <openssl/rsa.h>
#include <openssl/evp.h>
#include <openssl/rand.h>
#include <openssl/sha.h>
#include <openssl/evp.h>
#include <openssl/rand.h>
#include <openssl/sha.h>
+#include "rsa_locl.h"
int RSA_padding_add_PKCS1_OAEP(unsigned char *to, int tlen,
const unsigned char *from, int flen,
int RSA_padding_add_PKCS1_OAEP(unsigned char *to, int tlen,
const unsigned char *from, int flen,
@@
-242,7
+241,7
@@
int PKCS1_MGF1(unsigned char *mask, long len,
{
long i, outlen = 0;
unsigned char cnt[4];
{
long i, outlen = 0;
unsigned char cnt[4];
- EVP_MD_CTX *c = EVP_MD_CTX_
create
();
+ EVP_MD_CTX *c = EVP_MD_CTX_
new
();
unsigned char md[EVP_MAX_MD_SIZE];
int mdlen;
int rv = -1;
unsigned char md[EVP_MAX_MD_SIZE];
int mdlen;
int rv = -1;
@@
-274,6
+273,6
@@
int PKCS1_MGF1(unsigned char *mask, long len,
}
rv = 0;
err:
}
rv = 0;
err:
- EVP_MD_CTX_
destroy
(c);
+ EVP_MD_CTX_
free
(c);
return rv;
}
return rv;
}