package awa

  1. Overview
  2. Docs
val version_banner : string
val max_pkt_len : int
val max_len : int
val channel_win_len : int32
val channel_win_adj_threshold : int32
val channel_max_pkt_len : int32
val max_channels : int
val min_dh : int32
val n : int32
val max_dh : int32
val guard_sshlen : int -> (unit, string) Stdlib.result
val guard_sshlen_exn : int -> unit
type message_id =
  1. | MSG_DISCONNECT
  2. | MSG_IGNORE
  3. | MSG_UNIMPLEMENTED
  4. | MSG_DEBUG
  5. | MSG_SERVICE_REQUEST
  6. | MSG_SERVICE_ACCEPT
  7. | MSG_EXT_INFO
  8. | MSG_KEXINIT
  9. | MSG_NEWKEYS
  10. | MSG_KEX_0
  11. | MSG_KEX_1
  12. | MSG_KEX_2
  13. | MSG_KEX_3
  14. | MSG_KEX_4
  15. | MSG_USERAUTH_REQUEST
  16. | MSG_USERAUTH_FAILURE
  17. | MSG_USERAUTH_SUCCESS
  18. | MSG_USERAUTH_BANNER
  19. | MSG_USERAUTH_1
  20. | MSG_USERAUTH_2
  21. | MSG_GLOBAL_REQUEST
  22. | MSG_REQUEST_SUCCESS
  23. | MSG_REQUEST_FAILURE
  24. | MSG_CHANNEL_OPEN
  25. | MSG_CHANNEL_OPEN_CONFIRMATION
  26. | MSG_CHANNEL_OPEN_FAILURE
  27. | MSG_CHANNEL_WINDOW_ADJUST
  28. | MSG_CHANNEL_DATA
  29. | MSG_CHANNEL_EXTENDED_DATA
  30. | MSG_CHANNEL_EOF
  31. | MSG_CHANNEL_CLOSE
  32. | MSG_CHANNEL_REQUEST
  33. | MSG_CHANNEL_SUCCESS
  34. | MSG_CHANNEL_FAILURE
  35. | MSG_VERSION
val message_id_to_int : message_id -> int
val int_to_message_id : int -> message_id option
type kexinit = {
  1. cookie : Cstruct.t;
  2. kex_algs : string list;
  3. ext_info : [ `Ext_info_c | `Ext_info_s ] option;
  4. server_host_key_algs : string list;
  5. encryption_algs_ctos : string list;
  6. encryption_algs_stoc : string list;
  7. mac_algs_ctos : string list;
  8. mac_algs_stoc : string list;
  9. compression_algs_ctos : string list;
  10. compression_algs_stoc : string list;
  11. languages_ctos : string list;
  12. languages_stoc : string list;
  13. first_kex_packet_follows : bool;
  14. rawkex : Cstruct.t;
}
val pp_kexinit : Stdlib.Format.formatter -> kexinit -> unit
type extension =
  1. | Extension of {
    1. name : string;
    2. value : string;
    }
val pp_extension : Stdlib.Format.formatter -> extension -> unit
type disconnect_code =
  1. | DISCONNECT_HOST_NOT_ALLOWED_TO_CONNECT
  2. | DISCONNECT_PROTOCOL_ERROR
  3. | DISCONNECT_KEY_EXCHANGE_FAILED
  4. | DISCONNECT_RESERVED
  5. | DISCONNECT_MAC_ERROR
  6. | DISCONNECT_COMPRESSION_ERROR
  7. | DISCONNECT_SERVICE_NOT_AVAILABLE
  8. | DISCONNECT_PROTOCOL_VERSION_NOT_SUPPORTED
  9. | DISCONNECT_HOST_KEY_NOT_VERIFIABLE
  10. | DISCONNECT_CONNECTION_LOST
  11. | DISCONNECT_BY_APPLICATION
  12. | DISCONNECT_TOO_MANY_CONNECTIONS
  13. | DISCONNECT_AUTH_CANCELLED_BY_USER
  14. | DISCONNECT_NO_MORE_AUTH_METHODS_AVAILABLE
  15. | DISCONNECT_ILLEGAL_USER_NAME
val disconnect_code_to_int : disconnect_code -> int32
val int_to_disconnect_code : int32 -> disconnect_code
val disconnect_code_to_string : disconnect_code -> string
type channel_open_code =
  1. | OPEN_ADMINISTRATIVELY_PROHIBITED
  2. | OPEN_CONNECT_FAILED
  3. | OPEN_UNKNOWN_CHANNEL_TYPE
  4. | OPEN_RESOURCE_SHORTAGE
val channel_open_code_to_int : channel_open_code -> int32
val int_to_channel_open_code : int32 -> channel_open_code option
type mpint = Z.t
type global_request =
  1. | Tcpip_forward of string * int32
  2. | Cancel_tcpip_forward of string * int32
  3. | Unknown_request of string
type channel_request =
  1. | Pty_req of string * int32 * int32 * int32 * int32 * string
  2. | X11_req of bool * string * string * int32
  3. | Env of string * string
  4. | Shell
  5. | Exec of string
  6. | Subsystem of string
  7. | Window_change of int32 * int32 * int32 * int32
  8. | Xon_xoff of bool
  9. | Signal of string
  10. | Exit_status of int32
  11. | Exit_signal of string * bool * string * string
  12. | Raw_data of Cstruct.t
type channel_open =
  1. | Session
  2. | X11 of string * int32
  3. | Forwarded_tcpip of string * int32 * string * int32
  4. | Direct_tcpip of string * int32 * string * int32
  5. | Raw_data of Cstruct.t
type password = string
type auth_method =
  1. | Pubkey of string * Cstruct.t * (string * Cstruct.t) option
  2. | Password of password * password option
  3. | Keyboard_interactive of string option * string list
  4. | Authnone
val pp_auth_method : Stdlib.Format.formatter -> auth_method -> unit
val opt_eq : ('a -> 'b -> bool) -> 'a option -> 'b option -> bool
val auth_method_equal : auth_method -> auth_method -> bool
type message =
  1. | Msg_disconnect of disconnect_code * string * string
  2. | Msg_ignore of string
  3. | Msg_unimplemented of int32
  4. | Msg_debug of bool * string * string
  5. | Msg_service_request of string
  6. | Msg_service_accept of string
  7. | Msg_kexinit of kexinit
  8. | Msg_ext_info of extension list
  9. | Msg_newkeys
  10. | Msg_kexdh_reply of Hostkey.pub * mpint * Hostkey.alg * Cstruct.t
  11. | Msg_kexdh_init of mpint
  12. | Msg_kexecdh_reply of Hostkey.pub * mpint * Hostkey.alg * Cstruct.t
  13. | Msg_kexecdh_init of mpint
  14. | Msg_kexdh_gex_request of int32 * int32 * int32
  15. | Msg_kexdh_gex_group of mpint * mpint
  16. | Msg_kexdh_gex_init of mpint
  17. | Msg_kexdh_gex_reply of Hostkey.pub * mpint * Hostkey.alg * Cstruct.t
  18. | Msg_kex of message_id * Cstruct.t
  19. | Msg_userauth_request of string * string * auth_method
  20. | Msg_userauth_failure of string list * bool
  21. | Msg_userauth_success
  22. | Msg_userauth_banner of string * string
  23. | Msg_userauth_1 of Cstruct.t
  24. | Msg_userauth_2 of Cstruct.t
  25. | Msg_userauth_pk_ok of Hostkey.pub
  26. | Msg_userauth_info_request of string * string * string * (string * bool) list
  27. | Msg_userauth_info_response of password list
  28. | Msg_global_request of string * bool * global_request
  29. | Msg_request_success of Cstruct.t option
  30. | Msg_request_failure
  31. | Msg_channel_open of int32 * int32 * int32 * channel_open
  32. | Msg_channel_open_confirmation of int32 * int32 * int32 * int32 * Cstruct.t
  33. | Msg_channel_open_failure of int32 * int32 * string * string
  34. | Msg_channel_window_adjust of int32 * int32
  35. | Msg_channel_data of int32 * Cstruct.t
  36. | Msg_channel_extended_data of int32 * int32 * Cstruct.t
  37. | Msg_channel_eof of int32
  38. | Msg_channel_close of int32
  39. | Msg_channel_request of int32 * bool * channel_request
  40. | Msg_channel_success of int32
  41. | Msg_channel_failure of int32
  42. | Msg_version of string
val message_to_id : message -> message_id
val pp_lang : Stdlib.Format.formatter -> string -> unit
val pp_message : Stdlib.Format.formatter -> message -> unit
val message_to_int : message -> int
val disconnect_msg : disconnect_code -> string -> message
OCaml

Innovation. Community. Security.