unity-gateway: OAuth JWT written world-readable (0644) by ug configure

Abierto
#1,544 0 comentarios 0 reacciones 0 asignados Ver en GitHub

Los mantenedores suelen responder en 1 día

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
3/5
Tiempo estimado
1-2 días
Aptitud para principiantes
56/100
Tipo de issue
Error
Claridad
Bastante claro
Estado de actividad
Activo
Stack tecnológico
python
Área
cli, security

Línea de trabajo

Start by tracing how ug configure --user --agents opencode writes ~/.ucode/opencode-xdg/opencode/opencode.json, ucode-auth.js, and state.json, and compare their permissions with managed-config.json. Reproduce the setup and check the resulting file and directory modes; done means the live token is not readable by other local users, with the chosen approach consistent across these files.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

ug configure --user --agents opencode (v0.2.1) writes the live OAuth access token (client_id databricks-cli, about 1 hour remaining) into ~/.ucode/opencode-xdg/opencode/opencode.json as both options.apiKey and options.headers.Authorization.

The file has mode -rw-r--r--, so any local user can read it, and ucode-auth.js and state.json are also 0644. managed-config.json is correctly 0600. Suggested fix: create these files with mode 0600 and the directory with 0700, or avoid writing the token and rely on the refresh plugin. Checked on macOS arm64, v0.2.1.

Lenguaje dominante
Python
Estrellas
122
Forks
101
Merge medio
1 d 16 h
PR fusionados (30 d)
198

Preparar el entorno

  • Sin Dockerfile ni archivo de Docker Compose
  • Tiene una plantilla de pull request
  • Sin guía de contribución

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de databricks/unity-gateway

Todos los issues de databricks/unity-gateway

Issues similares

Más issues de Python

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.