diff options
Diffstat (limited to 'fs')
-rw-r--r-- | fs/ecryptfs/crypto.c | 8 | ||||
-rw-r--r-- | fs/ecryptfs/ecryptfs_kernel.h | 4 | ||||
-rw-r--r-- | fs/ecryptfs/keystore.c | 8 |
3 files changed, 10 insertions, 10 deletions
diff --git a/fs/ecryptfs/crypto.c b/fs/ecryptfs/crypto.c index 942edfaa7113..40d14625f515 100644 --- a/fs/ecryptfs/crypto.c +++ b/fs/ecryptfs/crypto.c | |||
@@ -1128,7 +1128,7 @@ write_ecryptfs_flags(char *page_virt, struct ecryptfs_crypt_stat *crypt_stat, | |||
1128 | 1128 | ||
1129 | struct ecryptfs_cipher_code_str_map_elem { | 1129 | struct ecryptfs_cipher_code_str_map_elem { |
1130 | char cipher_str[16]; | 1130 | char cipher_str[16]; |
1131 | u16 cipher_code; | 1131 | u8 cipher_code; |
1132 | }; | 1132 | }; |
1133 | 1133 | ||
1134 | /* Add support for additional ciphers by adding elements here. The | 1134 | /* Add support for additional ciphers by adding elements here. The |
@@ -1152,10 +1152,10 @@ ecryptfs_cipher_code_str_map[] = { | |||
1152 | * | 1152 | * |
1153 | * Returns zero on no match, or the cipher code on match | 1153 | * Returns zero on no match, or the cipher code on match |
1154 | */ | 1154 | */ |
1155 | u16 ecryptfs_code_for_cipher_string(struct ecryptfs_crypt_stat *crypt_stat) | 1155 | u8 ecryptfs_code_for_cipher_string(struct ecryptfs_crypt_stat *crypt_stat) |
1156 | { | 1156 | { |
1157 | int i; | 1157 | int i; |
1158 | u16 code = 0; | 1158 | u8 code = 0; |
1159 | struct ecryptfs_cipher_code_str_map_elem *map = | 1159 | struct ecryptfs_cipher_code_str_map_elem *map = |
1160 | ecryptfs_cipher_code_str_map; | 1160 | ecryptfs_cipher_code_str_map; |
1161 | 1161 | ||
@@ -1187,7 +1187,7 @@ u16 ecryptfs_code_for_cipher_string(struct ecryptfs_crypt_stat *crypt_stat) | |||
1187 | * | 1187 | * |
1188 | * Returns zero on success | 1188 | * Returns zero on success |
1189 | */ | 1189 | */ |
1190 | int ecryptfs_cipher_code_to_string(char *str, u16 cipher_code) | 1190 | int ecryptfs_cipher_code_to_string(char *str, u8 cipher_code) |
1191 | { | 1191 | { |
1192 | int rc = 0; | 1192 | int rc = 0; |
1193 | int i; | 1193 | int i; |
diff --git a/fs/ecryptfs/ecryptfs_kernel.h b/fs/ecryptfs/ecryptfs_kernel.h index 2a6103954c1e..f44f71b7605a 100644 --- a/fs/ecryptfs/ecryptfs_kernel.h +++ b/fs/ecryptfs/ecryptfs_kernel.h | |||
@@ -558,8 +558,8 @@ int ecryptfs_read_and_validate_header_region(char *data, | |||
558 | struct inode *ecryptfs_inode); | 558 | struct inode *ecryptfs_inode); |
559 | int ecryptfs_read_and_validate_xattr_region(char *page_virt, | 559 | int ecryptfs_read_and_validate_xattr_region(char *page_virt, |
560 | struct dentry *ecryptfs_dentry); | 560 | struct dentry *ecryptfs_dentry); |
561 | u16 ecryptfs_code_for_cipher_string(struct ecryptfs_crypt_stat *crypt_stat); | 561 | u8 ecryptfs_code_for_cipher_string(struct ecryptfs_crypt_stat *crypt_stat); |
562 | int ecryptfs_cipher_code_to_string(char *str, u16 cipher_code); | 562 | int ecryptfs_cipher_code_to_string(char *str, u8 cipher_code); |
563 | void ecryptfs_set_default_sizes(struct ecryptfs_crypt_stat *crypt_stat); | 563 | void ecryptfs_set_default_sizes(struct ecryptfs_crypt_stat *crypt_stat); |
564 | int ecryptfs_generate_key_packet_set(char *dest_base, | 564 | int ecryptfs_generate_key_packet_set(char *dest_base, |
565 | struct ecryptfs_crypt_stat *crypt_stat, | 565 | struct ecryptfs_crypt_stat *crypt_stat, |
diff --git a/fs/ecryptfs/keystore.c b/fs/ecryptfs/keystore.c index f458c1f35565..682b1b2482c2 100644 --- a/fs/ecryptfs/keystore.c +++ b/fs/ecryptfs/keystore.c | |||
@@ -189,7 +189,7 @@ out: | |||
189 | } | 189 | } |
190 | 190 | ||
191 | static int | 191 | static int |
192 | parse_tag_65_packet(struct ecryptfs_session_key *session_key, u16 *cipher_code, | 192 | parse_tag_65_packet(struct ecryptfs_session_key *session_key, u8 *cipher_code, |
193 | struct ecryptfs_message *msg) | 193 | struct ecryptfs_message *msg) |
194 | { | 194 | { |
195 | size_t i = 0; | 195 | size_t i = 0; |
@@ -275,7 +275,7 @@ out: | |||
275 | 275 | ||
276 | 276 | ||
277 | static int | 277 | static int |
278 | write_tag_66_packet(char *signature, size_t cipher_code, | 278 | write_tag_66_packet(char *signature, u8 cipher_code, |
279 | struct ecryptfs_crypt_stat *crypt_stat, char **packet, | 279 | struct ecryptfs_crypt_stat *crypt_stat, char **packet, |
280 | size_t *packet_len) | 280 | size_t *packet_len) |
281 | { | 281 | { |
@@ -428,7 +428,7 @@ static int | |||
428 | decrypt_pki_encrypted_session_key(struct ecryptfs_auth_tok *auth_tok, | 428 | decrypt_pki_encrypted_session_key(struct ecryptfs_auth_tok *auth_tok, |
429 | struct ecryptfs_crypt_stat *crypt_stat) | 429 | struct ecryptfs_crypt_stat *crypt_stat) |
430 | { | 430 | { |
431 | u16 cipher_code = 0; | 431 | u8 cipher_code = 0; |
432 | struct ecryptfs_msg_ctx *msg_ctx; | 432 | struct ecryptfs_msg_ctx *msg_ctx; |
433 | struct ecryptfs_message *msg = NULL; | 433 | struct ecryptfs_message *msg = NULL; |
434 | char *auth_tok_sig; | 434 | char *auth_tok_sig; |
@@ -1537,7 +1537,7 @@ write_tag_3_packet(char *dest, size_t *remaining_bytes, | |||
1537 | struct scatterlist dst_sg; | 1537 | struct scatterlist dst_sg; |
1538 | struct scatterlist src_sg; | 1538 | struct scatterlist src_sg; |
1539 | struct mutex *tfm_mutex = NULL; | 1539 | struct mutex *tfm_mutex = NULL; |
1540 | size_t cipher_code; | 1540 | u8 cipher_code; |
1541 | size_t packet_size_length; | 1541 | size_t packet_size_length; |
1542 | size_t max_packet_size; | 1542 | size_t max_packet_size; |
1543 | struct ecryptfs_mount_crypt_stat *mount_crypt_stat = | 1543 | struct ecryptfs_mount_crypt_stat *mount_crypt_stat = |