-
Notifications
You must be signed in to change notification settings - Fork 25
/
Copy pathCA.h
38 lines (31 loc) · 775 Bytes
/
CA.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
#ifndef ___CA_H
#define ___CA_H
/* aes key */
typedef struct ca_descr_aes {
unsigned int index;
unsigned int parity; /* 0 == even, 1 == odd */
unsigned char cw[16];
} ca_descr_aes_t;
enum ca_descr_data_type {
CA_DATA_IV,
CA_DATA_KEY,
};
enum ca_descr_parity {
CA_PARITY_EVEN,
CA_PARITY_ODD,
};
typedef struct ca_descr_data {
uint32_t index;
enum ca_descr_parity parity;
enum ca_descr_data_type data_type;
uint32_t length;
uint8_t *data;
} ca_descr_data_t;
#ifndef CA_SET_PID /* removed in kernel 4.14 */
typedef struct ca_pid {
unsigned int pid;
int index; /* -1 == disable */
} ca_pid_t;
#define CA_SET_PID _IOW('o', 135, struct ca_pid)
#endif
#endif // __CA_H