1//
2// Copyright (c) 2016-2019 Vinnie Falco (vinnie dot falco at gmail dot com)
3//
4// Distributed under the Boost Software License, Version 1.0. (See accompanying
5// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
6//
7// Official repository: https://github.com/boostorg/beast
8//
9
10#ifndef BOOST_BEAST_WEBSOCKET_DETAIL_HYBI13_HPP
11#define BOOST_BEAST_WEBSOCKET_DETAIL_HYBI13_HPP
12
13#include <boost/beast/core/static_string.hpp>
14#include <boost/beast/core/string.hpp>
15#include <boost/beast/core/detail/base64.hpp>
16#include <cstdint>
17
18namespace boost {
19namespace beast {
20namespace websocket {
21namespace detail {
22
23using sec_ws_key_type = static_string<
24 beast::detail::base64::encoded_size(n: 16)>;
25
26using sec_ws_accept_type = static_string<
27 beast::detail::base64::encoded_size(n: 20)>;
28
29BOOST_BEAST_DECL
30void
31make_sec_ws_key(sec_ws_key_type& key);
32
33BOOST_BEAST_DECL
34void
35make_sec_ws_accept(
36 sec_ws_accept_type& accept,
37 string_view key);
38
39} // detail
40} // websocket
41} // beast
42} // boost
43
44#if BOOST_BEAST_HEADER_ONLY
45#include <boost/beast/websocket/detail/hybi13.ipp>
46#endif
47
48#endif
49

source code of boost/libs/beast/include/boost/beast/websocket/detail/hybi13.hpp