diff --git a/websocketpp/transport/asio/security/none.hpp b/websocketpp/transport/asio/security/none.hpp index 96bf868589..48d258fc49 100644 --- a/websocketpp/transport/asio/security/none.hpp +++ b/websocketpp/transport/asio/security/none.hpp @@ -39,8 +39,11 @@ namespace websocketpp { namespace transport { namespace asio { +/// A socket policy for the asio transport that implements a plain, unencrypted +/// socket namespace basic_socket { +/// The signature of the socket init handler for this socket policy typedef lib::function socket_init_handler; @@ -60,8 +63,10 @@ public: typedef boost::asio::io_service* io_service_ptr; /// Type of a pointer to the ASIO io_service strand being used typedef lib::shared_ptr strand_ptr; + /// Type of the ASIO socket being used + typedef boost::asio::ip::tcp::socket socket_type; /// Type of a shared pointer to the socket being used. - typedef lib::shared_ptr socket_ptr; + typedef lib::shared_ptr socket_ptr; explicit connection() : m_state(UNINITIALIZED) { //std::cout << "transport::asio::basic_socket::connection constructor" @@ -229,7 +234,7 @@ protected: lib::error_code get_ec() const { return lib::error_code(); } - + /// Translate any security policy specific information about an error code /** * Translate_ec takes a boost error code and attempts to convert its value diff --git a/websocketpp/transport/asio/security/tls.hpp b/websocketpp/transport/asio/security/tls.hpp index 9b884ceef7..7d69a88427 100644 --- a/websocketpp/transport/asio/security/tls.hpp +++ b/websocketpp/transport/asio/security/tls.hpp @@ -43,10 +43,14 @@ namespace websocketpp { namespace transport { namespace asio { +/// A socket policy for the asio transport that implements a TLS encrypted +/// socket by wrapping with an asio::ssl::stream namespace tls_socket { +/// The signature of the socket_init_handler for this socket policy typedef lib::function&)> socket_init_handler; +/// The signature of the tls_init_handler for this socket policy typedef lib::function(connection_hdl)> tls_init_handler;