forked from Rupan/paperbak
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdummycrypto.c
50 lines (41 loc) · 1.36 KB
/
dummycrypto.c
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
#include <windows.h>
#include <stdbool.h>
#include "CRYPTO/pwd2key.h"
#include "CRYPTO/aes.h"
static void __attribute__((noreturn)) not_implemented(void)
{
MessageBox(NULL, "Not implemented", "Not implemented. Try using GPG to encrypt.", MB_OK);
while (true)
{
asm("int $3");
}
}
void derive_key(
const unsigned char pwd[], /* the PASSWORD, and */
unsigned int pwd_len, /* its length */
const unsigned char salt[], /* the SALT and its */
unsigned int salt_len, /* length */
unsigned int iter, /* the number of iterations */
unsigned char key[], /* space for the output key */
unsigned int key_len) /* and its required length */
{
not_implemented();
}
AES_RETURN aes_encrypt_key(const unsigned char *key, int key_len, aes_encrypt_ctx cx[1])
{
not_implemented();
}
AES_RETURN aes_decrypt_key(const unsigned char *key, int key_len, aes_decrypt_ctx cx[1])
{
not_implemented();
}
AES_RETURN aes_cbc_encrypt(const unsigned char *ibuf, unsigned char *obuf,
int len, unsigned char *iv, const aes_encrypt_ctx cx[1])
{
not_implemented();
}
AES_RETURN aes_cbc_decrypt(const unsigned char *ibuf, unsigned char *obuf,
int len, unsigned char *iv, const aes_decrypt_ctx cx[1])
{
not_implemented();
}