├── .codecov.yml ├── .drone.star ├── .drone ├── drone.bat └── drone.sh ├── .gitattributes ├── .github ├── ISSUE_TEMPLATE.md └── workflows │ ├── build.yml │ └── fuzz.yml ├── .gitignore ├── CHANGELOG.md ├── CMakeLists.txt ├── CONTRIBUTING.md ├── LICENSE_1_0.txt ├── README.md ├── build.jam ├── cmake └── toolchains │ ├── clang.cmake │ ├── common.cmake │ ├── gcc.cmake │ └── msvc.cmake ├── doc ├── .gitignore ├── Jamfile ├── images │ ├── message.png │ └── readme2.png ├── qbk │ ├── 01_intro │ │ ├── 1_quick_look.qbk │ │ ├── 1a_bishop_fox.qbk │ │ ├── 1b_autobahn.qbk │ │ └── _intro.qbk │ ├── 02_examples │ │ └── _examples.qbk │ ├── 03_core │ │ ├── 10_ssl_tls_shutdown.qbk │ │ ├── 1_refresher.qbk │ │ ├── 2_streams.qbk │ │ ├── 3_timeouts.qbk │ │ ├── 4__layers.qbk │ │ ├── 5_buffers.qbk │ │ ├── 6_files.qbk │ │ ├── 7_composed.qbk │ │ ├── 7a_echo.qbk │ │ ├── 7b_detect_ssl.qbk │ │ ├── 8_conf_macros.qbk │ │ ├── 9_ssl_tls_certificate.qbk │ │ └── _core.qbk │ ├── 04_http │ │ ├── 01_primer.qbk │ │ ├── 02_message.qbk │ │ ├── 03_streams.qbk │ │ ├── 04_serializer_streams.qbk │ │ ├── 05_parser_streams.qbk │ │ ├── 06_serializer_buffers.qbk │ │ ├── 07_parser_buffers.qbk │ │ ├── 08_chunked_encoding.qbk │ │ ├── 09_custom_body.qbk │ │ ├── 10_custom_parsers.qbk │ │ └── _http.qbk │ ├── 05_http_examples │ │ └── _http_examples.qbk │ ├── 06_websocket │ │ ├── 01_connecting.qbk │ │ ├── 02_handshaking.qbk │ │ ├── 03_decorator.qbk │ │ ├── 04_messages.qbk │ │ ├── 05_control_frames.qbk │ │ ├── 06_timeouts.qbk │ │ ├── 07_teardown.qbk │ │ ├── 08_notes.qbk │ │ └── _websocket.qbk │ ├── 07_concepts │ │ ├── Body.qbk │ │ ├── BodyReader.qbk │ │ ├── BodyWriter.qbk │ │ ├── BufferSequence.qbk │ │ ├── BuffersGenerator.qbk │ │ ├── DynamicBuffer.qbk │ │ ├── Fields.qbk │ │ ├── FieldsWriter.qbk │ │ ├── File.qbk │ │ ├── RatePolicy.qbk │ │ ├── Streams.qbk │ │ └── _concepts.qbk │ ├── 08_design │ │ ├── 1_http_message.qbk │ │ ├── 2_http_comparison.qbk │ │ ├── 3_websocket_zaphoyd.qbk │ │ ├── 4_faq.qbk │ │ └── _design.qbk │ ├── index.xml │ ├── main.qbk │ ├── quickref.xml │ ├── release_notes.qbk │ └── version.qbk └── xsl │ └── custom-overrides.xsl ├── example ├── CMakeLists.txt ├── Jamfile ├── advanced │ ├── CMakeLists.txt │ ├── Jamfile │ ├── server-flex-awaitable │ │ ├── CMakeLists.txt │ │ ├── Jamfile │ │ └── advanced_server_flex_awaitable.cpp │ ├── server-flex │ │ ├── CMakeLists.txt │ │ ├── Jamfile │ │ └── advanced_server_flex.cpp │ └── server │ │ ├── CMakeLists.txt │ │ ├── Jamfile │ │ └── advanced_server.cpp ├── common │ ├── root_certificates.hpp │ └── server_certificate.hpp ├── doc │ ├── CMakeLists.txt │ ├── Jamfile │ ├── http_examples.hpp │ └── ssl │ │ ├── CMakeLists.txt │ │ ├── Jamfile │ │ ├── client.cpp │ │ └── server.cpp ├── echo-op │ ├── CMakeLists.txt │ ├── Jamfile │ └── echo_op.cpp ├── http │ ├── CMakeLists.txt │ ├── Jamfile │ ├── client │ │ ├── CMakeLists.txt │ │ ├── Jamfile │ │ ├── async-local │ │ │ ├── CMakeLists.txt │ │ │ ├── Jamfile │ │ │ └── http_client_async_local.cpp │ │ ├── async-ssl-system-executor │ │ │ ├── CMakeLists.txt │ │ │ ├── Jamfile │ │ │ └── http_client_async_ssl_system_executor.cpp │ │ ├── async-ssl │ │ │ ├── CMakeLists.txt │ │ │ ├── Jamfile │ │ │ └── http_client_async_ssl.cpp │ │ ├── async │ │ │ ├── CMakeLists.txt │ │ │ ├── Jamfile │ │ │ └── http_client_async.cpp │ │ ├── awaitable-ssl │ │ │ ├── CMakeLists.txt │ │ │ ├── Jamfile │ │ │ └── http_client_awaitable_ssl.cpp │ │ ├── awaitable │ │ │ ├── CMakeLists.txt │ │ │ ├── Jamfile │ │ │ └── http_client_awaitable.cpp │ │ ├── body │ │ │ ├── CMakeLists.txt │ │ │ ├── Jamfile │ │ │ ├── json_body.hpp │ │ │ └── json_client.cpp │ │ ├── coro-ssl │ │ │ ├── CMakeLists.txt │ │ │ ├── Jamfile │ │ │ └── http_client_coro_ssl.cpp │ │ ├── coro │ │ │ ├── CMakeLists.txt │ │ │ ├── Jamfile │ │ │ └── http_client_coro.cpp │ │ ├── crawl │ │ │ ├── CMakeLists.txt │ │ │ ├── Jamfile │ │ │ ├── http_crawl.cpp │ │ │ ├── urls_large_data.cpp │ │ │ └── urls_large_data.hpp │ │ ├── methods │ │ │ ├── CMakeLists.txt │ │ │ ├── Jamfile │ │ │ └── http_client_methods.cpp │ │ ├── sync-ssl │ │ │ ├── CMakeLists.txt │ │ │ ├── Jamfile │ │ │ └── http_client_sync_ssl.cpp │ │ └── sync │ │ │ ├── CMakeLists.txt │ │ │ ├── Jamfile │ │ │ └── http_client_sync.cpp │ └── server │ │ ├── CMakeLists.txt │ │ ├── Jamfile │ │ ├── async-local │ │ ├── CMakeLists.txt │ │ ├── Jamfile │ │ └── http_server_async_local.cpp │ │ ├── async-ssl │ │ ├── CMakeLists.txt │ │ ├── Jamfile │ │ └── http_server_async_ssl.cpp │ │ ├── async │ │ ├── CMakeLists.txt │ │ ├── Jamfile │ │ └── http_server_async.cpp │ │ ├── awaitable │ │ ├── CMakeLists.txt │ │ ├── Jamfile │ │ └── http_server_awaitable.cpp │ │ ├── coro-ssl │ │ ├── CMakeLists.txt │ │ ├── Jamfile │ │ └── http_server_coro_ssl.cpp │ │ ├── coro │ │ ├── CMakeLists.txt │ │ ├── Jamfile │ │ └── http_server_coro.cpp │ │ ├── fast │ │ ├── CMakeLists.txt │ │ ├── Jamfile │ │ ├── fields_alloc.hpp │ │ └── http_server_fast.cpp │ │ ├── flex │ │ ├── CMakeLists.txt │ │ ├── Jamfile │ │ └── http_server_flex.cpp │ │ ├── small │ │ ├── CMakeLists.txt │ │ ├── Jamfile │ │ └── http_server_small.cpp │ │ ├── stackless-ssl │ │ ├── CMakeLists.txt │ │ ├── Jamfile │ │ └── http_server_stackless_ssl.cpp │ │ ├── stackless │ │ ├── CMakeLists.txt │ │ ├── Jamfile │ │ └── http_server_stackless.cpp │ │ ├── sync-ssl │ │ ├── CMakeLists.txt │ │ ├── Jamfile │ │ └── http_server_sync_ssl.cpp │ │ └── sync │ │ ├── CMakeLists.txt │ │ ├── Jamfile │ │ └── http_server_sync.cpp └── websocket │ ├── CMakeLists.txt │ ├── Jamfile │ ├── client │ ├── CMakeLists.txt │ ├── Jamfile │ ├── async-local │ │ ├── CMakeLists.txt │ │ ├── Jamfile │ │ └── websocket_client_async_local.cpp │ ├── async-ssl-system-executor │ │ ├── CMakeLists.txt │ │ ├── Jamfile │ │ └── websocket_client_async_ssl_system_executor.cpp │ ├── async-ssl │ │ ├── CMakeLists.txt │ │ ├── Jamfile │ │ └── websocket_client_async_ssl.cpp │ ├── async │ │ ├── CMakeLists.txt │ │ ├── Jamfile │ │ └── websocket_client_async.cpp │ ├── awaitable │ │ ├── CMakeLists.txt │ │ ├── Jamfile │ │ └── websocket_client_awaitable.cpp │ ├── coro-ssl │ │ ├── CMakeLists.txt │ │ ├── Jamfile │ │ └── websocket_client_coro_ssl.cpp │ ├── coro │ │ ├── CMakeLists.txt │ │ ├── Jamfile │ │ └── websocket_client_coro.cpp │ ├── sync-ssl │ │ ├── CMakeLists.txt │ │ ├── Jamfile │ │ └── websocket_client_sync_ssl.cpp │ └── sync │ │ ├── CMakeLists.txt │ │ ├── Jamfile │ │ └── websocket_client_sync.cpp │ └── server │ ├── CMakeLists.txt │ ├── Jamfile │ ├── async-local │ ├── CMakeLists.txt │ ├── Jamfile │ └── websocket_server_async_local.cpp │ ├── async-ssl │ ├── CMakeLists.txt │ ├── Jamfile │ └── websocket_server_async_ssl.cpp │ ├── async │ ├── CMakeLists.txt │ ├── Jamfile │ └── websocket_server_async.cpp │ ├── awaitable │ ├── CMakeLists.txt │ ├── Jamfile │ └── websocket_server_awaitable.cpp │ ├── chat-multi │ ├── CMakeLists.txt │ ├── Jamfile │ ├── beast.hpp │ ├── chat_client.html │ ├── http_session.cpp │ ├── http_session.hpp │ ├── listener.cpp │ ├── listener.hpp │ ├── main.cpp │ ├── net.hpp │ ├── shared_state.cpp │ ├── shared_state.hpp │ ├── websocket_session.cpp │ └── websocket_session.hpp │ ├── coro-ssl │ ├── CMakeLists.txt │ ├── Jamfile │ └── websocket_server_coro_ssl.cpp │ ├── coro │ ├── CMakeLists.txt │ ├── Jamfile │ └── websocket_server_coro.cpp │ ├── fast │ ├── CMakeLists.txt │ ├── Jamfile │ └── websocket_server_fast.cpp │ ├── stackless-ssl │ ├── CMakeLists.txt │ ├── Jamfile │ └── websocket_server_stackless_ssl.cpp │ ├── stackless │ ├── CMakeLists.txt │ ├── Jamfile │ └── websocket_server_stackless.cpp │ ├── sync-ssl │ ├── CMakeLists.txt │ ├── Jamfile │ └── websocket_server_sync_ssl.cpp │ └── sync │ ├── CMakeLists.txt │ ├── Jamfile │ └── websocket_server_sync.cpp ├── include └── boost │ ├── beast.hpp │ └── beast │ ├── _experimental │ ├── http │ │ ├── icy_stream.hpp │ │ └── impl │ │ │ └── icy_stream.hpp │ ├── test │ │ ├── detail │ │ │ ├── stream_state.hpp │ │ │ └── stream_state.ipp │ │ ├── error.hpp │ │ ├── fail_count.hpp │ │ ├── handler.hpp │ │ ├── immediate_executor.hpp │ │ ├── impl │ │ │ ├── error.hpp │ │ │ ├── error.ipp │ │ │ ├── fail_count.ipp │ │ │ ├── stream.hpp │ │ │ └── stream.ipp │ │ ├── stream.hpp │ │ └── tcp.hpp │ └── unit_test │ │ ├── amount.hpp │ │ ├── detail │ │ └── const_container.hpp │ │ ├── dstream.hpp │ │ ├── global_suites.hpp │ │ ├── main.ipp │ │ ├── match.hpp │ │ ├── recorder.hpp │ │ ├── reporter.hpp │ │ ├── results.hpp │ │ ├── runner.hpp │ │ ├── suite.hpp │ │ ├── suite_info.hpp │ │ └── suite_list.hpp │ ├── core.hpp │ ├── core │ ├── async_base.hpp │ ├── basic_stream.hpp │ ├── bind_handler.hpp │ ├── buffer_ref.hpp │ ├── buffer_traits.hpp │ ├── buffered_read_stream.hpp │ ├── buffers_adaptor.hpp │ ├── buffers_cat.hpp │ ├── buffers_generator.hpp │ ├── buffers_prefix.hpp │ ├── buffers_range.hpp │ ├── buffers_suffix.hpp │ ├── buffers_to_string.hpp │ ├── detail │ │ ├── allocator.hpp │ │ ├── async_base.hpp │ │ ├── base64.hpp │ │ ├── base64.ipp │ │ ├── bind_continuation.hpp │ │ ├── bind_handler.hpp │ │ ├── buffer.hpp │ │ ├── buffer_traits.hpp │ │ ├── buffers_pair.hpp │ │ ├── buffers_range_adaptor.hpp │ │ ├── buffers_ref.hpp │ │ ├── chacha.hpp │ │ ├── char_buffer.hpp │ │ ├── clamp.hpp │ │ ├── config.hpp │ │ ├── cpu_info.hpp │ │ ├── filtering_cancellation_slot.hpp │ │ ├── flat_stream.hpp │ │ ├── get_io_context.hpp │ │ ├── impl │ │ │ ├── read.hpp │ │ │ └── temporary_buffer.ipp │ │ ├── is_invocable.hpp │ │ ├── ostream.hpp │ │ ├── pcg.hpp │ │ ├── read.hpp │ │ ├── remap_post_to_defer.hpp │ │ ├── service_base.hpp │ │ ├── sha1.hpp │ │ ├── sha1.ipp │ │ ├── static_const.hpp │ │ ├── static_ostream.hpp │ │ ├── static_string.hpp │ │ ├── stream_base.hpp │ │ ├── stream_traits.hpp │ │ ├── string.hpp │ │ ├── temporary_buffer.hpp │ │ ├── tuple.hpp │ │ ├── type_traits.hpp │ │ ├── variant.hpp │ │ ├── varint.hpp │ │ └── win32_unicode_path.hpp │ ├── detect_ssl.hpp │ ├── error.hpp │ ├── file.hpp │ ├── file_base.hpp │ ├── file_posix.hpp │ ├── file_stdio.hpp │ ├── file_win32.hpp │ ├── flat_buffer.hpp │ ├── flat_static_buffer.hpp │ ├── flat_stream.hpp │ ├── impl │ │ ├── async_base.hpp │ │ ├── basic_stream.hpp │ │ ├── buffered_read_stream.hpp │ │ ├── buffers_adaptor.hpp │ │ ├── buffers_cat.hpp │ │ ├── buffers_generator.hpp │ │ ├── buffers_prefix.hpp │ │ ├── buffers_suffix.hpp │ │ ├── error.hpp │ │ ├── error.ipp │ │ ├── file_posix.ipp │ │ ├── file_stdio.ipp │ │ ├── file_win32.ipp │ │ ├── flat_buffer.hpp │ │ ├── flat_static_buffer.hpp │ │ ├── flat_static_buffer.ipp │ │ ├── flat_stream.hpp │ │ ├── multi_buffer.hpp │ │ ├── read_size.hpp │ │ ├── saved_handler.hpp │ │ ├── saved_handler.ipp │ │ ├── static_buffer.hpp │ │ ├── static_buffer.ipp │ │ ├── string.ipp │ │ └── string_param.hpp │ ├── make_printable.hpp │ ├── multi_buffer.hpp │ ├── ostream.hpp │ ├── rate_policy.hpp │ ├── read_size.hpp │ ├── role.hpp │ ├── saved_handler.hpp │ ├── span.hpp │ ├── static_buffer.hpp │ ├── static_string.hpp │ ├── stream_traits.hpp │ ├── string.hpp │ ├── string_param.hpp │ ├── string_type.hpp │ └── tcp_stream.hpp │ ├── http.hpp │ ├── http │ ├── basic_dynamic_body.hpp │ ├── basic_dynamic_body_fwd.hpp │ ├── basic_file_body.hpp │ ├── basic_file_body_fwd.hpp │ ├── basic_parser.hpp │ ├── buffer_body.hpp │ ├── buffer_body_fwd.hpp │ ├── chunk_encode.hpp │ ├── detail │ │ ├── basic_parsed_list.hpp │ │ ├── basic_parser.hpp │ │ ├── basic_parser.ipp │ │ ├── chunk_encode.hpp │ │ ├── rfc7230.hpp │ │ ├── rfc7230.ipp │ │ └── type_traits.hpp │ ├── dynamic_body.hpp │ ├── dynamic_body_fwd.hpp │ ├── empty_body.hpp │ ├── empty_body_fwd.hpp │ ├── error.hpp │ ├── field.hpp │ ├── fields.hpp │ ├── fields_fwd.hpp │ ├── file_body.hpp │ ├── file_body_fwd.hpp │ ├── impl │ │ ├── basic_parser.hpp │ │ ├── basic_parser.ipp │ │ ├── chunk_encode.hpp │ │ ├── error.hpp │ │ ├── error.ipp │ │ ├── field.ipp │ │ ├── fields.hpp │ │ ├── fields.ipp │ │ ├── file_body_win32.hpp │ │ ├── message.hpp │ │ ├── message_generator.hpp │ │ ├── parser.hpp │ │ ├── read.hpp │ │ ├── rfc7230.hpp │ │ ├── rfc7230.ipp │ │ ├── serializer.hpp │ │ ├── status.ipp │ │ ├── verb.ipp │ │ └── write.hpp │ ├── message.hpp │ ├── message_fwd.hpp │ ├── message_generator.hpp │ ├── message_generator_fwd.hpp │ ├── parser.hpp │ ├── parser_fwd.hpp │ ├── read.hpp │ ├── rfc7230.hpp │ ├── serializer.hpp │ ├── serializer_fwd.hpp │ ├── span_body.hpp │ ├── span_body_fwd.hpp │ ├── status.hpp │ ├── string_body.hpp │ ├── string_body_fwd.hpp │ ├── type_traits.hpp │ ├── vector_body.hpp │ ├── vector_body_fwd.hpp │ ├── verb.hpp │ └── write.hpp │ ├── src.hpp │ ├── ssl.hpp │ ├── ssl │ └── ssl_stream.hpp │ ├── version.hpp │ ├── websocket.hpp │ ├── websocket │ ├── detail │ │ ├── decorator.hpp │ │ ├── frame.hpp │ │ ├── hybi13.hpp │ │ ├── hybi13.ipp │ │ ├── impl_base.hpp │ │ ├── mask.hpp │ │ ├── mask.ipp │ │ ├── pmd_extension.hpp │ │ ├── pmd_extension.ipp │ │ ├── prng.hpp │ │ ├── prng.ipp │ │ ├── service.hpp │ │ ├── service.ipp │ │ ├── soft_mutex.hpp │ │ ├── type_traits.hpp │ │ ├── utf8_checker.hpp │ │ └── utf8_checker.ipp │ ├── error.hpp │ ├── impl │ │ ├── accept.hpp │ │ ├── close.hpp │ │ ├── error.hpp │ │ ├── error.ipp │ │ ├── handshake.hpp │ │ ├── ping.hpp │ │ ├── read.hpp │ │ ├── rfc6455.hpp │ │ ├── ssl.hpp │ │ ├── stream.hpp │ │ ├── stream_impl.hpp │ │ ├── teardown.hpp │ │ └── write.hpp │ ├── option.hpp │ ├── rfc6455.hpp │ ├── ssl.hpp │ ├── stream.hpp │ ├── stream_base.hpp │ ├── stream_fwd.hpp │ └── teardown.hpp │ ├── zlib.hpp │ └── zlib │ ├── deflate_stream.hpp │ ├── detail │ ├── bitstream.hpp │ ├── deflate_stream.hpp │ ├── deflate_stream.ipp │ ├── inflate_stream.hpp │ ├── inflate_stream.ipp │ ├── ranges.hpp │ └── window.hpp │ ├── error.hpp │ ├── impl │ ├── error.hpp │ └── error.ipp │ ├── inflate_stream.hpp │ └── zlib.hpp ├── index.html ├── meta ├── explicit-failures-markup.xml └── libraries.json ├── test ├── CMakeLists.txt ├── Jamfile ├── beast │ ├── CMakeLists.txt │ ├── Jamfile │ ├── _experimental │ │ ├── CMakeLists.txt │ │ ├── Jamfile │ │ ├── _test_detail_stream_state.cpp │ │ ├── error.cpp │ │ ├── icy_stream.cpp │ │ └── stream.cpp │ ├── core.cpp │ ├── core │ │ ├── CMakeLists.txt │ │ ├── Jamfile │ │ ├── _detail_base64.cpp │ │ ├── _detail_bind_continuation.cpp │ │ ├── _detail_buffer.cpp │ │ ├── _detail_clamp.cpp │ │ ├── _detail_get_io_context.cpp │ │ ├── _detail_is_invocable.cpp │ │ ├── _detail_read.cpp │ │ ├── _detail_sha1.cpp │ │ ├── _detail_tuple.cpp │ │ ├── _detail_variant.cpp │ │ ├── _detail_varint.cpp │ │ ├── async_base.cpp │ │ ├── basic_stream.cpp │ │ ├── bind_handler.cpp │ │ ├── buffer_ref.cpp │ │ ├── buffer_traits.cpp │ │ ├── buffered_read_stream.cpp │ │ ├── buffers_adaptor.cpp │ │ ├── buffers_cat.cpp │ │ ├── buffers_generator.cpp │ │ ├── buffers_prefix.cpp │ │ ├── buffers_range.cpp │ │ ├── buffers_suffix.cpp │ │ ├── buffers_to_string.cpp │ │ ├── detect_ssl.cpp │ │ ├── error.cpp │ │ ├── file.cpp │ │ ├── file_base.cpp │ │ ├── file_posix.cpp │ │ ├── file_stdio.cpp │ │ ├── file_test.hpp │ │ ├── file_win32.cpp │ │ ├── filtering_cancellation_slot.cpp │ │ ├── flat_buffer.cpp │ │ ├── flat_static_buffer.cpp │ │ ├── flat_stream.cpp │ │ ├── make_printable.cpp │ │ ├── multi_buffer.cpp │ │ ├── ostream.cpp │ │ ├── rate_policy.cpp │ │ ├── read_size.cpp │ │ ├── role.cpp │ │ ├── saved_handler.cpp │ │ ├── span.cpp │ │ ├── static_buffer.cpp │ │ ├── static_string.cpp │ │ ├── stream_tests.hpp │ │ ├── stream_traits.cpp │ │ ├── string.cpp │ │ ├── tcp_stream.cpp │ │ ├── test_buffer.hpp │ │ ├── test_executor.hpp │ │ └── test_handler.hpp │ ├── http.cpp │ ├── http │ │ ├── CMakeLists.txt │ │ ├── Jamfile │ │ ├── any_completion_handler.cpp │ │ ├── basic_dynamic_body.cpp │ │ ├── basic_dynamic_body_fwd.cpp │ │ ├── basic_file_body.cpp │ │ ├── basic_file_body_fwd.cpp │ │ ├── basic_parser.cpp │ │ ├── buffer_body.cpp │ │ ├── buffer_body_fwd.cpp │ │ ├── chunk_encode.cpp │ │ ├── deferred.cpp │ │ ├── dynamic_body.cpp │ │ ├── dynamic_body_fwd.cpp │ │ ├── empty_body.cpp │ │ ├── empty_body_fwd.cpp │ │ ├── error.cpp │ │ ├── field.cpp │ │ ├── field_compiles.cpp │ │ ├── fields.cpp │ │ ├── fields_fwd.cpp │ │ ├── file_body.cpp │ │ ├── file_body_fwd.cpp │ │ ├── message.cpp │ │ ├── message_fuzz.hpp │ │ ├── message_fwd.cpp │ │ ├── message_generator.cpp │ │ ├── message_generator_fwd.cpp │ │ ├── parser.cpp │ │ ├── parser_fwd.cpp │ │ ├── read.cpp │ │ ├── rfc7230.cpp │ │ ├── serializer.cpp │ │ ├── serializer_fwd.cpp │ │ ├── span_body.cpp │ │ ├── span_body_fwd.cpp │ │ ├── status.cpp │ │ ├── string_body.cpp │ │ ├── string_body_fwd.cpp │ │ ├── test_parser.hpp │ │ ├── type_traits.cpp │ │ ├── vector_body.cpp │ │ ├── vector_body_fwd.cpp │ │ ├── verb.cpp │ │ └── write.cpp │ ├── ssl.cpp │ ├── ssl │ │ ├── CMakeLists.txt │ │ ├── Jamfile │ │ └── ssl_stream.cpp │ ├── version.cpp │ ├── websocket.cpp │ ├── websocket │ │ ├── CMakeLists.txt │ │ ├── Jamfile │ │ ├── _detail_decorator.cpp │ │ ├── _detail_impl_base.cpp │ │ ├── _detail_prng.cpp │ │ ├── accept.cpp │ │ ├── any_completion_handler.cpp │ │ ├── cancel.cpp │ │ ├── close.cpp │ │ ├── deferred.cpp │ │ ├── error.cpp │ │ ├── frame.cpp │ │ ├── handshake.cpp │ │ ├── option.cpp │ │ ├── ping.cpp │ │ ├── read1.cpp │ │ ├── read2.cpp │ │ ├── read3.cpp │ │ ├── rfc6455.cpp │ │ ├── ssl.cpp │ │ ├── stream.cpp │ │ ├── stream_base.cpp │ │ ├── stream_explicit.cpp │ │ ├── stream_fwd.cpp │ │ ├── teardown.cpp │ │ ├── test.hpp │ │ ├── timer.cpp │ │ ├── utf8_checker.cpp │ │ └── write.cpp │ ├── zlib.cpp │ └── zlib │ │ ├── CMakeLists.txt │ │ ├── Jamfile │ │ ├── deflate_stream.cpp │ │ ├── error.cpp │ │ ├── fixtures │ │ └── CVE_2018_25032 │ │ │ ├── default.hpp │ │ │ └── fixed.hpp │ │ ├── inflate_stream.cpp │ │ └── zlib.cpp ├── bench │ ├── CMakeLists.txt │ ├── Jamfile │ ├── buffers │ │ ├── CMakeLists.txt │ │ ├── Jamfile │ │ └── bench_buffers.cpp │ ├── parser │ │ ├── CMakeLists.txt │ │ ├── Jamfile │ │ ├── bench_parser.cpp │ │ ├── nodejs-parser │ │ │ ├── AUTHORS │ │ │ ├── LICENSE-MIT │ │ │ ├── README.md │ │ │ ├── http_parser.c │ │ │ └── http_parser.h │ │ ├── nodejs_parser.cpp │ │ └── nodejs_parser.hpp │ ├── utf8_checker │ │ ├── CMakeLists.txt │ │ ├── Jamfile │ │ └── bench_utf8_checker.cpp │ ├── wsload │ │ ├── CMakeLists.txt │ │ ├── Jamfile │ │ └── wsload.cpp │ └── zlib │ │ ├── CMakeLists.txt │ │ ├── Jamfile │ │ ├── deflate_stream.cpp │ │ └── inflate_stream.cpp ├── cmake_test │ ├── CMakeLists.txt │ └── main.cpp ├── doc │ ├── CMakeLists.txt │ ├── Jamfile │ ├── core_1_refresher.cpp │ ├── core_3_timeouts.cpp │ ├── core_4_layers.cpp │ ├── core_snippets.cpp │ ├── exemplars.cpp │ ├── http_10_custom_parser.cpp │ ├── http_examples.cpp │ ├── http_snippets.cpp │ ├── snippets.hpp │ ├── snippets.ipp │ ├── websocket.cpp │ ├── websocket_1_connecting.cpp │ ├── websocket_2_handshaking.cpp │ ├── websocket_3_decorator.cpp │ ├── websocket_4_messages.cpp │ ├── websocket_5_control_frames.cpp │ ├── websocket_6_timeouts.cpp │ ├── websocket_7_teardown.cpp │ ├── websocket_8_notes.cpp │ └── websocket_common.ipp ├── example │ ├── CMakeLists.txt │ ├── Jamfile │ └── common │ │ ├── CMakeLists.txt │ │ ├── Jamfile │ │ ├── root_certificates.cpp │ │ └── server_certificate.cpp ├── extern │ └── zlib-1.2.12 │ │ ├── .gitignore │ │ ├── CMakeLists.txt │ │ ├── ChangeLog │ │ ├── FAQ │ │ ├── INDEX │ │ ├── Makefile │ │ ├── Makefile.in │ │ ├── README │ │ ├── adler32.c │ │ ├── amiga │ │ ├── Makefile.pup │ │ └── Makefile.sas │ │ ├── compress.c │ │ ├── configure │ │ ├── contrib │ │ ├── README.contrib │ │ ├── ada │ │ │ ├── buffer_demo.adb │ │ │ ├── mtest.adb │ │ │ ├── read.adb │ │ │ ├── readme.txt │ │ │ ├── test.adb │ │ │ ├── zlib-streams.adb │ │ │ ├── zlib-streams.ads │ │ │ ├── zlib-thin.adb │ │ │ ├── zlib-thin.ads │ │ │ ├── zlib.adb │ │ │ ├── zlib.ads │ │ │ └── zlib.gpr │ │ ├── blast │ │ │ ├── Makefile │ │ │ ├── README │ │ │ ├── blast.c │ │ │ ├── blast.h │ │ │ ├── test.pk │ │ │ └── test.txt │ │ ├── delphi │ │ │ ├── ZLib.pas │ │ │ ├── ZLibConst.pas │ │ │ ├── readme.txt │ │ │ └── zlibd32.mak │ │ ├── dotzlib │ │ │ ├── DotZLib.build │ │ │ ├── DotZLib.chm │ │ │ ├── DotZLib.sln │ │ │ ├── DotZLib │ │ │ │ ├── AssemblyInfo.cs │ │ │ │ ├── ChecksumImpl.cs │ │ │ │ ├── CircularBuffer.cs │ │ │ │ ├── CodecBase.cs │ │ │ │ ├── Deflater.cs │ │ │ │ ├── DotZLib.cs │ │ │ │ ├── DotZLib.csproj │ │ │ │ ├── GZipStream.cs │ │ │ │ ├── Inflater.cs │ │ │ │ └── UnitTests.cs │ │ │ ├── LICENSE_1_0.txt │ │ │ └── readme.txt │ │ ├── gcc_gvmat64 │ │ │ └── gvmat64.S │ │ ├── infback9 │ │ │ ├── README │ │ │ ├── infback9.c │ │ │ ├── infback9.h │ │ │ ├── inffix9.h │ │ │ ├── inflate9.h │ │ │ ├── inftree9.c │ │ │ └── inftree9.h │ │ ├── iostream │ │ │ ├── test.cpp │ │ │ ├── zfstream.cpp │ │ │ └── zfstream.h │ │ ├── iostream2 │ │ │ ├── zstream.h │ │ │ └── zstream_test.cpp │ │ ├── iostream3 │ │ │ ├── README │ │ │ ├── TODO │ │ │ ├── test.cc │ │ │ ├── zfstream.cc │ │ │ └── zfstream.h │ │ ├── minizip │ │ │ ├── Makefile │ │ │ ├── Makefile.am │ │ │ ├── MiniZip64_Changes.txt │ │ │ ├── MiniZip64_info.txt │ │ │ ├── configure.ac │ │ │ ├── crypt.h │ │ │ ├── ioapi.c │ │ │ ├── ioapi.h │ │ │ ├── iowin32.c │ │ │ ├── iowin32.h │ │ │ ├── make_vms.com │ │ │ ├── miniunz.c │ │ │ ├── miniunzip.1 │ │ │ ├── minizip.1 │ │ │ ├── minizip.c │ │ │ ├── minizip.pc.in │ │ │ ├── mztools.c │ │ │ ├── mztools.h │ │ │ ├── unzip.c │ │ │ ├── unzip.h │ │ │ ├── zip.c │ │ │ └── zip.h │ │ ├── pascal │ │ │ ├── example.pas │ │ │ ├── readme.txt │ │ │ ├── zlibd32.mak │ │ │ └── zlibpas.pas │ │ ├── puff │ │ │ ├── Makefile │ │ │ ├── README │ │ │ ├── puff.c │ │ │ ├── puff.h │ │ │ ├── pufftest.c │ │ │ └── zeros.raw │ │ ├── testzlib │ │ │ ├── testzlib.c │ │ │ └── testzlib.txt │ │ ├── untgz │ │ │ ├── Makefile │ │ │ ├── Makefile.msc │ │ │ └── untgz.c │ │ └── vstudio │ │ │ ├── readme.txt │ │ │ ├── vc10 │ │ │ ├── miniunz.vcxproj │ │ │ ├── miniunz.vcxproj.filters │ │ │ ├── minizip.vcxproj │ │ │ ├── minizip.vcxproj.filters │ │ │ ├── testzlib.vcxproj │ │ │ ├── testzlib.vcxproj.filters │ │ │ ├── testzlibdll.vcxproj │ │ │ ├── testzlibdll.vcxproj.filters │ │ │ ├── zlib.rc │ │ │ ├── zlibstat.vcxproj │ │ │ ├── zlibstat.vcxproj.filters │ │ │ ├── zlibvc.def │ │ │ ├── zlibvc.sln │ │ │ ├── zlibvc.vcxproj │ │ │ └── zlibvc.vcxproj.filters │ │ │ ├── vc11 │ │ │ ├── miniunz.vcxproj │ │ │ ├── minizip.vcxproj │ │ │ ├── testzlib.vcxproj │ │ │ ├── testzlibdll.vcxproj │ │ │ ├── zlib.rc │ │ │ ├── zlibstat.vcxproj │ │ │ ├── zlibvc.def │ │ │ ├── zlibvc.sln │ │ │ └── zlibvc.vcxproj │ │ │ ├── vc12 │ │ │ ├── miniunz.vcxproj │ │ │ ├── minizip.vcxproj │ │ │ ├── testzlib.vcxproj │ │ │ ├── testzlibdll.vcxproj │ │ │ ├── zlib.rc │ │ │ ├── zlibstat.vcxproj │ │ │ ├── zlibvc.def │ │ │ ├── zlibvc.sln │ │ │ └── zlibvc.vcxproj │ │ │ ├── vc14 │ │ │ ├── miniunz.vcxproj │ │ │ ├── minizip.vcxproj │ │ │ ├── testzlib.vcxproj │ │ │ ├── testzlibdll.vcxproj │ │ │ ├── zlib.rc │ │ │ ├── zlibstat.vcxproj │ │ │ ├── zlibvc.def │ │ │ ├── zlibvc.sln │ │ │ └── zlibvc.vcxproj │ │ │ └── vc9 │ │ │ ├── miniunz.vcproj │ │ │ ├── minizip.vcproj │ │ │ ├── testzlib.vcproj │ │ │ ├── testzlibdll.vcproj │ │ │ ├── zlib.rc │ │ │ ├── zlibstat.vcproj │ │ │ ├── zlibvc.def │ │ │ ├── zlibvc.sln │ │ │ └── zlibvc.vcproj │ │ ├── crc32.c │ │ ├── crc32.h │ │ ├── deflate.c │ │ ├── deflate.h │ │ ├── doc │ │ ├── algorithm.txt │ │ ├── crc-doc.1.0.pdf │ │ ├── rfc1950.txt │ │ ├── rfc1951.txt │ │ ├── rfc1952.txt │ │ └── txtvsbin.txt │ │ ├── examples │ │ ├── README.examples │ │ ├── enough.c │ │ ├── fitblk.c │ │ ├── gun.c │ │ ├── gzappend.c │ │ ├── gzjoin.c │ │ ├── gzlog.c │ │ ├── gzlog.h │ │ ├── gznorm.c │ │ ├── zlib_how.html │ │ ├── zpipe.c │ │ ├── zran.c │ │ └── zran.h │ │ ├── gzclose.c │ │ ├── gzguts.h │ │ ├── gzlib.c │ │ ├── gzread.c │ │ ├── gzwrite.c │ │ ├── infback.c │ │ ├── inffast.c │ │ ├── inffast.h │ │ ├── inffixed.h │ │ ├── inflate.c │ │ ├── inflate.h │ │ ├── inftrees.c │ │ ├── inftrees.h │ │ ├── make_vms.com │ │ ├── msdos │ │ ├── Makefile.bor │ │ ├── Makefile.dj2 │ │ ├── Makefile.emx │ │ ├── Makefile.msc │ │ └── Makefile.tc │ │ ├── nintendods │ │ ├── Makefile │ │ └── README │ │ ├── old │ │ ├── Makefile.emx │ │ ├── Makefile.riscos │ │ ├── README │ │ ├── descrip.mms │ │ ├── os2 │ │ │ ├── Makefile.os2 │ │ │ └── zlib.def │ │ └── visual-basic.txt │ │ ├── os400 │ │ ├── README400 │ │ ├── bndsrc │ │ ├── make.sh │ │ └── zlib.inc │ │ ├── qnx │ │ └── package.qpg │ │ ├── test │ │ ├── example.c │ │ ├── infcover.c │ │ └── minigzip.c │ │ ├── treebuild.xml │ │ ├── trees.c │ │ ├── trees.h │ │ ├── uncompr.c │ │ ├── watcom │ │ ├── watcom_f.mak │ │ └── watcom_l.mak │ │ ├── win32 │ │ ├── DLL_FAQ.txt │ │ ├── Makefile.bor │ │ ├── Makefile.gcc │ │ ├── Makefile.msc │ │ ├── README-WIN32.txt │ │ ├── VisualC.txt │ │ ├── zlib.def │ │ └── zlib1.rc │ │ ├── zconf.h │ │ ├── zconf.h.cmakein │ │ ├── zconf.h.in │ │ ├── zlib.3 │ │ ├── zlib.3.pdf │ │ ├── zlib.h │ │ ├── zlib.map │ │ ├── zlib.pc.cmakein │ │ ├── zlib.pc.in │ │ ├── zlib2ansi │ │ ├── zutil.c │ │ └── zutil.h ├── extras │ ├── README.md │ └── include │ │ └── boost │ │ └── beast │ │ ├── doc_debug.hpp │ │ └── test │ │ ├── fuzz.hpp │ │ ├── sig_wait.hpp │ │ ├── test_allocator.hpp │ │ ├── throughput.hpp │ │ ├── websocket.hpp │ │ └── yield_to.hpp ├── fuzz │ ├── CMakeLists.txt │ ├── http_request.cpp │ ├── http_response.cpp │ ├── seeds.tar │ └── websocket_server.cpp ├── lib_asio.cpp ├── lib_asio_ssl.cpp ├── lib_beast.cpp └── lib_test.cpp └── tools ├── blacklist.supp ├── build-and-test.sh ├── get-boost.sh ├── retry.sh ├── user-config.jam └── valgrind.supp /.codecov.yml: -------------------------------------------------------------------------------- 1 | # Copyright 2019 - 2021 Alexander Grund 2 | # Distributed under the Boost Software License, Version 1.0. 3 | # (See accompanying file LICENSE_1_0.txt or copy at http://boost.org/LICENSE_1_0.txt) 4 | # 5 | # Sample codecov configuration file. Edit as required 6 | 7 | codecov: 8 | max_report_age: off 9 | require_ci_to_pass: yes 10 | notify: 11 | # Increase this if you have multiple coverage collection jobs 12 | after_n_builds: 1 13 | wait_for_ci: yes 14 | 15 | # Change how pull request comments look 16 | comment: 17 | layout: "reach,diff,flags,files,footer" 18 | 19 | # Ignore specific files or folders. Glob patterns are supported. 20 | # See https://docs.codecov.com/docs/ignoring-paths 21 | ignore: 22 | - extra/* 23 | - extra/**/* 24 | - test/* 25 | - test/**/* 26 | -------------------------------------------------------------------------------- /.gitattributes: -------------------------------------------------------------------------------- 1 | # Set default behaviour, in case users don't have core.autocrlf set. 2 | * text=auto 3 | 4 | # Github 5 | .md text eol=lf 6 | 7 | # Visual Studio 8 | *.sln text eol=crlf 9 | *.vcproj text eol=crlf 10 | *.vcxproj text eol=crlf 11 | *.props text eol=crlf 12 | *.filters text eol=crlf 13 | -------------------------------------------------------------------------------- /.github/ISSUE_TEMPLATE.md: -------------------------------------------------------------------------------- 1 | PLEASE DON'T FORGET TO "STAR" THIS REPOSITORY :) 2 | 3 | If you rather keep your project secret, feel free 4 | to email the author at ``; any 5 | private correspondence is treated as confidential. 6 | 7 | When reporting a bug please include the following: 8 | 9 | ### Version of Beast 10 | 11 | You can find the version number in the file ``, 12 | or by using the command "git log -1" in the local Beast repository 13 | directory. 14 | 15 | ### Steps necessary to reproduce the problem 16 | 17 | A small compiling program is the best. If your code is 18 | public, you can provide a link to the repository. 19 | 20 | ### All relevant compiler information 21 | 22 | If you are unable to compile please include the type and 23 | version of compiler you are using as well as all compiler 24 | output including the error message, file, and line numbers 25 | involved. 26 | 27 | The more information you provide the sooner your issue 28 | can get resolved! 29 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | bin/ 2 | bin64/ 3 | 4 | # Because of CMake and VS2017 5 | Win32/ 6 | x64/ 7 | 8 | -------------------------------------------------------------------------------- /cmake/toolchains/clang.cmake: -------------------------------------------------------------------------------- 1 | # Include gcc options. 2 | include(${CMAKE_CURRENT_LIST_DIR}/gcc.cmake) 3 | 4 | # Compiler options. 5 | add_compile_options(-Wrange-loop-analysis) 6 | -------------------------------------------------------------------------------- /cmake/toolchains/common.cmake: -------------------------------------------------------------------------------- 1 | # C++ standard. 2 | set(CMAKE_CXX_EXTENSIONS OFF CACHE STRING "") 3 | 4 | # Static library linkage. 5 | set(BUILD_SHARED_LIBS OFF CACHE STRING "") 6 | add_definitions(-DBOOST_ALL_STATIC_LINK=1) 7 | 8 | # Interprocedural optimization. 9 | set(CMAKE_INTERPROCEDURAL_OPTIMIZATION_RELEASE ON CACHE STRING "") 10 | set(CMAKE_INTERPROCEDURAL_OPTIMIZATION_MINSIZEREL ON CACHE STRING "") 11 | set(CMAKE_INTERPROCEDURAL_OPTIMIZATION_RELWITHDEBINFO ON CACHE STRING "") 12 | 13 | # Compiler definitions. 14 | if(WIN32) 15 | add_definitions(-D_WIN32_WINNT=0x0601 -D_CRT_SECURE_NO_WARNINGS) 16 | endif() 17 | 18 | # Project options. 19 | -------------------------------------------------------------------------------- /cmake/toolchains/gcc.cmake: -------------------------------------------------------------------------------- 1 | # Include common options. 2 | include(${CMAKE_CURRENT_LIST_DIR}/common.cmake) 3 | 4 | # Compiler options. 5 | add_compile_options(-Wall -Wextra -Wpedantic) 6 | -------------------------------------------------------------------------------- /doc/.gitignore: -------------------------------------------------------------------------------- 1 | html 2 | temp 3 | out.txt 4 | qbk/reference.qbk 5 | -------------------------------------------------------------------------------- /doc/images/message.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/boostorg/beast/916dcf8eb3eff582356f7b1849446a3893da6eac/doc/images/message.png -------------------------------------------------------------------------------- /doc/images/readme2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/boostorg/beast/916dcf8eb3eff582356f7b1849446a3893da6eac/doc/images/readme2.png -------------------------------------------------------------------------------- /doc/qbk/07_concepts/BufferSequence.qbk: -------------------------------------------------------------------------------- 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 | [section:BufferSequence BufferSequence] 11 | 12 | A [*BufferSequence] is a type meeting either of the following requirements: 13 | 14 | * __ConstBufferSequence__ 15 | * __MutableBufferSequence__ 16 | 17 | [endsect] 18 | -------------------------------------------------------------------------------- /doc/qbk/07_concepts/_concepts.qbk: -------------------------------------------------------------------------------- 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 | [section:concepts Concepts] 11 | 12 | This section describes all of the concepts defined by the library. 13 | 14 | [include Body.qbk] 15 | [include BodyReader.qbk] 16 | [include BodyWriter.qbk] 17 | [include BufferSequence.qbk] 18 | [include BuffersGenerator.qbk] 19 | [include DynamicBuffer.qbk] 20 | [include Fields.qbk] 21 | [include FieldsWriter.qbk] 22 | [include File.qbk] 23 | [include RatePolicy.qbk] 24 | [include Streams.qbk] 25 | 26 | [endsect] 27 | -------------------------------------------------------------------------------- /doc/qbk/index.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 11 | 12 |
13 | Index 14 | 15 |
16 | -------------------------------------------------------------------------------- /doc/qbk/version.qbk: -------------------------------------------------------------------------------- 1 | [/ 2 | Copyright (c) 2022 Klemens D. Morgenstern (klemens dot morgenstern at gmx dot net) 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 | [section Beast API Version] 11 | 12 | Beast maintains it's own API version, which is more fine-grained than the 13 | boost release. 14 | 15 | It can be obtained as a string from the `BOOST_BEAST_VERSION` macro 16 | or a string through `BOOST_BEAST_VERSION_STRING`. 17 | 18 | [version] 19 | 20 | 21 | [endsect] 22 | -------------------------------------------------------------------------------- /example/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2013-2017 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 | find_package(OpenSSL) 11 | 12 | add_subdirectory(advanced) 13 | add_subdirectory(http) 14 | add_subdirectory(websocket) 15 | 16 | add_subdirectory(doc) 17 | 18 | add_subdirectory(echo-op) 19 | -------------------------------------------------------------------------------- /example/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2013-2017 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 | import testing ; 11 | import-search /boost/config/checks ; 12 | import config : requires ; 13 | 14 | project /boost/beast/example 15 | : requirements 16 | [ requires 17 | cxx11_constexpr 18 | cxx11_decltype 19 | cxx11_hdr_tuple 20 | #cxx11_sfinae_expr # Every MSVC fails this 21 | cxx11_template_aliases 22 | cxx11_variadic_templates 23 | ] 24 | /boost/beast/test//lib-asio/static 25 | on:/boost/beast/test//lib-beast/static 26 | .. 27 | ; 28 | 29 | build-project advanced ; 30 | build-project http ; 31 | build-project websocket ; 32 | 33 | build-project doc ; 34 | 35 | # legacy 36 | build-project echo-op ; 37 | -------------------------------------------------------------------------------- /example/advanced/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2013-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_subdirectory(server) 12 | 13 | if (OPENSSL_FOUND) 14 | add_subdirectory(server-flex) 15 | add_subdirectory(server-flex-awaitable) 16 | endif () 17 | -------------------------------------------------------------------------------- /example/advanced/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2013-2017 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 | build-project server ; 11 | 12 | # SSL 13 | build-project server-flex ; 14 | 15 | # C++20 16 | build-project server-flex-awaitable ; 17 | -------------------------------------------------------------------------------- /example/advanced/server-flex-awaitable/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(advanced-server-flex-awaitable 12 | Jamfile 13 | advanced_server_flex_awaitable.cpp) 14 | 15 | source_group("" FILES 16 | Jamfile 17 | advanced_server_flex_awaitable.cpp) 18 | 19 | target_include_directories(advanced-server-flex-awaitable 20 | PRIVATE ${PROJECT_SOURCE_DIR}) 21 | 22 | target_link_libraries(advanced-server-flex-awaitable 23 | PRIVATE Boost::beast OpenSSL::SSL OpenSSL::Crypto) 24 | 25 | set_target_properties(advanced-server-flex-awaitable 26 | PROPERTIES FOLDER "example-advanced-server") 27 | -------------------------------------------------------------------------------- /example/advanced/server-flex-awaitable/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | import ac ; 11 | 12 | project 13 | : requirements 14 | [ ac.check-library /boost/beast/test//lib-asio-ssl : /boost/beast/test//lib-asio-ssl/static : no ] 15 | ; 16 | 17 | exe advanced-server-flex-awaitable : 18 | advanced_server_flex_awaitable.cpp 19 | : 20 | coverage:no 21 | ubasan:no 22 | ; 23 | -------------------------------------------------------------------------------- /example/advanced/server-flex/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(advanced-server-flex 12 | Jamfile 13 | advanced_server_flex.cpp) 14 | 15 | source_group("" FILES 16 | Jamfile 17 | advanced_server_flex.cpp) 18 | 19 | target_include_directories(advanced-server-flex 20 | PRIVATE ${PROJECT_SOURCE_DIR}) 21 | 22 | target_link_libraries(advanced-server-flex 23 | PRIVATE Boost::beast OpenSSL::SSL OpenSSL::Crypto) 24 | 25 | set_target_properties(advanced-server-flex 26 | PROPERTIES FOLDER "example-advanced-server") 27 | -------------------------------------------------------------------------------- /example/advanced/server-flex/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | import ac ; 11 | 12 | project 13 | : requirements 14 | [ ac.check-library /boost/beast/test//lib-asio-ssl : /boost/beast/test//lib-asio-ssl/static : no ] 15 | ; 16 | 17 | exe advanced-server-flex : 18 | advanced_server_flex.cpp 19 | : 20 | coverage:no 21 | ubasan:no 22 | ; 23 | -------------------------------------------------------------------------------- /example/advanced/server/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(advanced-server 12 | Jamfile 13 | advanced_server.cpp) 14 | 15 | source_group("" FILES 16 | Jamfile 17 | advanced_server.cpp) 18 | 19 | target_link_libraries(advanced-server PRIVATE Boost::beast) 20 | 21 | set_target_properties(advanced-server PROPERTIES FOLDER "example-advanced-server") 22 | -------------------------------------------------------------------------------- /example/advanced/server/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | exe advanced-server : 11 | advanced_server.cpp 12 | : 13 | coverage:no 14 | ubasan:no 15 | ; 16 | -------------------------------------------------------------------------------- /example/doc/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2025 Mohammad Nejati 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 | if (OPENSSL_FOUND) 11 | add_subdirectory(ssl) 12 | endif () 13 | -------------------------------------------------------------------------------- /example/doc/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2025 Mohammad Nejati 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 | build-project ssl ; 11 | -------------------------------------------------------------------------------- /example/doc/ssl/Jamfile: -------------------------------------------------------------------------------- 1 | import ac ; 2 | 3 | project 4 | : requirements 5 | [ ac.check-library /boost/beast/test//lib-asio-ssl : /boost/beast/test//lib-asio-ssl/static : no ] 6 | ; 7 | 8 | exe doc-ssl-client : 9 | client.cpp 10 | : 11 | coverage:no 12 | ubasan:no 13 | ; 14 | 15 | exe doc-ssl-server : 16 | server.cpp 17 | : 18 | coverage:no 19 | ubasan:no 20 | ; 21 | -------------------------------------------------------------------------------- /example/echo-op/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(echo-op 12 | Jamfile 13 | echo_op.cpp) 14 | 15 | source_group("" FILES 16 | Jamfile 17 | echo_op.cpp) 18 | 19 | target_link_libraries(echo-op PRIVATE Boost::beast) 20 | 21 | set_target_properties(echo-op 22 | PROPERTIES FOLDER "example-echo-op") 23 | -------------------------------------------------------------------------------- /example/echo-op/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | exe echo-op : 11 | echo_op.cpp 12 | : 13 | coverage:no 14 | ubasan:no 15 | ; 16 | -------------------------------------------------------------------------------- /example/http/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2013-2017 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 | add_subdirectory(client) 11 | add_subdirectory(server) 12 | -------------------------------------------------------------------------------- /example/http/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2013-2017 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 | build-project client ; 11 | build-project server ; 12 | -------------------------------------------------------------------------------- /example/http/client/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2013-2017 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 | add_subdirectory(async) 11 | add_subdirectory(async-local) 12 | add_subdirectory(awaitable) 13 | add_subdirectory(body) 14 | add_subdirectory(coro) 15 | add_subdirectory(crawl) 16 | add_subdirectory(methods) 17 | add_subdirectory(sync) 18 | 19 | if (OPENSSL_FOUND) 20 | add_subdirectory(async-ssl) 21 | add_subdirectory(async-ssl-system-executor) 22 | add_subdirectory(awaitable-ssl) 23 | add_subdirectory(coro-ssl) 24 | add_subdirectory(sync-ssl) 25 | endif () 26 | -------------------------------------------------------------------------------- /example/http/client/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2013-2017 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 | build-project async ; 11 | build-project async-local ; 12 | build-project coro ; 13 | build-project crawl ; 14 | build-project sync ; 15 | build-project awaitable ; 16 | 17 | # SSL 18 | build-project async-ssl ; 19 | build-project awaitable-ssl ; 20 | build-project coro-ssl ; 21 | build-project sync-ssl ; 22 | 23 | build-project body ; 24 | 25 | build-project methods ; 26 | -------------------------------------------------------------------------------- /example/http/client/async-local/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2025 Mohammad Nejati 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 | add_executable(http-client-async-local 11 | Jamfile 12 | http_client_async_local.cpp) 13 | 14 | source_group("" FILES 15 | Jamfile 16 | http_client_async_local.cpp) 17 | 18 | target_link_libraries(http-client-async-local PRIVATE Boost::beast) 19 | 20 | set_target_properties(http-client-async-local 21 | PROPERTIES FOLDER "example-http-client") 22 | -------------------------------------------------------------------------------- /example/http/client/async-local/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2025 Mohammad Nejati 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 | exe http-client-async-local : 11 | http_client_async_local.cpp 12 | : 13 | coverage:no 14 | ubasan:no 15 | ; 16 | -------------------------------------------------------------------------------- /example/http/client/async-ssl-system-executor/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(http-client-async-ssl-system-executor 12 | Jamfile 13 | http_client_async_ssl_system_executor.cpp) 14 | 15 | source_group("" FILES 16 | Jamfile 17 | http_client_async_ssl_system_executor.cpp) 18 | 19 | target_include_directories(http-client-async-ssl-system-executor 20 | PRIVATE ${PROJECT_SOURCE_DIR}) 21 | 22 | target_link_libraries(http-client-async-ssl-system-executor 23 | PRIVATE Boost::beast OpenSSL::SSL OpenSSL::Crypto) 24 | 25 | set_target_properties(http-client-async-ssl-system-executor 26 | PROPERTIES FOLDER "example-http-client") 27 | -------------------------------------------------------------------------------- /example/http/client/async-ssl-system-executor/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | import ac ; 11 | 12 | project 13 | : requirements 14 | [ ac.check-library /boost/beast/test//lib-asio-ssl : /boost/beast/test//lib-asio-ssl/static : no ] 15 | ; 16 | 17 | exe http-client-async-ssl-system-executor : 18 | http_client_async_ssl_system_executor.cpp 19 | : 20 | coverage:no 21 | ubasan:no 22 | ; 23 | -------------------------------------------------------------------------------- /example/http/client/async-ssl/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(http-client-async-ssl 12 | Jamfile 13 | http_client_async_ssl.cpp) 14 | 15 | source_group("" FILES 16 | Jamfile 17 | http_client_async_ssl.cpp) 18 | 19 | target_include_directories(http-client-async-ssl 20 | PRIVATE ${PROJECT_SOURCE_DIR}) 21 | 22 | target_link_libraries(http-client-async-ssl 23 | PRIVATE Boost::beast OpenSSL::SSL OpenSSL::Crypto) 24 | 25 | set_target_properties(http-client-async-ssl 26 | PROPERTIES FOLDER "example-http-client") 27 | -------------------------------------------------------------------------------- /example/http/client/async-ssl/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | import ac ; 11 | 12 | project 13 | : requirements 14 | [ ac.check-library /boost/beast/test//lib-asio-ssl : /boost/beast/test//lib-asio-ssl/static : no ] 15 | ; 16 | 17 | exe http-client-async-ssl : 18 | http_client_async_ssl.cpp 19 | : 20 | coverage:no 21 | ubasan:no 22 | ; 23 | -------------------------------------------------------------------------------- /example/http/client/async/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(http-client-async 12 | Jamfile 13 | http_client_async.cpp) 14 | 15 | source_group("" FILES 16 | Jamfile 17 | http_client_async.cpp) 18 | 19 | target_link_libraries(http-client-async PRIVATE Boost::beast) 20 | 21 | set_target_properties(http-client-async 22 | PROPERTIES FOLDER "example-http-client") 23 | -------------------------------------------------------------------------------- /example/http/client/async/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | exe http-client-async : 11 | http_client_async.cpp 12 | : 13 | coverage:no 14 | ubasan:no 15 | ; 16 | -------------------------------------------------------------------------------- /example/http/client/awaitable-ssl/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(http-client-awaitable-ssl 12 | Jamfile 13 | http_client_awaitable_ssl.cpp) 14 | 15 | source_group("" FILES 16 | Jamfile 17 | http_client_awaitable_ssl.cpp) 18 | 19 | target_include_directories(http-client-awaitable-ssl 20 | PRIVATE ${PROJECT_SOURCE_DIR}) 21 | 22 | target_link_libraries(http-client-awaitable-ssl 23 | PRIVATE Boost::beast OpenSSL::SSL OpenSSL::Crypto) 24 | 25 | set_target_properties(http-client-awaitable-ssl 26 | PROPERTIES FOLDER "example-http-client") 27 | -------------------------------------------------------------------------------- /example/http/client/awaitable-ssl/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | import ac ; 11 | 12 | project 13 | : requirements 14 | [ ac.check-library /boost/beast/test//lib-asio-ssl : /boost/beast/test//lib-asio-ssl/static : no ] 15 | ; 16 | 17 | exe http-client-awaitable-ssl : 18 | http_client_awaitable_ssl.cpp 19 | : 20 | coverage:no 21 | ubasan:no 22 | ; 23 | -------------------------------------------------------------------------------- /example/http/client/awaitable/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(http-client-awaitable 12 | Jamfile 13 | http_client_awaitable.cpp) 14 | 15 | source_group("" FILES 16 | Jamfile 17 | http_client_awaitable.cpp) 18 | 19 | target_link_libraries(http-client-awaitable PRIVATE Boost::beast) 20 | 21 | set_target_properties(http-client-awaitable 22 | PROPERTIES FOLDER "example-http-client") 23 | -------------------------------------------------------------------------------- /example/http/client/awaitable/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | exe http-client-awaitable : 11 | http_client_awaitable.cpp 12 | : 13 | coverage:no 14 | ubasan:no 15 | ; 16 | -------------------------------------------------------------------------------- /example/http/client/body/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(http-client-json 12 | Jamfile 13 | json_client.cpp) 14 | 15 | source_group("" FILES 16 | Jamfile 17 | json_client.cpp) 18 | 19 | target_link_libraries(http-client-json PRIVATE Boost::beast Boost::json) 20 | 21 | set_target_properties(http-client-json 22 | PROPERTIES FOLDER "example-http-client") 23 | -------------------------------------------------------------------------------- /example/http/client/body/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | exe json_client : json_client.cpp 11 | : 12 | coverage:no 13 | ubasan:no 14 | /boost/json//boost_json/static 15 | ; 16 | -------------------------------------------------------------------------------- /example/http/client/coro-ssl/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(http-client-coro-ssl 12 | Jamfile 13 | http_client_coro_ssl.cpp) 14 | 15 | source_group("" FILES 16 | Jamfile 17 | http_client_coro_ssl.cpp) 18 | 19 | target_include_directories(http-client-coro-ssl 20 | PRIVATE ${PROJECT_SOURCE_DIR}) 21 | 22 | target_link_libraries(http-client-coro-ssl 23 | PRIVATE Boost::beast OpenSSL::SSL OpenSSL::Crypto) 24 | 25 | set_target_properties(http-client-coro-ssl 26 | PROPERTIES FOLDER "example-http-client") 27 | -------------------------------------------------------------------------------- /example/http/client/coro-ssl/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | import ac ; 11 | 12 | project 13 | : requirements 14 | [ ac.check-library /boost/beast/test//lib-asio-ssl : /boost/beast/test//lib-asio-ssl/static : no ] 15 | ; 16 | 17 | exe http-client-coro-ssl : 18 | http_client_coro_ssl.cpp 19 | : 20 | coverage:no 21 | ubasan:no 22 | /boost/context//boost_context 23 | ; 24 | -------------------------------------------------------------------------------- /example/http/client/coro/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(http-client-coro 12 | Jamfile 13 | http_client_coro.cpp) 14 | 15 | source_group("" FILES 16 | Jamfile 17 | http_client_coro.cpp) 18 | 19 | target_link_libraries(http-client-coro PRIVATE Boost::beast) 20 | 21 | set_target_properties(http-client-coro 22 | PROPERTIES FOLDER "example-http-client") 23 | -------------------------------------------------------------------------------- /example/http/client/coro/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | exe http-client-coro : 11 | http_client_coro.cpp 12 | : 13 | coverage:no 14 | ubasan:no 15 | /boost/context//boost_context 16 | ; 17 | -------------------------------------------------------------------------------- /example/http/client/crawl/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(http-crawl 12 | Jamfile 13 | http_crawl.cpp 14 | urls_large_data.cpp) 15 | 16 | source_group("" FILES 17 | Jamfile 18 | http_crawl.cpp 19 | urls_large_data.cpp) 20 | 21 | target_link_libraries(http-crawl PRIVATE Boost::beast) 22 | 23 | set_target_properties(http-crawl 24 | PROPERTIES FOLDER "example-http-client") 25 | -------------------------------------------------------------------------------- /example/http/client/crawl/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | exe http-crawl : 11 | http_crawl.cpp 12 | urls_large_data.cpp 13 | : 14 | coverage:no 15 | ubasan:no 16 | ; 17 | -------------------------------------------------------------------------------- /example/http/client/crawl/urls_large_data.hpp: -------------------------------------------------------------------------------- 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_EXAMPLE_HTTP_CLIENT_CRAWL_URLS_LARGE_DATA_HPP 11 | #define BOOST_BEAST_EXAMPLE_HTTP_CLIENT_CRAWL_URLS_LARGE_DATA_HPP 12 | 13 | #include 14 | 15 | std::vector const& 16 | urls_large_data(); 17 | 18 | #endif 19 | -------------------------------------------------------------------------------- /example/http/client/methods/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(http-client-methods 12 | Jamfile 13 | http_client_methods.cpp) 14 | 15 | source_group("" FILES 16 | Jamfile 17 | http_client_methods.cpp) 18 | 19 | target_link_libraries(http-client-methods PRIVATE Boost::beast) 20 | 21 | set_target_properties(http-client-methods 22 | PROPERTIES FOLDER "example-http-client") 23 | -------------------------------------------------------------------------------- /example/http/client/methods/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | exe http-client-methods : 11 | http_client_methods.cpp 12 | : 13 | coverage:no 14 | ubasan:no 15 | ; 16 | -------------------------------------------------------------------------------- /example/http/client/sync-ssl/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(http-client-sync-ssl 12 | Jamfile 13 | http_client_sync_ssl.cpp) 14 | 15 | source_group("" FILES 16 | Jamfile 17 | http_client_sync_ssl.cpp) 18 | 19 | target_include_directories(http-client-sync-ssl 20 | PRIVATE ${PROJECT_SOURCE_DIR}) 21 | 22 | target_link_libraries(http-client-sync-ssl 23 | PRIVATE Boost::beast OpenSSL::SSL OpenSSL::Crypto) 24 | 25 | set_target_properties(http-client-sync-ssl 26 | PROPERTIES FOLDER "example-http-client") 27 | -------------------------------------------------------------------------------- /example/http/client/sync-ssl/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | import ac ; 11 | 12 | project 13 | : requirements 14 | [ ac.check-library /boost/beast/test//lib-asio-ssl : /boost/beast/test//lib-asio-ssl/static : no ] 15 | ; 16 | 17 | exe http-client-sync-ssl : 18 | http_client_sync_ssl.cpp 19 | : 20 | coverage:no 21 | ubasan:no 22 | ; 23 | -------------------------------------------------------------------------------- /example/http/client/sync/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(http-client-sync 12 | Jamfile 13 | http_client_sync.cpp) 14 | 15 | source_group("" FILES 16 | Jamfile 17 | http_client_sync.cpp) 18 | 19 | target_link_libraries(http-client-sync PRIVATE Boost::beast) 20 | 21 | set_target_properties(http-client-sync 22 | PROPERTIES FOLDER "example-http-client") 23 | -------------------------------------------------------------------------------- /example/http/client/sync/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | exe http-client-sync : 11 | http_client_sync.cpp 12 | : 13 | coverage:no 14 | ubasan:no 15 | ; 16 | -------------------------------------------------------------------------------- /example/http/server/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2013-2017 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 | add_subdirectory(async) 11 | add_subdirectory(async-local) 12 | add_subdirectory(awaitable) 13 | add_subdirectory(coro) 14 | add_subdirectory(fast) 15 | add_subdirectory(small) 16 | add_subdirectory(stackless) 17 | add_subdirectory(sync) 18 | 19 | if (OPENSSL_FOUND) 20 | add_subdirectory(async-ssl) 21 | add_subdirectory(coro-ssl) 22 | add_subdirectory(flex) 23 | add_subdirectory(stackless-ssl) 24 | add_subdirectory(sync-ssl) 25 | endif () 26 | -------------------------------------------------------------------------------- /example/http/server/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2013-2017 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 | build-project async ; 11 | build-project async-local ; 12 | build-project coro ; 13 | build-project fast ; 14 | build-project small ; 15 | build-project stackless ; 16 | build-project sync ; 17 | build-project awaitable ; 18 | 19 | # SSL 20 | build-project async-ssl ; 21 | build-project coro-ssl ; 22 | build-project flex ; 23 | build-project stackless-ssl ; 24 | build-project sync-ssl ; 25 | -------------------------------------------------------------------------------- /example/http/server/async-local/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2025 Mohammad Nejati 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 | add_executable(http-server-async-local 11 | Jamfile 12 | http_server_async_local.cpp) 13 | 14 | source_group("" FILES 15 | Jamfile 16 | http_server_async_local.cpp) 17 | 18 | target_link_libraries(http-server-async-local PRIVATE Boost::beast) 19 | 20 | set_target_properties(http-server-async-local 21 | PROPERTIES FOLDER "example-http-server") 22 | -------------------------------------------------------------------------------- /example/http/server/async-local/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2025 Mohammad Nejati 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 | exe http-server-async-local : 11 | http_server_async_local.cpp 12 | : 13 | coverage:no 14 | ubasan:no 15 | ; 16 | -------------------------------------------------------------------------------- /example/http/server/async-ssl/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(http-server-async-ssl 12 | Jamfile 13 | http_server_async_ssl.cpp) 14 | 15 | source_group("" FILES 16 | Jamfile 17 | http_server_async_ssl.cpp) 18 | 19 | target_include_directories(http-server-async-ssl 20 | PRIVATE ${PROJECT_SOURCE_DIR}) 21 | 22 | target_link_libraries(http-server-async-ssl 23 | PRIVATE Boost::beast OpenSSL::SSL OpenSSL::Crypto) 24 | 25 | set_target_properties(http-server-async-ssl 26 | PROPERTIES FOLDER "example-http-server") 27 | -------------------------------------------------------------------------------- /example/http/server/async-ssl/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | import ac ; 11 | 12 | project 13 | : requirements 14 | [ ac.check-library /boost/beast/test//lib-asio-ssl : /boost/beast/test//lib-asio-ssl/static : no ] 15 | ; 16 | 17 | exe http-server-async-ssl : 18 | http_server_async_ssl.cpp 19 | : 20 | coverage:no 21 | ubasan:no 22 | ; 23 | -------------------------------------------------------------------------------- /example/http/server/async/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(http-server-async 12 | Jamfile 13 | http_server_async.cpp) 14 | 15 | source_group("" FILES 16 | Jamfile 17 | http_server_async.cpp) 18 | 19 | target_link_libraries(http-server-async PRIVATE Boost::beast) 20 | 21 | set_target_properties(http-server-async 22 | PROPERTIES FOLDER "example-http-server") 23 | -------------------------------------------------------------------------------- /example/http/server/async/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | exe http-server-async : 11 | http_server_async.cpp 12 | : 13 | coverage:no 14 | ubasan:no 15 | ; 16 | -------------------------------------------------------------------------------- /example/http/server/awaitable/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(http-server-awaitable 12 | Jamfile 13 | http_server_awaitable.cpp) 14 | 15 | source_group("" FILES 16 | Jamfile 17 | http_server_awaitable.cpp) 18 | 19 | target_link_libraries(http-server-awaitable PRIVATE Boost::beast) 20 | 21 | set_target_properties(http-server-awaitable 22 | PROPERTIES FOLDER "example-http-server") 23 | -------------------------------------------------------------------------------- /example/http/server/awaitable/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | exe http-server-awaitable : 11 | http_server_awaitable.cpp 12 | : 13 | coverage:no 14 | ubasan:no 15 | no 16 | ; 17 | -------------------------------------------------------------------------------- /example/http/server/coro-ssl/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(http-server-coro-ssl 12 | Jamfile 13 | http_server_coro_ssl.cpp) 14 | 15 | source_group("" FILES 16 | Jamfile 17 | http_server_coro_ssl.cpp) 18 | 19 | target_include_directories(http-server-coro-ssl 20 | PRIVATE ${PROJECT_SOURCE_DIR}) 21 | 22 | target_link_libraries(http-server-coro-ssl 23 | PRIVATE Boost::beast OpenSSL::SSL OpenSSL::Crypto) 24 | 25 | set_target_properties(http-server-coro-ssl 26 | PROPERTIES FOLDER "example-http-server") 27 | -------------------------------------------------------------------------------- /example/http/server/coro-ssl/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | import ac ; 11 | 12 | project 13 | : requirements 14 | [ ac.check-library /boost/beast/test//lib-asio-ssl : /boost/beast/test//lib-asio-ssl/static : no ] 15 | ; 16 | 17 | exe http-server-coro-ssl : 18 | http_server_coro_ssl.cpp 19 | : 20 | coverage:no 21 | ubasan:no 22 | /boost/context//boost_context 23 | ; 24 | -------------------------------------------------------------------------------- /example/http/server/coro/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(http-server-coro 12 | Jamfile 13 | http_server_coro.cpp) 14 | 15 | source_group("" FILES 16 | Jamfile 17 | http_server_coro.cpp) 18 | 19 | target_link_libraries(http-server-coro PRIVATE Boost::beast) 20 | 21 | set_target_properties(http-server-coro 22 | PROPERTIES FOLDER "example-http-server") 23 | -------------------------------------------------------------------------------- /example/http/server/coro/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | exe http-server-coro : 11 | http_server_coro.cpp 12 | : 13 | coverage:no 14 | ubasan:no 15 | /boost/context//boost_context 16 | ; 17 | -------------------------------------------------------------------------------- /example/http/server/fast/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(http-server-fast 12 | Jamfile 13 | http_server_fast.cpp) 14 | 15 | source_group("" FILES 16 | Jamfile 17 | http_server_fast.cpp) 18 | 19 | target_link_libraries(http-server-fast PRIVATE Boost::beast) 20 | 21 | set_target_properties(http-server-fast 22 | PROPERTIES FOLDER "example-http-server") 23 | -------------------------------------------------------------------------------- /example/http/server/fast/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | exe http-server-fast : 11 | http_server_fast.cpp 12 | : 13 | coverage:no 14 | ubasan:no 15 | ; 16 | -------------------------------------------------------------------------------- /example/http/server/flex/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(http-server-flex 12 | Jamfile 13 | http_server_flex.cpp) 14 | 15 | source_group("" FILES 16 | Jamfile 17 | http_server_flex.cpp) 18 | 19 | target_include_directories(http-server-flex 20 | PRIVATE ${PROJECT_SOURCE_DIR}) 21 | 22 | target_link_libraries(http-server-flex 23 | PRIVATE Boost::beast OpenSSL::SSL OpenSSL::Crypto) 24 | 25 | set_target_properties(http-server-flex 26 | PROPERTIES FOLDER "example-http-server") 27 | -------------------------------------------------------------------------------- /example/http/server/flex/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | import ac ; 11 | 12 | project 13 | : requirements 14 | [ ac.check-library /boost/beast/test//lib-asio-ssl : /boost/beast/test//lib-asio-ssl/static : no ] 15 | ; 16 | 17 | exe http-server-flex : 18 | http_server_flex.cpp 19 | : 20 | coverage:no 21 | ubasan:no 22 | ; 23 | -------------------------------------------------------------------------------- /example/http/server/small/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(http-server-small 12 | Jamfile 13 | http_server_small.cpp) 14 | 15 | source_group("" FILES 16 | Jamfile 17 | http_server_small.cpp) 18 | 19 | target_link_libraries(http-server-small PRIVATE Boost::beast) 20 | 21 | set_target_properties(http-server-small 22 | PROPERTIES FOLDER "example-http-server") 23 | -------------------------------------------------------------------------------- /example/http/server/small/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | exe http-server-small : 11 | http_server_small.cpp 12 | : 13 | coverage:no 14 | ubasan:no 15 | ; 16 | -------------------------------------------------------------------------------- /example/http/server/stackless-ssl/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(http-server-stackless-ssl 12 | Jamfile 13 | http_server_stackless_ssl.cpp) 14 | 15 | source_group("" FILES 16 | Jamfile 17 | http_server_stackless_ssl.cpp) 18 | 19 | target_include_directories(http-server-stackless-ssl 20 | PRIVATE ${PROJECT_SOURCE_DIR}) 21 | 22 | target_link_libraries(http-server-stackless-ssl 23 | PRIVATE Boost::beast OpenSSL::SSL OpenSSL::Crypto) 24 | 25 | set_target_properties(http-server-stackless-ssl 26 | PROPERTIES FOLDER "example-http-server") 27 | -------------------------------------------------------------------------------- /example/http/server/stackless-ssl/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | import ac ; 11 | 12 | project 13 | : requirements 14 | [ ac.check-library /boost/beast/test//lib-asio-ssl : /boost/beast/test//lib-asio-ssl/static : no ] 15 | ; 16 | 17 | exe http-server-stackless-ssl : 18 | http_server_stackless_ssl.cpp 19 | : 20 | coverage:no 21 | ubasan:no 22 | ; 23 | -------------------------------------------------------------------------------- /example/http/server/stackless/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(http-server-stackless 12 | Jamfile 13 | http_server_stackless.cpp) 14 | 15 | source_group("" FILES 16 | Jamfile 17 | http_server_stackless.cpp) 18 | 19 | target_link_libraries(http-server-stackless PRIVATE Boost::beast) 20 | 21 | set_target_properties(http-server-stackless 22 | PROPERTIES FOLDER "example-http-server") 23 | -------------------------------------------------------------------------------- /example/http/server/stackless/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | exe http-server-stackless : 11 | http_server_stackless.cpp 12 | : 13 | coverage:no 14 | ubasan:no 15 | ; 16 | -------------------------------------------------------------------------------- /example/http/server/sync-ssl/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(http-server-sync-ssl 12 | Jamfile 13 | http_server_sync_ssl.cpp) 14 | 15 | source_group("" FILES 16 | Jamfile 17 | http_server_sync_ssl.cpp) 18 | 19 | target_include_directories(http-server-sync-ssl 20 | PRIVATE ${PROJECT_SOURCE_DIR}) 21 | 22 | target_link_libraries(http-server-sync-ssl 23 | PRIVATE Boost::beast OpenSSL::SSL OpenSSL::Crypto) 24 | 25 | set_target_properties(http-server-sync-ssl 26 | PROPERTIES FOLDER "example-http-server") 27 | -------------------------------------------------------------------------------- /example/http/server/sync-ssl/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | import ac ; 11 | 12 | project 13 | : requirements 14 | [ ac.check-library /boost/beast/test//lib-asio-ssl : /boost/beast/test//lib-asio-ssl/static : no ] 15 | ; 16 | 17 | exe http-server-sync-ssl : 18 | http_server_sync_ssl.cpp 19 | : 20 | coverage:no 21 | ubasan:no 22 | ; 23 | -------------------------------------------------------------------------------- /example/http/server/sync/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(http-server-sync 12 | Jamfile 13 | http_server_sync.cpp) 14 | 15 | source_group("" FILES 16 | Jamfile 17 | http_server_sync.cpp) 18 | 19 | target_link_libraries(http-server-sync PRIVATE Boost::beast) 20 | 21 | set_target_properties(http-server-sync 22 | PROPERTIES FOLDER "example-http-server") 23 | -------------------------------------------------------------------------------- /example/http/server/sync/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | exe http-server-sync : 11 | http_server_sync.cpp 12 | : 13 | coverage:no 14 | ubasan:no 15 | ; 16 | -------------------------------------------------------------------------------- /example/websocket/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2013-2017 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 | add_subdirectory(client) 11 | add_subdirectory(server) 12 | -------------------------------------------------------------------------------- /example/websocket/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2013-2017 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 | build-project client ; 11 | build-project server ; 12 | -------------------------------------------------------------------------------- /example/websocket/client/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2013-2017 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 | add_subdirectory(async) 11 | add_subdirectory(async-local) 12 | add_subdirectory(awaitable) 13 | add_subdirectory(coro) 14 | add_subdirectory(sync) 15 | 16 | if (OPENSSL_FOUND) 17 | add_subdirectory(async-ssl) 18 | add_subdirectory(async-ssl-system-executor) 19 | add_subdirectory(coro-ssl) 20 | add_subdirectory(sync-ssl) 21 | endif () 22 | -------------------------------------------------------------------------------- /example/websocket/client/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2013-2017 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 | build-project async ; 11 | build-project async-local ; 12 | build-project awaitable ; 13 | build-project coro ; 14 | build-project sync ; 15 | 16 | # SSL 17 | build-project async-ssl ; 18 | build-project async-ssl-system-executor ; 19 | build-project coro-ssl ; 20 | build-project sync-ssl ; 21 | -------------------------------------------------------------------------------- /example/websocket/client/async-local/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2024 Mohammad Nejati 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 | add_executable(websocket-client-async-local 11 | Jamfile 12 | websocket_client_async_local.cpp) 13 | 14 | source_group("" FILES 15 | Jamfile 16 | websocket_client_async_local.cpp) 17 | 18 | target_link_libraries(websocket-client-async-local PRIVATE Boost::beast) 19 | 20 | set_target_properties(websocket-client-async-local 21 | PROPERTIES FOLDER "example-websocket-client") 22 | -------------------------------------------------------------------------------- /example/websocket/client/async-local/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2025 Mohammad Nejati 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 | exe websocket-client-async-local : 11 | websocket_client_async_local.cpp 12 | : 13 | coverage:no 14 | ubasan:no 15 | ; 16 | -------------------------------------------------------------------------------- /example/websocket/client/async-ssl-system-executor/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(websocket-client-async-ssl-system-executor 12 | Jamfile 13 | websocket_client_async_ssl_system_executor.cpp) 14 | 15 | source_group("" FILES 16 | Jamfile 17 | websocket_client_async_ssl_system_executor.cpp) 18 | 19 | target_include_directories(websocket-client-async-ssl-system-executor 20 | PRIVATE ${PROJECT_SOURCE_DIR}) 21 | 22 | target_link_libraries(websocket-client-async-ssl-system-executor 23 | PRIVATE Boost::beast OpenSSL::SSL OpenSSL::Crypto) 24 | 25 | set_target_properties(websocket-client-async-ssl-system-executor 26 | PROPERTIES FOLDER "example-websocket-client") 27 | -------------------------------------------------------------------------------- /example/websocket/client/async-ssl-system-executor/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | import ac ; 11 | 12 | project 13 | : requirements 14 | [ ac.check-library /boost/beast/test//lib-asio-ssl : /boost/beast/test//lib-asio-ssl/static : no ] 15 | ; 16 | 17 | exe websocket-client-async-ssl-system-executor : 18 | websocket_client_async_ssl_system_executor.cpp 19 | : 20 | coverage:no 21 | ubasan:no 22 | ; 23 | -------------------------------------------------------------------------------- /example/websocket/client/async-ssl/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(websocket-client-async-ssl 12 | Jamfile 13 | websocket_client_async_ssl.cpp) 14 | 15 | source_group("" FILES 16 | Jamfile 17 | websocket_client_async_ssl.cpp) 18 | 19 | target_include_directories(websocket-client-async-ssl 20 | PRIVATE ${PROJECT_SOURCE_DIR}) 21 | 22 | target_link_libraries(websocket-client-async-ssl 23 | PRIVATE Boost::beast OpenSSL::SSL OpenSSL::Crypto) 24 | 25 | set_target_properties(websocket-client-async-ssl 26 | PROPERTIES FOLDER "example-websocket-client") 27 | -------------------------------------------------------------------------------- /example/websocket/client/async-ssl/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | import ac ; 11 | 12 | project 13 | : requirements 14 | [ ac.check-library /boost/beast/test//lib-asio-ssl : /boost/beast/test//lib-asio-ssl/static : no ] 15 | ; 16 | 17 | exe websocket-client-async-ssl : 18 | websocket_client_async_ssl.cpp 19 | : 20 | coverage:no 21 | ubasan:no 22 | ; 23 | -------------------------------------------------------------------------------- /example/websocket/client/async/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(websocket-client-async 12 | Jamfile 13 | websocket_client_async.cpp) 14 | 15 | source_group("" FILES 16 | Jamfile 17 | websocket_client_async.cpp) 18 | 19 | target_link_libraries(websocket-client-async PRIVATE Boost::beast) 20 | 21 | set_target_properties(websocket-client-async 22 | PROPERTIES FOLDER "example-websocket-client") 23 | -------------------------------------------------------------------------------- /example/websocket/client/async/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | exe websocket-client-async : 11 | websocket_client_async.cpp 12 | : 13 | coverage:no 14 | ubasan:no 15 | ; 16 | -------------------------------------------------------------------------------- /example/websocket/client/awaitable/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(websocket-client-awaitable 12 | Jamfile 13 | websocket_client_awaitable.cpp) 14 | 15 | source_group("" FILES 16 | Jamfile 17 | websocket_client_awaitable.cpp) 18 | 19 | target_link_libraries(websocket-client-awaitable PRIVATE Boost::beast) 20 | 21 | set_target_properties(websocket-client-awaitable 22 | PROPERTIES FOLDER "example-websocket-client") 23 | -------------------------------------------------------------------------------- /example/websocket/client/awaitable/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | exe websocket-client-awaitable : 11 | websocket_client_awaitable.cpp 12 | : 13 | coverage:no 14 | ubasan:no 15 | ; 16 | -------------------------------------------------------------------------------- /example/websocket/client/coro-ssl/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(websocket-client-coro-ssl 12 | Jamfile 13 | websocket_client_coro_ssl.cpp) 14 | 15 | source_group("" FILES 16 | Jamfile 17 | websocket_client_coro_ssl.cpp) 18 | 19 | target_include_directories(websocket-client-coro-ssl 20 | PRIVATE ${PROJECT_SOURCE_DIR}) 21 | 22 | target_link_libraries(websocket-client-coro-ssl 23 | PRIVATE Boost::beast OpenSSL::SSL OpenSSL::Crypto) 24 | 25 | set_target_properties(websocket-client-coro-ssl 26 | PROPERTIES FOLDER "example-websocket-client") 27 | -------------------------------------------------------------------------------- /example/websocket/client/coro-ssl/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | import ac ; 11 | 12 | project 13 | : requirements 14 | [ ac.check-library /boost/beast/test//lib-asio-ssl : /boost/beast/test//lib-asio-ssl/static : no ] 15 | ; 16 | 17 | exe websocket-client-coro-ssl : 18 | websocket_client_coro_ssl.cpp 19 | : 20 | coverage:no 21 | ubasan:no 22 | /boost/context//boost_context 23 | ; 24 | -------------------------------------------------------------------------------- /example/websocket/client/coro/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(websocket-client-coro 12 | Jamfile 13 | websocket_client_coro.cpp) 14 | 15 | source_group("" FILES 16 | Jamfile 17 | websocket_client_coro.cpp) 18 | 19 | target_link_libraries(websocket-client-coro PRIVATE Boost::beast) 20 | 21 | set_target_properties(websocket-client-coro 22 | PROPERTIES FOLDER "example-websocket-client") 23 | -------------------------------------------------------------------------------- /example/websocket/client/coro/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | exe websocket-client-coro : 11 | websocket_client_coro.cpp 12 | : 13 | coverage:no 14 | ubasan:no 15 | /boost/context//boost_context 16 | ; 17 | -------------------------------------------------------------------------------- /example/websocket/client/sync-ssl/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(websocket-client-sync-ssl 12 | Jamfile 13 | websocket_client_sync_ssl.cpp) 14 | 15 | source_group("" FILES 16 | Jamfile 17 | websocket_client_sync_ssl.cpp) 18 | 19 | target_include_directories(websocket-client-sync-ssl 20 | PRIVATE ${PROJECT_SOURCE_DIR}) 21 | 22 | target_link_libraries(websocket-client-sync-ssl 23 | PRIVATE Boost::beast OpenSSL::SSL OpenSSL::Crypto) 24 | 25 | set_target_properties(websocket-client-sync-ssl 26 | PROPERTIES FOLDER "example-websocket-client") 27 | -------------------------------------------------------------------------------- /example/websocket/client/sync-ssl/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | import ac ; 11 | 12 | project 13 | : requirements 14 | [ ac.check-library /boost/beast/test//lib-asio-ssl : /boost/beast/test//lib-asio-ssl/static : no ] 15 | ; 16 | 17 | exe websocket-client-sync-ssl : 18 | websocket_client_sync_ssl.cpp 19 | : 20 | coverage:no 21 | ubasan:no 22 | ; 23 | -------------------------------------------------------------------------------- /example/websocket/client/sync/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(websocket-client-sync 12 | Jamfile 13 | websocket_client_sync.cpp) 14 | 15 | source_group("" FILES 16 | Jamfile 17 | websocket_client_sync.cpp) 18 | 19 | target_link_libraries(websocket-client-sync PRIVATE Boost::beast) 20 | 21 | set_target_properties(websocket-client-sync 22 | PROPERTIES FOLDER "example-websocket-client") 23 | -------------------------------------------------------------------------------- /example/websocket/client/sync/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | exe websocket-client-sync : 11 | websocket_client_sync.cpp 12 | : 13 | coverage:no 14 | ubasan:no 15 | ; 16 | -------------------------------------------------------------------------------- /example/websocket/server/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2013-2017 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 | add_subdirectory(async) 11 | add_subdirectory(async-local) 12 | add_subdirectory(awaitable) 13 | add_subdirectory(chat-multi) 14 | add_subdirectory(coro) 15 | add_subdirectory(fast) 16 | add_subdirectory(stackless) 17 | add_subdirectory(sync) 18 | 19 | if (OPENSSL_FOUND) 20 | add_subdirectory(async-ssl) 21 | add_subdirectory(coro-ssl) 22 | add_subdirectory(stackless-ssl) 23 | add_subdirectory(sync-ssl) 24 | endif () 25 | -------------------------------------------------------------------------------- /example/websocket/server/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2013-2017 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 | build-project async ; 11 | build-project async-local ; 12 | build-project awaitable ; 13 | build-project chat-multi ; 14 | build-project coro ; 15 | build-project fast ; 16 | build-project stackless ; 17 | build-project sync ; 18 | 19 | # SSL 20 | build-project async-ssl ; 21 | build-project coro-ssl ; 22 | build-project stackless-ssl ; 23 | build-project sync-ssl ; 24 | -------------------------------------------------------------------------------- /example/websocket/server/async-local/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2025 Mohammad Nejati 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 | add_executable(websocket-server-async-local 11 | Jamfile 12 | websocket_server_async_local.cpp) 13 | 14 | source_group("" FILES 15 | Jamfile 16 | websocket_server_async_local.cpp) 17 | 18 | target_link_libraries(websocket-server-async-local PRIVATE Boost::beast) 19 | 20 | set_target_properties(websocket-server-async-local 21 | PROPERTIES FOLDER "example-websocket-server") 22 | -------------------------------------------------------------------------------- /example/websocket/server/async-local/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2025 Mohammad Nejati 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 | exe websocket-server-async-local : 11 | websocket_server_async_local.cpp 12 | : 13 | coverage:no 14 | ubasan:no 15 | ; 16 | -------------------------------------------------------------------------------- /example/websocket/server/async-ssl/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(websocket-server-async-ssl 12 | Jamfile 13 | websocket_server_async_ssl.cpp) 14 | 15 | source_group("" FILES 16 | Jamfile 17 | websocket_server_async_ssl.cpp) 18 | 19 | target_include_directories(websocket-server-async-ssl 20 | PRIVATE ${PROJECT_SOURCE_DIR}) 21 | 22 | target_link_libraries(websocket-server-async-ssl 23 | PRIVATE Boost::beast OpenSSL::SSL OpenSSL::Crypto) 24 | 25 | set_target_properties(websocket-server-async-ssl 26 | PROPERTIES FOLDER "example-websocket-server") 27 | -------------------------------------------------------------------------------- /example/websocket/server/async-ssl/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | import ac ; 11 | 12 | project 13 | : requirements 14 | [ ac.check-library /boost/beast/test//lib-asio-ssl : /boost/beast/test//lib-asio-ssl/static : no ] 15 | ; 16 | 17 | exe websocket-server-async-ssl : 18 | websocket_server_async_ssl.cpp 19 | : 20 | coverage:no 21 | ubasan:no 22 | ; 23 | -------------------------------------------------------------------------------- /example/websocket/server/async/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(websocket-server-async 12 | Jamfile 13 | websocket_server_async.cpp) 14 | 15 | source_group("" FILES 16 | Jamfile 17 | websocket_server_async.cpp) 18 | 19 | target_link_libraries(websocket-server-async PRIVATE Boost::beast) 20 | 21 | set_target_properties(websocket-server-async 22 | PROPERTIES FOLDER "example-websocket-server") 23 | -------------------------------------------------------------------------------- /example/websocket/server/async/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | exe websocket-server-async : 11 | websocket_server_async.cpp 12 | : 13 | coverage:no 14 | ubasan:no 15 | ; 16 | -------------------------------------------------------------------------------- /example/websocket/server/awaitable/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(websocket-server-awaitable 12 | Jamfile 13 | websocket_server_awaitable.cpp) 14 | 15 | source_group("" FILES 16 | Jamfile 17 | websocket_server_awaitable.cpp) 18 | 19 | target_link_libraries(websocket-server-awaitable PRIVATE Boost::beast) 20 | 21 | set_target_properties(websocket-server-awaitable 22 | PROPERTIES FOLDER "example-websocket-server") 23 | -------------------------------------------------------------------------------- /example/websocket/server/awaitable/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | exe websocket-server-awaitable : 11 | websocket_server_awaitable.cpp 12 | : 13 | coverage:no 14 | ubasan:no 15 | ; 16 | -------------------------------------------------------------------------------- /example/websocket/server/chat-multi/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | exe websocket-chat-multi : 11 | http_session.cpp 12 | listener.cpp 13 | main.cpp 14 | shared_state.cpp 15 | websocket_session.cpp 16 | : 17 | coverage:no 18 | ubasan:no 19 | ; 20 | -------------------------------------------------------------------------------- /example/websocket/server/chat-multi/beast.hpp: -------------------------------------------------------------------------------- 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/vinniefalco/CppCon2018 8 | // 9 | 10 | #ifndef BOOST_BEAST_EXAMPLE_WEBSOCKET_CHAT_MULTI_BEAST_HPP 11 | #define BOOST_BEAST_EXAMPLE_WEBSOCKET_CHAT_MULTI_BEAST_HPP 12 | 13 | #include 14 | 15 | namespace beast = boost::beast; // from 16 | namespace http = beast::http; // from 17 | namespace websocket = beast::websocket; // from 18 | 19 | #endif 20 | -------------------------------------------------------------------------------- /example/websocket/server/chat-multi/net.hpp: -------------------------------------------------------------------------------- 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/vinniefalco/CppCon2018 8 | // 9 | 10 | #ifndef BOOST_BEAST_EXAMPLE_WEBSOCKET_CHAT_MULTI_NET_HPP 11 | #define BOOST_BEAST_EXAMPLE_WEBSOCKET_CHAT_MULTI_NET_HPP 12 | 13 | #include 14 | 15 | namespace net = boost::asio; // from 16 | using tcp = boost::asio::ip::tcp; // from 17 | 18 | #endif 19 | -------------------------------------------------------------------------------- /example/websocket/server/coro-ssl/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(websocket-server-coro-ssl 12 | Jamfile 13 | websocket_server_coro_ssl.cpp) 14 | 15 | source_group("" FILES 16 | Jamfile 17 | websocket_server_coro_ssl.cpp) 18 | 19 | target_include_directories(websocket-server-coro-ssl 20 | PRIVATE ${PROJECT_SOURCE_DIR}) 21 | 22 | target_link_libraries(websocket-server-coro-ssl 23 | PRIVATE Boost::beast OpenSSL::SSL OpenSSL::Crypto) 24 | 25 | set_target_properties(websocket-server-coro-ssl 26 | PROPERTIES FOLDER "example-websocket-server") 27 | -------------------------------------------------------------------------------- /example/websocket/server/coro-ssl/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | import ac ; 11 | 12 | project 13 | : requirements 14 | [ ac.check-library /boost/beast/test//lib-asio-ssl : /boost/beast/test//lib-asio-ssl/static : no ] 15 | ; 16 | 17 | exe websocket-server-coro-ssl : 18 | websocket_server_coro_ssl.cpp 19 | : 20 | coverage:no 21 | ubasan:no 22 | /boost/context//boost_context 23 | ; 24 | -------------------------------------------------------------------------------- /example/websocket/server/coro/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(websocket-server-coro 12 | Jamfile 13 | websocket_server_coro.cpp) 14 | 15 | source_group("" FILES 16 | Jamfile 17 | websocket_server_coro.cpp) 18 | 19 | target_link_libraries(websocket-server-coro PRIVATE Boost::beast) 20 | 21 | set_target_properties(websocket-server-coro 22 | PROPERTIES FOLDER "example-websocket-server") 23 | -------------------------------------------------------------------------------- /example/websocket/server/coro/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | exe websocket-server-coro : 11 | websocket_server_coro.cpp 12 | : 13 | coverage:no 14 | ubasan:no 15 | /boost/context//boost_context 16 | ; 17 | -------------------------------------------------------------------------------- /example/websocket/server/fast/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(websocket-server-fast 12 | Jamfile 13 | websocket_server_fast.cpp) 14 | 15 | source_group("" FILES 16 | Jamfile 17 | websocket_server_fast.cpp) 18 | 19 | target_link_libraries(websocket-server-fast PRIVATE Boost::beast) 20 | 21 | set_target_properties(websocket-server-fast 22 | PROPERTIES FOLDER "example-websocket-server") 23 | -------------------------------------------------------------------------------- /example/websocket/server/fast/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | exe websocket-server-fast : 11 | websocket_server_fast.cpp 12 | : 13 | coverage:no 14 | ubasan:no 15 | /boost/context//boost_context 16 | ; 17 | -------------------------------------------------------------------------------- /example/websocket/server/stackless-ssl/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(websocket-server-stackless-ssl 12 | Jamfile 13 | websocket_server_stackless_ssl.cpp) 14 | 15 | source_group("" FILES 16 | Jamfile 17 | websocket_server_stackless_ssl.cpp) 18 | 19 | target_include_directories(websocket-server-stackless-ssl 20 | PRIVATE ${PROJECT_SOURCE_DIR}) 21 | 22 | target_link_libraries(websocket-server-stackless-ssl 23 | PRIVATE Boost::beast OpenSSL::SSL OpenSSL::Crypto) 24 | 25 | set_target_properties(websocket-server-stackless-ssl 26 | PROPERTIES FOLDER "example-websocket-server") 27 | -------------------------------------------------------------------------------- /example/websocket/server/stackless-ssl/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | import ac ; 11 | 12 | project 13 | : requirements 14 | [ ac.check-library /boost/beast/test//lib-asio-ssl : /boost/beast/test//lib-asio-ssl/static : no ] 15 | ; 16 | 17 | exe websocket-server-stackless-ssl : 18 | websocket_server_stackless_ssl.cpp 19 | : 20 | coverage:no 21 | ubasan:no 22 | ; 23 | -------------------------------------------------------------------------------- /example/websocket/server/stackless/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(websocket-server-stackless 12 | Jamfile 13 | websocket_server_stackless.cpp) 14 | 15 | source_group("" FILES 16 | Jamfile 17 | websocket_server_stackless.cpp) 18 | 19 | target_link_libraries(websocket-server-stackless PRIVATE Boost::beast) 20 | 21 | set_target_properties(websocket-server-stackless 22 | PROPERTIES FOLDER "example-websocket-server") 23 | -------------------------------------------------------------------------------- /example/websocket/server/stackless/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | exe websocket-server-stackless : 11 | websocket_server_stackless.cpp 12 | : 13 | coverage:no 14 | ubasan:no 15 | ; 16 | -------------------------------------------------------------------------------- /example/websocket/server/sync-ssl/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(websocket-server-sync-ssl 12 | Jamfile 13 | websocket_server_sync_ssl.cpp) 14 | 15 | source_group("" FILES 16 | Jamfile 17 | websocket_server_sync_ssl.cpp) 18 | 19 | target_include_directories(websocket-server-sync-ssl 20 | PRIVATE ${PROJECT_SOURCE_DIR}) 21 | 22 | target_link_libraries(websocket-server-sync-ssl 23 | PRIVATE Boost::beast OpenSSL::SSL OpenSSL::Crypto) 24 | 25 | set_target_properties(websocket-server-sync-ssl 26 | PROPERTIES FOLDER "example-websocket-server") 27 | -------------------------------------------------------------------------------- /example/websocket/server/sync-ssl/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | import ac ; 11 | 12 | project 13 | : requirements 14 | [ ac.check-library /boost/beast/test//lib-asio-ssl : /boost/beast/test//lib-asio-ssl/static : no ] 15 | ; 16 | 17 | exe websocket-server-sync-ssl : 18 | websocket_server_sync_ssl.cpp 19 | : 20 | coverage:no 21 | ubasan:no 22 | ; 23 | -------------------------------------------------------------------------------- /example/websocket/server/sync/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(websocket-server-sync 12 | Jamfile 13 | websocket_server_sync.cpp) 14 | 15 | source_group("" FILES 16 | Jamfile 17 | websocket_server_sync.cpp) 18 | 19 | target_link_libraries(websocket-server-sync PRIVATE Boost::beast) 20 | 21 | set_target_properties(websocket-server-sync 22 | PROPERTIES FOLDER "example-websocket-server") 23 | -------------------------------------------------------------------------------- /example/websocket/server/sync/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | exe websocket-server-sync : 11 | websocket_server_sync.cpp 12 | : 13 | coverage:no 14 | ubasan:no 15 | ; 16 | -------------------------------------------------------------------------------- /include/boost/beast.hpp: -------------------------------------------------------------------------------- 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_HPP 11 | #define BOOST_BEAST_HPP 12 | 13 | #include // must come first 14 | 15 | #include 16 | #include 17 | #include 18 | #include 19 | #include 20 | 21 | #endif 22 | -------------------------------------------------------------------------------- /include/boost/beast/_experimental/test/impl/error.hpp: -------------------------------------------------------------------------------- 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_TEST_IMPL_ERROR_HPP 11 | #define BOOST_BEAST_TEST_IMPL_ERROR_HPP 12 | 13 | #include 14 | #include 15 | #include 16 | 17 | namespace boost { 18 | namespace system { 19 | template<> 20 | struct is_error_code_enum< 21 | boost::beast::test::error> 22 | : std::true_type 23 | { 24 | }; 25 | } // system 26 | } // boost 27 | 28 | namespace boost { 29 | namespace beast { 30 | namespace test { 31 | 32 | BOOST_BEAST_DECL 33 | error_code 34 | make_error_code(error e) noexcept; 35 | 36 | } // test 37 | } // beast 38 | } // boost 39 | 40 | #endif 41 | -------------------------------------------------------------------------------- /include/boost/beast/core/detail/service_base.hpp: -------------------------------------------------------------------------------- 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_DETAIL_SERVICE_BASE_HPP 11 | #define BOOST_BEAST_DETAIL_SERVICE_BASE_HPP 12 | 13 | #include 14 | 15 | namespace boost { 16 | namespace beast { 17 | namespace detail { 18 | 19 | template 20 | struct service_base : net::execution_context::service 21 | { 22 | static net::execution_context::id const id; 23 | 24 | explicit 25 | service_base(net::execution_context& ctx) 26 | : net::execution_context::service(ctx) 27 | { 28 | } 29 | }; 30 | 31 | template 32 | net::execution_context::id const service_base::id; 33 | 34 | } // detail 35 | } // beast 36 | } // boost 37 | 38 | #endif 39 | -------------------------------------------------------------------------------- /include/boost/beast/core/impl/error.hpp: -------------------------------------------------------------------------------- 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_IMPL_ERROR_HPP 11 | #define BOOST_BEAST_IMPL_ERROR_HPP 12 | 13 | #include 14 | 15 | namespace boost { 16 | namespace system { 17 | template<> 18 | struct is_error_code_enum<::boost::beast::error> 19 | { 20 | static bool const value = true; 21 | }; 22 | template<> 23 | struct is_error_condition_enum<::boost::beast::condition> 24 | { 25 | static bool const value = true; 26 | }; 27 | } // system 28 | } // boost 29 | 30 | namespace boost { 31 | namespace beast { 32 | 33 | BOOST_BEAST_DECL 34 | error_code 35 | make_error_code(error e); 36 | 37 | BOOST_BEAST_DECL 38 | error_condition 39 | make_error_condition(condition c); 40 | 41 | } // beast 42 | } // boost 43 | 44 | #endif 45 | -------------------------------------------------------------------------------- /include/boost/beast/core/span.hpp: -------------------------------------------------------------------------------- 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_CORE_SPAN_HPP 11 | #define BOOST_BEAST_CORE_SPAN_HPP 12 | 13 | #include 14 | #include 15 | 16 | namespace boost { 17 | namespace beast { 18 | 19 | template 20 | using span = boost::span; 21 | 22 | } // beast 23 | } // boost 24 | 25 | #endif 26 | -------------------------------------------------------------------------------- /include/boost/beast/core/static_string.hpp: -------------------------------------------------------------------------------- 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_STATIC_STRING_HPP 11 | #define BOOST_BEAST_STATIC_STRING_HPP 12 | 13 | #include 14 | #include 15 | 16 | namespace boost { 17 | namespace beast { 18 | 19 | template > 22 | using static_string = boost::static_strings::basic_static_string; 24 | 25 | template 26 | inline auto 27 | to_static_string(Integer x) 28 | -> decltype(boost::static_strings::to_static_string(x)) 29 | { 30 | return boost::static_strings::to_static_string(x); 31 | } 32 | 33 | } // beast 34 | } // boost 35 | 36 | #endif 37 | -------------------------------------------------------------------------------- /include/boost/beast/core/string_type.hpp: -------------------------------------------------------------------------------- 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_STRING_TYPE_HPP 11 | #define BOOST_BEAST_STRING_TYPE_HPP 12 | 13 | #include 14 | #include 15 | 16 | namespace boost { 17 | namespace beast { 18 | 19 | /// The type of string view used by the library 20 | using string_view = boost::core::string_view; 21 | 22 | /// The type of `basic_string_view` used by the library 23 | template 24 | using basic_string_view = 25 | boost::core::basic_string_view; 26 | 27 | template 28 | inline string_view 29 | to_string_view(const S& s) 30 | { 31 | return string_view(s.data(), s.size()); 32 | } 33 | 34 | } // beast 35 | } // boost 36 | 37 | #endif 38 | -------------------------------------------------------------------------------- /include/boost/beast/core/tcp_stream.hpp: -------------------------------------------------------------------------------- 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_CORE_TCP_STREAM_HPP 11 | #define BOOST_BEAST_CORE_TCP_STREAM_HPP 12 | 13 | #include 14 | #include 15 | #include 16 | #include 17 | #include 18 | 19 | namespace boost { 20 | namespace beast { 21 | 22 | /** A TCP/IP stream socket with timeouts and a polymorphic executor. 23 | 24 | @see basic_stream 25 | */ 26 | using tcp_stream = basic_stream< 27 | net::ip::tcp, 28 | net::any_io_executor, 29 | unlimited_rate_policy>; 30 | 31 | } // beast 32 | } // boost 33 | 34 | #endif 35 | -------------------------------------------------------------------------------- /include/boost/beast/http/basic_dynamic_body_fwd.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (c) 2024 Mohammad Nejati 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_HTTP_BASIC_DYNAMIC_BODY_FWD_HPP 11 | #define BOOST_BEAST_HTTP_BASIC_DYNAMIC_BODY_FWD_HPP 12 | 13 | namespace boost { 14 | namespace beast { 15 | namespace http { 16 | 17 | template 18 | struct basic_dynamic_body; 19 | 20 | } // http 21 | } // beast 22 | } // boost 23 | 24 | #endif 25 | -------------------------------------------------------------------------------- /include/boost/beast/http/basic_file_body_fwd.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (c) 2024 Mohammad Nejati 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_HTTP_BASIC_FILE_BODY_FWD_HPP 11 | #define BOOST_BEAST_HTTP_BASIC_FILE_BODY_FWD_HPP 12 | 13 | namespace boost { 14 | namespace beast { 15 | namespace http { 16 | 17 | template 18 | struct basic_file_body; 19 | 20 | } // http 21 | } // beast 22 | } // boost 23 | 24 | #endif 25 | -------------------------------------------------------------------------------- /include/boost/beast/http/buffer_body_fwd.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (c) 2024 Mohammad Nejati 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_HTTP_BUFFER_BODY_FWD_HPP 11 | #define BOOST_BEAST_HTTP_BUFFER_BODY_FWD_HPP 12 | 13 | namespace boost { 14 | namespace beast { 15 | namespace http { 16 | 17 | struct buffer_body; 18 | 19 | } // http 20 | } // beast 21 | } // boost 22 | 23 | #endif 24 | -------------------------------------------------------------------------------- /include/boost/beast/http/dynamic_body.hpp: -------------------------------------------------------------------------------- 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_HTTP_DYNAMIC_BODY_HPP 11 | #define BOOST_BEAST_HTTP_DYNAMIC_BODY_HPP 12 | 13 | #include 14 | 15 | #include 16 | #include 17 | 18 | namespace boost { 19 | namespace beast { 20 | namespace http { 21 | 22 | #if BOOST_BEAST_DOXYGEN 23 | /** A dynamic message body represented by a @ref multi_buffer 24 | 25 | Meets the requirements of Body. 26 | */ 27 | using dynamic_body = basic_dynamic_body; 28 | #endif 29 | 30 | } // http 31 | } // beast 32 | } // boost 33 | 34 | #endif 35 | -------------------------------------------------------------------------------- /include/boost/beast/http/dynamic_body_fwd.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (c) 2024 Mohammad Nejati 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_HTTP_DYNAMIC_BODY_FWD_HPP 11 | #define BOOST_BEAST_HTTP_DYNAMIC_BODY_FWD_HPP 12 | 13 | #include 14 | 15 | #include 16 | 17 | namespace boost { 18 | namespace beast { 19 | 20 | #ifndef BOOST_BEAST_DOXYGEN 21 | template 22 | class basic_multi_buffer; 23 | 24 | using multi_buffer = basic_multi_buffer>; 25 | #endif 26 | 27 | namespace http { 28 | 29 | #ifndef BOOST_BEAST_DOXYGEN 30 | using dynamic_body = basic_dynamic_body; 31 | #endif 32 | 33 | } // http 34 | } // beast 35 | } // boost 36 | 37 | #endif 38 | -------------------------------------------------------------------------------- /include/boost/beast/http/empty_body_fwd.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (c) 2024 Mohammad Nejati 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_HTTP_EMPTY_BODY_FWD_HPP 11 | #define BOOST_BEAST_HTTP_EMPTY_BODY_FWD_HPP 12 | 13 | namespace boost { 14 | namespace beast { 15 | namespace http { 16 | 17 | struct empty_body; 18 | 19 | } // http 20 | } // beast 21 | } // boost 22 | 23 | #endif 24 | -------------------------------------------------------------------------------- /include/boost/beast/http/fields_fwd.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (c) 2024 Mohammad Nejati 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_HTTP_FIELDS_FWD_HPP 11 | #define BOOST_BEAST_HTTP_FIELDS_FWD_HPP 12 | 13 | #include 14 | 15 | namespace boost { 16 | namespace beast { 17 | namespace http { 18 | 19 | template 20 | class basic_fields; 21 | 22 | #ifndef BOOST_BEAST_DOXYGEN 23 | using fields = basic_fields>; 24 | #endif 25 | 26 | } // http 27 | } // beast 28 | } // boost 29 | 30 | #endif 31 | -------------------------------------------------------------------------------- /include/boost/beast/http/file_body_fwd.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (c) 2024 Mohammad Nejati 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_HTTP_FILE_BODY_FWD_HPP 11 | #define BOOST_BEAST_HTTP_FILE_BODY_FWD_HPP 12 | 13 | #include 14 | 15 | #include 16 | 17 | namespace boost { 18 | namespace beast { 19 | namespace http { 20 | 21 | #ifndef BOOST_BEAST_DOXYGEN 22 | using file_body = basic_file_body; 23 | #endif 24 | 25 | } // http 26 | } // beast 27 | } // boost 28 | 29 | #endif 30 | -------------------------------------------------------------------------------- /include/boost/beast/http/impl/error.hpp: -------------------------------------------------------------------------------- 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_HTTP_IMPL_ERROR_HPP 11 | #define BOOST_BEAST_HTTP_IMPL_ERROR_HPP 12 | 13 | #include 14 | 15 | namespace boost { 16 | namespace system { 17 | template<> 18 | struct is_error_code_enum<::boost::beast::http::error> 19 | { 20 | static bool const value = true; 21 | }; 22 | } // system 23 | } // boost 24 | 25 | namespace boost { 26 | namespace beast { 27 | namespace http { 28 | 29 | BOOST_BEAST_DECL 30 | error_code 31 | make_error_code(error ev); 32 | 33 | } // http 34 | } // beast 35 | } // boost 36 | 37 | #endif 38 | -------------------------------------------------------------------------------- /include/boost/beast/http/message_generator_fwd.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (c) 2024 Mohammad Nejati 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_HTTP_MESSAGE_GENERATOR_FWD_HPP 11 | #define BOOST_BEAST_HTTP_MESSAGE_GENERATOR_FWD_HPP 12 | 13 | namespace boost { 14 | namespace beast { 15 | namespace http { 16 | 17 | class message_generator; 18 | 19 | } // http 20 | } // beast 21 | } // boost 22 | 23 | #endif 24 | -------------------------------------------------------------------------------- /include/boost/beast/http/parser_fwd.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (c) 2024 Mohammad Nejati 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_HTTP_PARSER_FWD_HPP 11 | #define BOOST_BEAST_HTTP_PARSER_FWD_HPP 12 | 13 | #include 14 | 15 | namespace boost { 16 | namespace beast { 17 | namespace http { 18 | 19 | #ifndef BOOST_BEAST_DOXYGEN 20 | template< 21 | bool isRequest, 22 | class Body, 23 | class Allocator = std::allocator> 24 | class parser; 25 | 26 | template> 27 | using request_parser = parser; 28 | 29 | template> 30 | using response_parser = parser; 31 | #endif 32 | 33 | } // http 34 | } // beast 35 | } // boost 36 | 37 | #endif 38 | -------------------------------------------------------------------------------- /include/boost/beast/http/serializer_fwd.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (c) 2024 Mohammad Nejati 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_HTTP_SERIALIZER_FWD_HPP 11 | #define BOOST_BEAST_HTTP_SERIALIZER_FWD_HPP 12 | 13 | #include 14 | 15 | namespace boost { 16 | namespace beast { 17 | namespace http { 18 | 19 | #ifndef BOOST_BEAST_DOXYGEN 20 | template 21 | class serializer; 22 | 23 | template 24 | using request_serializer = serializer; 25 | 26 | template 27 | using response_serializer = serializer; 28 | #endif 29 | 30 | } // http 31 | } // beast 32 | } // boost 33 | 34 | #endif 35 | -------------------------------------------------------------------------------- /include/boost/beast/http/span_body_fwd.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (c) 2024 Mohammad Nejati 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_HTTP_SPAN_BODY_FWD_HPP 11 | #define BOOST_BEAST_HTTP_SPAN_BODY_FWD_HPP 12 | 13 | namespace boost { 14 | namespace beast { 15 | namespace http { 16 | 17 | template 18 | struct span_body; 19 | 20 | } // http 21 | } // beast 22 | } // boost 23 | 24 | #endif 25 | -------------------------------------------------------------------------------- /include/boost/beast/http/string_body_fwd.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (c) 2024 Mohammad Nejati 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_HTTP_STRING_BODY_FWD_HPP 11 | #define BOOST_BEAST_HTTP_STRING_BODY_FWD_HPP 12 | 13 | #include 14 | #include 15 | 16 | namespace boost { 17 | namespace beast { 18 | namespace http { 19 | 20 | #ifndef BOOST_BEAST_DOXYGEN 21 | template< 22 | class CharT, 23 | class Traits = std::char_traits, 24 | class Allocator = std::allocator> 25 | struct basic_string_body; 26 | 27 | using string_body = basic_string_body; 28 | #endif 29 | 30 | } // http 31 | } // beast 32 | } // boost 33 | 34 | #endif 35 | -------------------------------------------------------------------------------- /include/boost/beast/http/vector_body_fwd.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (c) 2024 Mohammad Nejati 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_HTTP_VECTOR_BODY_FWD_HPP 11 | #define BOOST_BEAST_HTTP_VECTOR_BODY_FWD_HPP 12 | 13 | #include 14 | 15 | namespace boost { 16 | namespace beast { 17 | namespace http { 18 | 19 | template> 20 | struct vector_body; 21 | 22 | } // http 23 | } // beast 24 | } // boost 25 | 26 | #endif 27 | -------------------------------------------------------------------------------- /include/boost/beast/ssl.hpp: -------------------------------------------------------------------------------- 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_SSL_HPP 11 | #define BOOST_BEAST_SSL_HPP 12 | 13 | #include 14 | 15 | #include 16 | 17 | #endif 18 | -------------------------------------------------------------------------------- /include/boost/beast/version.hpp: -------------------------------------------------------------------------------- 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_VERSION_HPP 11 | #define BOOST_BEAST_VERSION_HPP 12 | 13 | #include 14 | #include 15 | 16 | //[version 17 | 18 | /* Identifies the API version of Beast. 19 | 20 | This is a simple integer that is incremented by one every 21 | time a set of code changes is merged to the develop branch. 22 | */ 23 | #define BOOST_BEAST_VERSION 357 24 | 25 | // A string describing BOOST_BEAST_VERSION, that can be used in http headers. 26 | #define BOOST_BEAST_VERSION_STRING "Boost.Beast/" BOOST_STRINGIZE(BOOST_BEAST_VERSION) 27 | 28 | //] 29 | 30 | #endif 31 | 32 | -------------------------------------------------------------------------------- /include/boost/beast/websocket.hpp: -------------------------------------------------------------------------------- 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_HPP 11 | #define BOOST_BEAST_WEBSOCKET_HPP 12 | 13 | #include 14 | 15 | #include 16 | #include 17 | #include 18 | #include 19 | #include 20 | #include 21 | #include 22 | 23 | #endif 24 | -------------------------------------------------------------------------------- /include/boost/beast/websocket/detail/type_traits.hpp: -------------------------------------------------------------------------------- 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_TYPE_TRAITS_HPP 11 | #define BOOST_BEAST_WEBSOCKET_DETAIL_TYPE_TRAITS_HPP 12 | 13 | #include 14 | #include 15 | 16 | namespace boost { 17 | namespace beast { 18 | namespace websocket { 19 | namespace detail { 20 | 21 | template 22 | using is_request_decorator = 23 | typename beast::detail::is_invocable::type; 25 | 26 | template 27 | using is_response_decorator = 28 | typename beast::detail::is_invocable::type; 30 | 31 | } // detail 32 | } // websocket 33 | } // beast 34 | } // boost 35 | 36 | #endif 37 | -------------------------------------------------------------------------------- /include/boost/beast/websocket/stream_fwd.hpp: -------------------------------------------------------------------------------- 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_STREAM_FWD_HPP 11 | #define BOOST_BEAST_WEBSOCKET_STREAM_FWD_HPP 12 | 13 | #include 14 | 15 | #ifndef BOOST_BEAST_DOXYGEN 16 | 17 | //[code_websocket_1h 18 | 19 | namespace boost { 20 | namespace beast { 21 | namespace websocket { 22 | 23 | template< 24 | class NextLayer, 25 | bool deflateSupported = true> 26 | class stream; 27 | 28 | } // websocket 29 | } // beast 30 | } // boost 31 | 32 | //] 33 | 34 | #endif 35 | 36 | #endif 37 | -------------------------------------------------------------------------------- /include/boost/beast/zlib.hpp: -------------------------------------------------------------------------------- 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_ZLIB_HPP 11 | #define BOOST_BEAST_ZLIB_HPP 12 | 13 | #include 14 | 15 | #include 16 | #include 17 | #include 18 | #include 19 | 20 | #endif 21 | -------------------------------------------------------------------------------- /index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | Boost.Beast 4 | 5 | 6 | 7 | Automatic redirection failed, please go to 8 | ./doc/html/index.html 9 |
10 | 11 | Boost.Beast
12 |
13 | Copyright (C) 2016-2017 Vinnie Falco
14 |
15 | Distributed under the Boost Software License, Version 1.0. 16 | (See accompanying file LICENSE_1_0.txt or copy at 17 | http://www.boost.org/LICENSE_1_0.txt)
18 |
19 |
20 | 21 | 22 | -------------------------------------------------------------------------------- /meta/libraries.json: -------------------------------------------------------------------------------- 1 | { 2 | "key": "beast", 3 | "name": "Beast", 4 | "authors": [ 5 | "Vinnie Falco" 6 | ], 7 | "description": "Portable HTTP, WebSocket, and network operations using only C++11 and Boost.Asio", 8 | "category": [ 9 | "Concurrent", 10 | "IO" 11 | ], 12 | "maintainers": [ 13 | "Vinnie Falco ", 14 | "Mohammad Nejati " 15 | ], 16 | "cxxstd": "11" 17 | } 18 | -------------------------------------------------------------------------------- /test/beast/_experimental/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | local SOURCES = 11 | _test_detail_stream_state.cpp 12 | error.cpp 13 | icy_stream.cpp 14 | stream.cpp 15 | ; 16 | 17 | local RUN_TESTS ; 18 | 19 | for local f in $(SOURCES) 20 | { 21 | RUN_TESTS += [ run $(f) 22 | /boost/beast/test//lib-asio-ssl 23 | /boost/beast/test//lib-test 24 | ] ; 25 | } 26 | 27 | alias run-tests : $(RUN_TESTS) ; 28 | 29 | exe fat-tests : 30 | $(SOURCES) 31 | /boost/beast/test//lib-asio-ssl 32 | /boost/beast/test//lib-test 33 | ; 34 | 35 | explicit fat-tests ; 36 | 37 | run $(SOURCES) 38 | /boost/beast/test//lib-asio-ssl 39 | /boost/beast/test//lib-test 40 | : : : : run-fat-tests ; 41 | 42 | explicit run-fat-tests ; 43 | -------------------------------------------------------------------------------- /test/beast/_experimental/_test_detail_stream_state.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (c) 2016-2021 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | // Copyright (c) 2021 Richard Hodges (hodges.r@gmail.com) 4 | // 5 | // Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | // file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | // 8 | // Official repository: https://github.com/boostorg/beast 9 | // 10 | 11 | // Test that header file is self-contained. 12 | #include 13 | -------------------------------------------------------------------------------- /test/beast/_experimental/error.cpp: -------------------------------------------------------------------------------- 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 | // Test that header file is self-contained. 11 | #include 12 | -------------------------------------------------------------------------------- /test/beast/core.cpp: -------------------------------------------------------------------------------- 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 | // If including Windows.h generates errors, it 11 | // means that min/max macros are being substituted. 12 | #ifdef _MSC_VER 13 | #define WIN32_LEAN_AND_MEAN 14 | #include 15 | #endif 16 | 17 | // Test that header file is self-contained. 18 | #include 19 | -------------------------------------------------------------------------------- /test/beast/core/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | file(GLOB_RECURSE PFILES CONFIGURE_DEPENDS Jamfile *.cpp *.hpp) 12 | 13 | add_executable(boost_beast_tests_core ${PFILES}) 14 | 15 | source_group("" FILES ${PFILES}) 16 | 17 | target_link_libraries(boost_beast_tests_core 18 | boost_beast_lib_test 19 | Boost::filesystem) 20 | 21 | set_target_properties(boost_beast_tests_core 22 | PROPERTIES FOLDER "tests") 23 | 24 | add_test(NAME boost_beast_tests_core COMMAND boost_beast_tests_core) 25 | add_dependencies(tests boost_beast_tests_core) 26 | -------------------------------------------------------------------------------- /test/beast/core/file.cpp: -------------------------------------------------------------------------------- 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 | // Test that header file is self-contained. 11 | #include 12 | -------------------------------------------------------------------------------- /test/beast/core/file_base.cpp: -------------------------------------------------------------------------------- 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 | // Test that header file is self-contained. 11 | #include 12 | -------------------------------------------------------------------------------- /test/beast/core/file_posix.cpp: -------------------------------------------------------------------------------- 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 | // Test that header file is self-contained. 11 | #include 12 | 13 | #if BOOST_BEAST_USE_POSIX_FILE 14 | 15 | #include "file_test.hpp" 16 | 17 | #include 18 | 19 | namespace boost { 20 | namespace beast { 21 | 22 | BOOST_STATIC_ASSERT(! std::is_copy_constructible::value); 23 | 24 | class file_posix_test 25 | : public beast::unit_test::suite 26 | { 27 | public: 28 | void 29 | run() 30 | { 31 | test_file(); 32 | } 33 | }; 34 | 35 | BEAST_DEFINE_TESTSUITE(beast,core,file_posix); 36 | 37 | } // beast 38 | } // boost 39 | 40 | #endif 41 | -------------------------------------------------------------------------------- /test/beast/core/file_stdio.cpp: -------------------------------------------------------------------------------- 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 | // Test that header file is self-contained. 11 | #include 12 | 13 | #include "file_test.hpp" 14 | 15 | #include 16 | 17 | namespace boost { 18 | namespace beast { 19 | 20 | BOOST_STATIC_ASSERT(! std::is_copy_constructible::value); 21 | 22 | class file_stdio_test 23 | : public beast::unit_test::suite 24 | { 25 | public: 26 | void 27 | run() 28 | { 29 | #ifdef BOOST_MSVC 30 | test_file(); 31 | #else 32 | test_file(); 33 | #endif 34 | } 35 | }; 36 | 37 | BEAST_DEFINE_TESTSUITE(beast,core,file_stdio); 38 | 39 | } // beast 40 | } // boost 41 | -------------------------------------------------------------------------------- /test/beast/core/file_win32.cpp: -------------------------------------------------------------------------------- 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 | // Test that header file is self-contained. 11 | #include 12 | 13 | #if BOOST_BEAST_USE_WIN32_FILE 14 | 15 | #include "file_test.hpp" 16 | 17 | #include 18 | 19 | namespace boost { 20 | namespace beast { 21 | 22 | class file_win32_test 23 | : public beast::unit_test::suite 24 | { 25 | public: 26 | void 27 | run() 28 | { 29 | test_file(); 30 | } 31 | }; 32 | 33 | BEAST_DEFINE_TESTSUITE(beast,core,file_win32); 34 | 35 | } // beast 36 | } // boost 37 | 38 | #endif 39 | -------------------------------------------------------------------------------- /test/beast/core/role.cpp: -------------------------------------------------------------------------------- 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 | // Test that header file is self-contained. 11 | #include 12 | -------------------------------------------------------------------------------- /test/beast/core/span.cpp: -------------------------------------------------------------------------------- 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 | // Test that header file is self-contained. 11 | #include 12 | 13 | #include 14 | #include 15 | 16 | #include 17 | 18 | namespace boost { 19 | namespace beast { 20 | 21 | class span_test : public beast::unit_test::suite 22 | { 23 | public: 24 | void 25 | testSpan() 26 | { 27 | span sp{"hello", 5}; 28 | BEAST_EXPECT(sp.size() == 5); 29 | std::string s("world"); 30 | sp = s; 31 | } 32 | 33 | void 34 | run() override 35 | { 36 | testSpan(); 37 | } 38 | }; 39 | 40 | BEAST_DEFINE_TESTSUITE(beast,core,span); 41 | 42 | } // beast 43 | } // boost 44 | -------------------------------------------------------------------------------- /test/beast/core/string.cpp: -------------------------------------------------------------------------------- 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 | // Test that header file is self-contained. 11 | #include 12 | -------------------------------------------------------------------------------- /test/beast/http.cpp: -------------------------------------------------------------------------------- 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 | // If including Windows.h generates errors, it 11 | // means that min/max macros are being substituted. 12 | #ifdef _MSC_VER 13 | #define WIN32_LEAN_AND_MEAN 14 | #include 15 | #endif 16 | 17 | // Test that header file is self-contained. 18 | #include 19 | -------------------------------------------------------------------------------- /test/beast/http/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | file(GLOB_RECURSE PFILES CONFIGURE_DEPENDS Jamfile *.cpp *.hpp) 12 | 13 | add_executable(boost_beast_tests_http ${PFILES}) 14 | 15 | source_group("" FILES ${PFILES}) 16 | 17 | target_link_libraries(boost_beast_tests_http 18 | boost_beast_lib_test 19 | Boost::filesystem) 20 | 21 | set_target_properties(boost_beast_tests_http 22 | PROPERTIES FOLDER "tests") 23 | 24 | add_test(NAME boost_beast_tests_http COMMAND boost_beast_tests_http) 25 | add_dependencies(tests boost_beast_tests_http) 26 | -------------------------------------------------------------------------------- /test/beast/http/basic_dynamic_body.cpp: -------------------------------------------------------------------------------- 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 | // Test that header file is self-contained. 11 | #include 12 | -------------------------------------------------------------------------------- /test/beast/http/basic_dynamic_body_fwd.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (c) 2024 Mohammad Nejati 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 | // Test that header file is self-contained. 11 | #include 12 | -------------------------------------------------------------------------------- /test/beast/http/basic_file_body.cpp: -------------------------------------------------------------------------------- 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 | // Test that header file is self-contained. 11 | #include 12 | -------------------------------------------------------------------------------- /test/beast/http/basic_file_body_fwd.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (c) 2024 Mohammad Nejati 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 | // Test that header file is self-contained. 11 | #include 12 | -------------------------------------------------------------------------------- /test/beast/http/buffer_body_fwd.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (c) 2024 Mohammad Nejati 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 | // Test that header file is self-contained. 11 | #include 12 | -------------------------------------------------------------------------------- /test/beast/http/dynamic_body_fwd.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (c) 2024 Mohammad Nejati 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 | // Test that header file is self-contained. 11 | #include 12 | -------------------------------------------------------------------------------- /test/beast/http/empty_body.cpp: -------------------------------------------------------------------------------- 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 | // Test that header file is self-contained. 11 | #include 12 | 13 | #include 14 | 15 | namespace boost { 16 | namespace beast { 17 | namespace http { 18 | 19 | BOOST_STATIC_ASSERT(is_body::value); 20 | BOOST_STATIC_ASSERT(is_body_writer::value); 21 | BOOST_STATIC_ASSERT(is_body_reader::value); 22 | 23 | } // http 24 | } // beast 25 | } // boost 26 | -------------------------------------------------------------------------------- /test/beast/http/empty_body_fwd.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (c) 2024 Mohammad Nejati 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 | // Test that header file is self-contained. 11 | #include 12 | -------------------------------------------------------------------------------- /test/beast/http/field_compiles.cpp: -------------------------------------------------------------------------------- 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 | // Test that header file is self-contained. 11 | #include 12 | -------------------------------------------------------------------------------- /test/beast/http/fields_fwd.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (c) 2024 Mohammad Nejati 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 | // Test that header file is self-contained. 11 | #include 12 | -------------------------------------------------------------------------------- /test/beast/http/file_body_fwd.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (c) 2024 Mohammad Nejati 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 | // Test that header file is self-contained. 11 | #include 12 | -------------------------------------------------------------------------------- /test/beast/http/message_fwd.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (c) 2024 Mohammad Nejati 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 | // Test that header file is self-contained. 11 | #include 12 | -------------------------------------------------------------------------------- /test/beast/http/message_generator_fwd.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (c) 2024 Mohammad Nejati 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 | // Test that header file is self-contained. 11 | #include 12 | -------------------------------------------------------------------------------- /test/beast/http/parser_fwd.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (c) 2024 Mohammad Nejati 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 | // Test that header file is self-contained. 11 | #include 12 | -------------------------------------------------------------------------------- /test/beast/http/serializer_fwd.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (c) 2024 Mohammad Nejati 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 | // Test that header file is self-contained. 11 | #include 12 | -------------------------------------------------------------------------------- /test/beast/http/span_body_fwd.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (c) 2024 Mohammad Nejati 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 | // Test that header file is self-contained. 11 | #include 12 | -------------------------------------------------------------------------------- /test/beast/http/string_body.cpp: -------------------------------------------------------------------------------- 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 | // Test that header file is self-contained. 11 | #include 12 | 13 | #include 14 | 15 | namespace boost { 16 | namespace beast { 17 | namespace http { 18 | 19 | BOOST_STATIC_ASSERT(is_body::value); 20 | BOOST_STATIC_ASSERT(is_body_writer::value); 21 | BOOST_STATIC_ASSERT(is_body_reader::value); 22 | 23 | } // http 24 | } // beast 25 | } // boost 26 | -------------------------------------------------------------------------------- /test/beast/http/string_body_fwd.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (c) 2024 Mohammad Nejati 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 | // Test that header file is self-contained. 11 | #include 12 | -------------------------------------------------------------------------------- /test/beast/http/vector_body_fwd.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (c) 2024 Mohammad Nejati 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 | // Test that header file is self-contained. 11 | #include 12 | -------------------------------------------------------------------------------- /test/beast/ssl.cpp: -------------------------------------------------------------------------------- 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 | // If including Windows.h generates errors, it 11 | // means that min/max macros are being substituted. 12 | #ifdef _MSC_VER 13 | #define WIN32_LEAN_AND_MEAN 14 | #include 15 | #endif 16 | 17 | // Test that header file is self-contained. 18 | #include 19 | -------------------------------------------------------------------------------- /test/beast/ssl/CMakeLists.txt: -------------------------------------------------------------------------------- 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 | add_executable (boost_beast_tests_ssl 11 | Jamfile 12 | ssl_stream.cpp) 13 | 14 | source_group("" FILES 15 | Jamfile 16 | ssl_stream.cpp) 17 | 18 | target_link_libraries(boost_beast_tests_ssl 19 | boost_beast_lib_asio_ssl 20 | boost_beast_lib_test) 21 | 22 | set_target_properties(boost_beast_tests_ssl 23 | PROPERTIES FOLDER "tests") 24 | 25 | add_test(NAME boost_beast_tests_ssl COMMAND boost_beast_tests_ssl) 26 | add_dependencies(tests boost_beast_tests_ssl) 27 | -------------------------------------------------------------------------------- /test/beast/ssl/Jamfile: -------------------------------------------------------------------------------- 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 | local SOURCES = 11 | ssl_stream.cpp 12 | ; 13 | 14 | local RUN_TESTS ; 15 | 16 | for local f in $(SOURCES) 17 | { 18 | RUN_TESTS += [ run $(f) 19 | /boost/beast/test//lib-asio-ssl 20 | /boost/beast/test//lib-test 21 | ] ; 22 | } 23 | 24 | alias run-tests : $(RUN_TESTS) ; 25 | 26 | exe fat-tests 27 | : 28 | $(SOURCES) 29 | /boost/beast/test//lib-asio-ssl 30 | /boost/beast/test//lib-test 31 | ; 32 | 33 | explicit fat-tests ; 34 | 35 | run $(SOURCES) 36 | /boost/beast/test//lib-asio-ssl 37 | /boost/beast/test//lib-test 38 | : : : : run-fat-tests ; 39 | 40 | explicit run-fat-tests ; 41 | -------------------------------------------------------------------------------- /test/beast/ssl/ssl_stream.cpp: -------------------------------------------------------------------------------- 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 | // Test that header file is self-contained. 11 | #include 12 | -------------------------------------------------------------------------------- /test/beast/version.cpp: -------------------------------------------------------------------------------- 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 | // If including Windows.h generates errors, it 11 | // means that min/max macros are being substituted. 12 | #ifdef _MSC_VER 13 | #define WIN32_LEAN_AND_MEAN 14 | #include 15 | #endif 16 | 17 | // Test that header file is self-contained. 18 | #include 19 | -------------------------------------------------------------------------------- /test/beast/websocket.cpp: -------------------------------------------------------------------------------- 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 | // If including Windows.h generates errors, it 11 | // means that min/max macros are being substituted. 12 | #ifdef _MSC_VER 13 | #define WIN32_LEAN_AND_MEAN 14 | #include 15 | #endif 16 | 17 | // Test that header file is self-contained. 18 | #include 19 | -------------------------------------------------------------------------------- /test/beast/websocket/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | file(GLOB_RECURSE PFILES CONFIGURE_DEPENDS Jamfile *.cpp *.hpp) 12 | 13 | add_executable(boost_beast_tests_websocket ${PFILES}) 14 | 15 | source_group("" FILES ${PFILES}) 16 | 17 | target_link_libraries(boost_beast_tests_websocket 18 | boost_beast_lib_asio_ssl 19 | boost_beast_lib_test) 20 | 21 | set_target_properties(boost_beast_tests_websocket 22 | PROPERTIES FOLDER "tests") 23 | 24 | add_test(NAME boost_beast_tests_websocket COMMAND boost_beast_tests_websocket) 25 | add_dependencies(tests boost_beast_tests_websocket) 26 | -------------------------------------------------------------------------------- /test/beast/websocket/_detail_impl_base.cpp: -------------------------------------------------------------------------------- 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 | // Test that header file is self-contained. 11 | #include 12 | -------------------------------------------------------------------------------- /test/beast/websocket/option.cpp: -------------------------------------------------------------------------------- 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 | // Test that header file is self-contained. 11 | #include 12 | -------------------------------------------------------------------------------- /test/beast/websocket/stream_explicit.cpp: -------------------------------------------------------------------------------- 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 | // Test that header file is self-contained. 11 | #include 12 | 13 | #include 14 | #include 15 | 16 | namespace boost { 17 | namespace beast { 18 | 19 | template class websocket::stream; 20 | template class websocket::stream; 21 | 22 | } // beast 23 | } // boost 24 | -------------------------------------------------------------------------------- /test/beast/websocket/stream_fwd.cpp: -------------------------------------------------------------------------------- 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 | // Test that header file is self-contained. 11 | #include 12 | -------------------------------------------------------------------------------- /test/beast/websocket/teardown.cpp: -------------------------------------------------------------------------------- 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 | // Test that header file is self-contained. 11 | #include 12 | -------------------------------------------------------------------------------- /test/beast/zlib.cpp: -------------------------------------------------------------------------------- 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 | // If including Windows.h generates errors, it 11 | // means that min/max macros are being substituted. 12 | #ifdef _MSC_VER 13 | #define WIN32_LEAN_AND_MEAN 14 | #include 15 | #endif 16 | 17 | // Test that header file is self-contained. 18 | #include 19 | -------------------------------------------------------------------------------- /test/beast/zlib/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | local SOURCES = 11 | error.cpp 12 | deflate_stream.cpp 13 | inflate_stream.cpp 14 | zlib.cpp 15 | ; 16 | 17 | local RUN_TESTS ; 18 | 19 | for local f in $(SOURCES) 20 | { 21 | RUN_TESTS += [ run $(f) 22 | /boost/beast/test//lib-zlib 23 | /boost/beast/test//lib-test 24 | ] ; 25 | } 26 | 27 | alias run-tests : $(RUN_TESTS) ; 28 | 29 | exe fat-tests : 30 | $(SOURCES) 31 | /boost/beast/test//lib-zlib 32 | /boost/beast/test//lib-test 33 | ; 34 | 35 | explicit fat-tests ; 36 | 37 | run 38 | $(SOURCES) 39 | /boost/beast/test//lib-zlib 40 | /boost/beast/test//lib-test 41 | : : : : run-fat-tests ; 42 | 43 | explicit run-fat-tests ; 44 | -------------------------------------------------------------------------------- /test/beast/zlib/zlib.cpp: -------------------------------------------------------------------------------- 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 | // Make sure symbols don't conflict with ZLib 11 | #include "zlib-1.2.12/zlib.h" 12 | #include 13 | -------------------------------------------------------------------------------- /test/bench/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_subdirectory(buffers) 12 | add_subdirectory(parser) 13 | add_subdirectory(utf8_checker) 14 | add_subdirectory(wsload) 15 | add_subdirectory(zlib) 16 | -------------------------------------------------------------------------------- /test/bench/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | alias run-tests : 11 | buffers//run-tests 12 | parser//run-tests 13 | wsload//run-tests 14 | utf8_checker//run-tests 15 | #zlib//run-tests # Not built, too slow 16 | ; 17 | -------------------------------------------------------------------------------- /test/bench/buffers/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(boost_beast_bench_buffers 12 | Jamfile 13 | bench_buffers.cpp) 14 | 15 | source_group("" FILES 16 | Jamfile 17 | bench_buffers.cpp) 18 | 19 | target_link_libraries(boost_beast_bench_buffers 20 | boost_beast_lib_test) 21 | 22 | set_target_properties(boost_beast_bench_buffers 23 | PROPERTIES FOLDER "tests-bench") 24 | -------------------------------------------------------------------------------- /test/bench/buffers/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | exe bench-buffers : 11 | bench_buffers.cpp 12 | /boost/beast/test//lib-test 13 | ; 14 | 15 | explicit bench-buffers ; 16 | 17 | alias run-tests : 18 | [ compile bench_buffers.cpp ] 19 | ; 20 | -------------------------------------------------------------------------------- /test/bench/parser/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(boost_beast_bench_parser 12 | Jamfile 13 | nodejs_parser.hpp 14 | nodejs_parser.cpp 15 | bench_parser.cpp) 16 | 17 | source_group("" FILES 18 | Jamfile 19 | nodejs_parser.hpp 20 | nodejs_parser.cpp 21 | bench_parser.cpp) 22 | 23 | target_include_directories(boost_beast_bench_parser 24 | PRIVATE ${PROJECT_SOURCE_DIR}) 25 | 26 | target_link_libraries(boost_beast_bench_parser 27 | boost_beast_lib_test) 28 | 29 | set_target_properties(boost_beast_bench_parser 30 | PROPERTIES FOLDER "tests-bench") 31 | -------------------------------------------------------------------------------- /test/bench/parser/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | project : requirements /boost/beast/test//lib-test ; 11 | 12 | run 13 | nodejs_parser.cpp 14 | bench_parser.cpp 15 | : : : : 16 | bench-parser ; 17 | 18 | explicit bench-parser ; 19 | 20 | alias run-tests : 21 | [ compile nodejs_parser.cpp ] 22 | [ compile bench_parser.cpp ] 23 | ; 24 | -------------------------------------------------------------------------------- /test/bench/parser/nodejs_parser.cpp: -------------------------------------------------------------------------------- 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 | #if defined(__GNUC__) && (__GNUC__ >= 7) 11 | #pragma GCC diagnostic push 12 | #pragma GCC diagnostic ignored "-Wimplicit-fallthrough" 13 | #endif 14 | 15 | #include 16 | 17 | #ifdef BOOST_MSVC 18 | # pragma warning (push) 19 | # pragma warning (disable: 4127) // conditional expression is constant 20 | # pragma warning (disable: 4244) // integer conversion, possible loss of data 21 | #endif 22 | 23 | #include "nodejs-parser/http_parser.c" 24 | 25 | #ifdef BOOST_MSVC 26 | # pragma warning (pop) 27 | #endif 28 | 29 | #if defined(__GNUC__) && (__GNUC__ >= 7) 30 | #pragma GCC diagnostic pop 31 | #endif 32 | -------------------------------------------------------------------------------- /test/bench/utf8_checker/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(boost_beast_bench_utf8_checker 12 | Jamfile 13 | bench_utf8_checker.cpp) 14 | 15 | source_group("" FILES 16 | Jamfile 17 | bench_utf8_checker.cpp) 18 | 19 | target_link_libraries(boost_beast_bench_utf8_checker 20 | boost_beast_lib_test) 21 | 22 | set_target_properties(boost_beast_bench_utf8_checker 23 | PROPERTIES FOLDER "tests-bench") 24 | -------------------------------------------------------------------------------- /test/bench/utf8_checker/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | exe bench-utf8-checker : bench_utf8_checker.cpp 11 | : requirements 12 | /boost/beast/test//lib-test 13 | ; 14 | 15 | explicit bench-utf8-checker ; 16 | 17 | alias run-tests : 18 | [ compile bench_utf8_checker.cpp ] 19 | ; 20 | -------------------------------------------------------------------------------- /test/bench/wsload/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(boost_beast_bench_wsload 12 | Jamfile 13 | wsload.cpp) 14 | 15 | source_group("" FILES 16 | Jamfile 17 | wsload.cpp) 18 | 19 | target_link_libraries(boost_beast_bench_wsload 20 | boost_beast_lib_beast) 21 | 22 | set_target_properties(boost_beast_bench_wsload 23 | PROPERTIES FOLDER "tests-bench") 24 | -------------------------------------------------------------------------------- /test/bench/wsload/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | exe wsload : 11 | wsload.cpp 12 | ; 13 | 14 | explicit wsload ; 15 | 16 | alias run-tests : 17 | [ compile wsload.cpp : : wsload-compile ] 18 | ; 19 | -------------------------------------------------------------------------------- /test/bench/zlib/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_executable(boost_beast_bench_zlib 12 | Jamfile 13 | deflate_stream.cpp 14 | inflate_stream.cpp) 15 | 16 | source_group("" FILES 17 | Jamfile 18 | deflate_stream.cpp 19 | inflate_stream.cpp) 20 | 21 | target_include_directories(boost_beast_bench_zlib 22 | PRIVATE ${PROJECT_SOURCE_DIR}/test/extern) 23 | 24 | target_link_libraries(boost_beast_bench_zlib 25 | boost_beast_lib_test 26 | boost_beast_lib_zlib) 27 | 28 | set_target_properties(boost_beast_bench_zlib 29 | PROPERTIES FOLDER "tests-bench") 30 | -------------------------------------------------------------------------------- /test/bench/zlib/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | exe bench-zlib : 11 | $(ZLIB_SOURCES) 12 | deflate_stream.cpp 13 | inflate_stream.cpp 14 | /boost/beast/test//lib-test 15 | ; 16 | -------------------------------------------------------------------------------- /test/cmake_test/main.cpp: -------------------------------------------------------------------------------- 1 | #include 2 | 3 | int main() { 4 | 5 | } 6 | -------------------------------------------------------------------------------- /test/doc/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | file(GLOB_RECURSE PFILES CONFIGURE_DEPENDS Jamfile *.cpp *.ipp *.hpp) 12 | 13 | add_executable(boost_beast_tests_doc ${PFILES}) 14 | 15 | source_group("" FILES ${PFILES}) 16 | 17 | target_include_directories(boost_beast_tests_doc 18 | PRIVATE ${PROJECT_SOURCE_DIR}) 19 | 20 | target_link_libraries(boost_beast_tests_doc 21 | boost_beast_lib_asio_ssl 22 | boost_beast_lib_test) 23 | 24 | set_target_properties(boost_beast_tests_doc 25 | PROPERTIES FOLDER "tests") 26 | 27 | add_test(NAME boost_beast_tests_doc COMMAND boost_beast_tests_doc) 28 | add_dependencies(tests boost_beast_tests_doc) 29 | -------------------------------------------------------------------------------- /test/doc/snippets.hpp: -------------------------------------------------------------------------------- 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 SNIPPETS_HPP 11 | #define SNIPPETS_HPP 12 | 13 | // This file must be included before including snippets.ipp 14 | 15 | #include 16 | #include 17 | #include 18 | #include 19 | #include 20 | 21 | #endif 22 | -------------------------------------------------------------------------------- /test/doc/snippets.ipp: -------------------------------------------------------------------------------- 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 | // This header file is designed to be included multiple times 11 | // inside of function bodies holding documentation snippets. 12 | 13 | using namespace boost::beast; 14 | namespace net = boost::asio; 15 | namespace ssl = boost::asio::ssl; 16 | using tcp = net::ip::tcp; 17 | 18 | error_code ec; 19 | net::io_context ioc; 20 | net::any_io_executor work = 21 | net::require( 22 | ioc.get_executor(), 23 | net::execution::outstanding_work.tracked); 24 | std::thread t{[&](){ ioc.run(); }}; 25 | 26 | tcp::socket sock(ioc); 27 | 28 | ssl::context ctx(ssl::context::tlsv12); 29 | 30 | boost::ignore_unused(ec); 31 | -------------------------------------------------------------------------------- /test/doc/websocket_common.ipp: -------------------------------------------------------------------------------- 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 | //[code_websocket_1b 11 | 12 | namespace net = boost::asio; 13 | namespace beast = boost::beast; 14 | using namespace boost::beast; 15 | using namespace boost::beast::websocket; 16 | 17 | net::io_context ioc; 18 | tcp_stream sock(ioc); 19 | net::ssl::context ctx(net::ssl::context::tlsv12); 20 | 21 | //] 22 | -------------------------------------------------------------------------------- /test/example/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) 3 | # Copyright (c) 2024 Mohammad Nejati 4 | # 5 | # Distributed under the Boost Software License, Version 1.0. (See accompanying 6 | # file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 7 | # 8 | # Official repository: https://github.com/boostorg/beast 9 | # 10 | 11 | add_subdirectory(common) 12 | -------------------------------------------------------------------------------- /test/example/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | alias run-tests : 11 | common//run-tests 12 | ; 13 | 14 | alias fat-tests ; 15 | 16 | explicit fat-tests ; 17 | 18 | alias run-fat-tests : common//run-tests ; 19 | 20 | explicit run-fat-tests ; 21 | -------------------------------------------------------------------------------- /test/example/common/Jamfile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 2016-2017 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 | project 11 | : requirements 12 | ../../.. ; 13 | 14 | local SOURCES = 15 | root_certificates.cpp 16 | server_certificate.cpp 17 | ; 18 | 19 | local RUN_TESTS ; 20 | 21 | local libs = 22 | /boost/beast/test//lib-asio-ssl 23 | /boost/beast/test//lib-test 24 | ; 25 | 26 | for local f in $(SOURCES) 27 | { 28 | RUN_TESTS += [ run $(f) $(libs) ] ; 29 | } 30 | 31 | alias run-tests : $(RUN_TESTS) ; 32 | -------------------------------------------------------------------------------- /test/example/common/root_certificates.cpp: -------------------------------------------------------------------------------- 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 | // Test that header file is self-contained. 11 | #include "example/common/root_certificates.hpp" 12 | -------------------------------------------------------------------------------- /test/example/common/server_certificate.cpp: -------------------------------------------------------------------------------- 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 | // Test that header file is self-contained. 11 | #include "example/common/server_certificate.hpp" 12 | -------------------------------------------------------------------------------- /test/extern/zlib-1.2.12/.gitignore: -------------------------------------------------------------------------------- 1 | *.diff 2 | *.patch 3 | *.orig 4 | *.rej 5 | 6 | *~ 7 | *.a 8 | *.lo 9 | *.o 10 | *.dylib 11 | 12 | *.gcda 13 | *.gcno 14 | *.gcov 15 | 16 | /example 17 | /example64 18 | /examplesh 19 | /libz.so* 20 | /minigzip 21 | /minigzip64 22 | /minigzipsh 23 | /zlib.pc 24 | /configure.log 25 | 26 | .DS_Store 27 | -------------------------------------------------------------------------------- /test/extern/zlib-1.2.12/Makefile: -------------------------------------------------------------------------------- 1 | all: 2 | -@echo "Please use ./configure first. Thank you." 3 | 4 | distclean: 5 | make -f Makefile.in distclean 6 | -------------------------------------------------------------------------------- /test/extern/zlib-1.2.12/contrib/ada/zlib.gpr: -------------------------------------------------------------------------------- 1 | project Zlib is 2 | 3 | for Languages use ("Ada"); 4 | for Source_Dirs use ("."); 5 | for Object_Dir use "."; 6 | for Main use ("test.adb", "mtest.adb", "read.adb", "buffer_demo"); 7 | 8 | package Compiler is 9 | for Default_Switches ("ada") use ("-gnatwcfilopru", "-gnatVcdfimorst", "-gnatyabcefhiklmnoprst"); 10 | end Compiler; 11 | 12 | package Linker is 13 | for Default_Switches ("ada") use ("-lz"); 14 | end Linker; 15 | 16 | package Builder is 17 | for Default_Switches ("ada") use ("-s", "-gnatQ"); 18 | end Builder; 19 | 20 | end Zlib; 21 | -------------------------------------------------------------------------------- /test/extern/zlib-1.2.12/contrib/blast/Makefile: -------------------------------------------------------------------------------- 1 | blast: blast.c blast.h 2 | cc -DTEST -o blast blast.c 3 | 4 | test: blast 5 | blast < test.pk | cmp - test.txt 6 | 7 | clean: 8 | rm -f blast blast.o 9 | -------------------------------------------------------------------------------- /test/extern/zlib-1.2.12/contrib/blast/README: -------------------------------------------------------------------------------- 1 | Read blast.h for purpose and usage. 2 | 3 | Mark Adler 4 | madler@alumni.caltech.edu 5 | -------------------------------------------------------------------------------- /test/extern/zlib-1.2.12/contrib/blast/test.pk: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/boostorg/beast/916dcf8eb3eff582356f7b1849446a3893da6eac/test/extern/zlib-1.2.12/contrib/blast/test.pk -------------------------------------------------------------------------------- /test/extern/zlib-1.2.12/contrib/blast/test.txt: -------------------------------------------------------------------------------- 1 | AIAIAIAIAIAIA -------------------------------------------------------------------------------- /test/extern/zlib-1.2.12/contrib/delphi/ZLibConst.pas: -------------------------------------------------------------------------------- 1 | unit ZLibConst; 2 | 3 | interface 4 | 5 | resourcestring 6 | sTargetBufferTooSmall = 'ZLib error: target buffer may be too small'; 7 | sInvalidStreamOp = 'Invalid stream operation'; 8 | 9 | implementation 10 | 11 | end. 12 | -------------------------------------------------------------------------------- /test/extern/zlib-1.2.12/contrib/dotzlib/DotZLib.chm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/boostorg/beast/916dcf8eb3eff582356f7b1849446a3893da6eac/test/extern/zlib-1.2.12/contrib/dotzlib/DotZLib.chm -------------------------------------------------------------------------------- /test/extern/zlib-1.2.12/contrib/dotzlib/DotZLib.sln: -------------------------------------------------------------------------------- 1 | Microsoft Visual Studio Solution File, Format Version 8.00 2 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "DotZLib", "DotZLib\DotZLib.csproj", "{BB1EE0B1-1808-46CB-B786-949D91117FC5}" 3 | ProjectSection(ProjectDependencies) = postProject 4 | EndProjectSection 5 | EndProject 6 | Global 7 | GlobalSection(SolutionConfiguration) = preSolution 8 | Debug = Debug 9 | Release = Release 10 | EndGlobalSection 11 | GlobalSection(ProjectConfiguration) = postSolution 12 | {BB1EE0B1-1808-46CB-B786-949D91117FC5}.Debug.ActiveCfg = Debug|.NET 13 | {BB1EE0B1-1808-46CB-B786-949D91117FC5}.Debug.Build.0 = Debug|.NET 14 | {BB1EE0B1-1808-46CB-B786-949D91117FC5}.Release.ActiveCfg = Release|.NET 15 | {BB1EE0B1-1808-46CB-B786-949D91117FC5}.Release.Build.0 = Release|.NET 16 | EndGlobalSection 17 | GlobalSection(ExtensibilityGlobals) = postSolution 18 | EndGlobalSection 19 | GlobalSection(ExtensibilityAddIns) = postSolution 20 | EndGlobalSection 21 | EndGlobal 22 | -------------------------------------------------------------------------------- /test/extern/zlib-1.2.12/contrib/dotzlib/DotZLib/ChecksumImpl.cs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/boostorg/beast/916dcf8eb3eff582356f7b1849446a3893da6eac/test/extern/zlib-1.2.12/contrib/dotzlib/DotZLib/ChecksumImpl.cs -------------------------------------------------------------------------------- /test/extern/zlib-1.2.12/contrib/dotzlib/DotZLib/CircularBuffer.cs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/boostorg/beast/916dcf8eb3eff582356f7b1849446a3893da6eac/test/extern/zlib-1.2.12/contrib/dotzlib/DotZLib/CircularBuffer.cs -------------------------------------------------------------------------------- /test/extern/zlib-1.2.12/contrib/dotzlib/DotZLib/CodecBase.cs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/boostorg/beast/916dcf8eb3eff582356f7b1849446a3893da6eac/test/extern/zlib-1.2.12/contrib/dotzlib/DotZLib/CodecBase.cs -------------------------------------------------------------------------------- /test/extern/zlib-1.2.12/contrib/dotzlib/DotZLib/Deflater.cs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/boostorg/beast/916dcf8eb3eff582356f7b1849446a3893da6eac/test/extern/zlib-1.2.12/contrib/dotzlib/DotZLib/Deflater.cs -------------------------------------------------------------------------------- /test/extern/zlib-1.2.12/contrib/dotzlib/DotZLib/DotZLib.cs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/boostorg/beast/916dcf8eb3eff582356f7b1849446a3893da6eac/test/extern/zlib-1.2.12/contrib/dotzlib/DotZLib/DotZLib.cs -------------------------------------------------------------------------------- /test/extern/zlib-1.2.12/contrib/dotzlib/DotZLib/GZipStream.cs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/boostorg/beast/916dcf8eb3eff582356f7b1849446a3893da6eac/test/extern/zlib-1.2.12/contrib/dotzlib/DotZLib/GZipStream.cs -------------------------------------------------------------------------------- /test/extern/zlib-1.2.12/contrib/dotzlib/DotZLib/Inflater.cs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/boostorg/beast/916dcf8eb3eff582356f7b1849446a3893da6eac/test/extern/zlib-1.2.12/contrib/dotzlib/DotZLib/Inflater.cs -------------------------------------------------------------------------------- /test/extern/zlib-1.2.12/contrib/infback9/README: -------------------------------------------------------------------------------- 1 | See infback9.h for what this is and how to use it. 2 | -------------------------------------------------------------------------------- /test/extern/zlib-1.2.12/contrib/iostream/test.cpp: -------------------------------------------------------------------------------- 1 | 2 | #include "zfstream.h" 3 | 4 | int main() { 5 | 6 | // Construct a stream object with this filebuffer. Anything sent 7 | // to this stream will go to standard out. 8 | gzofstream os( 1, ios::out ); 9 | 10 | // This text is getting compressed and sent to stdout. 11 | // To prove this, run 'test | zcat'. 12 | os << "Hello, Mommy" << endl; 13 | 14 | os << setcompressionlevel( Z_NO_COMPRESSION ); 15 | os << "hello, hello, hi, ho!" << endl; 16 | 17 | setcompressionlevel( os, Z_DEFAULT_COMPRESSION ) 18 | << "I'm compressing again" << endl; 19 | 20 | os.close(); 21 | 22 | return 0; 23 | 24 | } 25 | -------------------------------------------------------------------------------- /test/extern/zlib-1.2.12/contrib/iostream2/zstream_test.cpp: -------------------------------------------------------------------------------- 1 | #include "zstream.h" 2 | #include 3 | #include 4 | #include 5 | 6 | void main() { 7 | char h[256] = "Hello"; 8 | char* g = "Goodbye"; 9 | ozstream out("temp.gz"); 10 | out < "This works well" < h < g; 11 | out.close(); 12 | 13 | izstream in("temp.gz"); // read it back 14 | char *x = read_string(in), *y = new char[256], z[256]; 15 | in > y > z; 16 | in.close(); 17 | cout << x << endl << y << endl << z << endl; 18 | 19 | out.open("temp.gz"); // try ascii output; zcat temp.gz to see the results 20 | out << setw(50) << setfill('#') << setprecision(20) << x << endl << y << endl << z << endl; 21 | out << z << endl << y << endl << x << endl; 22 | out << 1.1234567890123456789 << endl; 23 | 24 | delete[] x; delete[] y; 25 | } 26 | -------------------------------------------------------------------------------- /test/extern/zlib-1.2.12/contrib/iostream3/TODO: -------------------------------------------------------------------------------- 1 | Possible upgrades to gzfilebuf: 2 | 3 | - The ability to do putback (e.g. putbackfail) 4 | 5 | - The ability to seek (zlib supports this, but could be slow/tricky) 6 | 7 | - Simultaneous read/write access (does it make sense?) 8 | 9 | - Support for ios_base::ate open mode 10 | 11 | - Locale support? 12 | 13 | - Check public interface to see which calls give problems 14 | (due to dependence on library internals) 15 | 16 | - Override operator<<(ostream&, gzfilebuf*) to allow direct copying 17 | of stream buffer to stream ( i.e. os << is.rdbuf(); ) 18 | -------------------------------------------------------------------------------- /test/extern/zlib-1.2.12/contrib/minizip/Makefile: -------------------------------------------------------------------------------- 1 | CC=cc 2 | CFLAGS := $(CFLAGS) -O -I../.. 3 | 4 | UNZ_OBJS = miniunz.o unzip.o ioapi.o ../../libz.a 5 | ZIP_OBJS = minizip.o zip.o ioapi.o ../../libz.a 6 | 7 | .c.o: 8 | $(CC) -c $(CFLAGS) $*.c 9 | 10 | all: miniunz minizip 11 | 12 | miniunz: $(UNZ_OBJS) 13 | $(CC) $(CFLAGS) -o $@ $(UNZ_OBJS) 14 | 15 | minizip: $(ZIP_OBJS) 16 | $(CC) $(CFLAGS) -o $@ $(ZIP_OBJS) 17 | 18 | test: miniunz minizip 19 | @rm -f test.* 20 | @echo hello hello hello > test.txt 21 | ./minizip test test.txt 22 | ./miniunz -l test.zip 23 | @mv test.txt test.old 24 | ./miniunz test.zip 25 | @cmp test.txt test.old 26 | @rm -f test.* 27 | 28 | clean: 29 | /bin/rm -f *.o *~ minizip miniunz test.* 30 | -------------------------------------------------------------------------------- /test/extern/zlib-1.2.12/contrib/minizip/Makefile.am: -------------------------------------------------------------------------------- 1 | lib_LTLIBRARIES = libminizip.la 2 | 3 | if COND_DEMOS 4 | bin_PROGRAMS = miniunzip minizip 5 | endif 6 | 7 | zlib_top_srcdir = $(top_srcdir)/../.. 8 | zlib_top_builddir = $(top_builddir)/../.. 9 | 10 | AM_CPPFLAGS = -I$(zlib_top_srcdir) 11 | AM_LDFLAGS = -L$(zlib_top_builddir) 12 | 13 | if WIN32 14 | iowin32_src = iowin32.c 15 | iowin32_h = iowin32.h 16 | endif 17 | 18 | libminizip_la_SOURCES = \ 19 | ioapi.c \ 20 | mztools.c \ 21 | unzip.c \ 22 | zip.c \ 23 | ${iowin32_src} 24 | 25 | libminizip_la_LDFLAGS = $(AM_LDFLAGS) -version-info 1:0:0 -lz 26 | 27 | minizip_includedir = $(includedir)/minizip 28 | minizip_include_HEADERS = \ 29 | crypt.h \ 30 | ioapi.h \ 31 | mztools.h \ 32 | unzip.h \ 33 | zip.h \ 34 | ${iowin32_h} 35 | 36 | pkgconfigdir = $(libdir)/pkgconfig 37 | pkgconfig_DATA = minizip.pc 38 | 39 | EXTRA_PROGRAMS = miniunzip minizip 40 | 41 | miniunzip_SOURCES = miniunz.c 42 | miniunzip_LDADD = libminizip.la 43 | 44 | minizip_SOURCES = minizip.c 45 | minizip_LDADD = libminizip.la -lz 46 | -------------------------------------------------------------------------------- /test/extern/zlib-1.2.12/contrib/minizip/MiniZip64_Changes.txt: -------------------------------------------------------------------------------- 1 | 2 | MiniZip 1.1 was derrived from MiniZip at version 1.01f 3 | 4 | Change in 1.0 (Okt 2009) 5 | - **TODO - Add history** 6 | 7 | -------------------------------------------------------------------------------- /test/extern/zlib-1.2.12/contrib/minizip/configure.ac: -------------------------------------------------------------------------------- 1 | # -*- Autoconf -*- 2 | # Process this file with autoconf to produce a configure script. 3 | 4 | AC_INIT([minizip], [1.2.12], [bugzilla.redhat.com]) 5 | AC_CONFIG_SRCDIR([minizip.c]) 6 | AM_INIT_AUTOMAKE([foreign]) 7 | LT_INIT 8 | 9 | AC_MSG_CHECKING([whether to build example programs]) 10 | AC_ARG_ENABLE([demos], AC_HELP_STRING([--enable-demos], [build example programs])) 11 | AM_CONDITIONAL([COND_DEMOS], [test "$enable_demos" = yes]) 12 | if test "$enable_demos" = yes 13 | then 14 | AC_MSG_RESULT([yes]) 15 | else 16 | AC_MSG_RESULT([no]) 17 | fi 18 | 19 | case "${host}" in 20 | *-mingw* | mingw*) 21 | WIN32="yes" 22 | ;; 23 | *) 24 | ;; 25 | esac 26 | AM_CONDITIONAL([WIN32], [test "${WIN32}" = "yes"]) 27 | 28 | 29 | AC_SUBST([HAVE_UNISTD_H], [0]) 30 | AC_CHECK_HEADER([unistd.h], [HAVE_UNISTD_H=1], []) 31 | AC_CONFIG_FILES([Makefile minizip.pc]) 32 | AC_OUTPUT 33 | -------------------------------------------------------------------------------- /test/extern/zlib-1.2.12/contrib/minizip/iowin32.h: -------------------------------------------------------------------------------- 1 | /* iowin32.h -- IO base function header for compress/uncompress .zip 2 | Version 1.1, February 14h, 2010 3 | part of the MiniZip project - ( http://www.winimage.com/zLibDll/minizip.html ) 4 | 5 | Copyright (C) 1998-2010 Gilles Vollant (minizip) ( http://www.winimage.com/zLibDll/minizip.html ) 6 | 7 | Modifications for Zip64 support 8 | Copyright (C) 2009-2010 Mathias Svensson ( http://result42.com ) 9 | 10 | For more info read MiniZip_info.txt 11 | 12 | */ 13 | 14 | #include 15 | 16 | 17 | #ifdef __cplusplus 18 | extern "C" { 19 | #endif 20 | 21 | void fill_win32_filefunc OF((zlib_filefunc_def* pzlib_filefunc_def)); 22 | void fill_win32_filefunc64 OF((zlib_filefunc64_def* pzlib_filefunc_def)); 23 | void fill_win32_filefunc64A OF((zlib_filefunc64_def* pzlib_filefunc_def)); 24 | void fill_win32_filefunc64W OF((zlib_filefunc64_def* pzlib_filefunc_def)); 25 | 26 | #ifdef __cplusplus 27 | } 28 | #endif 29 | -------------------------------------------------------------------------------- /test/extern/zlib-1.2.12/contrib/minizip/make_vms.com: -------------------------------------------------------------------------------- 1 | $ if f$search("ioapi.h_orig") .eqs. "" then copy ioapi.h ioapi.h_orig 2 | $ open/write zdef vmsdefs.h 3 | $ copy sys$input: zdef 4 | $ deck 5 | #define unix 6 | #define fill_zlib_filefunc64_32_def_from_filefunc32 fillzffunc64from 7 | #define Write_Zip64EndOfCentralDirectoryLocator Write_Zip64EoDLocator 8 | #define Write_Zip64EndOfCentralDirectoryRecord Write_Zip64EoDRecord 9 | #define Write_EndOfCentralDirectoryRecord Write_EoDRecord 10 | $ eod 11 | $ close zdef 12 | $ copy vmsdefs.h,ioapi.h_orig ioapi.h 13 | $ cc/include=[--]/prefix=all ioapi.c 14 | $ cc/include=[--]/prefix=all miniunz.c 15 | $ cc/include=[--]/prefix=all unzip.c 16 | $ cc/include=[--]/prefix=all minizip.c 17 | $ cc/include=[--]/prefix=all zip.c 18 | $ link miniunz,unzip,ioapi,[--]libz.olb/lib 19 | $ link minizip,zip,ioapi,[--]libz.olb/lib 20 | $ mcr []minizip test minizip_info.txt 21 | $ mcr []miniunz -l test.zip 22 | $ rename minizip_info.txt; minizip_info.txt_old 23 | $ mcr []miniunz test.zip 24 | $ delete test.zip;* 25 | $exit 26 | -------------------------------------------------------------------------------- /test/extern/zlib-1.2.12/contrib/minizip/minizip.pc.in: -------------------------------------------------------------------------------- 1 | prefix=@prefix@ 2 | exec_prefix=@exec_prefix@ 3 | libdir=@libdir@ 4 | includedir=@includedir@/minizip 5 | 6 | Name: minizip 7 | Description: Minizip zip file manipulation library 8 | Requires: 9 | Version: @PACKAGE_VERSION@ 10 | Libs: -L${libdir} -lminizip 11 | Libs.private: -lz 12 | Cflags: -I${includedir} 13 | -------------------------------------------------------------------------------- /test/extern/zlib-1.2.12/contrib/minizip/mztools.h: -------------------------------------------------------------------------------- 1 | /* 2 | Additional tools for Minizip 3 | Code: Xavier Roche '2004 4 | License: Same as ZLIB (www.gzip.org) 5 | */ 6 | 7 | #ifndef _zip_tools_H 8 | #define _zip_tools_H 9 | 10 | #ifdef __cplusplus 11 | extern "C" { 12 | #endif 13 | 14 | #ifndef _ZLIB_H 15 | #include "zlib.h" 16 | #endif 17 | 18 | #include "unzip.h" 19 | 20 | /* Repair a ZIP file (missing central directory) 21 | file: file to recover 22 | fileOut: output file after recovery 23 | fileOutTmp: temporary file name used for recovery 24 | */ 25 | extern int ZEXPORT unzRepair(const char* file, 26 | const char* fileOut, 27 | const char* fileOutTmp, 28 | uLong* nRecovered, 29 | uLong* bytesRecovered); 30 | 31 | 32 | #ifdef __cplusplus 33 | } 34 | #endif 35 | 36 | 37 | #endif 38 | -------------------------------------------------------------------------------- /test/extern/zlib-1.2.12/contrib/puff/zeros.raw: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/boostorg/beast/916dcf8eb3eff582356f7b1849446a3893da6eac/test/extern/zlib-1.2.12/contrib/puff/zeros.raw -------------------------------------------------------------------------------- /test/extern/zlib-1.2.12/contrib/testzlib/testzlib.txt: -------------------------------------------------------------------------------- 1 | To build testzLib with Visual Studio 2005: 2 | 3 | copy to a directory file from : 4 | - root of zLib tree 5 | - contrib/testzlib 6 | - contrib/masmx86 7 | - contrib/masmx64 8 | - contrib/vstudio/vc7 9 | 10 | and open testzlib8.sln -------------------------------------------------------------------------------- /test/extern/zlib-1.2.12/contrib/untgz/Makefile: -------------------------------------------------------------------------------- 1 | CC=cc 2 | CFLAGS=-g 3 | 4 | untgz: untgz.o ../../libz.a 5 | $(CC) $(CFLAGS) -o untgz untgz.o -L../.. -lz 6 | 7 | untgz.o: untgz.c ../../zlib.h 8 | $(CC) $(CFLAGS) -c -I../.. untgz.c 9 | 10 | ../../libz.a: 11 | cd ../..; ./configure; make 12 | 13 | clean: 14 | rm -f untgz untgz.o *~ 15 | -------------------------------------------------------------------------------- /test/extern/zlib-1.2.12/contrib/untgz/Makefile.msc: -------------------------------------------------------------------------------- 1 | CC=cl 2 | CFLAGS=-MD 3 | 4 | untgz.exe: untgz.obj ..\..\zlib.lib 5 | $(CC) $(CFLAGS) untgz.obj ..\..\zlib.lib 6 | 7 | untgz.obj: untgz.c ..\..\zlib.h 8 | $(CC) $(CFLAGS) -c -I..\.. untgz.c 9 | 10 | ..\..\zlib.lib: 11 | cd ..\.. 12 | $(MAKE) -f win32\makefile.msc 13 | cd contrib\untgz 14 | 15 | clean: 16 | -del untgz.obj 17 | -del untgz.exe 18 | -------------------------------------------------------------------------------- /test/extern/zlib-1.2.12/contrib/vstudio/vc10/miniunz.vcxproj.filters: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | {048af943-022b-4db6-beeb-a54c34774ee2} 6 | cpp;c;cxx;def;odl;idl;hpj;bat;asm 7 | 8 | 9 | {c1d600d2-888f-4aea-b73e-8b0dd9befa0c} 10 | h;hpp;hxx;hm;inl;inc 11 | 12 | 13 | {0844199a-966b-4f19-81db-1e0125e141b9} 14 | rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe 15 | 16 | 17 | 18 | 19 | Source Files 20 | 21 | 22 | -------------------------------------------------------------------------------- /test/extern/zlib-1.2.12/contrib/vstudio/vc10/minizip.vcxproj.filters: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | {c0419b40-bf50-40da-b153-ff74215b79de} 6 | cpp;c;cxx;def;odl;idl;hpj;bat;asm 7 | 8 | 9 | {bb87b070-735b-478e-92ce-7383abb2f36c} 10 | h;hpp;hxx;hm;inl;inc 11 | 12 | 13 | {f46ab6a6-548f-43cb-ae96-681abb5bd5db} 14 | rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe 15 | 16 | 17 | 18 | 19 | Source Files 20 | 21 | 22 | -------------------------------------------------------------------------------- /test/extern/zlib-1.2.12/contrib/vstudio/vc10/testzlibdll.vcxproj.filters: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | {fa61a89f-93fc-4c89-b29e-36224b7592f4} 6 | cpp;c;cxx;def;odl;idl;hpj;bat;asm 7 | 8 | 9 | {d4b85da0-2ba2-4934-b57f-e2584e3848ee} 10 | h;hpp;hxx;hm;inl;inc 11 | 12 | 13 | {e573e075-00bd-4a7d-bd67-a8cc9bfc5aca} 14 | rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe 15 | 16 | 17 | 18 | 19 | Source Files 20 | 21 | 22 | -------------------------------------------------------------------------------- /test/extern/zlib-1.2.12/doc/crc-doc.1.0.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/boostorg/beast/916dcf8eb3eff582356f7b1849446a3893da6eac/test/extern/zlib-1.2.12/doc/crc-doc.1.0.pdf -------------------------------------------------------------------------------- /test/extern/zlib-1.2.12/gzclose.c: -------------------------------------------------------------------------------- 1 | /* gzclose.c -- zlib gzclose() function 2 | * Copyright (C) 2004, 2010 Mark Adler 3 | * For conditions of distribution and use, see copyright notice in zlib.h 4 | */ 5 | 6 | #include "gzguts.h" 7 | 8 | /* gzclose() is in a separate file so that it is linked in only if it is used. 9 | That way the other gzclose functions can be used instead to avoid linking in 10 | unneeded compression or decompression routines. */ 11 | int ZEXPORT gzclose(file) 12 | gzFile file; 13 | { 14 | #ifndef NO_GZCOMPRESS 15 | gz_statep state; 16 | 17 | if (file == NULL) 18 | return Z_STREAM_ERROR; 19 | state = (gz_statep)file; 20 | 21 | return state->mode == GZ_READ ? gzclose_r(file) : gzclose_w(file); 22 | #else 23 | return gzclose_r(file); 24 | #endif 25 | } 26 | -------------------------------------------------------------------------------- /test/extern/zlib-1.2.12/inffast.h: -------------------------------------------------------------------------------- 1 | /* inffast.h -- header to use inffast.c 2 | * Copyright (C) 1995-2003, 2010 Mark Adler 3 | * For conditions of distribution and use, see copyright notice in zlib.h 4 | */ 5 | 6 | /* WARNING: this file should *not* be used by applications. It is 7 | part of the implementation of the compression library and is 8 | subject to change. Applications should only use zlib.h. 9 | */ 10 | 11 | void ZLIB_INTERNAL inflate_fast OF((z_streamp strm, unsigned start)); 12 | -------------------------------------------------------------------------------- /test/extern/zlib-1.2.12/nintendods/README: -------------------------------------------------------------------------------- 1 | This Makefile requires devkitARM (http://www.devkitpro.org/category/devkitarm/) and works inside "contrib/nds". It is based on a devkitARM template. 2 | 3 | Eduardo Costa 4 | January 3, 2009 5 | 6 | -------------------------------------------------------------------------------- /test/extern/zlib-1.2.12/old/README: -------------------------------------------------------------------------------- 1 | This directory contains files that have not been updated for zlib 1.2.x 2 | 3 | (Volunteers are encouraged to help clean this up. Thanks.) 4 | -------------------------------------------------------------------------------- /test/extern/zlib-1.2.12/old/os2/zlib.def: -------------------------------------------------------------------------------- 1 | ; 2 | ; Slightly modified version of ../nt/zlib.dnt :-) 3 | ; 4 | 5 | LIBRARY Z 6 | DESCRIPTION "Zlib compression library for OS/2" 7 | CODE PRELOAD MOVEABLE DISCARDABLE 8 | DATA PRELOAD MOVEABLE MULTIPLE 9 | 10 | EXPORTS 11 | adler32 12 | compress 13 | crc32 14 | deflate 15 | deflateCopy 16 | deflateEnd 17 | deflateInit2_ 18 | deflateInit_ 19 | deflateParams 20 | deflateReset 21 | deflateSetDictionary 22 | gzclose 23 | gzdopen 24 | gzerror 25 | gzflush 26 | gzopen 27 | gzread 28 | gzwrite 29 | inflate 30 | inflateEnd 31 | inflateInit2_ 32 | inflateInit_ 33 | inflateReset 34 | inflateSetDictionary 35 | inflateSync 36 | uncompress 37 | zlibVersion 38 | gzprintf 39 | gzputc 40 | gzgetc 41 | gzseek 42 | gzrewind 43 | gztell 44 | gzeof 45 | gzsetparams 46 | zError 47 | inflateSyncPoint 48 | get_crc_table 49 | compress2 50 | gzputs 51 | gzgets 52 | -------------------------------------------------------------------------------- /test/extern/zlib-1.2.12/win32/VisualC.txt: -------------------------------------------------------------------------------- 1 | 2 | To build zlib using the Microsoft Visual C++ environment, 3 | use the appropriate project from the contrib/vstudio/ directory. 4 | -------------------------------------------------------------------------------- /test/extern/zlib-1.2.12/zlib.3.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/boostorg/beast/916dcf8eb3eff582356f7b1849446a3893da6eac/test/extern/zlib-1.2.12/zlib.3.pdf -------------------------------------------------------------------------------- /test/extern/zlib-1.2.12/zlib.pc.cmakein: -------------------------------------------------------------------------------- 1 | prefix=@CMAKE_INSTALL_PREFIX@ 2 | exec_prefix=@CMAKE_INSTALL_PREFIX@ 3 | libdir=@INSTALL_LIB_DIR@ 4 | sharedlibdir=@INSTALL_LIB_DIR@ 5 | includedir=@INSTALL_INC_DIR@ 6 | 7 | Name: zlib 8 | Description: zlib compression library 9 | Version: @VERSION@ 10 | 11 | Requires: 12 | Libs: -L${libdir} -L${sharedlibdir} -lz 13 | Cflags: -I${includedir} 14 | -------------------------------------------------------------------------------- /test/extern/zlib-1.2.12/zlib.pc.in: -------------------------------------------------------------------------------- 1 | prefix=@prefix@ 2 | exec_prefix=@exec_prefix@ 3 | libdir=@libdir@ 4 | sharedlibdir=@sharedlibdir@ 5 | includedir=@includedir@ 6 | 7 | Name: zlib 8 | Description: zlib compression library 9 | Version: @VERSION@ 10 | 11 | Requires: 12 | Libs: -L${libdir} -L${sharedlibdir} -lz 13 | Cflags: -I${includedir} 14 | -------------------------------------------------------------------------------- /test/extras/README.md: -------------------------------------------------------------------------------- 1 | # Extras 2 | 3 | These are not part of the official public Beast interface but they are used by the tests and some third party programs. 4 | -------------------------------------------------------------------------------- /test/extras/include/boost/beast/test/sig_wait.hpp: -------------------------------------------------------------------------------- 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_TEST_SIG_WAIT_HPP 11 | #define BOOST_BEAST_TEST_SIG_WAIT_HPP 12 | 13 | #include 14 | 15 | namespace boost { 16 | namespace beast { 17 | namespace test { 18 | 19 | /// Block until SIGINT or SIGTERM is received. 20 | inline 21 | void 22 | sig_wait() 23 | { 24 | net::io_context ioc; 25 | net::signal_set signals( 26 | ioc, SIGINT, SIGTERM); 27 | signals.async_wait( 28 | [&](boost::system::error_code const&, int) 29 | { 30 | }); 31 | ioc.run(); 32 | } 33 | 34 | } // test 35 | } // beast 36 | } // boost 37 | 38 | #endif 39 | -------------------------------------------------------------------------------- /test/fuzz/http_request.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (c) 2024 Mikhail Khachayants 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 | 8 | #include 9 | #include 10 | 11 | extern "C" int LLVMFuzzerTestOneInput(const uint8_t* data, size_t size) 12 | { 13 | using namespace boost::beast; 14 | 15 | error_code ec; 16 | flat_buffer buffer; 17 | net::io_context ioc; 18 | test::stream stream{ioc, {reinterpret_cast(data), size}}; 19 | stream.close_remote(); 20 | 21 | http::request_parser parser; 22 | http::read(stream, buffer, parser, ec); 23 | 24 | return 0; 25 | } 26 | -------------------------------------------------------------------------------- /test/fuzz/http_response.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (c) 2024 Mikhail Khachayants 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 | 8 | #include 9 | #include 10 | 11 | extern "C" int LLVMFuzzerTestOneInput(const uint8_t* data, size_t size) 12 | { 13 | using namespace boost::beast; 14 | 15 | error_code ec; 16 | flat_buffer buffer; 17 | net::io_context ioc; 18 | test::stream stream{ioc, {reinterpret_cast(data), size}}; 19 | stream.close_remote(); 20 | 21 | http::chunk_extensions ce; 22 | http::response_parser parser; 23 | 24 | auto chunk_header_cb = [&ce](std::uint64_t, string_view extensions, error_code& ev) 25 | { 26 | ce.parse(extensions, ev); 27 | }; 28 | 29 | parser.on_chunk_header(chunk_header_cb); 30 | http::read(stream, buffer, parser, ec); 31 | 32 | return 0; 33 | } 34 | -------------------------------------------------------------------------------- /test/fuzz/seeds.tar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/boostorg/beast/916dcf8eb3eff582356f7b1849446a3893da6eac/test/fuzz/seeds.tar -------------------------------------------------------------------------------- /test/lib_asio.cpp: -------------------------------------------------------------------------------- 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 | // This file is used to build a static library 11 | 12 | #include 13 | -------------------------------------------------------------------------------- /test/lib_asio_ssl.cpp: -------------------------------------------------------------------------------- 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 | // This file is used to build a static library 11 | 12 | #include 13 | -------------------------------------------------------------------------------- /test/lib_beast.cpp: -------------------------------------------------------------------------------- 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 | // This file is used to build a static library 11 | 12 | #include 13 | -------------------------------------------------------------------------------- /test/lib_test.cpp: -------------------------------------------------------------------------------- 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 | // This file is used to build a static library 11 | 12 | #include 13 | 14 | -------------------------------------------------------------------------------- /tools/retry.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | for i in {1..3} 4 | do 5 | $1 "${@:2:99}" && exit 0; 6 | export BEAST_RETRY="true" 7 | done 8 | 9 | exit 1 10 | -------------------------------------------------------------------------------- /tools/user-config.jam: -------------------------------------------------------------------------------- 1 | # Used on CI 2 | 3 | import os ; 4 | 5 | local OPENSSL_ROOT = [ os.environ OPENSSL_ROOT ] ; 6 | 7 | project 8 | : requirements 9 | $(OPENSSL_ROOT)/include 10 | debug:$(OPENSSL_ROOT)/lib 11 | windowsdebug:$(OPENSSL_ROOT)/debug/lib 12 | release:$(OPENSSL_ROOT)/lib 13 | ; 14 | -------------------------------------------------------------------------------- /tools/valgrind.supp: -------------------------------------------------------------------------------- 1 | { 2 | zlib_fill_window_no_init 3 | Memcheck:Cond 4 | fun:fill_window 5 | } 6 | 7 | { 8 | zlib_deflate_fast 9 | Memcheck:Cond 10 | fun:deflate_fast 11 | } 12 | 13 | { 14 | Ignore OpenSSL malloc 15 | Memcheck:Leak 16 | fun:malloc 17 | fun:CRYPTO_malloc 18 | obj:*libcrypto* 19 | } 20 | { 21 | Ignore OpenSSL realloc 22 | Memcheck:Leak 23 | fun:realloc 24 | fun:CRYPTO_realloc 25 | obj:*libcrypto* 26 | } 27 | { 28 | OpenSSL Non-Purify 29 | Memcheck:Cond 30 | obj:*libcrypto* 31 | } 32 | --------------------------------------------------------------------------------