Skip to content

Commit

Permalink
Zowe Suite v1.20.0
Browse files Browse the repository at this point in the history
  • Loading branch information
zowe-robot authored Mar 3, 2021
2 parents dd1626f + a756ea5 commit 7a99f12
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 7 deletions.
4 changes: 0 additions & 4 deletions lib/unp-constants.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,10 +30,6 @@ exports.setProductCode = function(productCode) {
}

exports.HTTPS_DEFAULT_CIPHERS = [
'AES128-GCM-SHA256',
'AES128-SHA256',
'AES256-GCM-SHA384',
'AES256-SHA256',
'DHE-RSA-AES128-GCM-SHA256',
'DHE-RSA-AES128-SHA256',
'DHE-RSA-AES256-GCM-SHA384',
Expand Down
4 changes: 2 additions & 2 deletions lib/webapp.js
Original file line number Diff line number Diff line change
Expand Up @@ -1168,13 +1168,13 @@ function makeLoopbackConfig(nodeConfig) {
return {
port: nodeConfig.https.port,
isHttps: true,
host: zluxUtil.getLoopbackAddress(nodeConfig.https.ipAddresses)
host: nodeConfig.loopbackAddress ? nodeConfig.loopbackAddress : zluxUtil.getLoopbackAddress(nodeConfig.https.ipAddresses)
}
} else {
return {
port: nodeConfig.http.port,
isHttps: false,
host: zluxUtil.getLoopbackAddress(nodeConfig.http.ipAddresses)
host: nodeConfig.loopbackAddress ? nodeConfig.loopbackAddress : zluxUtil.getLoopbackAddress(nodeConfig.http.ipAddresses)
}
}
}
Expand Down
8 changes: 7 additions & 1 deletion plugins/sso-auth/lib/zssHandler.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ const ipaddr = require('ipaddr.js');
const url = require('url');
const makeProfileNameForRequest = require('./safprofile').makeProfileNameForRequest;
const DEFAULT_CLASS = "ZOWE";
const ZSS_SESSION_TIMEOUT_HEADER = "session-expires-seconds";
const DEFAULT_EXPIRATION_MS = 3600000 //hour;
const HTTP_STATUS_PRECONDITION_REQUIRED = 428;

Expand Down Expand Up @@ -179,8 +180,13 @@ class ZssHandler {
}
//intended to be known as result of network call
sessionState.zssCookies = zssCookie;
let expiresSec = response.headers[ZSS_SESSION_TIMEOUT_HEADER];
let expiresMs = DEFAULT_EXPIRATION_MS;
if (expiresSec) {
expiresMs = expiresSec == -1 ? expiresSec : Number(expiresSec)*1000;
}
resolve({ success: true, username: sessionState.username,
expms: DEFAULT_EXPIRATION_MS})
expms: expiresMs});
} else {
let res = { success: false, error: {message: `ZSS ${response.statusCode} ${response.statusMessage}`}};
if (response.statusCode === 500) {
Expand Down

0 comments on commit 7a99f12

Please sign in to comment.