No description
Find a file
Snider 714a1e081b refactor(lns): move internal/ + pkg/ under go/ subtree (Mantis #1342)
Phase 1 cascade was incomplete — `/go/` source imports
`dappco.re/go/lns/internal/nameutil` and `dappco.re/go/lns/pkg/{chain,
covenant,dns,primitives,wallet}` but those dirs were still at the repo
root. Pure file move via `git mv`. Build clean, all 7 packages pass
tests.
2026-05-01 15:33:48 +01:00
.core chore(repo): add .core/go.yaml — canonicalize as managed Lethean Go repo 2026-05-01 11:22:09 +01:00
docs chore(go-lns): clear 1 sonar bug — javascript:S2871 (Mantis #1291) 2026-05-01 09:56:04 +01:00
go refactor(lns): move internal/ + pkg/ under go/ subtree (Mantis #1342) 2026-05-01 15:33:48 +01:00
tests/cli/lns feat(ax-10): add go-lns CLI test scaffold per AX-10 2026-04-24 23:31:24 +01:00
.gitignore refactor(lns): simplify canonical name helpers 2026-04-02 13:10:14 +00:00
.woodpecker.yml ci: woodpecker pipeline (Go) — golangci-lint/eslint/phpstan + sonar.lthn.sh 2026-04-29 00:03:11 +01:00
AGENTS.md chore: go mod tidy 2026-04-24 08:26:11 +01:00
CLAUDE.md refactor(core): align go-lns with hardened core/go reference shape 2026-04-29 03:26:21 +01:00
go.work chore(repo): refresh submodules + go.work hygiene (Phase 2 cascade unblock) 2026-05-01 09:40:11 +01:00
LICENCE chore: add EUPL-1.2 LICENCE file (UK English canonical) 2026-05-01 08:34:25 +01:00
README.md refactor(core): align go-lns with hardened core/go reference shape 2026-04-29 03:26:21 +01:00
sonar-project.properties ci: woodpecker pipeline (Go) — golangci-lint/eslint/phpstan + sonar.lthn.sh 2026-04-28 23:33:26 +01:00

Lethean Name System for Go

This module is the native Go implementation of the Lethean Name System (LNS). It provides name validation, name hashing, reserved and locked catalog lookup, covenant helpers, DNS resource encoding, and a Core service wrapper that exposes the same operations from the top-level dappco.re/go/lns package.

The package is intentionally self-contained. The JavaScript and HSD source trees under docs/js-* are reference material for porting and compatibility checks; runtime code should use the Go primitives in pkg/primitives, pkg/covenant, and pkg/dns.

Quick Start

package main

import (
	core "dappco.re/go"
	"dappco.re/go/lns"
)

func main() {
	app := core.New(core.WithService(lns.Register))
	_ = app
	hash, err := lns.ResolveString("example.lthn")
	if err != nil {
		panic(err)
	}
	core.Println(hash)
}

Packages

lns.go mirrors the public API for callers that want one import path. The subpackages hold the implementation: pkg/covenant owns name rules and catalog verification, pkg/dns owns DNS resource projection and live bridge helpers, pkg/primitives owns serializable chain data structures, and pkg/wallet / pkg/chain provide lightweight scaffolding for action handlers.

Validation

This repository is not included in the parent go.work, so run validation with workspace mode disabled:

GOWORK=off go test ./...

For compliance work, also run the v0.9.0 audit script supplied by the core/go workspace.