zig icon indicating copy to clipboard operation
zig copied to clipboard

std.crypto.Certificate.verify: additionally verify "key usage"

Open andrewrk opened this issue 2 years ago • 1 comments

RFC 5280 section 4.2.1.3

https://github.com/ziglang/zig/blob/c9ef277fa7e43f119a7f2896635b4fdf9c97edbe/lib/std/crypto/Certificate.zig#L197-L201

andrewrk avatar Jan 03 '23 08:01 andrewrk

Not only should key usage be verified, but also:

  • Additional key usage
  • Policy chain
  • Basic constraints
  • All critical extensions are parsed
  • Correctly parse dates before 1950 (currently they are all parsed as 1970)

clickingbuttons avatar Apr 26 '24 21:04 clickingbuttons