Commit 3bd87ab0 authored by Niels Möller's avatar Niels Möller
Browse files

Extra name-mangling, to avoid collisions in case a

program links with both nettle and libcrypto (the nettle-benchmark
program does).

Rev: src/nettle/des-compat.h:1.8
parent 986161a0
...@@ -35,10 +35,22 @@ ...@@ -35,10 +35,22 @@
#include "des.h" #include "des.h"
/* Some names collides with nettle, so we'll need some ugly symbol /* We use some name mangling, to avoid collisions with either other
* munging */ * nettle functions or with libcrypto. */
#define des_set_key des_key_sched #define des_ecb3_encrypt nettle_openssl_des_ecb3_encrypt
#define des_cbc_cksum nettle_openssl_des_cbc_cksum
#define des_ncbc_encrypt nettle_openssl_des_ncbc_encrypt
#define des_cbc_encrypt nettle_openssl_des_cbc_encrypt
#define des_ecb_encrypt nettle_openssl_des_ecb_encrypt
#define des_ede3_cbc_encrypt nettle_openssl_des_ede3_cbc_encrypt
#define des_set_odd_parity nettle_openssl_des_set_odd_parity
#define des_check_key nettle_openssl_des_check_key
#define des_key_sched nettle_openssl_des_key_sched
#define des_is_weak_key nettle_openssl_des_is_weak_key
/* An extra alias */
#define des_set_key nettle_openssl_des_key_sched
enum { DES_DECRYPT = 0, DES_ENCRYPT = 1 }; enum { DES_DECRYPT = 0, DES_ENCRYPT = 1 };
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment