diff options
author | Matthias Schiffer <matthias@gamezock.de> | 2008-09-06 03:15:06 +0200 |
---|---|---|
committer | Matthias Schiffer <matthias@gamezock.de> | 2008-09-06 03:15:06 +0200 |
commit | 7d5b81e9936b1c778fd6408f3f22478e9ab9486b (patch) | |
tree | 671e3f323d7298a5a0887302d6f1a397f5e0c1cd /src/Net/Listener.cpp | |
parent | b961ec7011bb50785dbbc271592b84f3ebae6432 (diff) | |
download | mad-7d5b81e9936b1c778fd6408f3f22478e9ab9486b.tar mad-7d5b81e9936b1c778fd6408f3f22478e9ab9486b.zip |
X.509-basierte TLS-Verbindung funktioniert
Diffstat (limited to 'src/Net/Listener.cpp')
-rw-r--r-- | src/Net/Listener.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/Net/Listener.cpp b/src/Net/Listener.cpp index 3b2e3d6..892d057 100644 --- a/src/Net/Listener.cpp +++ b/src/Net/Listener.cpp @@ -28,8 +28,8 @@ namespace Mad { namespace Net { -Listener::Listener(const IPAddress &address0) throw(ConnectionException) -: address(address0) { +Listener::Listener(const std::string &x905CertFile0, const std::string &x905KeyFile0, const IPAddress &address0) throw(ConnectionException) +: x905CertFile(x905CertFile0), x905KeyFile(x905KeyFile0), address(address0) { gnutls_dh_params_init(&dh_params); gnutls_dh_params_generate2(dh_params, 768); @@ -99,7 +99,7 @@ ServerConnection* Listener::getConnection(const std::map<int,const short*> &poll while((sd = accept(sock, reinterpret_cast<struct sockaddr*>(&sa), &addrlen)) >= 0) { - connections.push_back(new ServerConnection(sd, IPAddress(sa), dh_params)); + connections.push_back(new ServerConnection(sd, IPAddress(sa), dh_params, x905CertFile, x905KeyFile)); addrlen = sizeof(sa); } |