#[non_exhaustive]pub enum AnomalyKind {
NonZeroReservedSpace {
reserved: u8,
},
DeletedRecordRecovered {
page: u32,
offset: usize,
rowid: i64,
},
NonEmptyFreelist {
free_pages: u32,
},
WalUncheckpointedState {
overlaid_pages: u32,
},
PageCountMismatch {
header_pages: u32,
file_pages: u32,
},
}Expand description
The classified SQLite forensic anomalies this auditor can grade.
#[non_exhaustive] so WS-E can add carving / WAL / freelist variants without
a breaking change; downstream match arms must carry a _ arm.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
NonZeroReservedSpace
The header’s reserved-space-per-page field is non-zero. Standard
SQLite leaves this at 0; a non-zero value is used by page-level
extensions (e.g. encryption such as SQLCipher/SEE, or checksum VFS) and
is worth flagging on an evidence database.
DeletedRecordRecovered
A record-shaped cell was recovered from unallocated / free space — consistent with a deleted row that has not yet been overwritten.
Fields
NonEmptyFreelist
The freelist is non-empty: the database holds free (unallocated) pages.
Consistent with prior deletions (DELETE without VACUUM); those pages
may retain recoverable deleted records.
WalUncheckpointedState
A -wal sidecar carried committed-but-unflushed page versions that the
main database file does not yet reflect. Consistent with an evidence
database captured while a write transaction was checkpoint-pending; the
main file alone would under-report the true state.
PageCountMismatch
The in-header page count disagrees with the page count implied by the file length. Consistent with truncation, carving, or out-of-band modification of the database file.
Implementations§
Trait Implementations§
Source§impl Clone for AnomalyKind
impl Clone for AnomalyKind
Source§fn clone(&self) -> AnomalyKind
fn clone(&self) -> AnomalyKind
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for AnomalyKind
impl Debug for AnomalyKind
impl Eq for AnomalyKind
Source§impl PartialEq for AnomalyKind
impl PartialEq for AnomalyKind
Source§fn eq(&self, other: &AnomalyKind) -> bool
fn eq(&self, other: &AnomalyKind) -> bool
self and other values to be equal, and is used by ==.