mirror of
https://github.com/znc/znc.git
synced 2026-08-07 09:22:55 +02:00
Make --makeconf check for znc.pem and generate it if it's missing
This patch is based on ideas and an actual patch from the-me aka Patrick Matthäi. Thanks. git-svn-id: https://znc.svn.sourceforge.net/svnroot/znc/trunk@1246 726aef4b-f618-498e-8847-2d620e286838
This commit is contained in:
@@ -571,6 +571,15 @@ bool CZNC::WriteNewConfig(CString& sConfigFile) {
|
||||
#ifdef HAVE_LIBSSL
|
||||
if (CUtils::GetBoolInput("Would you like ZNC to listen using SSL?", false)) {
|
||||
sSSL = "+";
|
||||
|
||||
CString sPemFile = GetPemLocation();
|
||||
if (!CFile::Exists(sPemFile)) {
|
||||
CUtils::PrintError("Unable to locate pem file: [" + sPemFile + "]");
|
||||
if (CUtils::GetBoolInput("Would you like to create a new pem file now?",
|
||||
true)) {
|
||||
WritePemFile();
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
Reference in New Issue
Block a user