Fix SAML2 session timeout during XHR requests

This commit is contained in:
Francis Lachapelle committed 2018-04-17 15:14:48 -04:00
1 parent e6e1fddb3e
commit 162206b934
4 files changed
+19 -2

No files matched your search

@@ -267,9 +267,10 @@
var deferred, iframe;
if (/^application\/json/.test(rejection.config.headers.Accept)) {
// Handle CAS ticket renewal
if ($window.usesCASAuthentication && rejection.status == -1) {
if (($window.usesCASAuthentication && rejection.status == -1) ||
($window.usesSAML2Authentication && rejection.status == 401)) {
deferred = $q.defer();
iframe = angular.element('<iframe class="ng-hide" src="' + UserFolderURL + 'recover"></iframe>');
iframe = angular.element('<iframe class="ng-hide" src="' + $window.UserFolderURL + 'recover"></iframe>');
iframe.on('load', function() {
// Once the browser has followed the redirection, send the initial request
var $http = $injector.get('$http');