mirror of
https://github.com/bitwarden/server.git
synced 2024-11-25 12:45:18 +01:00
move cert warnings to main
This commit is contained in:
parent
54aef8e8d3
commit
818a668e3c
@ -25,12 +25,6 @@ namespace Bit.Setup
|
||||
{
|
||||
if(Helpers.ReadQuestion("Do you want to generate a self-signed SSL certificate?"))
|
||||
{
|
||||
var message = "You are using a self-signed SSL certificate. This certificate will not be \n" +
|
||||
"trusted by Bitwarden client applications. You must add this certificate to \n" +
|
||||
"the trusted store on each device or else you will receive errors when trying \n" +
|
||||
"to connect to your installation.";
|
||||
Helpers.ShowBanner("WARNING", message, ConsoleColor.Yellow);
|
||||
|
||||
Directory.CreateDirectory($"/bitwarden/ssl/self/{Domain}/");
|
||||
Console.WriteLine("Generating self signed SSL certificate.");
|
||||
Ssl = selfSignedSsl = true;
|
||||
@ -39,13 +33,6 @@ namespace Bit.Setup
|
||||
$"-out /bitwarden/ssl/self/{Domain}/certificate.crt " +
|
||||
$"-subj \"/C=US/ST=New York/L=New York/O=8bit Solutions LLC/OU=Bitwarden/CN={Domain}\"");
|
||||
}
|
||||
else
|
||||
{
|
||||
var message = "You are not using an SSL certificate. Bitwarden requires HTTPS to operate. \n" +
|
||||
"You must front your installation with a HTTPS proxy. The web vault (and \n" +
|
||||
"other Bitwarden apps) will not work properly without HTTPS.";
|
||||
Helpers.ShowBanner("WARNING", message, ConsoleColor.Yellow);
|
||||
}
|
||||
}
|
||||
|
||||
if(LetsEncrypt)
|
||||
|
@ -96,6 +96,22 @@ namespace Bit.Setup
|
||||
sslTrusted = Helpers.ReadQuestion("Is this a trusted SSL certificate (requires ca.crt, see docs)?");
|
||||
}
|
||||
|
||||
if(!ssl)
|
||||
{
|
||||
var message = "You are not using a SSL certificate. Bitwarden requires HTTPS to operate. \n" +
|
||||
"You must front your installation with a HTTPS proxy. The web vault (and \n" +
|
||||
"other Bitwarden apps) will not work properly without HTTPS.";
|
||||
Helpers.ShowBanner("WARNING", message, ConsoleColor.Yellow);
|
||||
}
|
||||
else if(ssl && !sslTrusted)
|
||||
{
|
||||
var message = "You are using an untrusted SSL certificate. This certificate will not be \n" +
|
||||
"trusted by Bitwarden client applications. You must add this certificate to \n" +
|
||||
"the trusted store on each device or else you will receive errors when trying \n" +
|
||||
"to connect to your installation.";
|
||||
Helpers.ShowBanner("WARNING", message, ConsoleColor.Yellow);
|
||||
}
|
||||
|
||||
var url = $"https://{domain}";
|
||||
int httpPort = default(int), httpsPort = default(int);
|
||||
if(Helpers.ReadQuestion("Do you want to use the default ports for HTTP (80) and HTTPS (443)?"))
|
||||
|
Loading…
Reference in New Issue
Block a user