From cdc95b904ed18fac29205ba9b6bc351cd9853820 Mon Sep 17 00:00:00 2001 From: Jan Mojzis Date: Tue, 9 Jan 2018 06:48:44 +0100 Subject: [PATCH] removed uint64_pack_big/uint64_unpack_big --- crypto/CRYPTOLIBS | 2 -- crypto/CRYPTOSOURCES | 2 -- crypto/uint64_pack_big.c | 12 ------------ crypto/uint64_pack_big.h | 8 -------- crypto/uint64_unpack_big.c | 14 -------------- crypto/uint64_unpack_big.h | 8 -------- 6 files changed, 46 deletions(-) delete mode 100644 crypto/uint64_pack_big.c delete mode 100644 crypto/uint64_pack_big.h delete mode 100644 crypto/uint64_unpack_big.c delete mode 100644 crypto/uint64_unpack_big.h diff --git a/crypto/CRYPTOLIBS b/crypto/CRYPTOLIBS index 592ffe5..007d903 100644 --- a/crypto/CRYPTOLIBS +++ b/crypto/CRYPTOLIBS @@ -4,8 +4,6 @@ crypto_core_aes256encrypt.o randombytes.o uint32_pack.o uint32_unpack.o -uint64_pack_big.o -uint64_unpack_big.o uint32_pack_big.o uint32_unpack_big.o crypto_stream_chacha20.o diff --git a/crypto/CRYPTOSOURCES b/crypto/CRYPTOSOURCES index edf10d9..2edbf05 100644 --- a/crypto/CRYPTOSOURCES +++ b/crypto/CRYPTOSOURCES @@ -4,8 +4,6 @@ crypto_core_aes256encrypt randombytes uint32_pack uint32_unpack -uint64_pack_big -uint64_unpack_big uint32_pack_big uint32_unpack_big crypto_stream_chacha20 diff --git a/crypto/uint64_pack_big.c b/crypto/uint64_pack_big.c deleted file mode 100644 index f24dcef..0000000 --- a/crypto/uint64_pack_big.c +++ /dev/null @@ -1,12 +0,0 @@ -#include "uint64_pack_big.h" - -/* -The 'uint64_pack_big' function converts 64-bit unsigned -integer into 8 bytes stored in big-endian format -*/ -void uint64_pack_big(unsigned char *y, crypto_uint64 x) { - - long long i; - - for (i = 7; i >= 0; --i) { y[i] = x; x >>= 8; } -} diff --git a/crypto/uint64_pack_big.h b/crypto/uint64_pack_big.h deleted file mode 100644 index 0a386b7..0000000 --- a/crypto/uint64_pack_big.h +++ /dev/null @@ -1,8 +0,0 @@ -#ifndef _UINT64_PACK_BIG____ -#define _UINT64_PACK_BIG____ - -#include "crypto_uint64.h" - -extern void uint64_pack_big(unsigned char *y, crypto_uint64 x); - -#endif diff --git a/crypto/uint64_unpack_big.c b/crypto/uint64_unpack_big.c deleted file mode 100644 index e39348e..0000000 --- a/crypto/uint64_unpack_big.c +++ /dev/null @@ -1,14 +0,0 @@ -#include "uint64_unpack_big.h" - -/* -The 'uint64_unpack_big' function converts 8 bytes -in big-endian format into 64-bit unsigned integer. -*/ -crypto_uint64 uint64_unpack_big(const unsigned char *x) { - - crypto_uint64 y = 0; - long long i; - - for (i = 0; i < 8; ++i) y = (y << 8) | x[i]; - return y; -} diff --git a/crypto/uint64_unpack_big.h b/crypto/uint64_unpack_big.h deleted file mode 100644 index aab4384..0000000 --- a/crypto/uint64_unpack_big.h +++ /dev/null @@ -1,8 +0,0 @@ -#ifndef _UINT64_UNPACK_BIG____ -#define _UINT64_UNPACK_BIG____ - -#include "crypto_uint64.h" - -extern crypto_uint64 uint64_unpack_big(const unsigned char *); - -#endif