Interactive consent for a non-ASCII host is asked for and then always refused
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 2/5
- Tiempo estimado
- 1-3 horas
- Aptitud para principiantes
- 72/100
- Tipo de issue
- Error
- Claridad
- Bien especificado
- Estado de actividad
- Activo
- Stack tecnológico
- go
- Área
- authorization, security
Línea de trabajo
Empieza en internal/authz/authz.go en la rama por defecto de Gate (alrededor de las líneas 84-96), donde confirm se ejecuta antes de validar el host. internal/authz/scope.go tiene parseScopeHost, que ya rechaza hosts no ASCII; comprueba si puede ejecutarse antes del aviso. Está listo cuando un host no ASCII se rechaza antes de cualquier aviso con la sugerencia de punycode, y una prueba en internal/authz lo cubre. Ejecuta go test ./internal/authz.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
Summary
For a running target with a non-ASCII host (for example http://bücher.example/), authz.Gate asks the operator to type the host to confirm. After they type it correctly, it refuses with an error about the scope "from the interactive confirmation" not being valid. The host check that makes the target unusable runs after the prompt instead of before it.
Where
internal/authz/authz.go:84-96(confirm, then the interactive scope built fromep.String(), thennormalize)internal/authz/scope.go:213-216(parseScopeHostrejects non-ASCII hosts)internal/authz/scope.go:290(endpointOfaccepts anyu.Hostname())
Details
default:
if err := confirm(ep, opts); err != nil {
return nil, err
}
g.source = sourceInteractive
raw = config.Scope{
Hosts: []string{ep.String()},
...
}
}
g.scope, g.hosts, g.prefixes, err = normalize(raw)
Impact
The operator is asked for consent, types the host exactly, and is then refused with an error about a scope they never wrote. The punycode hint in the error is useful, but it should come before the prompt.
Steps to reproduce
authz.Gate on http://bücher.example/ with Interactive: true and stdin bücher.example\n: it prints the confirmation prompt, then returns "the scope from the interactive confirmation is not valid ... write international names in punycode".
Suggested fix
In Gate, run parseScopeHost(ep.String()) before confirm, and refuse up front with the punycode hint. Converting the host to punycode would need golang.org/x/net/idna, a new dependency that AGENTS.md asks to justify.
Acceptance criteria
- A non-ASCII host is refused before any prompt, with the punycode hint.
- A test in
internal/authzcovers it.
Getting started
- Relevant files:
internal/authz/authz.go,internal/authz/scope.go - How to run tests:
go test ./internal/authz
Filed by repo-audit/full-audit at fffef43. Severity: low. Effort: S. audit-key: bug|internal/authz/authz.go|Gate
- Lenguaje dominante
- Go
- Estrellas
- 0
- Forks
- 1
- Métricas de merge de PR
- Sin PR fusionados en 30 d
Preparar el entorno
Inicia el contenedor de desarrollo del proyecto en tu navegador, con tu propia cuenta de GitHub.
- Incluye un Dockerfile o un archivo de Docker Compose
- Tiene una plantilla de pull request
- Leer la guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de TMHSDigital/Spackle
-
enhancement good first issue severity: low
Dificultad 2/5 Medio día Aptitud para principiantes 72/100
TMHSDigital/Spackle#139 ·
-
enhancement good first issue severity: low
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
TMHSDigital/Spackle#138 ·
-
documentation good first issue severity: low
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
TMHSDigital/Spackle#135 ·
-
runs and runs compare print target text without the control-character cleaning the reports useAbiertobug good first issue severity: low
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
TMHSDigital/Spackle#129 ·
-
bug good first issue severity: low
Dificultad 2/5 1-3 horas Aptitud para principiantes 82/100
TMHSDigital/Spackle#128 ·
Todos los issues de TMHSDigital/Spackle
Issues similares
-
bug raised-by:reviewer
Dificultad 2/5 1-3 horas Aptitud para principiantes 66/100
medici-finance/assay#7655 ·
Los mantenedores suelen responder en 1 día
-
helm chart: make DaemonSet pod affinity configurable via values.yamlPosiblemente ocupada @Young-Zen la tomó hoy. Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
flannel-io/flannel#2632 ·
Los mantenedores suelen responder en 6 días
-
go-vulnerability security-scan
Dificultad 1/5 Menos de una hora Aptitud para principiantes 72/100
teslashibe/agent-go#36 ·
-
enhancement
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
nwverse/persona#15194 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
bug flaky-test
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
rosskukulinski/tailworks#411 ·
Los mantenedores suelen responder en 1 día