Describe LDAPS setup with self-signed certificate #7993

Open
opened 2025-11-02 07:44:59 -06:00 by GiteaMirror · 1 comment
Owner

Originally created by @justusbunsi on GitHub (Oct 19, 2021).

In the current documentation there is no guidance on how to handle LDAPS connections with self-signed certificates.

Originally created by @justusbunsi on GitHub (Oct 19, 2021). In the current documentation there is no guidance on how to handle LDAPS connections with self-signed certificates.
GiteaMirror added the topic/authenticationtype/docs labels 2025-11-02 07:44:59 -06:00
Author
Owner

@zeripath commented on GitHub (Oct 19, 2021):

https://github.com/go-gitea/gitea/issues/16376#issuecomment-885828441

Add your certificate to a copy of the root certs file and set the SSL_CERT_FILE environment variable to the new file.

See: https://pkg.go.dev/crypto/x509@go1.16.6#SystemCertPool

and

https://cs.opensource.google/go/go/+/refs/tags/go1.16.6:src/crypto/x509/root_linux.go

(On linux that is. On windows and mac you need to add the new RootCA to the system pool.)

Unfortunately as far as I can see if we were to provide an option to set the trusted CAs, users would have to provide a file containing all root CAs.

@zeripath commented on GitHub (Oct 19, 2021): https://github.com/go-gitea/gitea/issues/16376#issuecomment-885828441 Add your certificate to a copy of the root certs file and set the `SSL_CERT_FILE` environment variable to the new file. See: https://pkg.go.dev/crypto/x509@go1.16.6#SystemCertPool and https://cs.opensource.google/go/go/+/refs/tags/go1.16.6:src/crypto/x509/root_linux.go (On linux that is. On windows and mac you need to add the new RootCA to the system pool.) Unfortunately as far as I can see if we were to provide an option to set the trusted CAs, users would have to provide a file containing all root CAs.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/gitea#7993