Ocamlnet 3 Reference Manual : Netgssapi

`sig
type oid = int array
type oid_set = Netgssapi.oid list
type credential = < otype : [ `Credential ] >
type context = < otype : [ `Context ]; valid : bool >
type token = string
type interprocess_token = string
type calling_error =
[ `Bad_structure | `Inaccessible_read | `Inaccessible_write | `None ]
type routine_error =
[ `Bad_QOP
| `Bad_bindings
| `Bad_mech
| `Bad_mic
| `Bad_name
| `Bad_nametype
| `Bad_status
| `Context_expired
| `Credentials_expired
| `Defective_credential
| `Defective_token
| `Duplicate_element
| `Failure
| `Name_not_mn
| `No_context
| `No_cred
| `None
| `Unauthorized
| `Unavailable ]
type suppl_status =
[ `Continue_needed
| `Duplicate_token
| `Gap_token
| `Old_token
| `Unseq_token ]
type major_status =
Netgssapi.calling_error * Netgssapi.routine_error *
Netgssapi.suppl_status list
type minor_status = int32
type name = < otype : [ `Name ] >
type address =
[ `Inet of Unix.inet_addr
| `Local of string
| `Nulladdr
| `Other of int32 * string
| `Unspecified of string ]
type channel_bindings = Netgssapi.address * Netgssapi.address * string
type cred_usage = [ `Accept | `Both | `Initiate ]
type qop = < otype : [ `QOP ] >
type message = Xdr_mstring.mstring list
type ret_flag =
[ `Anon_flag
| `Conf_flag
| `Deleg_flag
| `Integ_flag
| `Mutual_flag
| `Prot_ready_flag
| `Replay_flag
| `Sequence_flag
| `Trans_flag ]
type req_flag =
[ `Anon_flag
| `Conf_flag
| `Deleg_flag
| `Integ_flag
| `Mutual_flag
| `Replay_flag
| `Sequence_flag ]
class type gss_api =
object
method accept_sec_context :
context:Netgssapi.context option ->
acceptor_cred:Netgssapi.credential ->
input_token:Netgssapi.token ->
chan_bindings:Netgssapi.channel_bindings option ->
out:(src_name:Netgssapi.name ->
mech_type:Netgssapi.oid ->
output_context:Netgssapi.context option ->
output_token:Netgssapi.token ->
ret_flags:Netgssapi.ret_flag list ->
time_rec:[ `Indefinite | `This of float ] ->
delegated_cred:Netgssapi.credential ->
minor_status:Netgssapi.minor_status ->
major_status:Netgssapi.major_status -> unit -> 't) ->
unit -> 't
method acquire_cred :
desired_name:Netgssapi.name ->
time_req:[ `Indefinite | `None | `This of float ] ->
desired_mechs:Netgssapi.oid_set ->
cred_usage:Netgssapi.cred_usage ->
out:(cred:Netgssapi.credential ->
actual_mechs:Netgssapi.oid_set ->
time_rec:[ `Indefinite | `This of float ] ->
minor_status:Netgssapi.minor_status ->
major_status:Netgssapi.major_status -> unit -> 't) ->
unit -> 't
method add_cred :
input_cred:Netgssapi.credential ->
desired_name:Netgssapi.name ->
desired_mech:Netgssapi.oid ->
cred_usage:Netgssapi.cred_usage ->
initiator_time_req:[ `Indefinite | `None | `This of float ] ->
acceptor_time_req:[ `Indefinite | `None | `This of float ] ->
out:(output_cred:Netgssapi.credential ->
actual_mechs:Netgssapi.oid_set ->
initiator_time_rec:[ `Indefinite | `This of float ] ->
acceptor_time_rec:[ `Indefinite | `This of float ] ->
minor_status:Netgssapi.minor_status ->
major_status:Netgssapi.major_status -> unit -> 't) ->
unit -> 't
method canonicalize_name :
input_name:Netgssapi.name ->
mech_type:Netgssapi.oid ->
out:(output_name:Netgssapi.name ->
minor_status:Netgssapi.minor_status ->
major_status:Netgssapi.major_status -> unit -> 't) ->
unit -> 't
method compare_name :
name1:Netgssapi.name ->
name2:Netgssapi.name ->
out:(name_equal:bool ->
minor_status:Netgssapi.minor_status ->
major_status:Netgssapi.major_status -> unit -> 't) ->
unit -> 't
method context_time :
context:Netgssapi.context ->
out:(time_rec:[ `Indefinite | `This of float ] ->
minor_status:Netgssapi.minor_status ->
major_status:Netgssapi.major_status -> unit -> 't) ->
unit -> 't
method delete_sec_context :
context:Netgssapi.context ->
out:(minor_status:Netgssapi.minor_status ->
major_status:Netgssapi.major_status -> unit -> 't) ->
unit -> 't
method display_minor_status :
minor_status:Netgssapi.minor_status ->
mech_type:Netgssapi.oid ->
out:(status_strings:string list ->
minor_status:Netgssapi.minor_status ->
major_status:Netgssapi.major_status -> unit -> 't) ->
unit -> 't
method display_name :
input_name:Netgssapi.name ->
out:(output_name:string ->
output_name_type:Netgssapi.oid ->
minor_status:Netgssapi.minor_status ->
major_status:Netgssapi.major_status -> unit -> 't) ->
unit -> 't
method export_name :
name:Netgssapi.name ->
out:(exported_name:string ->
minor_status:Netgssapi.minor_status ->
major_status:Netgssapi.major_status -> unit -> 't) ->
unit -> 't
method export_sec_context :
context:Netgssapi.context ->
out:(interprocess_token:Netgssapi.interprocess_token ->
minor_status:Netgssapi.minor_status ->
major_status:Netgssapi.major_status -> unit -> 't) ->
unit -> 't
method get_mic :
context:Netgssapi.context ->
qop_req:Netgssapi.qop option ->
message:Netgssapi.message ->
out:(msg_token:Netgssapi.token ->
minor_status:Netgssapi.minor_status ->
major_status:Netgssapi.major_status -> unit -> 't) ->
unit -> 't
method import_name :
input_name:string ->
input_name_type:Netgssapi.oid ->
out:(output_name:Netgssapi.name ->
minor_status:Netgssapi.minor_status ->
major_status:Netgssapi.major_status -> unit -> 't) ->
unit -> 't
method import_sec_context :
interprocess_token:Netgssapi.interprocess_token ->
out:(context:Netgssapi.context option ->
minor_status:Netgssapi.minor_status ->
major_status:Netgssapi.major_status -> unit -> 't) ->
unit -> 't
method indicate_mechs :
out:(mech_set:Netgssapi.oid_set ->
minor_status:Netgssapi.minor_status ->
major_status:Netgssapi.major_status -> unit -> 't) ->
unit -> 't
method init_sec_context :
initiator_cred:Netgssapi.credential ->
context:Netgssapi.context option ->
target_name:Netgssapi.name ->
mech_type:Netgssapi.oid ->
req_flags:Netgssapi.req_flag list ->
time_rec:float option ->
chan_bindings:Netgssapi.channel_bindings option ->
input_token:Netgssapi.token option ->
out:(actual_mech_type:Netgssapi.oid ->
output_context:Netgssapi.context option ->
output_token:Netgssapi.token ->
ret_flags:Netgssapi.ret_flag list ->
time_rec:[ `Indefinite | `This of float ] ->
minor_status:Netgssapi.minor_status ->
major_status:Netgssapi.major_status -> unit -> 't) ->
unit -> 't
method inquire_context :
context:Netgssapi.context ->
out:(src_name:Netgssapi.name ->
targ_name:Netgssapi.name ->
lifetime_req:[ `Indefinite | `This of float ] ->
mech_type:Netgssapi.oid ->
ctx_flags:Netgssapi.ret_flag list ->
locally_initiated:bool ->
is_open:bool ->
minor_status:Netgssapi.minor_status ->
major_status:Netgssapi.major_status -> unit -> 't) ->
unit -> 't
method inquire_cred :
cred:Netgssapi.credential ->
out:(name:Netgssapi.name ->
lifetime:[ `Indefinite | `This of float ] ->
cred_usage:Netgssapi.cred_usage ->
mechanisms:Netgssapi.oid_set ->
minor_status:Netgssapi.minor_status ->
major_status:Netgssapi.major_status -> unit -> 't) ->
unit -> 't
method inquire_cred_by_mech :
cred:Netgssapi.credential ->
mech_type:Netgssapi.oid ->
out:(name:Netgssapi.name ->
initiator_lifetime:[ `Indefinite | `This of float ] ->
acceptor_lifetime:[ `Indefinite | `This of float ] ->
cred_usage:Netgssapi.cred_usage ->
minor_status:Netgssapi.minor_status ->
major_status:Netgssapi.major_status -> unit -> 't) ->
unit -> 't
method inquire_mechs_for_name :
name:Netgssapi.name ->
out:(mech_types:Netgssapi.oid_set ->
minor_status:Netgssapi.minor_status ->
major_status:Netgssapi.major_status -> unit -> 't) ->
unit -> 't
method inquire_names_for_mech :
mechanism:Netgssapi.oid ->
out:(name_types:Netgssapi.oid_set ->
minor_status:Netgssapi.minor_status ->
major_status:Netgssapi.major_status -> unit -> 't) ->
unit -> 't
method no_credential : Netgssapi.credential
method no_name : Netgssapi.name
method process_context_token :
context:Netgssapi.context ->
token:Netgssapi.token ->
out:(minor_status:Netgssapi.minor_status ->
major_status:Netgssapi.major_status -> unit -> 't) ->
unit -> 't
method provider : string
method unwrap :
context:Netgssapi.context ->
input_message:Netgssapi.message ->
output_message_preferred_type:[ `Memory | `String ] ->
out:(output_message:Netgssapi.message ->
conf_state:bool ->
qop_state:Netgssapi.qop ->
minor_status:Netgssapi.minor_status ->
major_status:Netgssapi.major_status -> unit -> 't) ->
unit -> 't
method verify_mic :
context:Netgssapi.context ->
message:Netgssapi.message ->
token:Netgssapi.token ->
out:(qop_state:Netgssapi.qop ->
minor_status:Netgssapi.minor_status ->
major_status:Netgssapi.major_status -> unit -> 't) ->
unit -> 't
method wrap :
context:Netgssapi.context ->
conf_req:bool ->
qop_req:Netgssapi.qop option ->
input_message:Netgssapi.message ->
output_message_preferred_type:[ `Memory | `String ] ->
out:(conf_state:bool ->
output_message:Netgssapi.message ->
minor_status:Netgssapi.minor_status ->
major_status:Netgssapi.major_status -> unit -> 't) ->
unit -> 't
method wrap_size_limit :
context:Netgssapi.context ->
conf_req:bool ->
qop_req:Netgssapi.qop option ->
req_output_size:int ->
out:(max_input_size:int ->
minor_status:Netgssapi.minor_status ->
major_status:Netgssapi.major_status -> unit -> 't) ->
unit -> 't
end
val string_of_calling_error : Netgssapi.calling_error -> string
val string_of_routine_error : Netgssapi.routine_error -> string
val string_of_suppl_status : Netgssapi.suppl_status -> string
val string_of_major_status : Netgssapi.major_status -> string
val nt_hostbased_service : Netgssapi.oid
val nt_user_name : Netgssapi.oid
val nt_machine_uid_name : Netgssapi.oid
val nt_string_uid_name : Netgssapi.oid
val nt_anonymous : Netgssapi.oid
val nt_export_name : Netgssapi.oid
val parse_hostbased_service : string -> string * string
val oid_to_string : Netgssapi.oid -> string
val string_to_oid : string -> Netgssapi.oid
val oid_to_der : Netgssapi.oid -> string
val der_to_oid : string -> int Pervasives.ref -> Netgssapi.oid
val wire_encode_token : Netgssapi.oid -> Netgssapi.token -> string
val wire_decode_token :
string -> int Pervasives.ref -> Netgssapi.oid * Netgssapi.token
val encode_exported_name : Netgssapi.oid -> string -> string
val decode_exported_name :
string -> int Pervasives.ref -> Netgssapi.oid * string
val create_mic_token :
sent_by_acceptor:bool ->
acceptor_subkey:bool ->
sequence_number:int64 ->
get_mic:(Netgssapi.message -> string) ->
message:Netgssapi.message -> string
val parse_mic_token_header : string -> bool * bool * int64
val verify_mic_token :
get_mic:(Netgssapi.message -> string) ->
message:Netgssapi.message -> token:string -> bool
val create_wrap_token_conf :
sent_by_acceptor:bool ->
acceptor_subkey:bool ->
sequence_number:int64 ->
get_ec:(int -> int) ->
encrypt_and_sign:(Netgssapi.message -> Netgssapi.message) ->
message:Netgssapi.message -> Netgssapi.message
val parse_wrap_token_header :
Netgssapi.message -> bool * bool * bool * int64
val unwrap_wrap_token_conf :
decrypt_and_verify:(Netgssapi.message -> Netgssapi.message) ->
token:Netgssapi.message -> Netgssapi.message
end`