Home
last modified time | relevance | path

Searched refs:crypt_stat (Results 1 – 8 of 8) sorted by relevance

/linux-3.4.99/fs/ecryptfs/
Dcrypto.c41 ecryptfs_decrypt_page_offset(struct ecryptfs_crypt_stat *crypt_stat,
46 ecryptfs_encrypt_page_offset(struct ecryptfs_crypt_stat *crypt_stat,
96 struct ecryptfs_crypt_stat *crypt_stat, in ecryptfs_calculate_md5() argument
101 .tfm = crypt_stat->hash_tfm, in ecryptfs_calculate_md5()
106 mutex_lock(&crypt_stat->cs_hash_tfm_mutex); in ecryptfs_calculate_md5()
118 crypt_stat->hash_tfm = desc.tfm; in ecryptfs_calculate_md5()
142 mutex_unlock(&crypt_stat->cs_hash_tfm_mutex); in ecryptfs_calculate_md5()
179 int ecryptfs_derive_iv(char *iv, struct ecryptfs_crypt_stat *crypt_stat, in ecryptfs_derive_iv() argument
188 ecryptfs_dump_hex(crypt_stat->root_iv, crypt_stat->iv_bytes); in ecryptfs_derive_iv()
194 memcpy(src, crypt_stat->root_iv, crypt_stat->iv_bytes); in ecryptfs_derive_iv()
[all …]
Dmmap.c83 struct ecryptfs_crypt_stat *crypt_stat) in strip_xattr_flag() argument
85 if (crypt_stat->flags & ECRYPTFS_METADATA_IN_XATTR) { in strip_xattr_flag()
88 crypt_stat->flags &= ~ECRYPTFS_METADATA_IN_XATTR; in strip_xattr_flag()
89 ecryptfs_write_crypt_stat_flags(page_virt, crypt_stat, in strip_xattr_flag()
91 crypt_stat->flags |= ECRYPTFS_METADATA_IN_XATTR; in strip_xattr_flag()
123 struct ecryptfs_crypt_stat *crypt_stat) in ecryptfs_copy_up_encrypted_with_header() argument
127 / crypt_stat->extent_size); in ecryptfs_copy_up_encrypted_with_header()
135 (crypt_stat->metadata_size / crypt_stat->extent_size); in ecryptfs_copy_up_encrypted_with_header()
149 strip_xattr_flag(page_virt + 16, crypt_stat); in ecryptfs_copy_up_encrypted_with_header()
151 crypt_stat, in ecryptfs_copy_up_encrypted_with_header()
[all …]
Dfile.c147 struct ecryptfs_crypt_stat *crypt_stat; in read_or_initialize_metadata() local
150 crypt_stat = &ecryptfs_inode_to_private(inode)->crypt_stat; in read_or_initialize_metadata()
153 mutex_lock(&crypt_stat->cs_mutex); in read_or_initialize_metadata()
155 if (crypt_stat->flags & ECRYPTFS_POLICY_APPLIED && in read_or_initialize_metadata()
156 crypt_stat->flags & ECRYPTFS_KEY_VALID) { in read_or_initialize_metadata()
166 crypt_stat->flags &= ~(ECRYPTFS_I_SIZE_INITIALIZED in read_or_initialize_metadata()
181 mutex_unlock(&crypt_stat->cs_mutex); in read_or_initialize_metadata()
197 struct ecryptfs_crypt_stat *crypt_stat = NULL; in ecryptfs_open() local
226 crypt_stat = &ecryptfs_inode_to_private(inode)->crypt_stat; in ecryptfs_open()
227 mutex_lock(&crypt_stat->cs_mutex); in ecryptfs_open()
[all …]
Dkeystore.c300 struct ecryptfs_crypt_stat *crypt_stat, char **packet, in write_tag_66_packet() argument
319 data_len = (5 + ECRYPTFS_SIG_SIZE_HEX + crypt_stat->key_size); in write_tag_66_packet()
339 rc = ecryptfs_write_packet_length(&message[i], crypt_stat->key_size + 3, in write_tag_66_packet()
348 memcpy(&message[i], crypt_stat->key, crypt_stat->key_size); in write_tag_66_packet()
349 i += crypt_stat->key_size; in write_tag_66_packet()
350 for (j = 0; j < crypt_stat->key_size; j++) in write_tag_66_packet()
351 checksum += crypt_stat->key[j]; in write_tag_66_packet()
1146 struct ecryptfs_crypt_stat *crypt_stat) in decrypt_pki_encrypted_session_key() argument
1189 memcpy(crypt_stat->key, auth_tok->session_key.decrypted_key, in decrypt_pki_encrypted_session_key()
1191 crypt_stat->key_size = auth_tok->session_key.decrypted_key_size; in decrypt_pki_encrypted_session_key()
[all …]
Dinode.c233 struct ecryptfs_crypt_stat *crypt_stat = in ecryptfs_initialize_file() local
234 &ecryptfs_inode_to_private(ecryptfs_inode)->crypt_stat; in ecryptfs_initialize_file()
239 crypt_stat->flags &= ~(ECRYPTFS_ENCRYPTED); in ecryptfs_initialize_file()
310 struct ecryptfs_crypt_stat *crypt_stat; in ecryptfs_i_size_read() local
322 crypt_stat = &ecryptfs_inode_to_private(inode)->crypt_stat; in ecryptfs_i_size_read()
324 if (!(crypt_stat->flags & ECRYPTFS_POLICY_APPLIED)) in ecryptfs_i_size_read()
325 ecryptfs_set_default_sizes(crypt_stat); in ecryptfs_i_size_read()
332 crypt_stat->flags |= ECRYPTFS_METADATA_IN_XATTR; in ecryptfs_i_size_read()
769 upper_size_to_lower_size(struct ecryptfs_crypt_stat *crypt_stat, in upper_size_to_lower_size() argument
774 lower_size = ecryptfs_lower_header_size(crypt_stat); in upper_size_to_lower_size()
[all …]
Decryptfs_kernel.h243 struct ecryptfs_crypt_stat crypt_stat; member
250 struct ecryptfs_crypt_stat *crypt_stat; member
343 struct ecryptfs_crypt_stat *crypt_stat; member
410 ecryptfs_lower_header_size(struct ecryptfs_crypt_stat *crypt_stat) in ecryptfs_lower_header_size() argument
412 if (crypt_stat->flags & ECRYPTFS_METADATA_IN_XATTR) in ecryptfs_lower_header_size()
414 return crypt_stat->metadata_size; in ecryptfs_lower_header_size()
581 struct ecryptfs_crypt_stat *crypt_stat,
588 int ecryptfs_compute_root_iv(struct ecryptfs_crypt_stat *crypt_stat);
590 void ecryptfs_init_crypt_stat(struct ecryptfs_crypt_stat *crypt_stat);
591 void ecryptfs_destroy_crypt_stat(struct ecryptfs_crypt_stat *crypt_stat);
[all …]
Dread_write.c113 struct ecryptfs_crypt_stat *crypt_stat; in ecryptfs_write() local
120 crypt_stat = &ecryptfs_inode_to_private(ecryptfs_inode)->crypt_stat; in ecryptfs_write()
186 if (crypt_stat->flags & ECRYPTFS_ENCRYPTED) in ecryptfs_write()
203 if (crypt_stat->flags & ECRYPTFS_ENCRYPTED) { in ecryptfs_write()
Dsuper.c59 ecryptfs_init_crypt_stat(&inode_info->crypt_stat); in ecryptfs_alloc_inode()
92 ecryptfs_destroy_crypt_stat(&inode_info->crypt_stat); in ecryptfs_destroy_inode()