cipher.c (4ffa88c99c54d2a30f79e3dbecec50b023eff1c8) | cipher.c (986bc8ded9a5459e72951cc91b53cf2b52eb735f) |
---|---|
1/* 2 * QEMU Crypto cipher algorithms 3 * 4 * Copyright (c) 2015 Red Hat, Inc. 5 * 6 * This library is free software; you can redistribute it and/or 7 * modify it under the terms of the GNU Lesser General Public 8 * License as published by the Free Software Foundation; either --- 136 unchanged lines hidden (view full) --- 145 r = (r & 0xaa) >> 1 | (r & 0x55) << 1; 146 ret[i] = r; 147 } 148 return ret; 149} 150#endif /* CONFIG_GCRYPT || CONFIG_NETTLE */ 151 152#ifdef CONFIG_GCRYPT | 1/* 2 * QEMU Crypto cipher algorithms 3 * 4 * Copyright (c) 2015 Red Hat, Inc. 5 * 6 * This library is free software; you can redistribute it and/or 7 * modify it under the terms of the GNU Lesser General Public 8 * License as published by the Free Software Foundation; either --- 136 unchanged lines hidden (view full) --- 145 r = (r & 0xaa) >> 1 | (r & 0x55) << 1; 146 ret[i] = r; 147 } 148 return ret; 149} 150#endif /* CONFIG_GCRYPT || CONFIG_NETTLE */ 151 152#ifdef CONFIG_GCRYPT |
153#include "crypto/cipher-gcrypt.c" | 153#include "cipher-gcrypt.c" |
154#elif defined CONFIG_NETTLE | 154#elif defined CONFIG_NETTLE |
155#include "crypto/cipher-nettle.c" | 155#include "cipher-nettle.c" |
156#else | 156#else |
157#include "crypto/cipher-builtin.c" | 157#include "cipher-builtin.c" |
158#endif 159 160QCryptoCipher *qcrypto_cipher_new(QCryptoCipherAlgorithm alg, 161 QCryptoCipherMode mode, 162 const uint8_t *key, size_t nkey, 163 Error **errp) 164{ 165 QCryptoCipher *cipher; --- 69 unchanged lines hidden --- | 158#endif 159 160QCryptoCipher *qcrypto_cipher_new(QCryptoCipherAlgorithm alg, 161 QCryptoCipherMode mode, 162 const uint8_t *key, size_t nkey, 163 Error **errp) 164{ 165 QCryptoCipher *cipher; --- 69 unchanged lines hidden --- |