• Home
  • Raw
  • Download

Lines Matching refs:rc

31 	int rc = 0;  in process_request_key_err()  local
36 rc = -ENOENT; in process_request_key_err()
40 rc = -ETIME; in process_request_key_err()
44 rc = -EINVAL; in process_request_key_err()
49 rc = -EINVAL; in process_request_key_err()
51 return rc; in process_request_key_err()
56 int rc = err_code; in process_find_global_auth_tok_for_sig_err() local
66 rc = process_request_key_err(err_code); in process_find_global_auth_tok_for_sig_err()
69 return rc; in process_find_global_auth_tok_for_sig_err()
84 int rc = 0; in ecryptfs_parse_packet_length() local
101 rc = -EINVAL; in ecryptfs_parse_packet_length()
105 rc = -EINVAL; in ecryptfs_parse_packet_length()
109 return rc; in ecryptfs_parse_packet_length()
125 int rc = 0; in ecryptfs_write_packet_length() local
136 rc = -EINVAL; in ecryptfs_write_packet_length()
140 return rc; in ecryptfs_write_packet_length()
151 int rc; in write_tag_64_packet() local
167 rc = -ENOMEM; in write_tag_64_packet()
171 rc = ecryptfs_write_packet_length(&message[i], ECRYPTFS_SIG_SIZE_HEX, in write_tag_64_packet()
173 if (rc) { in write_tag_64_packet()
181 rc = ecryptfs_write_packet_length(&message[i], in write_tag_64_packet()
184 if (rc) { in write_tag_64_packet()
195 return rc; in write_tag_64_packet()
209 int rc; in parse_tag_65_packet() local
221 rc = -EIO; in parse_tag_65_packet()
226 rc = -EIO; in parse_tag_65_packet()
232 rc = -EIO; in parse_tag_65_packet()
235 rc = ecryptfs_parse_packet_length(&data[i], &m_size, &data_len); in parse_tag_65_packet()
236 if (rc) { in parse_tag_65_packet()
238 "rc = [%d]\n", rc); in parse_tag_65_packet()
245 rc = -EIO; in parse_tag_65_packet()
252 rc = -EIO; in parse_tag_65_packet()
263 rc = -EIO; in parse_tag_65_packet()
277 rc = -EIO; in parse_tag_65_packet()
280 return rc; in parse_tag_65_packet()
295 int rc; in write_tag_66_packet() local
310 rc = -ENOMEM; in write_tag_66_packet()
314 rc = ecryptfs_write_packet_length(&message[i], ECRYPTFS_SIG_SIZE_HEX, in write_tag_66_packet()
316 if (rc) { in write_tag_66_packet()
325 rc = ecryptfs_write_packet_length(&message[i], crypt_stat->key_size + 3, in write_tag_66_packet()
327 if (rc) { in write_tag_66_packet()
342 return rc; in write_tag_66_packet()
353 int rc; in parse_tag_67_packet() local
366 rc = -EIO; in parse_tag_67_packet()
372 rc = -EIO; in parse_tag_67_packet()
378 rc = -EIO; in parse_tag_67_packet()
384 rc = ecryptfs_parse_packet_length(&data[i], &key_rec->enc_key_size, in parse_tag_67_packet()
386 if (rc) { in parse_tag_67_packet()
388 "rc = [%d]\n", rc); in parse_tag_67_packet()
393 rc = -EIO; in parse_tag_67_packet()
399 rc = -EIO; in parse_tag_67_packet()
408 return rc; in parse_tag_67_packet()
419 int rc = 0; in ecryptfs_verify_version() local
429 rc = -EINVAL; in ecryptfs_verify_version()
436 rc = -EINVAL; in ecryptfs_verify_version()
440 return rc; in ecryptfs_verify_version()
455 int rc = 0; in ecryptfs_verify_auth_tok_from_key() local
459 rc = PTR_ERR(*auth_tok); in ecryptfs_verify_auth_tok_from_key()
469 rc = -EINVAL; in ecryptfs_verify_auth_tok_from_key()
476 rc = -EINVAL; in ecryptfs_verify_auth_tok_from_key()
480 return rc; in ecryptfs_verify_auth_tok_from_key()
490 int rc = 0; in ecryptfs_find_global_auth_tok_for_sig() local
502 rc = -EINVAL; in ecryptfs_find_global_auth_tok_for_sig()
506 rc = key_validate(walker->global_auth_tok_key); in ecryptfs_find_global_auth_tok_for_sig()
507 if (rc) { in ecryptfs_find_global_auth_tok_for_sig()
508 if (rc == -EKEYEXPIRED) in ecryptfs_find_global_auth_tok_for_sig()
514 rc = ecryptfs_verify_auth_tok_from_key( in ecryptfs_find_global_auth_tok_for_sig()
516 if (rc) in ecryptfs_find_global_auth_tok_for_sig()
523 rc = -ENOENT; in ecryptfs_find_global_auth_tok_for_sig()
534 return rc; in ecryptfs_find_global_auth_tok_for_sig()
559 int rc = 0; in ecryptfs_find_auth_tok_for_sig() local
561 rc = ecryptfs_find_global_auth_tok_for_sig(auth_tok_key, auth_tok, in ecryptfs_find_auth_tok_for_sig()
563 if (rc == -ENOENT) { in ecryptfs_find_auth_tok_for_sig()
573 rc = ecryptfs_keyring_auth_tok_for_sig(auth_tok_key, auth_tok, in ecryptfs_find_auth_tok_for_sig()
576 return rc; in ecryptfs_find_auth_tok_for_sig()
625 int rc = 0; in ecryptfs_write_tag_70_packet() local
632 rc = ecryptfs_find_auth_tok_for_sig( in ecryptfs_write_tag_70_packet()
636 if (rc) { in ecryptfs_write_tag_70_packet()
639 mount_crypt_stat->global_default_fnek_sig, rc); in ecryptfs_write_tag_70_packet()
642 rc = ecryptfs_get_tfm_and_mutex_for_cipher_name( in ecryptfs_write_tag_70_packet()
645 if (unlikely(rc)) { in ecryptfs_write_tag_70_packet()
648 mount_crypt_stat->global_default_fn_cipher_name, rc); in ecryptfs_write_tag_70_packet()
682 rc = -EINVAL; in ecryptfs_write_tag_70_packet()
691 rc = -ENOMEM; in ecryptfs_write_tag_70_packet()
701 rc = -ENOMEM; in ecryptfs_write_tag_70_packet()
705 rc = ecryptfs_write_packet_length(&dest[s->i], in ecryptfs_write_tag_70_packet()
710 if (rc) { in ecryptfs_write_tag_70_packet()
713 __func__, rc); in ecryptfs_write_tag_70_packet()
729 rc = -EINVAL; in ecryptfs_write_tag_70_packet()
736 rc = -EOPNOTSUPP; in ecryptfs_write_tag_70_packet()
743 rc = PTR_ERR(s->hash_tfm); in ecryptfs_write_tag_70_packet()
746 __func__, rc); in ecryptfs_write_tag_70_packet()
753 rc = -ENOMEM; in ecryptfs_write_tag_70_packet()
759 rc = crypto_shash_digest(s->hash_desc, in ecryptfs_write_tag_70_packet()
763 if (rc) { in ecryptfs_write_tag_70_packet()
766 __func__, rc); in ecryptfs_write_tag_70_packet()
774 rc = crypto_shash_digest(s->hash_desc, (u8 *)s->hash, in ecryptfs_write_tag_70_packet()
777 if (rc) { in ecryptfs_write_tag_70_packet()
780 "rc = [%d]\n", __func__, rc); in ecryptfs_write_tag_70_packet()
791 rc = virt_to_scatterlist(s->block_aligned_filename, in ecryptfs_write_tag_70_packet()
793 if (rc < 1) { in ecryptfs_write_tag_70_packet()
796 "block_aligned_filename_size = [%zd]\n", __func__, rc, in ecryptfs_write_tag_70_packet()
800 rc = virt_to_scatterlist(&dest[s->i], s->block_aligned_filename_size, in ecryptfs_write_tag_70_packet()
802 if (rc < 1) { in ecryptfs_write_tag_70_packet()
806 __func__, rc, s->block_aligned_filename_size); in ecryptfs_write_tag_70_packet()
813 rc = crypto_skcipher_setkey( in ecryptfs_write_tag_70_packet()
817 if (rc < 0) { in ecryptfs_write_tag_70_packet()
822 rc, in ecryptfs_write_tag_70_packet()
829 rc = crypto_skcipher_encrypt(s->skcipher_req); in ecryptfs_write_tag_70_packet()
830 if (rc) { in ecryptfs_write_tag_70_packet()
832 "rc = [%d]\n", __func__, rc); in ecryptfs_write_tag_70_packet()
852 return rc; in ecryptfs_write_tag_70_packet()
898 int rc = 0; in ecryptfs_parse_tag_70_packet() local
911 rc = -EINVAL; in ecryptfs_parse_tag_70_packet()
926 rc = -EINVAL; in ecryptfs_parse_tag_70_packet()
929 rc = ecryptfs_parse_packet_length(&data[(*packet_size)], in ecryptfs_parse_tag_70_packet()
932 if (rc) { in ecryptfs_parse_tag_70_packet()
934 "rc = [%d]\n", __func__, rc); in ecryptfs_parse_tag_70_packet()
945 rc = -EINVAL; in ecryptfs_parse_tag_70_packet()
954 rc = ecryptfs_cipher_code_to_string(s->cipher_string, s->cipher_code); in ecryptfs_parse_tag_70_packet()
955 if (rc) { in ecryptfs_parse_tag_70_packet()
960 rc = ecryptfs_find_auth_tok_for_sig(&auth_tok_key, in ecryptfs_parse_tag_70_packet()
963 if (rc) { in ecryptfs_parse_tag_70_packet()
966 rc); in ecryptfs_parse_tag_70_packet()
969 rc = ecryptfs_get_tfm_and_mutex_for_cipher_name(&s->skcipher_tfm, in ecryptfs_parse_tag_70_packet()
972 if (unlikely(rc)) { in ecryptfs_parse_tag_70_packet()
975 s->cipher_string, rc); in ecryptfs_parse_tag_70_packet()
979 rc = virt_to_scatterlist(&data[(*packet_size)], in ecryptfs_parse_tag_70_packet()
981 if (rc < 1) { in ecryptfs_parse_tag_70_packet()
985 __func__, rc, s->block_aligned_filename_size); in ecryptfs_parse_tag_70_packet()
992 rc = -ENOMEM; in ecryptfs_parse_tag_70_packet()
995 rc = virt_to_scatterlist(s->decrypted_filename, in ecryptfs_parse_tag_70_packet()
997 if (rc < 1) { in ecryptfs_parse_tag_70_packet()
1001 __func__, rc, s->block_aligned_filename_size); in ecryptfs_parse_tag_70_packet()
1010 rc = -ENOMEM; in ecryptfs_parse_tag_70_packet()
1024 rc = -EOPNOTSUPP; in ecryptfs_parse_tag_70_packet()
1029 rc = crypto_skcipher_setkey( in ecryptfs_parse_tag_70_packet()
1033 if (rc < 0) { in ecryptfs_parse_tag_70_packet()
1038 rc, in ecryptfs_parse_tag_70_packet()
1045 rc = crypto_skcipher_decrypt(s->skcipher_req); in ecryptfs_parse_tag_70_packet()
1046 if (rc) { in ecryptfs_parse_tag_70_packet()
1048 "rc = [%d]\n", __func__, rc); in ecryptfs_parse_tag_70_packet()
1059 rc = -EINVAL; in ecryptfs_parse_tag_70_packet()
1067 rc = -EINVAL; in ecryptfs_parse_tag_70_packet()
1072 rc = -ENOMEM; in ecryptfs_parse_tag_70_packet()
1082 if (rc) { in ecryptfs_parse_tag_70_packet()
1093 return rc; in ecryptfs_parse_tag_70_packet()
1099 int rc = 0; in ecryptfs_get_auth_tok_sig() local
1112 rc = -EINVAL; in ecryptfs_get_auth_tok_sig()
1114 return rc; in ecryptfs_get_auth_tok_sig()
1134 int rc; in decrypt_pki_encrypted_session_key() local
1136 rc = ecryptfs_get_auth_tok_sig(&auth_tok_sig, auth_tok); in decrypt_pki_encrypted_session_key()
1137 if (rc) { in decrypt_pki_encrypted_session_key()
1142 rc = write_tag_64_packet(auth_tok_sig, &(auth_tok->session_key), in decrypt_pki_encrypted_session_key()
1144 if (rc) { in decrypt_pki_encrypted_session_key()
1148 rc = ecryptfs_send_message(payload, payload_len, &msg_ctx); in decrypt_pki_encrypted_session_key()
1149 if (rc) { in decrypt_pki_encrypted_session_key()
1151 "ecryptfsd: %d\n", rc); in decrypt_pki_encrypted_session_key()
1154 rc = ecryptfs_wait_for_response(msg_ctx, &msg); in decrypt_pki_encrypted_session_key()
1155 if (rc) { in decrypt_pki_encrypted_session_key()
1158 rc = -EIO; in decrypt_pki_encrypted_session_key()
1161 rc = parse_tag_65_packet(&(auth_tok->session_key), in decrypt_pki_encrypted_session_key()
1163 if (rc) { in decrypt_pki_encrypted_session_key()
1165 rc); in decrypt_pki_encrypted_session_key()
1172 rc = ecryptfs_cipher_code_to_string(crypt_stat->cipher, cipher_code); in decrypt_pki_encrypted_session_key()
1173 if (rc) { in decrypt_pki_encrypted_session_key()
1187 return rc; in decrypt_pki_encrypted_session_key()
1231 int rc = 0; in parse_tag_1_packet() local
1250 rc = -EINVAL; in parse_tag_1_packet()
1256 rc = -EINVAL; in parse_tag_1_packet()
1266 rc = -ENOMEM; in parse_tag_1_packet()
1270 rc = ecryptfs_parse_packet_length(&data[(*packet_size)], &body_size, in parse_tag_1_packet()
1272 if (rc) { in parse_tag_1_packet()
1274 "rc = [%d]\n", rc); in parse_tag_1_packet()
1279 rc = -EINVAL; in parse_tag_1_packet()
1285 rc = -EINVAL; in parse_tag_1_packet()
1291 rc = -EINVAL; in parse_tag_1_packet()
1306 rc = -EINVAL; in parse_tag_1_packet()
1331 if (rc) in parse_tag_1_packet()
1333 return rc; in parse_tag_1_packet()
1363 int rc = 0; in parse_tag_3_packet() local
1385 rc = -EINVAL; in parse_tag_3_packet()
1391 rc = -EINVAL; in parse_tag_3_packet()
1400 rc = -ENOMEM; in parse_tag_3_packet()
1404 rc = ecryptfs_parse_packet_length(&data[(*packet_size)], &body_size, in parse_tag_3_packet()
1406 if (rc) { in parse_tag_3_packet()
1408 rc); in parse_tag_3_packet()
1413 rc = -EINVAL; in parse_tag_3_packet()
1419 rc = -EINVAL; in parse_tag_3_packet()
1428 rc = -EINVAL; in parse_tag_3_packet()
1434 rc = -EINVAL; in parse_tag_3_packet()
1437 rc = ecryptfs_cipher_code_to_string(crypt_stat->cipher, in parse_tag_3_packet()
1439 if (rc) in parse_tag_3_packet()
1451 rc = ecryptfs_init_crypt_ctx(crypt_stat); in parse_tag_3_packet()
1452 if (rc) in parse_tag_3_packet()
1456 rc = -ENOSYS; in parse_tag_3_packet()
1488 rc = -ENOSYS; in parse_tag_3_packet()
1507 if (rc) in parse_tag_3_packet()
1509 return rc; in parse_tag_3_packet()
1535 int rc = 0; in parse_tag_11_packet() local
1555 rc = -EINVAL; in parse_tag_11_packet()
1560 rc = -EINVAL; in parse_tag_11_packet()
1563 rc = ecryptfs_parse_packet_length(&data[(*packet_size)], &body_size, in parse_tag_11_packet()
1565 if (rc) { in parse_tag_11_packet()
1571 rc = -EINVAL; in parse_tag_11_packet()
1578 rc = -EINVAL; in parse_tag_11_packet()
1584 rc = -EINVAL; in parse_tag_11_packet()
1589 rc = -EINVAL; in parse_tag_11_packet()
1594 rc = -EINVAL; in parse_tag_11_packet()
1601 if (rc) { in parse_tag_11_packet()
1605 return rc; in parse_tag_11_packet()
1612 int rc = 0; in ecryptfs_keyring_auth_tok_for_sig() local
1620 rc = process_request_key_err(PTR_ERR(*auth_tok_key)); in ecryptfs_keyring_auth_tok_for_sig()
1626 rc = ecryptfs_verify_auth_tok_from_key(*auth_tok_key, auth_tok); in ecryptfs_keyring_auth_tok_for_sig()
1627 if (rc) { in ecryptfs_keyring_auth_tok_for_sig()
1634 return rc; in ecryptfs_keyring_auth_tok_for_sig()
1653 int rc = 0; in decrypt_passphrase_encrypted_session_key() local
1663 rc = ecryptfs_get_tfm_and_mutex_for_cipher_name(&tfm, &tfm_mutex, in decrypt_passphrase_encrypted_session_key()
1665 if (unlikely(rc)) { in decrypt_passphrase_encrypted_session_key()
1668 crypt_stat->cipher, rc); in decrypt_passphrase_encrypted_session_key()
1671 rc = virt_to_scatterlist(auth_tok->session_key.encrypted_key, in decrypt_passphrase_encrypted_session_key()
1674 if (rc < 1 || rc > 2) { in decrypt_passphrase_encrypted_session_key()
1678 "auth_tok->session_key.encrypted_key_size = [%d]\n", rc, in decrypt_passphrase_encrypted_session_key()
1684 rc = virt_to_scatterlist(auth_tok->session_key.decrypted_key, in decrypt_passphrase_encrypted_session_key()
1687 if (rc < 1 || rc > 2) { in decrypt_passphrase_encrypted_session_key()
1690 "expected rc = 1; got rc = [%d]\n", rc); in decrypt_passphrase_encrypted_session_key()
1700 rc = -ENOMEM; in decrypt_passphrase_encrypted_session_key()
1706 rc = crypto_skcipher_setkey( in decrypt_passphrase_encrypted_session_key()
1709 if (unlikely(rc < 0)) { in decrypt_passphrase_encrypted_session_key()
1712 rc = -EINVAL; in decrypt_passphrase_encrypted_session_key()
1718 rc = crypto_skcipher_decrypt(req); in decrypt_passphrase_encrypted_session_key()
1720 if (unlikely(rc)) { in decrypt_passphrase_encrypted_session_key()
1721 printk(KERN_ERR "Error decrypting; rc = [%d]\n", rc); in decrypt_passphrase_encrypted_session_key()
1736 return rc; in decrypt_passphrase_encrypted_session_key()
1770 int rc = 0; in ecryptfs_parse_packet_set() local
1781 rc = parse_tag_3_packet(crypt_stat, in ecryptfs_parse_packet_set()
1785 if (rc) { in ecryptfs_parse_packet_set()
1788 rc = -EIO; in ecryptfs_parse_packet_set()
1792 rc = parse_tag_11_packet((unsigned char *)&src[i], in ecryptfs_parse_packet_set()
1798 if (rc) { in ecryptfs_parse_packet_set()
1805 rc = -EIO; in ecryptfs_parse_packet_set()
1815 rc = -EIO; in ecryptfs_parse_packet_set()
1825 rc = parse_tag_1_packet(crypt_stat, in ecryptfs_parse_packet_set()
1829 if (rc) { in ecryptfs_parse_packet_set()
1832 rc = -EIO; in ecryptfs_parse_packet_set()
1841 rc = -EIO; in ecryptfs_parse_packet_set()
1854 rc = -EINVAL; in ecryptfs_parse_packet_set()
1872 rc = ecryptfs_get_auth_tok_sig(&candidate_auth_tok_sig, in ecryptfs_parse_packet_set()
1874 if (rc) { in ecryptfs_parse_packet_set()
1878 rc = -EINVAL; in ecryptfs_parse_packet_set()
1881 rc = ecryptfs_find_auth_tok_for_sig(&auth_tok_key, in ecryptfs_parse_packet_set()
1885 if (!rc) { in ecryptfs_parse_packet_set()
1893 rc = -EIO; in ecryptfs_parse_packet_set()
1903 rc = decrypt_pki_encrypted_session_key(candidate_auth_tok, in ecryptfs_parse_packet_set()
1911 rc = decrypt_passphrase_encrypted_session_key( in ecryptfs_parse_packet_set()
1916 rc = -EINVAL; in ecryptfs_parse_packet_set()
1918 if (rc) { in ecryptfs_parse_packet_set()
1926 candidate_auth_tok_sig, rc); in ecryptfs_parse_packet_set()
1941 rc = ecryptfs_compute_root_iv(crypt_stat); in ecryptfs_parse_packet_set()
1942 if (rc) { in ecryptfs_parse_packet_set()
1947 rc = ecryptfs_init_crypt_ctx(crypt_stat); in ecryptfs_parse_packet_set()
1948 if (rc) { in ecryptfs_parse_packet_set()
1951 crypt_stat->cipher, rc); in ecryptfs_parse_packet_set()
1956 return rc; in ecryptfs_parse_packet_set()
1969 int rc; in pki_encrypt_session_key() local
1971 rc = write_tag_66_packet(auth_tok->token.private_key.signature, in pki_encrypt_session_key()
1978 if (rc) { in pki_encrypt_session_key()
1982 rc = ecryptfs_send_message(payload, payload_len, &msg_ctx); in pki_encrypt_session_key()
1983 if (rc) { in pki_encrypt_session_key()
1985 "ecryptfsd: %d\n", rc); in pki_encrypt_session_key()
1988 rc = ecryptfs_wait_for_response(msg_ctx, &msg); in pki_encrypt_session_key()
1989 if (rc) { in pki_encrypt_session_key()
1992 rc = -EIO; in pki_encrypt_session_key()
1995 rc = parse_tag_67_packet(key_rec, msg); in pki_encrypt_session_key()
1996 if (rc) in pki_encrypt_session_key()
2001 return rc; in pki_encrypt_session_key()
2027 int rc = 0; in write_tag_1_packet() local
2047 rc = pki_encrypt_session_key(auth_tok_key, auth_tok, crypt_stat, in write_tag_1_packet()
2049 if (rc) { in write_tag_1_packet()
2051 "module; rc = [%d]\n", rc); in write_tag_1_packet()
2071 rc = -EINVAL; in write_tag_1_packet()
2075 rc = ecryptfs_write_packet_length(&dest[(*packet_size)], in write_tag_1_packet()
2078 if (rc) { in write_tag_1_packet()
2092 if (rc) in write_tag_1_packet()
2096 return rc; in write_tag_1_packet()
2115 int rc = 0; in write_tag_11_packet() local
2131 rc = -EINVAL; in write_tag_11_packet()
2135 rc = ecryptfs_write_packet_length(&dest[(*packet_length)], in write_tag_11_packet()
2138 if (rc) { in write_tag_11_packet()
2140 "generate packet length. rc = [%d]\n", rc); in write_tag_11_packet()
2153 if (rc) in write_tag_11_packet()
2157 return rc; in write_tag_11_packet()
2191 int rc = 0; in write_tag_3_packet() local
2196 rc = ecryptfs_get_tfm_and_mutex_for_cipher_name(&tfm, &tfm_mutex, in write_tag_3_packet()
2198 if (unlikely(rc)) { in write_tag_3_packet()
2201 crypt_stat->cipher, rc); in write_tag_3_packet()
2257 rc = virt_to_scatterlist(crypt_stat->key, key_rec->enc_key_size, in write_tag_3_packet()
2259 if (rc < 1 || rc > 2) { in write_tag_3_packet()
2263 rc, key_rec->enc_key_size); in write_tag_3_packet()
2264 rc = -ENOMEM; in write_tag_3_packet()
2267 rc = virt_to_scatterlist(key_rec->enc_key, key_rec->enc_key_size, in write_tag_3_packet()
2269 if (rc < 1 || rc > 2) { in write_tag_3_packet()
2273 "key_rec->enc_key_size = [%zd]\n", rc, in write_tag_3_packet()
2275 rc = -ENOMEM; in write_tag_3_packet()
2279 rc = crypto_skcipher_setkey(tfm, session_key_encryption_key, in write_tag_3_packet()
2281 if (rc < 0) { in write_tag_3_packet()
2284 "context; rc = [%d]\n", rc); in write_tag_3_packet()
2294 rc = -ENOMEM; in write_tag_3_packet()
2301 rc = 0; in write_tag_3_packet()
2306 rc = crypto_skcipher_encrypt(req); in write_tag_3_packet()
2309 if (rc) { in write_tag_3_packet()
2310 printk(KERN_ERR "Error encrypting; rc = [%d]\n", rc); in write_tag_3_packet()
2336 rc = -EINVAL; in write_tag_3_packet()
2342 rc = ecryptfs_write_packet_length(&dest[(*packet_size)], in write_tag_3_packet()
2345 if (rc) { in write_tag_3_packet()
2347 "generate packet length. rc = [%d]\n", rc); in write_tag_3_packet()
2359 rc = -EINVAL; in write_tag_3_packet()
2373 if (rc) in write_tag_3_packet()
2377 return rc; in write_tag_3_packet()
2411 int rc = 0; in ecryptfs_generate_key_packet_set() local
2417 rc = -ENOMEM; in ecryptfs_generate_key_packet_set()
2423 rc = ecryptfs_find_global_auth_tok_for_sig(&auth_tok_key, in ecryptfs_generate_key_packet_set()
2427 if (rc) { in ecryptfs_generate_key_packet_set()
2430 rc = process_find_global_auth_tok_for_sig_err(rc); in ecryptfs_generate_key_packet_set()
2434 rc = write_tag_3_packet((dest_base + (*len)), in ecryptfs_generate_key_packet_set()
2440 if (rc) { in ecryptfs_generate_key_packet_set()
2447 rc = write_tag_11_packet((dest_base + (*len)), &max, in ecryptfs_generate_key_packet_set()
2450 if (rc) { in ecryptfs_generate_key_packet_set()
2457 rc = write_tag_1_packet(dest_base + (*len), &max, in ecryptfs_generate_key_packet_set()
2460 if (rc) { in ecryptfs_generate_key_packet_set()
2471 rc = -EINVAL; in ecryptfs_generate_key_packet_set()
2479 rc = -EIO; in ecryptfs_generate_key_packet_set()
2484 if (rc) in ecryptfs_generate_key_packet_set()
2487 return rc; in ecryptfs_generate_key_packet_set()