TLSServerContextFactory
This commit is contained in:
parent
05e874df86
commit
9275aa8c8e
1 changed files with 5 additions and 0 deletions
|
@ -25,6 +25,9 @@
|
|||
#include "discoinforesponder.h"
|
||||
#include "discoitemsresponder.h"
|
||||
#include "storageparser.h"
|
||||
#include "Swiften/TLS/OpenSSL/OpenSSLServerContext.h"
|
||||
#include "Swiften/TLS/PKCS12Certificate.h"
|
||||
#include "Swiften/TLS/OpenSSL/OpenSSLServerContextFactory.h"
|
||||
|
||||
using namespace Swift;
|
||||
using namespace boost;
|
||||
|
@ -68,6 +71,8 @@ Component::Component(Swift::EventLoop *loop, Config *config, Factory *factory) {
|
|||
if (CONFIG_BOOL(m_config, "service.server_mode")) {
|
||||
m_userRegistry = new MyUserRegistry(this);
|
||||
m_server = new Swift::Server(loop, m_factories, m_userRegistry, m_jid, CONFIG_INT(m_config, "service.port"));
|
||||
TLSServerContextFactory *f = new OpenSSLServerContextFactory();
|
||||
// m_server->addTLSEncryption(f, PKCS12Certificate("localhost.p12", createSafeByteArray("")));
|
||||
m_server->start();
|
||||
m_stanzaChannel = m_server->getStanzaChannel();
|
||||
m_iqRouter = m_server->getIQRouter();
|
||||
|
|
Loading…
Add table
Reference in a new issue