Lines Matching refs:crypt_device
301 struct crypt_device *cd, in luks_try_passwords()
354 struct crypt_device **ret, in luks_setup()
361 _cleanup_(sym_crypt_freep) struct crypt_device *cd = NULL; in luks_setup()
482 _cleanup_(sym_crypt_freep) struct crypt_device *cd = NULL; in acquire_open_luks_device()
487 assert(!setup->crypt_device); in acquire_open_luks_device()
505 setup->crypt_device = TAKE_PTR(cd); in acquire_open_luks_device()
525 assert(!setup->crypt_device); in luks_open()
534 r = sym_crypt_load(setup->crypt_device, CRYPT_LUKS2, NULL); in luks_open()
538 r = sym_crypt_get_volume_key_size(setup->crypt_device); in luks_open()
546 s = sym_crypt_get_uuid(setup->crypt_device); in luks_open()
565 r = luks_try_passwords(h, setup->crypt_device, list, vk, &vks, NULL); in luks_open()
578 …r = sym_crypt_activate_by_volume_key(setup->crypt_device, NULL, vk, vks, CRYPT_ACTIVATE_KEYRING_KE… in luks_open()
751 static int crypt_device_to_evp_cipher(struct crypt_device *cd, const EVP_CIPHER **ret) { in crypt_device_to_evp_cipher()
801 struct crypt_device *cd, in luks_validate_home_record()
922 struct crypt_device *cd, in format_luks_token_text()
1012 if (!setup->crypt_device) in home_store_header_identity_luks()
1034 r = format_luks_token_text(setup->crypt_device, header_home, setup->volume_key, &text); in home_store_header_identity_luks()
1042 state = sym_crypt_token_status(setup->crypt_device, token, &type); in home_store_header_identity_luks()
1053 r = sym_crypt_token_json_set(setup->crypt_device, token, text); in home_store_header_identity_luks()
1264 if (!setup->crypt_device) { in home_setup_luks()
1276 … r = luks_validate_home_record(setup->crypt_device, h, volume_key, cache, &luks_home); in home_setup_luks()
1281 n = sym_crypt_get_device_name(setup->crypt_device); in home_setup_luks()
1356 assert(!setup->crypt_device); in home_setup_luks()
1400 &setup->crypt_device, in home_setup_luks()
1411 … r = luks_validate_home_record(setup->crypt_device, h, volume_key, cache, &luks_home); in home_setup_luks()
1618 if (!setup->crypt_device) { in home_deactivate_luks()
1628 if (setup->crypt_device) { in home_deactivate_luks()
1631 cryptsetup_enable_logging(setup->crypt_device); in home_deactivate_luks()
1633 r = sym_crypt_deactivate_by_name(setup->crypt_device, setup->dm_name, 0); in home_deactivate_luks()
1711 struct crypt_device **ret) { in luks_format()
1714 _cleanup_(sym_crypt_freep) struct crypt_device *cd = NULL; in luks_format()
2326 &setup->crypt_device); in home_create_luks()
2395 sym_crypt_get_cipher(setup->crypt_device), in home_create_luks()
2396 sym_crypt_get_cipher_mode(setup->crypt_device), in home_create_luks()
2397 luks_volume_key_size_convert(setup->crypt_device), in home_create_luks()
3244 crypto_offset = sym_crypt_get_data_offset(setup->crypt_device); in home_resize_luks()
3384 r = sym_crypt_resize(setup->crypt_device, setup->dm_name, new_fs_size / 512U); in home_resize_luks()
3444 r = sym_crypt_resize(setup->crypt_device, setup->dm_name, new_fs_size / 512); in home_resize_luks()
3542 type = sym_crypt_get_type(setup->crypt_device); in home_passwd_luks()
3551 r = sym_crypt_get_volume_key_size(setup->crypt_device); in home_passwd_luks()
3567 … r = luks_try_passwords(h, setup->crypt_device, list, volume_key, &volume_key_size, NULL); in home_passwd_luks()
3582 r = sym_crypt_keyslot_destroy(setup->crypt_device, i); in home_passwd_luks()
3594 r = sym_crypt_set_pbkdf_type(setup->crypt_device, &minimal_pbkdf); in home_passwd_luks()
3597 r = sym_crypt_set_pbkdf_type(setup->crypt_device, &good_pbkdf); in home_passwd_luks()
3603 setup->crypt_device, in home_passwd_luks()
3630 assert(!setup->crypt_device); in home_lock_luks()
3647 r = sym_crypt_suspend(setup->crypt_device, setup->dm_name); in home_lock_luks()
3656 struct crypt_device *cd, in luks_try_resume()
3689 assert(!setup->crypt_device); in home_unlock_luks()
3702 r = luks_try_resume(setup->crypt_device, setup->dm_name, list); in home_unlock_luks()