LNS web Draft · 27 November 2026

4. Names and records

A site lives under an LNS name. This section covers what a name is, how a client finds its record, which record fields make a site, and when a change shows up.

Describes the LNS registry on the LEZ 0.4 testnet line (rc3, moving to released LEZ 0.4.0 in a new deployment), as specified in the Logos Names specification (version 2, draft) and implemented in its core and seal crates, and as read by Names Browser 0.4.6 and the gateway.

4.1 LNS names

Normalising input. Before using typed or pasted input as a name, a client trims surrounding whitespace, lowers ASCII case, then removes one leading lns:// or lns:, one leading @, and one trailing .lez (an old suffix, still accepted when typed). Alice, @alice, lns:alice and lns://alice all become alice.

A client MUST normalise names exactly as above and refuse anything that is not then a valid name. Two clients that normalise differently would read different records for the same input.

Required by the Logos Names specification, section 2. Implemented in links.rs is_valid_lns_name and parse_url, and in logic.mjs normalizeName and isValidName, which the gateway imports.

Subnames (non-normative). Until the planned registry subnames exist (section 4.10), folders already work: publish under alice/blog (lns://alice/blog and https://alice.lnsweb.online/blog/) using normal lns-links/1 folders.

4.2 From name to record

The chain never sees a name. A client derives two values from it:

master = Argon2id(password = name, salt = "logos-names/v5",
                  version 0x13, memory 64 MiB, passes 3,
                  lanes 1, length 32 bytes)
id     = SHA-256("logos-names/v5/id"  ‖ master)
key    = SHA-256("logos-names/v5/key" ‖ master)

id is public: the chain knows the name by it. key never leaves the client: it opens what the name resolves to. Each name has two accounts in the registry program, found from id:

AccountAddress
RecordPDA(registry, SHA-256("logos-names/v5/name/" ‖ id))
PagePDA(registry, SHA-256("logos-names/v5/page/" ‖ id))

A client reads each with the sequencer's getAccountView call. The derivation needs 64 MiB of memory and about 70 to 140 ms in native code, so a client SHOULD derive once per name and keep the result (Logos Names specification, section 3). The gateway keeps an index of names it already knows and runs at most two derivations at once (section 8.9).

4.3 The record

The record account holds a version, an owner tag (not an account), an expiry time, a claimed flag, and sealed: the profile encrypted with AES-256-GCM under key. sealed is at most 12,288 bytes. The profile inside holds:

The plaintext is padded with zeros to a multiple of 256 bytes, so its length says little about what it holds. In deposit mode (section 4.9), expires is u64::MAX and the name never lapses; in fee mode, expires is a Unix timestamp in milliseconds with a 30-day grace period.

A client MUST treat a name as having nothing set if sealed does not open with the name's key, or opens to a profile whose name is not the name asked for.

A client MUST treat a fee-mode name as unregistered once 30 days have passed after its expiry.

Logos Names specification, sections 5 and 6. The gateway does both in derive.mjs (resolveNameWithDerived, readRecord). The Names Browser reads records through Basecamp's Names module.

A client MUST bind a record to the name the user asked for, never to a name supplied in the RPC's answer.

Enforced in logic.mjs extractSiteInfo (a round-3 fix): the site, its avatar and its "older version" are filed under the requested name.

4.4 Site fields

A site is set through ordinary text entries. These are the ones LNS web reads:

KeyValueRead by
cidCID of the site's root: 8 to 128 ASCII letters and digits. A leading cid=, cid: or cid:// is removed.browser, gateway, publisher
cid.sha256SHA-256 of the root's bytes: 64 hex digits, compared in lower case.browser, gateway, publisher
cid.typelinks for an lns-links/1 root, which is what lns publish writes. Older values: single, manifest (section 5.9).browser, gateway
avatarA small image as a data: URL (section 4.6).browser, publisher
displayDisplay name, shown in the browser. BiDi and control characters are removed; at most 200 characters.browser
bioShort text, shown in the browser. Cleaned the same way; at most 500 characters.browser
gatewayoff stops the HTTPS gateway serving the site.gateway
gateway.indexon lets search engines index the gateway copy.gateway

Set cid.type=links on every lns-links/1 site: in the Names Browser's Basecamp Storage path, a root without cid.type=links starts under the 512 KiB single-page fetch cap instead of the 2 MiB list cap (section 6.9).

Other LNS text records. The Logos Names specification defines other standard text entries (such as forward, color, theme, font, chat, inbox, agent, logos.account, blockchain and app.<module>). LNS web reads only the eight keys in the table above. In particular, neither the Names Browser nor the gateway follows forward when loading a website.

A publisher MUST set cid.sha256 whenever it sets cid.

A client MUST NOT show or serve a Storage site whose record has a cid but no valid cid.sha256.

The Names Browser stops with "Unverified file skipped — LNS record for … has no pinned cid.sha256 hash" (Main.qml loadNativeStaticNavigation). The gateway answers 502 "Unverified site root" (serve.mjs loadSiteRoot). lns publish always sets both in one transaction (publish.mjs buildNamesProfileCommand).

4.5 Storage site or on-chain page

A name can carry a site in two places.

Storage site
The record's cid names the root (usually an lns-links/1 root list) in Logos Storage. There is no size limit beyond the list limits in section 5.10. This is what lns publish makes, and it is the right choice for every normal site.
On-chain page
The name's page account holds the content itself, encrypted under the same key with the associated data logos-names/v5/page. The plaintext is a content type (1 to 64 bytes) and a body. Although LEZ caps actor data at 100 KiB, a 96 KiB write fails the wallet's default gas limit, so the registry caps a sealed page at 80 KiB (81,920 bytes, MAX_SEALED_PAGE_LEN), giving a practical maximum of about 78 KB of HTML.

When a record has a valid cid, a client MUST use the Storage site and not read the on-chain page. It reads the page only when there is no cid.

Both clients agree: Main.qml loadNativeStaticNavigation and serve.mjs loadSiteRoot read the page only as a fallback.

An on-chain page body is one of:

On-chain pages come straight from the LEZ RPC (getAccountView) with no Storage fetch and no separate hash pin. They are as trustworthy as the RPC's answer for the record (sections 6.8 and 10.4). The gateway computes the body's SHA-256 only to show in the banner and to check its blocklist.

4.5.1 Cost and when to use one

Writing an on-chain page costs in proportion to its size — about 185 LEZ per byte per write (roughly 185 to 220 LEZ per byte across these measured sizes on the LEZ 0.4 testnet on 25 November 2026, in testnet LEZ):

Page sizeFee per write
5 KBabout 1.1 million
23 KBabout 4.2 million
46 KBabout 8.7 million
78 KB (the real cap)about 14.5 million

That fee is paid again on every edit. A record update pointing at a Storage site costs about 250,000 LEZ whatever the site's size (section 9.6). Use an on-chain page only for a tiny single-page site (or a small root list under 10 KiB) when you have no Logos Storage node; use a Storage site for everything else.

4.6 Avatar

The avatar text entry is the name's icon, shown on tiles, in history and on tabs. Its value is a data:image/png, jpeg, gif or webp base64 URL. Showing it fetches nothing.

Open contradiction. The Logos Names specification (section 5) and its seal crate cap every text value at 512 bytes (validate_profile), while section 7 of the same specification, the Names Browser and lns publish allow a 12 KiB avatar value. A data: URL longer than 512 bytes fails validate_profile in the seal source. Until this is settled, keep icons tiny (or pass --no-avatar) and never exceed about 8 KiB raw even if avatar is exempted from the 512-byte check.

4.7 Addresses

The address of a page is:

lns://<name>[/<site path>][?<query>][#<fragment>]

A client MUST refuse an address longer than 2,048 bytes, or one containing control or BiDi characters.

Enforced in links.rs parse_url (MAX_URL_BYTES, round-3 BiDi fix) and logic.mjs parseUrl.

cid:// addresses. Both URL parsers (parse_url in links.rs and parseUrl in logic.mjs) accept the syntax cid://<cid>[/<path>][?<query>][#<fragment>], and HTML links to cid://… are preserved by resolve_safe_link (sanitize.rs). However, Names Browser 0.4.6 refuses to open a bare cid:// address from the address bar or a link: it stops with an error ("Unverified file skipped — direct cid:// URLs have no pinned SHA-256 hash") and fetches nothing (Main.qml loadNativeStaticNavigation; lib.rs fetch_static_site). That is because a bare CID has no record-pinned SHA-256, and the browser does not check the CID's multihash against the bytes (section 6.2.1, section 6.2.2). Inside a page's HTML or CSS (<img>, <link>, @font-face), cid:// references are likewise never fetched by the Names Browser; the gateway resolves one only if that CID appears with a pinned SHA-256 in the site's verified lists (section 6.4). (STATIC-PROFILE.md still says cid:// addresses navigate and load; the code wins.)

4.8 When a change takes effect

Making a change. The holder rewrites the record with one SetRecord transaction carrying the whole new sealed profile. lns publish does this through the names profile command, which sets cid, cid.sha256, cid.type and, if given, avatar in one transaction and keeps the other entries. LEZ includes failed transactions in blocks.

A publisher MUST confirm a change by reading the record back, not by seeing its transaction included.

Logos Names specification, section 8. lns publish step 6 resolves lns://name again and reports which side is behind (single-publish.mjs).

In the Names Browser. The browser asks the RPC for the record on every page load and link click, so a new root is used on the next load. While the new version loads, it may show the last version it verified for that name, marked as older (section 6.5).

On the gateway. The gateway keeps a name's record for 60 seconds, and the CDN keeps HTML for up to 120 seconds. A change usually shows within about three minutes, sooner if the publisher purges the CDN (section 8.6). Files under /_imm/ are addressed by hash, so they never go stale.

Transfer, release and expiry. A transfer or release empties the profile and the page, so the site is gone at once. A fee-mode name 30 days past its expiry reads as unregistered, so its site is gone too, whatever the record still holds. Deposit-held names do not expire (section 4.9).

4.9 Getting and holding a name

Publishing a site requires holding an LNS name. The Logos Names specification (section 8) defines the full transactions; this section summarises what affects site owners.

4.10 Planned: subnames and prices

Planned, not built (non-normative). These are decisions for the new registry on LEZ 0.4.0, made on 27 November 2026. Nothing here runs yet, and the details can change before it is deployed.

Subnames.

Prices. Names will be charged for, in place of the refundable deposit of section 4.9.