Skip to main content

Crate discord_desktop_core

Crate discord_desktop_core 

Source
Expand description

Discord desktop (Electron/Chromium) artifact reader.

Discord is an Electron app: its account/session state lives in Chromium Local Storage (a per-profile LevelDB at Local Storage/leveldb/), not in a chat database — Discord keeps no local message DB (messages are fetched from the server and only cached). This crate sits on top of the Wave-2 chromium_storage_localstorage reader and interprets the Discord-specific records inside it:

  • the auth token record — a session credential, surfaced as a token::TokenRecord whose value is a token::SensitiveToken that redacts by default (presence + length + location, never the secret in Debug/Display/serde output);
  • account identity — the MultiAccountStore / user_id_cache / email_cache records, parsed into account::Account;
  • recent channels / guilds — the SelectedGuildStore / RecentVoiceChannelStore records, parsed into channel::RecentChannel.

The Discord store paths and the Chromium Local Storage key/encoding constants come from the fleet KNOWLEDGE leaf forensicnomicon_core::messenger_desktop / forensicnomicon_core::chromium_local_storage — this crate re-uses them and never re-hardcodes a path or a marker byte.

§Sources

Re-exports§

pub use account::Account;
pub use channel::RecentChannel;
pub use error::Error;
pub use token::TokenRecord;

Modules§

account
Discord account identity from Local Storage.
channel
Discord recent channels / guilds from Local Storage.
error
Error type for the Discord desktop reader.
timeline
Timeline reconstruction from decoded Discord artifacts.
token
The Discord auth token Local Storage record — a session credential.

Structs§

DiscordArtifacts
Everything the reader recovered from a Discord Local Storage store.
OriginMeta
A per-origin Local Storage metadata record (META:) — the store’s declared size and its last-modified time.

Functions§

decode_local_storage
Interpret already-decoded Local Storage records into typed Discord artifacts.
extract_origin_meta
Extract per-origin META: metadata for Discord origins.
is_discord_origin
Does this Local Storage origin belong to Discord?
read_profile
Read and interpret a Discord desktop profile directory (the Electron userData dir, e.g. ~/Library/Application Support/discord).