Setting username via OAuth on shared servers

Aberta
#9,540 2 comentários 0 reações 1 responsável Ver no GitHub

Mantenedores costumam responder em até 2 dias

@excalq já está trabalhando nisso.

Desde 16/1/2026.

Avaliação

Esta issue ainda não foi avaliada.

Descrição

Feature

We have a use case of providing users with pre-configured database connections, which shared servers works well for. However, each user has a separate account in these databases, matching the email in their OAuth authentication flow (via Auth0). Their passwords are sourced externally (aws rds generate-db-auth-token) and short-lived, so we only need to set usernames, not passwords.

I was attempting to set a configuration to achieve this using servers.json, but it does not appear possible, looking at the codebase. We don't want a shared username, nor does Username: null cause the email/oauth-username-claim to be used, instead username is missing, and 'must be specified'.

The goal: Use the value of OAUTH2_USERNAME_CLAIM for Shared Servers instead of SharedUsername.

Related Issue: Shared Usernames: #6229

Describe alternatives you've considered

  1. Provisioning non-shared databases, per user: The servers.json is loaded into the SQLite DB once, as I understand, and removing it has undesired consequences, so this would be burdensome when adding new users.

Additional context

I am willing to contribute a PR with some changes in ‎ServerModule.create_shared_server, but would like to open this discussion first.

Linguagem predominante
Python
Estrelas
3.9k
Forks
922
Merge médio
2d 3h
PRs com merge (30d)
33

Preparar o ambiente

Primeiros passos

  1. Leia a issue inteira e depois o guia de contribuição do projeto.
  2. Comente na issue dizendo que vai assumir — evita que duas pessoas façam o mesmo trabalho.
  3. Faça um fork do repositório e trabalhe em uma branch.
  4. Abra um pull request que referencie o número da issue.

Mais de pgadmin-org/pgadmin4

Todas as issues de pgadmin-org/pgadmin4

Issues semelhantes

Mais issues de Python

Receba novas issues na sua caixa de entrada

Um resumo curto de issues do GitHub para quem está começando.