Changeset - 8c77ffefc232
[Not reviewed]
0 3 0
Vitaly Takmazov - 13 years ago 2012-08-15 15:10:53
vitalyster@gmail.com
fix compilation
3 files changed with 2 insertions and 10 deletions:
0 comments (0 inline, 0 general)
include/Swiften/Server/ServerStanzaChannel.cpp
Show inline comments
 
@@ -170,12 +170,7 @@ void ServerStanzaChannel::handleElement(boost::shared_ptr<Element> element, cons
 
}
 

	
 
void ServerStanzaChannel::handleSessionInitialized() {
 
	onAvailableChanged(true);
 
}
 

	
 
std::vector<Certificate::ref> ServerStanzaChannel::getPeerCertificateChain() const {
 
	return std::vector<Certificate::ref>();
 
}
 

	
 

	
 
}
include/Swiften/Server/ServerStanzaChannel.h
Show inline comments
 
@@ -29,13 +29,12 @@ namespace Swift {
 

	
 
			void finishSession(const JID& to, boost::shared_ptr<Element> element, bool last = false);
 

	
 
			bool getStreamManagementEnabled() const {
 
				return false;
 
			}
 
		        virtual std::vector<Certificate::ref> getPeerCertificateChain() const;
 
	
 
			bool isAvailable() const {
 
				return true;
 
			}
 
			
 
			std::vector<Certificate::ref> getPeerCertificateChain() const {
src/transport.cpp
Show inline comments
 
@@ -79,18 +79,16 @@ Component::Component(Swift::EventLoop *loop, Swift::NetworkFactories *factories,
 
	m_reconnectTimer->onTick.connect(bind(&Component::start, this)); 
 

	
 
	if (CONFIG_BOOL(m_config, "service.server_mode")) {
 
		LOG4CXX_INFO(logger, "Creating component in server mode on port " << CONFIG_INT(m_config, "service.port"));
 
		m_server = new Swift::Server(loop, m_factories, m_userRegistry, m_jid, CONFIG_INT(m_config, "service.port"));
 
		if (!CONFIG_STRING(m_config, "service.cert").empty()) {
 
#ifndef _WIN32
 
//TODO: fix
 
			LOG4CXX_INFO(logger, "Using PKCS#12 certificate " << CONFIG_STRING(m_config, "service.cert"));
 
			LOG4CXX_INFO(logger, "SSLv23_server_method used.");
 
#ifdef _MSC_VER
 
			TLSServerContextFactory *f = new SchannelServerContextFactory();
 
			m_server->addTLSEncryption(f, boost::make_shared<CAPICertificate>(CONFIG_STRING(m_config, "service.cert")));
 
#else
 
			TLSServerContextFactory *f = new OpenSSLServerContextFactory();
 
			m_server->addTLSEncryption(f, boost::make_shared<PKCS12Certificate>(CONFIG_STRING(m_config, "service.cert"), createSafeByteArray(CONFIG_STRING(m_config, "service.cert_password"))));
 
#endif
 
			
 
		}
 
		else {
0 comments (0 inline, 0 general)