Correct a mail address...
[openssl.git] / crypto / asn1 / a_verify.c
index fc2711058bd57fb1c386341e5a4e3075d1cff322..2a11927e5c1c2a68e415dbda002f711dde730c41 100644 (file)
 
 #include <stdio.h>
 #include <time.h>
-#include <sys/types.h>
-#include <sys/stat.h>
 
 #include "cryptlib.h"
-#include "bn.h"
-#include "x509.h"
-#include "objects.h"
-#include "buffer.h"
-#include "evp.h"
+
+#ifndef NO_SYS_TYPES_H
+# include <sys/types.h>
+#endif
+
+#include <openssl/bn.h>
+#include <openssl/x509.h>
+#include <openssl/objects.h>
+#include <openssl/buffer.h>
+#include <openssl/evp.h>
 
 int ASN1_verify(int (*i2d)(), X509_ALGOR *a, ASN1_BIT_STRING *signature,
             char *data, EVP_PKEY *pkey)
@@ -85,7 +88,7 @@ int ASN1_verify(int (*i2d)(), X509_ALGOR *a, ASN1_BIT_STRING *signature,
                }
        
        inl=i2d(data,NULL);
-       buf_in=Malloc((unsigned int)inl);
+       buf_in=OPENSSL_malloc((unsigned int)inl);
        if (buf_in == NULL)
                {
                ASN1err(ASN1_F_ASN1_VERIFY,ERR_R_MALLOC_FAILURE);
@@ -98,7 +101,7 @@ int ASN1_verify(int (*i2d)(), X509_ALGOR *a, ASN1_BIT_STRING *signature,
        EVP_VerifyUpdate(&ctx,(unsigned char *)buf_in,inl);
 
        memset(buf_in,0,(unsigned int)inl);
-       Free((char *)buf_in);
+       OPENSSL_free(buf_in);
 
        if (EVP_VerifyFinal(&ctx,(unsigned char *)signature->data,
                        (unsigned int)signature->length,pkey) <= 0)