# 5.12 lcs.audit.value.deleted

_Peios / Using Peios / Events / Registry Events_

> The record that a registry value was deleted through a key handle, or that an attempt to delete one failed.

- **Event type:** `lcs.audit.value.deleted`
- **Defined in:** `lcs.evman`
- **Tier:** essential
- **Gating:** KEY_SET_VALUE overlaps the alarm mask cached on the key handle
- **Cardinality:** once per delete through a handle whose mask covers it

The record that a registry value was deleted through a key handle, or that
an attempt to delete one failed. Gated, staged and fixed at open exactly as
`lcs.audit.value.set` is.

What was removed is recorded by type, length and SHA-256 digest: the
effective value before the delete, read in the transaction's own view when
the delete is transacted.

## 5.12.1 Fields

| Field | Type | Presence | Meaning |
|---|---|---|---|
| [`subject.token.sid`](/peios/using-peios/events/field-index/fields-subject.md#subject.token.sid) | `bin.sid` | via [`caller`](/peios/using-peios/events/groups/group-caller.md) | The user SID of the effective token the operation ran under. |
| [`subject.token.integrity`](/peios/using-peios/events/field-index/fields-subject.md#subject.token.integrity) | `uint.integrity` | via [`caller`](/peios/using-peios/events/groups/group-caller.md) | The integrity RID of the effective token. |
| [`subject.token.id`](/peios/using-peios/events/field-index/fields-subject.md#subject.token.id) | `uint.luid` | via [`caller`](/peios/using-peios/events/groups/group-caller.md) | The token's own LUID, identifying this specific token rather than the logon session it belongs to. |
| [`subject.token.auth-id`](/peios/using-peios/events/field-index/fields-subject.md#subject.token.auth-id) | `uint.luid` | via [`caller`](/peios/using-peios/events/groups/group-caller.md) | The LUID of the logon session the effective token belongs to. |
| [`subject.token.type`](/peios/using-peios/events/field-index/fields-subject.md#subject.token.type) | `str.enum` | via [`caller`](/peios/using-peios/events/groups/group-caller.md) | Whether the effective token is a primary token or an impersonation token. |
| [`subject.token.impersonation`](/peios/using-peios/events/field-index/fields-subject.md#subject.token.impersonation) | `uint.enum` | via [`caller`](/peios/using-peios/events/groups/group-caller.md) | The impersonation level of the effective token. |
| [`object.kind`](/peios/using-peios/events/field-index/fields-object.md#object.kind) | `str.enum` | required | Always `key`. |
| [`object.key.guid`](/peios/using-peios/events/field-index/fields-object.md#object.key.guid) | `bin.guid` | required | The registry key an operation acted on. |
| [`object.key.path`](/peios/using-peios/events/field-index/fields-object.md#object.key.path) | `str` | required | The resolved absolute path of the registry key, in canonical form, such as `Machine\System\KMES`. |
| [`object.key.layer.name`](/peios/using-peios/events/field-index/fields-object.md#object.key.layer.name) | `str` | optional | The layer whose entry was deleted. Absent only when the request failed before its layer was read. |
| [`object.key.value.name`](/peios/using-peios/events/field-index/fields-object.md#object.key.value.name) | `str` | optional | Absent only when the request failed before its name was read. |
| [`object.key.value.type-previous`](/peios/using-peios/events/field-index/fields-object.md#object.key.value.type-previous) | `uint.enum` | optional | Absent when no value was found to delete. |
| [`object.key.value.length-previous`](/peios/using-peios/events/field-index/fields-object.md#object.key.value.length-previous) | `uint.bytes` | optional | Present with `object.key.value.type-previous`. |
| [`object.key.value.digest-previous`](/peios/using-peios/events/field-index/fields-object.md#object.key.value.digest-previous) | `bin` | optional | Present with `object.key.value.type-previous`. |
| [`access.requested`](/peios/using-peios/events/field-index/fields-access.md#access.requested) | `uint.mask` | required | Always `KEY_SET_VALUE`. |
| [`access.granted`](/peios/using-peios/events/field-index/fields-access.md#access.granted) | `uint.mask` | required | The access mask in force. |
| [`access.matched`](/peios/using-peios/events/field-index/fields-access.md#access.matched) | `uint.mask` | required | The subset of the requested access that overlapped an audit mask and therefore caused the record to exist. |
| [`access.audit-mask`](/peios/using-peios/events/field-index/fields-access.md#access.audit-mask) | `uint.mask` | required | The full continuous-audit mask cached on a handle, of which `access.matched` is the part this operation touched. |
| [`transaction.id`](/peios/using-peios/events/field-index/fields-transaction.md#transaction.id) | `uint` | optional | The transaction the operation belonged to, registry or package. |
| [`request.timed-out`](/peios/using-peios/events/field-index/fields-request.md#request.timed-out) | `bool` | when `outcome.success == false` | Whether a request's wait for the source's reply ran out before the reply arrived. |
| [`outcome.success`](/peios/using-peios/events/field-index/fields-outcome.md#outcome.success) | `bool` | required | Whether the operation succeeded. |
| [`outcome.errno`](/peios/using-peios/events/field-index/fields-outcome.md#outcome.errno) | `int.errno` | when `outcome.success == false` | The error the operation failed with, as a negative errno. |

Every record also carries the header fields of [the envelope](/peios/using-peios/events/introduction/the-envelope.md), which no payload repeats.

*Generated from `lcs.evman` by `pkm/tools/gen-events-book.py`. Edit the fragment, not this page.*
