You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cloudstack.apache.org by GitBox <gi...@apache.org> on 2021/10/25 18:17:05 UTC

[GitHub] [cloudstack] weizhouapache commented on a change in pull request #5624: core: use the URL scheme same as iframe for non-SSL enabled consoles

weizhouapache commented on a change in pull request #5624:
URL: https://github.com/apache/cloudstack/pull/5624#discussion_r735848454



##########
File path: server/src/main/java/com/cloud/consoleproxy/AgentHookBase.java
##########
@@ -198,12 +198,14 @@ public void startAgentHttpHandlerInVM(StartupProxyCommand startupCmd) {
             String storePassword = Base64.encodeBase64String(randomBytes);
 
             byte[] ksBits = null;
+
             String consoleProxyUrlDomain = _configDao.getValue(Config.ConsoleProxyUrlDomain.key());
-            if (consoleProxyUrlDomain == null || consoleProxyUrlDomain.isEmpty()) {
-                s_logger.debug("SSL is disabled for console proxy based on global config, skip loading certificates");
-            } else {
+            String consoleProxySslEnabled = _configDao.getValue("consoleproxy.sslEnabled");
+            if (consoleProxyUrlDomain != null && !consoleProxyUrlDomain.isEmpty() && consoleProxySslEnabled != null && consoleProxySslEnabled.equalsIgnoreCase("true")) {

Review comment:
       use StringUtils.isNotEmpty ?




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org