bugzilla-daemon at mindrot.org
2024-Jan-24 11:23 UTC
[Bug 3659] New: Certificates are ignored when listing revoked items in a (binary) revocation list
https://bugzilla.mindrot.org/show_bug.cgi?id=3659
Bug ID: 3659
Summary: Certificates are ignored when listing revoked items in
a (binary) revocation list
Product: Portable OpenSSH
Version: 9.2p1
Hardware: All
OS: All
Status: NEW
Severity: minor
Priority: P5
Component: ssh-keygen
Assignee: unassigned-bugs at mindrot.org
Reporter: webmaster at mmf-research.de
1. Create a blank binary revocation list:
ssh-keygen -Qlf my.krl
# KRL version 0
# Generated at 20240122T162948
2. Revoke a key, and a certificate:
ssh-keygen -kuf my.krl user1_id25519.pub user2_id25519-cert.pub
Revoking from user1_id25519.pub
Revoking from user2_id25519-cert.pub
3. Check the successful revocation:
ssh-keygen -Qf my.krl user1_id25519.pub user2_id25519-cert.pub
> user1_id25519.pub (USER1 ID): REVOKED
> user2_id25519-cert.pub (USER2 ID): REVOKED
4. Displaying the updated content of the revocation list will ignore
the certificate:
ssh-keygen -Qlf my.krl
# KRL version 0
# Generated at 20240122T162948
hash: SHA256:SHA256:3IJIl... # ssh-ed25519
# CA key ssh-ed25519 SHA256:f4o3Bp...
serial: 3007
I would expect the revoked certificate to show up in this list, too.
Note that in my setup, the SSH daemon correctly denies login with the
revoked certificate. It seems that just the KRL/CRL content listing is
affected.
--
You are receiving this mail because:
You are watching the assignee of the bug.
bugzilla-daemon at mindrot.org
2024-Jan-24 23:36 UTC
[Bug 3659] Certificates are ignored when listing revoked items in a (binary) revocation list
https://bugzilla.mindrot.org/show_bug.cgi?id=3659
Damien Miller <djm at mindrot.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Resolution|--- |WORKSFORME
Status|NEW |RESOLVED
CC| |djm at mindrot.org
--- Comment #1 from Damien Miller <djm at mindrot.org> ---
This is working correctly.
You revoked two keys. A plain public key that is revoked by its hash:
hash: SHA256:SHA256:3IJIl... # ssh-ed25519
and a certificate. The certificate is revoked by its CA key and serial
number, that is the last two lines of your output:
# CA key ssh-ed25519 SHA256:f4o3Bp...
serial: 3007
So both keys are definitely represented in the KRL dump.
Generally, the KRL code tries to write as small a file as possible. For
Certificates this means that it uses the smallest unique identifier
which is the serial number (for each given CA.
If you don't like this then you can use a KRL spec file to control how
the KRL revokes the keys. Something like:
(printf "sha256: "; cat user1_id25519.pub; \
printf "\nsha256: "; cat user2_id25519-cert.pub; printf
"\n") >
krl.spec
ssh-keygen -kuf my.krl krl.spec
See the "KEY REVOCATION LISTS" section of the ssh-keygen(1) manpage
for
more information on KRL spec files.
--
You are receiving this mail because:
You are watching someone on the CC list of the bug.
You are watching the assignee of the bug.