···1212 | Error e -> Alcotest.failf "%a" Client.pp_error e
13131414(* Find the first occurrence of [sub] in [s]. *)
1515-let index s sub = Astring.String.find_sub ~sub s
1515+let index s sub =
1616+ Re.exec_opt Re.(compile (str sub)) s
1717+ |> Option.map (fun g -> Re.Group.start g 0)
16181719(* The whole chain verifies: this passes only if our canonical JSON of each
1820 [signed] object reproduces what python-tuf signed, and our Ed25519 check