Defined in 2 files as a function:
- drivers/virt/coco/sev-guest/sev-guest.c, line 116 (as a function)
- security/keys/encrypted-keys/encrypted.c, line 331 (as a function)
Referenced in 2 files:
Smatch caller information:
drivers/virt/coco/sev-guest/sev-guest.c snp_guest_ioctl() -> get_derived_key()
| Type | Parameter | Key | Value |
|---|---|---|---|
| PARAM_VALUE | 0 | snp_dev | 4096-ptr_max |
| PARAM_VALUE | 1 | arg | 3634276090450407424 |
| PARAM_VALUE | 1 | arg->exitinfo2 | 255 |
| PARAM_VALUE | 1 | arg->msg_version | 1-255 |
| DATA_SOURCE | 0 | snp_dev | r to_snp_dev |
| USER_DATA | 1 | arg->fw_error | 0-u32max |
| USER_DATA | 1 | arg->msg_version | 1-255 |
| USER_DATA | 1 | arg->req_data | 0-u64max |
| USER_DATA | 1 | arg->resp_data | 0-u64max |
| USER_DATA | 1 | arg->vmm_error | 0-u32max |
security/keys/encrypted-keys/encrypted.c datablob_hmac_append() -> get_derived_key()
| Type | Parameter | Key | Value |
|---|---|---|---|
| PARAM_VALUE | 0 | snp_dev | 6093768750801133568 |
| PARAM_VALUE | 1 | arg | 1 |
| PARAM_VALUE | 3 | master_keylen | 0-u32max |
| BUF_SIZE | 0 | snp_dev | 32 |
| DATA_SOURCE | 2 | master_key | $1 |
| DATA_SOURCE | 3 | master_keylen | $2 |
| LOCK2 | &key->sem | ||
| TYPE_LOCK | (struct key)->sem |
security/keys/encrypted-keys/encrypted.c datablob_hmac_verify() -> get_derived_key()
| Type | Parameter | Key | Value |
|---|---|---|---|
| PARAM_VALUE | 0 | snp_dev | 4955411994388361216 |
| PARAM_VALUE | 1 | arg | 1 |
| PARAM_VALUE | 3 | master_keylen | 0-u32max |
| BUF_SIZE | 0 | snp_dev | 32 |
| DATA_SOURCE | 2 | master_key | $2 |
| DATA_SOURCE | 3 | master_keylen | $3 |
| RX_PATH | |||
| TASK_NOT_RUNNING | |||
| LOCK2 | global &key_construction_mutex | ||
| HALF_LOCKED2 | &keyring->sem | ||
| HALF_LOCKED2 | global &key_types_sem |
security/keys/encrypted-keys/encrypted.c encrypted_key_decrypt() -> get_derived_key()
| Type | Parameter | Key | Value |
|---|---|---|---|
| PARAM_VALUE | 0 | snp_dev | 3116628199414124544 |
| PARAM_VALUE | 1 | arg | 0 |
| PARAM_VALUE | 2 | *master_key | 0-255 |
| PARAM_VALUE | 3 | master_keylen | 0-u32max |
| BUF_SIZE | 0 | snp_dev | 32 |
| RX_PATH | |||
| TASK_NOT_RUNNING | |||
| LOCK2 | global &key_construction_mutex | ||
| HALF_LOCKED2 | &keyring->sem | ||
| HALF_LOCKED2 | global &key_types_sem |
security/keys/encrypted-keys/encrypted.c encrypted_read() -> get_derived_key()
| Type | Parameter | Key | Value |
|---|---|---|---|
| PARAM_VALUE | 0 | snp_dev | 1903459002154860544 |
| PARAM_VALUE | 1 | arg | 0 |
| PARAM_VALUE | 2 | *master_key | 0-255 |
| PARAM_VALUE | 3 | master_keylen | 0-u32max |
| BUF_SIZE | 0 | snp_dev | 32 |
| LOCK2 | &key->sem | ||
| TYPE_LOCK | (struct key)->sem |