Skip to main content

Module identifiers

Module identifiers 

Source
Expand description

Squib-wide validated identifier newtypes.

Per 70-security.md § 4: every external string crossing into squib goes through a fallible-constructor newtype before reaching downstream code. Validation runs once in new/try_from; every downstream use is provably safe by construction.

Placing the canonical newtypes at squib-core (the bottom of the dependency DAG — see I-CRATE-1) means any crate can witness the validation in the type system without cross-crate detours via squib-api. The API layer’s Raw* → Validated TryFrom boundary still drives the validation; this module hosts the result types.

Structs§

HostDevName
Validated host-side network device name (the host_dev_name field on a /network-interfaces/{id} PUT body).

Enums§

IdentifierError
Errors that can surface while validating an identifier.

Constants§

HOST_DEV_NAME_MAX_BYTES
Maximum byte length for a host_dev_name. Mirrors the API-layer cap that’s been in force since Phase 2 (see crates/api/src/schemas/network.rs).