Hacktoberfest 2026: le issue che i maintainer hanno segnato per ottobre, aperte e adatte ai principianti. Sfoglia le issue Hacktoberfest

[Bug Bash] doc: authorization.md says golden tags skip can_use_tag, but onSourceTag checks every source_tag.

Aperta Adatta ai principianti
#3,235 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
1/5
Tempo stimato
Meno di un'ora
Idoneità per principianti
83/100
Tipo di issue
Documentazione
Chiarezza
Specificata chiaramente
Stato di attività
Attiva
Stack tecnologico
go

Direzione di ricerca

Inizia con la riga CreateActor in docs/authorization.md, poi controlla onSourceTag in cmd/ateapi/internal/authz/registry.go e il valore di fallback in cmd/ateapi/internal/controlapi/actor.go. Aggiorna il testo per spiegare quando viene verificato can_use_tag e cosa succede quando sourceTag viene omesso. Il lavoro è terminato quando la documentazione corrisponde a questi percorsi del codice.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

area/security bug-bash kind/docs

docs/authorization.md (the CreateActor row under "Checks per RPC") says:

Golden tags skip this check: the handler only accepts one built from the actor's own template.

The skip doesn't depend on whether the tag is golden. It depends on whether sourceTag is set:

  • sourceTag omitted: CreateActor in cmd/ateapi/internal/controlapi/actor.go falls back to template.status.goldenSnapshotStatus.goldenTag. The interceptor never sees a tag, so it checks only can_create_actor and can_use_template.
  • sourceTag set, golden or not: onSourceTag in cmd/ateapi/internal/authz/registry.go always adds can_use_tag, which needs editor on the tag's atespace.

A caller who can use a template from another atespace (viewer there) gets its golden snapshot when they omit sourceTag, but is denied if they name the same golden tag explicitly. The doc suggests both are allowed.

The rule that a tag must come from the actor's own template is in resolveTagSource, and it applies to every tag, not only golden ones.

Suggested wording for the doc: "can_use_tag applies only when sourceTag is set. With no sourceTag, CreateActor uses the template's golden tag and checks can_use_template only."

I checked this in the code on main (ffed8551). I couldn't confirm it on the cluster, because creating a tag failed there with a snapshot upload error.

Found during the authorization bug bash, with help from an AI agent.

Lingua principale
Go
Stelle
5.9k
Fork
637
Merge medio
2g 10h
PR unite (30g)
562

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di agent-substrate/substrate

Tutte le issue di agent-substrate/substrate

Issue simili

Altre issue su Go

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.