summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPhilipp Gesang <phg@phi-gamma.net>2018-10-27 22:31:51 +0200
committerPhilipp Gesang <phg@phi-gamma.net>2018-10-30 01:15:03 +0100
commit8d1269767de9268db630187fc9da9b58c49a0745 (patch)
tree13b60b560cbe0eb5fc8e3b87da1a5c76d0425dcb
parenta626ab534224cc244d58259e622b9a59703223f6 (diff)
downloadocaml-sid-8d1269767de9268db630187fc9da9b58c49a0745.tar.gz
sid: define more constant authorities from MS-DTYP
-rw-r--r--sid.ml16
-rw-r--r--sid.mli8
2 files changed, 18 insertions, 6 deletions
diff --git a/sid.ml b/sid.ml
index ddfb8e1..ece361d 100644
--- a/sid.ml
+++ b/sid.ml
@@ -218,11 +218,17 @@ module WellKnown = struct
let elite = create_unsafe [| U32.of_int 3 ; U32.of_int 3; U32.of_int 7 |] U64.one
module Prefix = struct
- let security_null_sid_authority ?(sa=[||]) () = create ~sa (U64.of_int 0)
- let security_world_sid_authority ?(sa=[||]) () = create ~sa (U64.of_int 1)
- let security_local_sid_authority ?(sa=[||]) () = create ~sa (U64.of_int 2)
- let security_creator_sid_authority ?(sa=[||]) () = create ~sa (U64.of_int 3)
- let security_nt_authority ?(sa=[||]) () = create ~sa (U64.of_int 5)
+ type toplevel_auth = ?sa:sub_auths -> unit -> sid
+
+ let security_null_sid_authority ?(sa=[||]) () = create_unsafe sa (U64.of_int 0x00)
+ let security_world_sid_authority ?(sa=[||]) () = create_unsafe sa (U64.of_int 0x01)
+ let security_local_sid_authority ?(sa=[||]) () = create_unsafe sa (U64.of_int 0x02)
+ let security_creator_sid_authority ?(sa=[||]) () = create_unsafe sa (U64.of_int 0x03)
+ let security_nt_authority ?(sa=[||]) () = create_unsafe sa (U64.of_int 0x05)
+ let security_app_package_authority ?(sa=[||]) () = create_unsafe sa (U64.of_int 0x0f)
+ let security_mandatory_label_authority ?(sa=[||]) () = create_unsafe sa (U64.of_int 0x10)
+ let security_scoped_policy_id_authority ?(sa=[||]) () = create_unsafe sa (U64.of_int 0x11)
+ let security_authentication_authority ?(sa=[||]) () = create_unsafe sa (U64.of_int 0x12)
end
end
diff --git a/sid.mli b/sid.mli
index 12d31a9..f7fcbec 100644
--- a/sid.mli
+++ b/sid.mli
@@ -32,11 +32,17 @@ module WellKnown :
module Prefix :
sig
- val security_null_sid_authority : ?sa:sub_auths -> unit -> t
+ type toplevel_auth = ?sa:sub_auths -> unit -> t
+
+ val security_null_sid_authority : toplevel_auth
val security_world_sid_authority : ?sa:sub_auths -> unit -> t
val security_local_sid_authority : ?sa:sub_auths -> unit -> t
val security_creator_sid_authority : ?sa:sub_auths -> unit -> t
val security_nt_authority : ?sa:sub_auths -> unit -> t
+ val security_app_package_authority : ?sa:sub_auths -> unit -> t
+ val security_mandatory_label_authority : ?sa:sub_auths -> unit -> t
+ val security_scoped_policy_id_authority : ?sa:sub_auths -> unit -> t
+ val security_authentication_authority : ?sa:sub_auths -> unit -> t
end
end