jakob / jakob/Postico

Follow softlinks for ~/.postgresql/ certs

Open
#816 2 comments 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
486
Forks
8
PR merge metrics
No merged PRs in 30d

Description

You can use this template for reporting bugs.
Feel free to remove parts that are not relevant, or just write something free-form if you prefer.

## What did you do?

setup tls certificates as links to files:
```
ln -s ~/.tsh/keys/example.com/certs.pem ~/.postgresql/root.crt
ln -s ~/.tsh/keys/example.com/gabeio-db/example.com/db-x509.pem ~/.postgresql/postgresql.crt
ln -s ~/.tsh/keys/example.com/gabeio ~/.postgresql/postgresql.key
```

## What did you expect to happen?

I expected to be able to connect using the tls certificates that the links point to.

## What actually happened?

`could not read root certificate file "/Users/gabeio/.postgresql/root.crt": Operation not permitted`

when they are actual files instead of links it does work fine, but we use gravitational Teleport which manages the tls certs in a specific place which is why having hard copies isn't ideal (automatically updated/replaced). psql cli seems to be fine with the links.

## What software versions are you using?

Postico version: Version 1.5.19 (8260)
(select "About Postico" from the Postico menu)

macOS version: 12.3.1 (21E258)
(selecting "About this Mac" from the Apple menu)

PostgreSQL version: PostgreSQL 12.8 on x86_64-pc-linux-gnu, compiled by x86_64-pc-linux-gnu-gcc (GCC) 7.4.0, 64-bit
(execute the command "SELECT VERSION();" to find out)

Cheers 🌮

Contributor guide

No contributing guide indexed for this repository

Research direction

Reproduce the connection using the linked files under ~/.postgresql/ and compare it with the working psql CLI behavior. Trace how Postico reads root.crt, postgresql.crt, and postgresql.key, then verify that connections using symlinked certificates succeed without changing the Teleport-managed files.

Written by the indexing model from the issue text.

Assessment

Tech stack
macos, postgresql, python
Domain
databases, desktop, security
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.