diff options
author | David Carlier <[email protected]> | 2019-01-06 17:07:53 +0000 |
---|---|---|
committer | David Carlier <[email protected]> | 2019-01-06 17:07:53 +0000 |
commit | 738a37784f707f7e0ee10d3eca7d03f7ae4063a5 (patch) | |
tree | a901965c487f5f80463aea020459fd356116b373 /src/cli/tls_server.cpp | |
parent | aae03e177452a5b7f5a42b4acf0c3fde07fdf045 (diff) |
Proposal of sandboxing feature.
For now only used by the TLS server.
Diffstat (limited to 'src/cli/tls_server.cpp')
-rw-r--r-- | src/cli/tls_server.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/cli/tls_server.cpp b/src/cli/tls_server.cpp index c8e6c58f3..7259c091b 100644 --- a/src/cli/tls_server.cpp +++ b/src/cli/tls_server.cpp @@ -87,6 +87,12 @@ class TLS_Server final : public Command, public Botan::TLS::Callbacks output() << "Listening for new connections on " << transport << " port " << port << std::endl; + if(!Botan::OS::sandbox_start()) + { + error_output() << "Failed sandboxing\n"; + return; + } + int server_fd = make_server_socket(port); size_t clients_served = 0; |