mirror of
https://github.com/jedisct1/libsodium.git
synced 2024-12-28 22:21:15 -07:00
More api.h removal
This commit is contained in:
parent
e5a6057724
commit
fd0c47025f
@ -234,7 +234,6 @@ libsodium_la_SOURCES += \
|
||||
crypto_sign/ed25519/ref10/obsolete.c \
|
||||
crypto_stream/aes128ctr/portable/afternm_aes128ctr.c \
|
||||
crypto_stream/aes128ctr/stream_aes128ctr_api.c \
|
||||
crypto_stream/aes128ctr/portable/api.h \
|
||||
crypto_stream/aes128ctr/portable/beforenm_aes128ctr.c \
|
||||
crypto_stream/aes128ctr/portable/common.h \
|
||||
crypto_stream/aes128ctr/portable/common_aes128ctr.c \
|
||||
|
@ -2,12 +2,12 @@
|
||||
* Date: 2009-03-19
|
||||
* Public domain */
|
||||
|
||||
#include "api.h"
|
||||
#include "crypto_stream_aes128ctr.h"
|
||||
#include "int128.h"
|
||||
#include "common.h"
|
||||
#include "consts.h"
|
||||
|
||||
int crypto_stream_afternm(unsigned char *out, unsigned long long len, const unsigned char *nonce, const unsigned char *c)
|
||||
int crypto_stream_aes128ctr_afternm(unsigned char *out, unsigned long long len, const unsigned char *nonce, const unsigned char *c)
|
||||
{
|
||||
|
||||
int128 xmm0;
|
||||
|
@ -1,13 +0,0 @@
|
||||
|
||||
#include "crypto_stream_aes128ctr.h"
|
||||
|
||||
#define crypto_stream crypto_stream_aes128ctr
|
||||
#define crypto_stream_xor crypto_stream_aes128ctr_xor
|
||||
#define crypto_stream_beforenm crypto_stream_aes128ctr_beforenm
|
||||
#define crypto_stream_afternm crypto_stream_aes128ctr_afternm
|
||||
#define crypto_stream_xor_afternm crypto_stream_aes128ctr_xor_afternm
|
||||
#define crypto_stream_KEYBYTES crypto_stream_aes128ctr_KEYBYTES
|
||||
#define crypto_stream_NONCEBYTES crypto_stream_aes128ctr_NONCEBYTES
|
||||
#define crypto_stream_BEFORENMBYTES crypto_stream_aes128ctr_BEFORENMBYTES
|
||||
#define crypto_stream_IMPLEMENTATION crypto_stream_aes128ctr_IMPLEMENTATION
|
||||
#define crypto_stream_VERSION crypto_stream_aes128ctr_VERSION
|
@ -2,12 +2,12 @@
|
||||
* Date: 2009-03-19
|
||||
* Public domain */
|
||||
|
||||
#include "api.h"
|
||||
#include "crypto_stream_aes128ctr.h"
|
||||
#include "consts.h"
|
||||
#include "int128.h"
|
||||
#include "common.h"
|
||||
|
||||
int crypto_stream_beforenm(unsigned char *c, const unsigned char *k)
|
||||
int crypto_stream_aes128ctr_beforenm(unsigned char *c, const unsigned char *k)
|
||||
{
|
||||
|
||||
/*
|
||||
|
@ -1,19 +1,20 @@
|
||||
#include "api.h"
|
||||
|
||||
int crypto_stream(
|
||||
#include "crypto_stream_aes128ctr.h"
|
||||
|
||||
int crypto_stream_aes128ctr(
|
||||
unsigned char *out,
|
||||
unsigned long long outlen,
|
||||
const unsigned char *n,
|
||||
const unsigned char *k
|
||||
)
|
||||
{
|
||||
unsigned char d[crypto_stream_BEFORENMBYTES];
|
||||
crypto_stream_beforenm(d, k);
|
||||
crypto_stream_afternm(out, outlen, n, d);
|
||||
unsigned char d[crypto_stream_aes128ctr_BEFORENMBYTES];
|
||||
crypto_stream_aes128ctr_beforenm(d, k);
|
||||
crypto_stream_aes128ctr_afternm(out, outlen, n, d);
|
||||
return 0;
|
||||
}
|
||||
|
||||
int crypto_stream_xor(
|
||||
int crypto_stream_aes128ctr_xor(
|
||||
unsigned char *out,
|
||||
const unsigned char *in,
|
||||
unsigned long long inlen,
|
||||
@ -21,8 +22,8 @@ int crypto_stream_xor(
|
||||
const unsigned char *k
|
||||
)
|
||||
{
|
||||
unsigned char d[crypto_stream_BEFORENMBYTES];
|
||||
crypto_stream_beforenm(d, k);
|
||||
crypto_stream_xor_afternm(out, in, inlen, n, d);
|
||||
unsigned char d[crypto_stream_aes128ctr_BEFORENMBYTES];
|
||||
crypto_stream_aes128ctr_beforenm(d, k);
|
||||
crypto_stream_aes128ctr_xor_afternm(out, in, inlen, n, d);
|
||||
return 0;
|
||||
}
|
||||
|
@ -2,13 +2,12 @@
|
||||
* Date: 2009-03-19
|
||||
* Public domain */
|
||||
|
||||
#include <stdio.h>
|
||||
#include "api.h"
|
||||
#include "crypto_stream_aes128ctr.h"
|
||||
#include "int128.h"
|
||||
#include "common.h"
|
||||
#include "consts.h"
|
||||
|
||||
int crypto_stream_xor_afternm(unsigned char *out, const unsigned char *in, unsigned long long len, const unsigned char *nonce, const unsigned char *c)
|
||||
int crypto_stream_aes128ctr_xor_afternm(unsigned char *out, const unsigned char *in, unsigned long long len, const unsigned char *nonce, const unsigned char *c)
|
||||
{
|
||||
|
||||
int128 xmm0;
|
||||
|
Loading…
Reference in New Issue
Block a user