This commit is contained in:
parent
56b665178a
commit
071f5704fe
1 changed files with 4 additions and 4 deletions
|
|
@ -217,7 +217,8 @@ module GNUNET_RsaPublicKey = struct
|
||||||
e: Z.t;
|
e: Z.t;
|
||||||
}
|
}
|
||||||
|
|
||||||
(* need to strip leading zeros or something? *)
|
(* todo: need to strip leading zeros or something? *)
|
||||||
|
(* Z.to_bits is in little endian but we need it in big endian *)
|
||||||
let z_to_bigendian_bits v =
|
let z_to_bigendian_bits v =
|
||||||
let s = Z.to_bits v in
|
let s = Z.to_bits v in
|
||||||
let len = String.length s in
|
let len = String.length s in
|
||||||
|
|
@ -240,9 +241,8 @@ module GNUNET_RsaPublicKey = struct
|
||||||
{ header; n; e })
|
{ header; n; e })
|
||||||
|+ field header_bin (fun t -> t.header)
|
|+ field header_bin (fun t -> t.header)
|
||||||
(* TODO
|
(* TODO
|
||||||
Z.to_bits is in little endian but we need it in big endian *)
|
here it should not be [cstring] but [bytes t.header.n_len]
|
||||||
(* TODO
|
-> just parse this without Bin *)
|
||||||
here it should not be [cstring] but [bytes t.header.n_len] *)
|
|
||||||
|+ field cstring (fun t -> z_to_bigendian_bits t.n)
|
|+ field cstring (fun t -> z_to_bigendian_bits t.n)
|
||||||
|+ field cstring (fun t -> z_to_bigendian_bits t.e)
|
|+ field cstring (fun t -> z_to_bigendian_bits t.e)
|
||||||
|> sealr
|
|> sealr
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue