Skip to content

registration: refuse labels confusable with reserved and community names #43

Closed

Description

@brenzi-agent

A label that differs from a reserved or community-listed name only by hyphens is offered as an ordinary name, under the general terms.

Current checks

  • useReservedStatus reads reservedNames(keccak256(label)) for the exact label only.
  • getNameTermsQueryFn reads communityNames for the exact label only.
  • ALLOWED_LABEL_REGEX admits interior hyphens, and the SimpleX app keeps them when it parses a name.

Case and script variants are already refused: ENS normalisation lowercases, and the LDH regex rejects non-ASCII and xn-- labels.

Required behaviour

  1. The separator skeleton of a label is the label without hyphens.
  2. When the skeleton differs from the label, the dapp also reads reservedNames and communityNames for keccak256(skeleton).
  3. A label whose skeleton is reserved is refused, with the reserved-name banner and the skeleton's reason.
  4. A label whose skeleton is community-listed is refused, with a message that names the listed spelling. The contract decides the terms kind by the exact label, so such a label cannot be registered under the community terms.
  5. A label that contains simplex is refused.
  6. The checks apply in search results, the profile page, the Pricing step and the claim flow.

Examples

  • example reserved: exam-ple and ex-am-ple are refused.
  • examplecity community-listed: example-city is refused.
  • simplex-anything and mysimplex are refused.

Tests

  • Skeleton function: hyphen removal, a label without hyphens is its own skeleton.
  • Each refusal case above, with mocked reservedNames and communityNames reads.

Activity

  1. brenzi commented on Nov 3, 2026

    @brenzi

    we can't prevent someone from interacting with contracts directly, bypassing this check

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions