From: ng0@n0.is
To: Julien Lepiller <julien@lepiller.eu>
Cc: guix-devel@gnu.org
Subject: Re: Renewing certificates with certbot
Date: Wed, 6 Mar 2019 16:26:12 +0000 [thread overview]
Message-ID: <20190306162612.2clxbjrh6wipj4wp@uptimegirl> (raw)
In-Reply-To: <cd84f6f520a6b5819f582bef0e4e6e32@lepiller.eu>
Julien Lepiller transcribed 2.1K bytes:
> Le 2019-03-06 15:19, ng0@n0.is a écrit :
> > Julien Lepiller transcribed 1.6K bytes:
> > > Le 2019-03-06 14:42, Ludovic Courtès a écrit :
> > > > Hi,
> > > >
> > > > Julien Lepiller <julien@lepiller.eu> skribis:
> > > >
> > > > > I use certificates from let's encrypt for my website and mail servers,
> > > > > and found that there was an issue with certificates generated by the
> > > > > certbot service in Guix: the generated private keys are world-readable
> > > > > (in a directory that cannot be accessed by anyone but root, so it's OK
> > > > > I guess). OpenSMTPD is not happy with that though, so I have to chmod
> > > > > the files every time. I came up with a variant of the deploy-hook
> > > > > that's presented in the manual, and I'd like to update the example
> > > > > with it. Here it is:
> > > > >
> > > > > ;; Find running nginx and reload its configuration (for certificates)
> > > > > (define %my-deploy-hook
> > > > > (program-file
> > > > > "my-deploy-hook"
> > > > > #~(let* ((pid (call-with-input-file "/var/run/nginx/pid" read))
> > > > > (cert-dir (getenv "RENEWED_LINEAGE"))
> > > > > (privkey (string-append cert-dir "/privkey.pem")))
> > > > > ;; certbot private keys are world-readable by default, and
> > > > > smtpd complains
> > > > > ;; about that, refusing to start otherwise
> > > > > (chmod privkey #o600)
> > > > > (kill pid SIGHUP))))
> > > > >
> > > > > What do you think?
> > > >
> > > > It sounds like a serious issue that private keys are world-readable. Is
> > > > it a bug on our side or in Certbot? I think we should fix it so that
> >
> > It's a certbot default, on all all systems.
>
> Actually, reading https://github.com/certbot/certbot/issues/1473 suggests
> it's not the case anymore. I was probably running an older version
> of certbot.
Thanks for pointing me to this, I wasn't aware of this
> >
> > > > they are never world-readable, rather than document how to work around
> > > > the bug.
> > > >
> > > > WDYT?
> > > >
> > > > Thanks,
> > > > Ludo’.
> > >
> > > I don't think this is an issue: the file is world-readable, but the
> > > directory
> > > it's in is not accessible to anyone but root. OpenSMTPD still
> > > complains,
> > > but I think there's no security issue.
> > >
> > >
>
>
next prev parent reply other threads:[~2019-03-06 16:26 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-02-22 13:49 Renewing certificates with certbot Julien Lepiller
2019-02-22 17:57 ` swedebugia
2019-03-06 13:42 ` Ludovic Courtès
2019-03-06 13:51 ` Julien Lepiller
2019-03-06 14:12 ` Giovanni Biscuolo
2019-03-06 14:19 ` ng0
2019-03-06 14:33 ` Julien Lepiller
2019-03-06 16:26 ` ng0 [this message]
2019-03-22 8:00 ` Chris Marusich
-- strict thread matches above, loose matches on Subject: below --
2019-03-22 10:55 Clément Lassieur
2019-03-23 1:08 ` Chris Marusich
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://guix.gnu.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20190306162612.2clxbjrh6wipj4wp@uptimegirl \
--to=ng0@n0.is \
--cc=guix-devel@gnu.org \
--cc=julien@lepiller.eu \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/guix.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).