Angular web app routing within Juniper SSL VPN

Issue

Currently I am working on a simple web app, using AngularJS. During the development process, I tested it while the app was locally served by IIS. However, when I deployed it on a company web server and ran it within a Juniper SSL VPN the trouble began.

First I had to apply the following ‘fix’:
AngularJS Routing Fails when running within a Juniper SSL VPN #8905

But the above fix only solved part of the trouble. The problem that remains is that AngularJS returns the following error when I try to load an other than the default (‘/’) view ($location.path(‘/anotherView’) from the view controller, I get the following error message:

Error: [$rootScope:infdig] 10 $digest() iterations reached. Aborting!
Watchers fired in the last 5 iterations: []
http://errors.angularjs.org/1.3.15/$rootScope/infdig?p0=10&p1=%5B%5D
    at REGEX_STRING_REGEXP (,DanaInfo=server1.mydomain.nl,CT=js+angular.js:63)
    at Scope.$get.Scope.$digest (,DanaInfo=server1.mydomain.nl,CT=js+angular.js:14340)
    at Scope.$get.Scope.$apply (,DanaInfo=server1.mydomain.nl,CT=js+angular.js:14565)
    at done (,DanaInfo=server1.mydomain.nl,CT=js+angular.js:9685)
    at completeRequest (,DanaInfo=server1.mydomain.nl,CT=js+angular.js:9875)
    at XMLHttpRequest.requestLoaded (,DanaInfo=server1.mydomain.nl,CT=js+angular.js:9816)(anonymous function) @ ,DanaInfo=server1.mydomain.nl,CT=js+angular.js:11649$get @ ,DanaInfo=server1.mydomain.nl,CT=js+angular.js:8583$get.Scope.$apply @ ,DanaInfo=server1.mydomain.nl,CT=js+angular.js:14567done @ ,DanaInfo=server1.mydomain.nl,CT=js+angular.js:9685completeRequest @ ,DanaInfo=server1.mydomain.nl,CT=js+angular.js:9875requestLoaded @ ,DanaInfo=server1.mydomain.nl,CT=js+angular.js:9816

I’ve tested it with the default AngularJS Routing and the Angular ui.router mechanism and both give the same result.

Any help to solve this problem is really appreciated!

Solution

Problem is solved by configuring Juniper to act as a reversed proxy.

Answered By – André Bakker

Answer Checked By – Marie Seifert (AngularFixing Admin)

Leave a Reply

Your email address will not be published.