chromium/third_party/ffmpeg/libavutil/camellia.c

/*
 * An implementation of the CAMELLIA algorithm as mentioned in RFC3713
 * Copyright (c) 2014 Supraja Meedinti
 *
 * This file is part of FFmpeg.
 *
 * FFmpeg is free software; you can redistribute it and/or
 * modify it under the terms of the GNU Lesser General Public
 * License as published by the Free Software Foundation; either
 * version 2.1 of the License, or (at your option) any later version.
 *
 * FFmpeg is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 * Lesser General Public License for more details.
 *
 * You should have received a copy of the GNU Lesser General Public
 * License along with FFmpeg; if not, write to the Free Software
 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
 */

#include <string.h>

#include "camellia.h"
#include "error.h"
#include "intreadwrite.h"
#include "mem.h"
#include "attributes.h"

#define LR32(x,c)
#define RR32(x,c)

#define MASK8
#define MASK32
#define MASK64

#define Sigma1
#define Sigma2
#define Sigma3
#define Sigma4
#define Sigma5
#define Sigma6

static uint64_t SP[8][256];

AVCAMELLIA;

static const uint8_t SBOX1[256] =;

static const uint8_t SBOX2[256] =;

static const uint8_t SBOX3[256] =;

static const uint8_t SBOX4[256] =;

const int av_camellia_size =;

static void LR128(uint64_t d[2], const uint64_t K[2], int x)
{}

static uint64_t F(uint64_t F_IN, uint64_t KE)
{}

static uint64_t FL(uint64_t FL_IN, uint64_t KE)
{}

static uint64_t FLINV(uint64_t FLINV_IN, uint64_t KE)
{}

static const uint8_t shifts[2][12] =;

static const uint8_t vars[2][12] =;

static void generate_round_keys(AVCAMELLIA *cs, uint64_t Kl[2], uint64_t Kr[2], uint64_t Ka[2], uint64_t Kb[2])
{}

static void camellia_encrypt(AVCAMELLIA *cs, uint8_t *dst, const uint8_t *src)
{}

static void camellia_decrypt(AVCAMELLIA *cs, uint8_t *dst, const uint8_t *src, uint8_t *iv)
{}

static void computeSP(void)
{}

struct AVCAMELLIA *av_camellia_alloc(void)
{}

av_cold int av_camellia_init(AVCAMELLIA *cs, const uint8_t *key, int key_bits)
{}

void av_camellia_crypt(AVCAMELLIA *cs, uint8_t *dst, const uint8_t *src, int count, uint8_t *iv, int decrypt)
{}