PGSQL auth fails during install #1251

Closed
opened 2025-11-02 03:54:08 -06:00 by GiteaMirror · 8 comments
Owner

Originally created by @ghost on GitHub (Nov 17, 2017).

  • Gitea version (or commit ref): 1.2.3
  • Git version: 2.15.0
  • Operating system: FreeBSD 11.1
  • Database (use [x]):
    • PostgreSQL
    • MySQL
    • MSSQL
    • SQLite
  • Can you reproduce the bug at https://try.gitea.io:
    • Yes (provide example URL)
    • No
    • Not relevant
  • Log gist:

Description

When configuring the PostgreSQL database I see the following error:

Database setting is invalid: pq: unknown authentication response: 10

The same error is reported in the logs when using unix socket types instead of http.

The issue is I am using SCRAM-SHA-256 authentication for the gitea user, the upstream pq library does not support this from what I can tell.

Is it possible to use a library which does support this?

Originally created by @ghost on GitHub (Nov 17, 2017). - Gitea version (or commit ref): 1.2.3 - Git version: 2.15.0 - Operating system: FreeBSD 11.1 - Database (use `[x]`): - [x] PostgreSQL - [ ] MySQL - [ ] MSSQL - [ ] SQLite - Can you reproduce the bug at https://try.gitea.io: - [ ] Yes (provide example URL) - [x] No - [ ] Not relevant - Log gist: ## Description When configuring the PostgreSQL database I see the following error: ```Database setting is invalid: pq: unknown authentication response: 10``` The same error is reported in the logs when using unix socket types instead of http. The issue is I am using SCRAM-SHA-256 authentication for the gitea user, the upstream pq library does not support this from what I can tell. Is it possible to use a library which does support this?
GiteaMirror added the type/bug label 2025-11-02 03:54:08 -06:00
Author
Owner

@lafriks commented on GitHub (Nov 17, 2017):

Depends on used library lib/pq#608

@lafriks commented on GitHub (Nov 17, 2017): Depends on used library lib/pq#608
Author
Owner

@ghost commented on GitHub (Jan 17, 2018):

With pq not being updated are there plans to use another library for this functionality?

@ghost commented on GitHub (Jan 17, 2018): With pq not being updated are there plans to use another library for this functionality?
Author
Owner

@ghost commented on GitHub (Feb 23, 2018):

Any updates here?

@ghost commented on GitHub (Feb 23, 2018): Any updates here?
Author
Owner

@lunny commented on GitHub (Feb 24, 2018):

@evitalis do you know any other driver fix this issue?

@lunny commented on GitHub (Feb 24, 2018): @evitalis do you know any other driver fix this issue?
Author
Owner

@lunny commented on GitHub (Feb 24, 2018):

maybe we could try this one https://github.com/jackc/pgx

@lunny commented on GitHub (Feb 24, 2018): maybe we could try this one https://github.com/jackc/pgx
Author
Owner

@ghost commented on GitHub (Mar 5, 2018):

I am not familiar with Go enough to suggest an alternative library. But given the inactivity of the current one it may be worth looking into another to keep up with PostgreSQL features and security improvements.

@ghost commented on GitHub (Mar 5, 2018): I am not familiar with Go enough to suggest an alternative library. But given the inactivity of the current one it may be worth looking into another to keep up with PostgreSQL features and security improvements.
Author
Owner

@jsan4christ commented on GitHub (Oct 23, 2018):

Have the same problem, any leads?
Database setting is invalid: pq: SSL is not enabled on the server

@jsan4christ commented on GitHub (Oct 23, 2018): Have the same problem, any leads? Database setting is invalid: pq: SSL is not enabled on the server
Author
Owner

@techknowlogick commented on GitHub (Apr 15, 2019):

Please test if #6640 resolves your issue.

@techknowlogick commented on GitHub (Apr 15, 2019): Please test if #6640 resolves your issue.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/gitea#1251