WIP. User authentication on user interface

This commit is contained in:
emeric
2014-07-08 19:39:49 +02:00
parent 4744111959
commit 3e96534e08
17 changed files with 370 additions and 76 deletions
+2 -2
View File
@@ -15,7 +15,7 @@ _ioService(ioService),
_acceptor(_ioService, bindEndpoint, true /*SO_REUSEADDR*/),
_connectionManager(),
_context(boost::asio::ssl::context::tlsv1_server),
_requestHandler(dbPath)
_dbPath(dbPath)
{
_context.set_options( boost::asio::ssl::context::default_workarounds // TODO check this thing
| boost::asio::ssl::context::single_dh_use
@@ -40,7 +40,7 @@ Server::run()
void
Server::asyncAccept()
{
std::shared_ptr<Connection> newConnection = std::make_shared<Connection>(_ioService, _context, _connectionManager, _requestHandler);
std::shared_ptr<Connection> newConnection = std::make_shared<Connection>(_ioService, _context, _connectionManager, _dbPath);
_acceptor.async_accept(newConnection->getSocket(),
boost::bind(&Server::handleAccept, this, newConnection, boost::asio::placeholders::error));