Archive documentation for v0.2.1. Read the current release guide.
Read raw source ↗Security and reliability
Scope and trust boundaries
The native application can access files and OS integration that a renderer should not control directly. Gallery media, filenames and external sidecars are input data. Settings, installed state, derived caches and release packages each have a separate owner and integrity contract. These boundaries concern access and data integrity; they do not create content-eligibility rules for the gallery's general-purpose browsing capability.
SR-01: Native operations MUST validate their actual resource and session context. A string from the renderer, sidecar or filename must not grant unrestricted filesystem or process access. Root access must follow the selected traversal policy and the OS permissions available to the user. Tauri capabilities and handlers must be configured for the needed product operations, rather than enabling unrelated capabilities by convenience.
Filesystem and rendering boundaries
Relative paths must be resolved against the intended root using native path handling. SR-02: Access MUST account for path traversal, aliases and symlinks according to the declared policy. A metadata path or cached resource reference must not silently expand access to another collection. Validation must cover the actual opened resource as well as its display spelling where race conditions matter.
The renderer must treat external strings as text/data. Metadata resembling HTML or script must not become active markup. Media handling must not expose a general executable document viewer simply because an unknown extension was encountered. Format-specific display follows the playback contract.
Ordinary browsing uses bundled application assets and selected media resources. Any introduced network listener, external navigation, update request or download needs a documented purpose and access boundary. This specification does not require publishing a gallery to a network or adding an account service.
Write ownership and originals
SR-03: Discovery, rendering and metadata inspection MUST NOT rewrite originals or external sidecars. Preparation and settings operations may write their explicitly selected application-owned outputs. An installation or cache cleanup must not classify a whole user media directory as disposable application data.
Any future editing operation must define its target, conflict handling and recovery/undo behavior before it is enabled. This preserves the current limited-editing scope while allowing later approved features. Permission errors must be reported as access failures, not used to infer that a user's media is ineligible.
Staged output and atomic/recoverable replacement should keep valid prior state available until a replacement is complete. Concurrent writers require coordination. Private settings/history use the locked recovery policy in configuration and state. An interrupted save must not deliberately truncate an otherwise valid settings file.
Dependencies and executable artifacts
SR-04: Downloaded executable artifacts and governed brand imports MUST have an identified source, version and integrity verification before activation. Installation must preserve the artifact/architecture identity from verification through use. A checksum establishes agreement with an identified source record; it is not, by itself, a general security assessment of the software.
Optional platform launchers and media tools are executable dependencies. Their versions and associated files must be recorded and preserved through packaging. The Full/Lite size and prerequisite descriptions must account for them. Brand provenance and immutable delivered bytes are governed by brand integration.
SR-05: Project-owned Windows console child processes MUST use CREATE_NO_WINDOW or an equivalent hidden-process guarantee, redirected noninteractive I/O and disabled prompts. Terminal commands deliberately invoked by a user must retain their documented terminal behavior. Hiding a helper window must not hide failure results from the invoking operation.
Failure containment and recovery
SR-06: A failed media read, sidecar parse or thumbnail task SHOULD leave unaffected items usable. Failures must preserve their scope: root unavailable, item missing, unsupported media, invalid settings, incomplete preparation and internal error are different outcomes. Timeouts must not falsely certify that a subprocess or write stopped.
Recoverable operations need a defined result after process termination. Examples include leaving a valid previous settings file, identifying abandoned staging files, rediscovering a collection after cache loss and preserving completed thumbnails after cancellation. Recovery should not automatically repeat a write with unknown prior outcome as though it were idempotent.
A disconnected external location must remain distinguishable from deletion. Incomplete discovery retains unconfirmed observations as stale; it cannot infer deletion. Root identity checks compare held and currently named native directory identities, while actual media reads remain capability-relative and verify the opened file signature. Descendant hidden/system/reparse filtering uses capability-relative metadata. Cancellation and newer requests are rechecked before committing observations or revoking item grants. Invalid private convenience state automatically resets to usable defaults under the documented writer lock. Portable gallery documents, originals and external sidecars remain outside that reset policy. Actual access and contention failures leave browsing usable where possible and identify the affected file/action.
Diagnostics
SR-07: Diagnostics MUST identify the failing operation and useful context while avoiding unnecessary disclosure of private paths, sidecar payloads or credentials in ordinary output. A user-requested diagnostic export must describe what it includes. Logs must distinguish application version, edition and relevant runtime facts from speculation about a cause.
Diagnostics retain at most 256 records and 262144 exact serialized-record bytes in memory until process exit. Oldest records are evicted with an exact decimal dropped count. No ordinary disk log is written. Context contains product/release, edition, OS/architecture, compiled target and nullable observed runtime. Records contain sequence/time, opaque operation/session/item/job identities, operation/boundary/status, stable category/code, internally defined message/recovery and nullable exact counts. Missing facts are null; counts do not pass through floating-point conversion.
Categories distinguish roots/items, unsupported media, invalid/future/unavailable state, conflicts, complete/partial/cancelled preparation, helper availability/failure/timeout, cache validation and internal failures. Media errors are observed before HTTP mapping. Renderer observations accept only defined decode/playback categories for current granted items and are coalesced. Paths, credentials, raw errors/stderr, recents, settings values, media and sidecar payloads never enter ordinary reports.
The gallery's Diagnostics control explicitly inspects the current process and describes export contents. Export uses a native save dialog and a new user-selected UTF-8/LF JSON file; existing output is preserved and a write failure may leave an incomplete user-selected file. The diagnostics command describes its own invocation only. Requested --diagnostics attaches a report inside the preparation operation result. No report is submitted automatically and no telemetry service is introduced. Reporting a vulnerability follows the project's security policy.
Cancelled/interrupted preparation preserves completed valid cache entries. Abandoned validated staging is eligible for explicit owned cleanup; incomplete/future/unrecognized records remain untouched. Use originals after cache loss or corruption. Invalid or obsolete private preferences/history automatically reset under their writer locks, without a routine persistent warning. Actual access or contention failures name the affected file and action. Portable gallery settings and external media/sidecars retain their byte-preserving policy. See private-state recovery.
Open decisions
U-11 diagnostic/export/retention and recovery behavior is defined above. The initial traversal/storage policy is defined in gallery lifecycle; the configuration contract owns private reset and concurrency; U-08 owns handler/transport specifics. These choices must preserve bounded access, attributable failures and source preservation without adding unrelated product-use restrictions.
Return to the index or consult the glossary.
Sidecar read boundary
The native inspector reads only directly observed JSON through held directory authority. Single-child references can associate with current observations but never grant access to another path. File/link/root replacement and retired epochs reject the read; pre/post file identity checks do not claim a filesystem-wide atomic snapshot against arbitrary concurrent editors. Parser and source/result budgets constrain work, invalid data stays attributable, and raw source is inert text. Summary choices contain relative roles and field addresses rather than paths or grants. See metadata policy.
Optional recipient acquisition
Selecting recipient launchers and requesting a preparation preview authorizes native HTTPS reads of the official repository canonical published release and its named Lite assets. Ordinary opening and Refresh do not perform those requests. Redirects remain within GitHub release delivery hosts. Native TLS uses the host certificate trust facilities. Downloads have connection/overall bounds and cancellation interrupts pending send/body reads. Identity verification covers the canonical published native record, gates, publication asset bindings, archive size/digest and complete extracted inventory before gallery writes. Temporary staging contains only admitted regular files/directories and is removed when its preview is replaced, canceled or retired. Complete committed files remain for validated reuse.
Gallery-root writes use capability-relative no-follow parent handles, create-new file admission and revalidated session/root identity. Existing unrelated, redirected, hardlinked or modified outputs are preserved. Original media and arbitrary sidecars remain independent of recipient artifacts. Completed package outputs retain original archives and notices for recipient extraction and inspection.