Merge pull request #1443 from Squidly271/patch-3

Descriptive error messages on install_key
This commit is contained in:
tom mortensen
2023-10-08 08:57:18 -07:00
committed by GitHub
2 changed files with 27 additions and 1 deletions

View File

@@ -154,7 +154,7 @@ function error_desc($code) {
case 2: return 'Parse error';
case 3: return 'File I/O error';
case 4: return 'Network failure';
case 5: return 'SSL verification failure';
case 5: return 'SSL verification failure - Check the date and time of your server in Settings - Date And Time';
case 6: return 'Username/password authentication failure';
case 7: return 'Protocol errors';
case 8: return 'Invalid URL / Server error response';

View File

@@ -41,6 +41,32 @@ if (in_array($host,['keys.lime-technology.com','lime-technology.com'])) {
}
} else {
write("ERROR: $return_var\n");
switch($return_var) {
case 1:
write("Generic error code - Contact Support\n");
break;
case 2:
write("Parse Error - Contact Support\n");
break;
case 3:
write("File I/O error - Contact Support\n");
break;
case 4:
write("Network Failure: Try setting static DNS addresses within Settings - Network Settings or Contact Support\n");
break;
case 5:
write("SSL verification failure. Is the date & time set correctly? (Settings - Date & Time Settings) or Contact Support\n");
break;
case 6:
write("Username/password authentication failure - Contact Support\n");
break;
case 7:
write("Protocol error - Contact Support\n");
break;
case 8:
write("Server issued an error response - Contact Support\n");
break;
}
}
} else {
write("ERROR, bad or missing key file URL: $url\n");