-
Notifications
You must be signed in to change notification settings - Fork 27
/
Copy pathciphers_opencl.h
65 lines (57 loc) · 2.73 KB
/
ciphers_opencl.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
// vim:foldenable:foldmethod=marker:foldmarker=[[,]]
/**
* @version 0.1.3 (2011)
* @author Johannes Gilger <[email protected]>
*
* Copyright 2011 Johannes Gilger
*
* This file is part of engine-cuda
*
* engine-cuda is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License or
* any later version.
*
* engine-cuda 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 General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with engine-cuda. If not, see <http://www.gnu.org/licenses/>.
*
*/
#include <stdio.h>
#include <stdlib.h>
#include <stdint.h>
#include <assert.h>
#include <memory.h>
#include <openssl/engine.h>
#include <CL/opencl.h>
#include "opencl_common.h"
#include <openssl/aes.h>
void AES_opencl_crypt(opencl_crypt_parameters *c);
void AES_opencl_transfer_key_schedule(AES_KEY *ks, cl_mem *device_schedule,cl_command_queue queue);
void AES_opencl_transfer_iv(cl_context, const unsigned char*, cl_command_queue);
int AES_opencl_set_encrypt_key(const unsigned char *userKey, const int bits, AES_KEY *key);
int AES_opencl_set_decrypt_key(const unsigned char *userKey, const int bits, AES_KEY *key);
#include <openssl/blowfish.h>
void BF_opencl_transfer_key_schedule(BF_KEY *ks,cl_mem *device_schedule,cl_command_queue queue);
void BF_opencl_crypt(opencl_crypt_parameters *c);
void BF_opencl_transfer_iv(cl_context, const unsigned char*, cl_command_queue);
#include <openssl/des.h>
void DES_opencl_crypt(opencl_crypt_parameters *c);
void DES_opencl_transfer_key_schedule(DES_key_schedule *ks, cl_mem *device_schedule,cl_command_queue queue);
void DES_opencl_transfer_iv(cl_context, const unsigned char*, cl_command_queue);
#include <openssl/cast.h>
void CAST_opencl_crypt(opencl_crypt_parameters *c);
void CAST_opencl_transfer_key_schedule(CAST_KEY *ks, cl_mem *device_schedule,cl_command_queue queue);
void CAST_opencl_transfer_iv(cl_context, const unsigned char*, cl_command_queue);
#include <openssl/camellia.h>
void CMLL_opencl_crypt(opencl_crypt_parameters *c);
void CMLL_opencl_transfer_key_schedule(CAMELLIA_KEY *ks, cl_mem *device_schedule,cl_command_queue queue);
void CMLL_opencl_transfer_iv(cl_context, const unsigned char*, cl_command_queue);
#include <openssl/idea.h>
void IDEA_opencl_crypt(opencl_crypt_parameters *c);
void IDEA_opencl_transfer_key_schedule(IDEA_KEY_SCHEDULE *ks, cl_mem *device_schedule,cl_command_queue queue);
void IDEA_opencl_transfer_iv(cl_context, const unsigned char*, cl_command_queue);