Skip to content

cannot install certs on Debian #23

@ju1ius

Description

@ju1ius

Hi,

Installing a certificate into to the system trust store is broken on Debian Sid (see also: smallstep/cli#1043).

$ cat /etc/debian_version
trixie/sid
$ ./bin/truststore my_cert.crt
install is not supported on this system

On Debian the update-ca-certificates binary is located under /usr/sbin, which is not in the path of non-root users.

This causes the exec.LookPath call in truststore_linux.go's init function to always fail and setting SystemTrustCommand to nil, which in turn causes installPlatform to incorrectly return ErrNotSupported.

Since the command (and the equivalent step certificate install and step ca bootstrap --install) should not be run as root, the exec.LookPath check should be removed from the init function, letting commandWithSudo(SystemTrustCommand...) fail (with an actually useful message) if SystemTrustCommand is not found, which is what mkcert does.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions