diff --git a/basis/io/sockets/secure/openssl/openssl-docs.factor b/basis/io/sockets/secure/openssl/openssl-docs.factor index 0ff6903fe6..f917621d17 100644 --- a/basis/io/sockets/secure/openssl/openssl-docs.factor +++ b/basis/io/sockets/secure/openssl/openssl-docs.factor @@ -1,4 +1,5 @@ -USING: help.markup help.syntax kernel strings sequences ; +USING: help.markup help.syntax io.files io.buffers kernel openssl.libssl +strings sequences ; IN: io.sockets.secure.openssl HELP: subject-name @@ -18,3 +19,30 @@ HELP: subject-names-match? HELP: alternative-dns-names { $values { "certificate" "an SSL peer certificate" } { "dns-names" sequence } } { $description "Alternative subject names for the certificate." } ; + +HELP: do-ssl-connect +{ $values { "ssl-handle" ssl-handle } } +{ $description "Connects the SSL handle to the remote server. Blocks until the connection is established or an error is thrown." } ; + +HELP: do-ssl-read +{ $values + { "buffer" buffer } + { "ssl" SSL } + { "event/f" "f or a symbol indicating the desired operation" } } +{ $description "Reads from the ssl connection to the buffer." } ; + +HELP: do-ssl-write +{ $values + { "buffer" buffer } + { "ssl" SSL } + { "event/f" "f or a symbol indicating the desired operation" } } +{ $description "Writes from the buffer to the ssl connection." } ; + +HELP: check-ssl-error +{ $values + { "ssl" SSL } + { "ret" "error code returned by an SSL function" } + { "exra-cases/f" "f or an assoc of error codes and quotations" } + { "event/f" "f or a symbol indicating the desired operation" } +} +{ $description "Checks if the last SSL function returned successfully or not. If so, returns " { $link f } " or a symbol, " { $link +input+ } " or " { $link +output+ } ", that indicates the socket operation required by libssl." } ;