mirror of
https://github.com/outbackdingo/sysadm.git
synced 2026-01-27 10:20:26 +00:00
Fix the location of the SSL files used for the websocket server.
This commit is contained in:
@@ -57,7 +57,7 @@ bool WebServer::setupWebSocket(quint16 port){
|
||||
WSServer = new QWebSocketServer("sysadm-server", QWebSocketServer::SecureMode, this);
|
||||
//SSL Configuration
|
||||
QSslConfiguration config = QSslConfiguration::defaultConfiguration();
|
||||
QFile CF( QStringLiteral(SSLCERTFILE) );
|
||||
QFile CF( QStringLiteral(SSLCERTFILEWS) );
|
||||
if(CF.open(QIODevice::ReadOnly) ){
|
||||
QSslCertificate CERT(&CF,QSsl::Pem);
|
||||
config.setLocalCertificate( CERT );
|
||||
@@ -65,7 +65,7 @@ bool WebServer::setupWebSocket(quint16 port){
|
||||
}else{
|
||||
qWarning() << "Could not read WS certificate file:" << CF.fileName();
|
||||
}
|
||||
QFile KF( QStringLiteral(SSLKEYFILE));
|
||||
QFile KF( QStringLiteral(SSLKEYFILEWS));
|
||||
if(KF.open(QIODevice::ReadOnly) ){
|
||||
QSslKey KEY(&KF, QSsl::Rsa, QSsl::Pem);
|
||||
config.setPrivateKey( KEY );
|
||||
|
||||
@@ -53,6 +53,9 @@
|
||||
#define SSLCERTFILE "/usr/local/etc/sysadm/restserver.crt"
|
||||
#define SSLKEYFILE "/usr/local/etc/sysadm/restserver.key"
|
||||
|
||||
#define SSLCERTFILEWS "/usr/local/etc/sysadm/wsserver.crt"
|
||||
#define SSLKEYFILEWS "/usr/local/etc/sysadm/wsserver.key"
|
||||
|
||||
// Server Settings defines
|
||||
#define DISPATCH_QUEUE "/usr/local/etc/sysadm/dispatch_queue"
|
||||
|
||||
|
||||
Reference in New Issue
Block a user