@sap/approuter
Advanced tools
Comparing version 16.6.1 to 16.6.2
@@ -8,2 +8,9 @@ # Change Log | ||
## 16.6.2 - 2024-07-31 | ||
### Fixed | ||
- Don't use filter by subdomain when getting destinations from subscriber | ||
- Add id_token after refresh IAS token | ||
- Forward authToken when calling backend in logout flow | ||
## 16.6.1 - 2024-07-22 | ||
@@ -10,0 +17,0 @@ |
@@ -123,3 +123,3 @@ 'use strict'; | ||
// Destination flow | ||
if (route && route.destination) { | ||
if ((route && route.destination) || (destination && destination.isLogout)) { | ||
// On premise destination flow - cloud connector | ||
@@ -126,0 +126,0 @@ if (destination.proxyType && destination.proxyType === 'OnPremise') { |
@@ -65,2 +65,7 @@ 'use strict'; | ||
if (destination) { | ||
// Add indication that this is logout flow. This is needed in order to avoid sending the wrong token to the destination. | ||
// There is a case when req.internalUrl.service is set to html5-apps-repo-rt service. | ||
// In this case the accessToken will be overriden by the service's token (html5-apps-repo-rt service) in authorization header (see addOauthHeader() in headers.js) | ||
// and as a result the wrong token will be sent to the destination | ||
destination.isLogout = true; | ||
module.exports.handleRequest(req, accessToken, destination, destinationOptions, session); | ||
@@ -67,0 +72,0 @@ } else { |
@@ -101,2 +101,3 @@ 'use strict'; | ||
accessToken: uaaResponse.access_token ? uaaResponse.access_token : uaaResponse.id_token, | ||
idToken: uaaResponse.id_token, | ||
expiresIn: uaaResponse.expires_in, | ||
@@ -103,0 +104,0 @@ refreshToken: uaaResponse.refresh_token, |
@@ -469,3 +469,3 @@ /* eslint-disable camelcase,max-depth */ | ||
} | ||
destinationUtils.getDestinationsByTenant(headerUtils.getCorrelationId(req), req.tenant, null, req.zoneInfo, req.app.services,false, function (err, subaccountDestinations) { | ||
destinationUtils.getDestinationsByTenant(headerUtils.getCorrelationId(req), req.tenant, null, req.zoneInfo, req.app.services,true, function (err, subaccountDestinations) { | ||
if (err) { | ||
@@ -472,0 +472,0 @@ return cb(err); |
{ | ||
"name": "@sap/approuter", | ||
"description": "Node.js based application router", | ||
"version": "16.6.1", | ||
"version": "16.6.2", | ||
"repository": {}, | ||
@@ -6,0 +6,0 @@ "main": "approuter.js", |
737809
11998