This is a preliminary release of OCaml bindings for the GNU SASL library. They are written using Ctypes.
-
Install
libgsasl
. If you are using OS X with Homebrew, this is as simple as typingbrew install gsasl
-
Install with OPAM.
opam install gsasl
-
To see if it is working, you can try it out in the
ocaml
toplevel:# #use "topfind";; - : unit = () # #require "gsasl";; # let s = Gsasl.base64_to "Hello, World!";; val s : string = "SGVsbG8sIFdvcmxkIQ==" # Gsasl.base64_from s;; - : string = "Hello, World!" # let ctx = Gsasl.init ();; val ctx : Gsasl.context = <abstr> # Gsasl.client_mechlist ctx;; - : string list = ["GSSAPI"; "OPENID20"; "SAML20"; "SCRAM-SHA-1"; "CRAM-MD5"; "DIGEST-MD5"; "SECURID"; "PLAIN"; "LOGIN"; "EXTERNAL"; "ANONYMOUS"]
-
Read the documentation in
lib/gsasl.mli
.
Comments, bug reports and feature requests are very welcome: [email protected].