paused
bool// XXX: replace with p/moul/authz
Value
false
setPaused
func(newPausedValue bool)- OID
- 0ef147…2c10:4
setPaused details
updateUsername
func(userData *users.UserData, newName string) .uverse.error- OID
- 0ef147…2c10:6
updateUsername details
deleteUserdata
func(userData *users.UserData) .uverse.error- OID
- 0ef147…2c10:7
deleteUserdata details
setRegisterPrice
func(newPrice int64)- OID
- 0ef147…2c10:8
setRegisterPrice details
NewSetPausedExecutor
func(newPausedValue bool) dao.ProposalRequestNewSetPausedExecutor allows GovDAO to pause or unpause this realm
- OID
- 0ef147…2c10:9
NewSetPausedExecutor details
ProposeNewName
func(addr .uverse.address, newName string) dao.ProposalRequestProposeNewName allows GovDAO to propose a new name for an existing user. The associated address and all previous names of a user that changes a name are preserved, and all resolve to the new name. Governance renames bypass the Open Nym Tier \`nym-...\\d{3}\` format intentionally. The DAO is the trust root for this realm; if voters approve a rename to \`vitalik\` (e.g. for trademark dispute resolution or system reservations), the validation here imposes no further opinion. The new name is still subject to the base shape enforced by \`r/sys/users.validateName\` (\`^\[a-z]\[a-z0-9]\*(\[\_-]\[a-z0-9]+)\*$\`, max 64 chars), which runs inside the updateUsername callback below.
- OID
- 0ef147…2c10:10
ProposeNewName details
ProposeDeleteUser
func(addr .uverse.address, reason string) dao.ProposalRequestProposeDeleteUser allows GovDAO to propose deletion of a user This will make the associated address and names unresolvable. WARN: After deletion, the same address WILL NOT be able to register a new name.
- OID
- 0ef147…2c10:11
ProposeDeleteUser details
ProposeNewRegisterPrice
func(newPrice int64) dao.ProposalRequestProposeNewRegisterPrice allows GovDAO to update the price of registration. Rejects prices below MinRegisterPrice (currently 0) at proposal-creation time. (audit finding #14: original code only rejected negative values, which would have been arithmetically nonsensical.)
- OID
- 0ef147…2c10:12
ProposeNewRegisterPrice details
reNymFormat
untyped stringOpen Nym Tier username format. Anchored. - literal \`nym-\` prefix (4 chars) - 5-13 lowercase ASCII letters (the alpha stem) - exactly 3 trailing decimal digits Total length 12-20 chars. Distinct by length from \`g1...\` addresses which are always 40 chars.
Value
"^nym-[a-z]{5,13}\\d{3}$"
reNym
*regexp.Regexp- OID
- 0ef147…2c10:14
reNym details
reservedPrefixes
[]stringReserved alpha-stem prefixes. Names whose stem starts with one of these are rejected at format-validation time with ErrReservedPrefix (clearer than ErrCanonicalCollision after the fact). \`gi\` is intentionally NOT listed: in most rendering targets \`i\` is visually distinct enough from \`1\`/\`l\` that legitimate \`gi\*\` names (giggles, gimbal, gift, etc.) should remain registerable. Phishing protection for the visual class is still enforced by canonical- collision detection in r/sys/users — once any \`gi\*\` or \`gl\*\` name is registered, all variants under the {l,i,1}→i canonicalization collide. \`gl\` and \`g1\` remain listed because they're more visually confusable with the bech32 address prefix \`g1\`. \`g1\` itself is unreachable through the alpha-only stem regex; defense-in-depth for any future regex relaxation.
- OID
- 0ef147…2c10:174
reservedPrefixes details
ErrInvalidFormat
*errors.errorStringExported error sentinels returned by ValidateNymFormat. Use errors.Is or direct equality; do not string-match. ErrReservedPrefix's message is built from reservedPrefixes at package init time so the surfaced list never drifts from the actual policy. Canonical-collision detection moved to r/sys/users in Option B. Consumers that previously caught namereg.ErrCanonicalCollision should switch to susers.ErrCanonicalCollision.
- OID
- 0ef147…2c10:176
ErrInvalidFormat details
ErrReservedPrefix
*errors.errorStringExported error sentinels returned by ValidateNymFormat. Use errors.Is or direct equality; do not string-match. ErrReservedPrefix's message is built from reservedPrefixes at package init time so the surfaced list never drifts from the actual policy. Canonical-collision detection moved to r/sys/users in Option B. Consumers that previously caught namereg.ErrCanonicalCollision should switch to susers.ErrCanonicalCollision.
- OID
- 0ef147…2c10:179
ErrReservedPrefix details
ErrBlacklisted
*errors.errorStringExported error sentinels returned by ValidateNymFormat. Use errors.Is or direct equality; do not string-match. ErrReservedPrefix's message is built from reservedPrefixes at package init time so the surfaced list never drifts from the actual policy. Canonical-collision detection moved to r/sys/users in Option B. Consumers that previously caught namereg.ErrCanonicalCollision should switch to susers.ErrCanonicalCollision.
- OID
- 0ef147…2c10:182
ErrBlacklisted details
IsReserved
func(stem string) boolIsReserved reports whether the given alpha stem matches a reserved role name (with implicit \`s\`-suffix expansion). The check is canonicalized — so \`vital1k\`-style l-substituted variants of a reserved name are also caught. O(1) backed by \`reservedSet\` built in init().
- OID
- 0ef147…2c10:184
IsReserved details
ValidateNymFormat
func(username string) .uverse.errorValidateNymFormat checks the regex, prefix-exclusion, and reserved- name rules in that order. Returns one of the exported sentinel errors per failure mode, or nil on success. Does NOT run the canonical-collision check — that lives in r/sys/users (susers.IsCanonicalTaken or, atomically with the write, inside susers.RegisterUser).
- OID
- 0ef147…2c10:186
ValidateNymFormat details
IsPaused
func() boolIsPaused exposes the realm's pause flag for cross-controller coordination.
- OID
- 0ef147…2c10:187
IsPaused details
reservedNames
[]stringreservedNames lists role/system identifiers that must never be allocated as a registered name. The intent is to prevent Open Nym Tier auto-registrations like "nym-admin000" from impersonating system roles. Sources merged here: - Common role names already covered by Handshake's valid.json (the 90k curated trademark/gTLD-application list) — admin, help, support, etc. - Common role names NOT covered by Handshake — administrator, root, sysadmin, owner, staff, api, etc. - RFC 2606 / RFC 6761 reserved labels — example, invalid, localhost, local, test. Plural rule: every entry below is ALSO reserved with the literal "s" suffix appended. So "doc" reserves both "doc" and "docs"; "setting" reserves both "setting" and "settings"; "new" covers "news", and so on. Entries are stored in the singular here and the validator appends "s" at check time. This halves list maintenance and avoids the temptation to add \`name+"s"\` after every singular entry. Note on length: the Open Nym Tier regex restricts the \[a-z]{5,13} middle to 5–13 chars, so entries shorter than 5 (mod, api, bot, god, gno, ...) and longer than 13 (administrator, jesuschrist, newtendermint, ...) cannot appear in Register() even without this list. They are kept anyway because: (a) cross-reference value — a single canonical list is easier to audit than two scope-specific lists with overlapping intent; and (b) future controllers (e.g. a hypothetical DAO-allocated path) can opt in to the same blacklist by querying IsReserved, providing defense-in-depth across the registration ecosystem. IMPORTANT: this list is NOT consulted by \`ProposeNewName\` — governance renames are gated by GovDAO vote alone, not by this blacklist. Voters reviewing a rename proposal are responsible for catching collisions with reserved names. Sortedness: entries must be sorted lexicographically (Go's \< on strings, which is byte-wise ASCII). TestReservedNamesSorted enforces this.
- OID
- 0ef147…2c10:189
reservedNames details
reservedSet
map[string]struct{...}reservedSet is the runtime O(1) lookup for the role-name blacklist. Built in init() from reservedNames in blacklist.gno: each source entry contributes BOTH \`Canonicalize(n)\` and \`Canonicalize(n+"s")\` as keys, implementing the "implicit \`s\` suffix" rule documented on reservedNames. Why canonicalize the blacklist itself: validation canonicalizes the candidate stem before checking, so the comparison set must also be in canonical form. Otherwise a candidate like "vital1k" would canonicalize to "vitaiik" but the blacklist would contain only "vitalik" — the comparison would miss the match. Keeping both sides in canonical form makes the lookup exact. The blacklist remains namereg/v1-local because it is policy specific to the Open Nym Tier. Other controllers may have entirely different reserved-name policies, or none at all.
- OID
- 0ef147…2c10:238
reservedSet details
init.20
func()- OID
- 0ef147…2c10:191
init.20 details
Canonicalize
func(s string) stringCanonicalize is a delegating shim to r/sys/users.Canonicalize. HISTORY: namereg/v1 used to host its own per-stem canonical store and its own Canonicalize (l→i only). Option B unified the canonical lookup into r/sys/users keyed by full canonical name with broader substitutions ({l,i,1}→i, {0,o}→o, {-,.,\_} stripped). This shim preserves the call-site name for local consumers (blacklist init, IsReserved) and any external consumer that imported the function from namereg/v1 before Option B. New code should call susers.Canonicalize directly.
- OID
- 0ef147…2c10:193
Canonicalize details
ErrNonUserCall
*errors.errorString- OID
- 0ef147…2c10:195
ErrNonUserCall details
ErrPaused
*errors.errorString- OID
- 0ef147…2c10:198
ErrPaused details
ErrInvalidUsername
*errors.errorString- OID
- 0ef147…2c10:201
ErrInvalidUsername details
ErrInvalidPayment
*errors.errorString- OID
- 0ef147…2c10:204
ErrInvalidPayment details
errInvalidPayment
func() .uverse.errorerrInvalidPayment returns the panic value for an OriginSend mismatch. Constructed lazily so the formatted price reflects the current value of registerPrice rather than the value frozen at package init time. Replaces the old \`ErrInvalidPayment = ufmt.Errorf(...)\` package var (audit finding #13) which captured registerPrice once and silently drifted out of date after every ProposeNewRegisterPrice execution.
- OID
- 0ef147…2c10:206
errInvalidPayment details
init.27
func()- OID
- 0ef147…2c10:208
init.27 details
preRegisteredUsers
[]struct{...}pre-registered users
- OID
- 0ef147…2c10:211
preRegisteredUsers details
init.29
func()- OID
- 0ef147…2c10:222
init.29 details
Render
func(path string) string- OID
- 0ef147…2c10:224
Render details
renderHomePage
func() string- OID
- 0ef147…2c10:226
renderHomePage details
renderIntroParagraph
func() string- OID
- 0ef147…2c10:227
renderIntroParagraph details
resolveUser
func(path string) (*users.UserData, bool, bool)resolveUser resolves the user based on the path, determining if it's a name or address
- OID
- 0ef147…2c10:228
resolveUser details
renderUserPage
func(path string) stringrenderUserPage generates the user page based on user data and path
- OID
- 0ef147…2c10:229
renderUserPage details
RenderLatestUsersWidget
func(num int) stringRenderLatestUsersWidget renders the latest num registered users. For num = -1, the maximum number (100) will be displayed.
- OID
- 0ef147…2c10:230
RenderLatestUsersWidget details
MinRegisterPrice
int64MinRegisterPrice is the lowest price (in ugnot) that ProposeNewRegisterPrice will accept. Set to 0 — registration is free by default; governance can raise the price via ProposeNewRegisterPrice without a floor.
Value
0
registerPrice
int64// free by default; governance can raise via ProposeNewRegisterPrice
Value
0
latestUsers
*fifo.List// Save the latest 100 users for rendering purposes
- OID
- 0ef147…2c10:233
latestUsers details
Register
func(username string)Register registers a new username for the caller. Valid usernames match \`nym-\[a-z]{5,13}\\d{3}\`: - literal \`nym-\` prefix (4 chars) - 5-13 lowercase letters (the alpha stem) - exactly 3 trailing decimal digits Total length 12-20 chars. The alpha stem additionally must NOT start with \`gno\`/\`gi\`/\`gl\` and must not match a reserved role name (with implicit \`s\`-suffix expansion). See ValidateNymFormat for the format/blacklist check. Canonical-collision detection is enforced atomically by susers.RegisterUser via the unified canonical store in r/sys/users (decision: per Option B, every controller participates in the same canonical-form lookup keyed by full canonical name). Only direct EOA (maketx call) invocations are supported.
- OID
- 0ef147…2c10:235