add last_change timestamp to secmod_rsa

This commit is contained in:
swrup 2026-03-03 01:36:12 +01:00
parent 0526675e52
commit 6fb33ee8f2
6 changed files with 30 additions and 30 deletions

View file

@ -54,6 +54,9 @@ module TimeRelative = struct
Jsont.Object.map ~kind:"RelativeTime" Fun.id
|> Jsont.Object.mem "d_us" jsont ~enc:Fun.id
|> Jsont.Object.finish
let pp ppf t =
if t = forever then Fmt.pf ppf "forever" else Fmt.pf ppf "%Lu" t
end
module TimeAbsolute = struct
@ -89,6 +92,7 @@ module TimeAbsolute = struct
if Int64.unsigned_div v 1_000_000L <> s then never else v
let of_ptime v = v |> Ptime.to_float_s |> Int64.of_float |> of_s
let pp ppf t = if t = never then Fmt.pf ppf "never" else Fmt.pf ppf "%Lu" t
end
module Timestamp = struct
@ -148,4 +152,6 @@ module Timestamp = struct
Jsont.Object.map ~kind:"Timestamp" Fun.id
|> Jsont.Object.mem "t_s" jsont ~enc:Fun.id
|> Jsont.Object.finish
let pp ppf t = if t = never then Fmt.pf ppf "never" else Fmt.pf ppf "%Lu" t
end