#elif defined(ARCHIVE_HASH_MD5_WIN)
# define ARCHIVE_HAS_MD5
typedef MD5_CTX archive_md5_ctx;
-# define archive_md5_init(ctx) MD5_Init(ctx)
-# define archive_md5_final(ctx, buf) MD5_Final(buf, ctx)
-# define archive_md5_update(ctx, buf, n) MD5_Update(ctx, buf, n)
+# define archive_md5_init(ctx) __la_MD5_Init(ctx)
+# define archive_md5_final(ctx, buf) __la_MD5_Final(buf, ctx)
+# define archive_md5_update(ctx, buf, n) __la_MD5_Update(ctx, buf, n)
#endif
#if defined(ARCHIVE_HASH_RMD160_LIBC)
#elif defined(ARCHIVE_HASH_SHA1_WIN)
# define ARCHIVE_HAS_SHA1
typedef SHA1_CTX archive_sha1_ctx;
-# define archive_sha1_init(ctx) SHA1_Init(ctx)
-# define archive_sha1_final(ctx, buf) SHA1_Final(buf, ctx)
-# define archive_sha1_update(ctx, buf, n) SHA1_Update(ctx, buf, n)
+# define archive_sha1_init(ctx) __la_SHA1_Init(ctx)
+# define archive_sha1_final(ctx, buf) __la_SHA1_Final(buf, ctx)
+# define archive_sha1_update(ctx, buf, n) __la_SHA1_Update(ctx, buf, n)
#endif
#if defined(ARCHIVE_HASH_SHA256_LIBC)
#elif defined(ARCHIVE_HASH_SHA256_WIN)
# define ARCHIVE_HAS_SHA256
typedef SHA256_CTX archive_sha256_ctx;
-# define archive_sha256_init(ctx) SHA256_Init(ctx)
-# define archive_sha256_final(ctx, buf) SHA256_Final(buf, ctx)
-# define archive_sha256_update(ctx, buf, n) SHA256_Update(ctx, buf, n)
+# define archive_sha256_init(ctx) __la_SHA256_Init(ctx)
+# define archive_sha256_final(ctx, buf) __la_SHA256_Final(buf, ctx)
+# define archive_sha256_update(ctx, buf, n) __la_SHA256_Update(ctx, buf, n)
#endif
#if defined(ARCHIVE_HASH_SHA384_LIBC)
#elif defined(ARCHIVE_HASH_SHA384_WIN)
# define ARCHIVE_HAS_SHA384
typedef SHA512_CTX archive_sha384_ctx;
-# define archive_sha384_init(ctx) SHA384_Init(ctx)
-# define archive_sha384_final(ctx, buf) SHA384_Final(buf, ctx)
-# define archive_sha384_update(ctx, buf, n) SHA384_Update(ctx, buf, n)
+# define archive_sha384_init(ctx) __la_SHA384_Init(ctx)
+# define archive_sha384_final(ctx, buf) __la_SHA384_Final(buf, ctx)
+# define archive_sha384_update(ctx, buf, n) __la_SHA384_Update(ctx, buf, n)
#endif
#if defined(ARCHIVE_HASH_SHA512_LIBC)
#elif defined(ARCHIVE_HASH_SHA512_WIN)
# define ARCHIVE_HAS_SHA512
typedef SHA512_CTX archive_sha512_ctx;
-# define archive_sha512_init(ctx) SHA512_Init(ctx)
-# define archive_sha512_final(ctx, buf) SHA512_Final(buf, ctx)
-# define archive_sha512_update(ctx, buf, n) SHA512_Update(ctx, buf, n)
+# define archive_sha512_init(ctx) __la_SHA512_Init(ctx)
+# define archive_sha512_final(ctx, buf) __la_SHA512_Final(buf, ctx)
+# define archive_sha512_update(ctx, buf, n) __la_SHA512_Update(ctx, buf, n)
#endif
}
#define DIGEST_INIT(name, algid) \
-void name ## _Init(Digest_CTX *ctx)\
+void __la_ ## name ## _Init(Digest_CTX *ctx)\
{\
Digest_Init(ctx, algid);\
}
#define DIGEST_UPDATE(name) \
-void name ## _Update(Digest_CTX *ctx, const unsigned char *buf, size_t len)\
+void __la_ ## name ## _Update(Digest_CTX *ctx, const unsigned char *buf, size_t len)\
{\
Digest_Update(ctx, buf, len);\
}
#define DIGEST_FINAL(name, size) \
-void name ## _Final(unsigned char *buf, Digest_CTX *ctx)\
+void __la_ ## name ## _Final(unsigned char *buf, Digest_CTX *ctx)\
{\
Digest_Final(buf, size, ctx);\
}
/* Message digest function */
#if defined(ARCHIVE_HASH_MD5_WIN)
-extern void MD5_Init(Digest_CTX *ctx);
-extern void MD5_Update(Digest_CTX *ctx, const unsigned char *buf,
+extern void __la_MD5_Init(Digest_CTX *ctx);
+extern void __la_MD5_Update(Digest_CTX *ctx, const unsigned char *buf,
size_t len);
-extern void MD5_Final(unsigned char *buf, Digest_CTX *ctx);
+extern void __la_MD5_Final(unsigned char *buf, Digest_CTX *ctx);
#endif
#if defined(ARCHIVE_HASH_SHA1_WIN)
-extern void SHA1_Init(Digest_CTX *ctx);
-extern void SHA1_Update(Digest_CTX *ctx, const unsigned char *buf,
+extern void __la_SHA1_Init(Digest_CTX *ctx);
+extern void __la_SHA1_Update(Digest_CTX *ctx, const unsigned char *buf,
size_t len);
-extern void SHA1_Final(unsigned char *buf, Digest_CTX *ctx);
+extern void __la_SHA1_Final(unsigned char *buf, Digest_CTX *ctx);
#endif
#if defined(ARCHIVE_HASH_SHA256_WIN)
-extern void SHA256_Init(Digest_CTX *ctx);
-extern void SHA256_Update(Digest_CTX *ctx, const unsigned char *buf,
+extern void __la_SHA256_Init(Digest_CTX *ctx);
+extern void __la_SHA256_Update(Digest_CTX *ctx, const unsigned char *buf,
size_t len);
-extern void SHA256_Final(unsigned char *buf, Digest_CTX *ctx);
+extern void __la_SHA256_Final(unsigned char *buf, Digest_CTX *ctx);
#endif
#if defined(ARCHIVE_HASH_SHA384_WIN)
-extern void SHA384_Init(Digest_CTX *ctx);
-extern void SHA384_Update(Digest_CTX *ctx, const unsigned char *buf,
+extern void __la_SHA384_Init(Digest_CTX *ctx);
+extern void __la_SHA384_Update(Digest_CTX *ctx, const unsigned char *buf,
size_t len);
-extern void SHA384_Final(unsigned char *buf, Digest_CTX *ctx);
+extern void __la_SHA384_Final(unsigned char *buf, Digest_CTX *ctx);
#endif
#if defined(ARCHIVE_HASH_SHA512_WIN)
-extern void SHA512_Init(Digest_CTX *ctx);
-extern void SHA512_Update(Digest_CTX *ctx, const unsigned char *buf,
+extern void __la_SHA512_Init(Digest_CTX *ctx);
+extern void __la_SHA512_Update(Digest_CTX *ctx, const unsigned char *buf,
size_t len);
-extern void SHA512_Final(unsigned char *buf, Digest_CTX *ctx);
+extern void __la_SHA512_Final(unsigned char *buf, Digest_CTX *ctx);
#endif
#endif /* LIBARCHIVE_ARCHIVE_WINDOWS_H_INCLUDED */