Skip to content

Authentication bug with IE11 #2046

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
bestconsultant opened this issue Jul 7, 2016 · 10 comments
Open

Authentication bug with IE11 #2046

bestconsultant opened this issue Jul 7, 2016 · 10 comments

Comments

@bestconsultant
Copy link

bestconsultant commented Jul 7, 2016

Here is the case:

I create an application (parameters below), I push it on heroku. I create two users (A and B).
I open IE11 log in as A.
"Hello A" is displayed right on the bar.
Then I log out.
I login as B.
"Hello A" is displayed right on the bar.
I hit F5
"Hello B" is right displayed right on the bar.

For IE to work I had to modify Util.isSameOrigin() to return true always.
This needs to be tested several times as behaviour is inconsistent (ex. closing IE and reopening before executing the scenario).

Same scenario works flawless on Firefox, Chrome, Safari whether on mac or windows.

Moreover, console log outputs several CSS errors : CS3111: @font-face encountered unknown error. (Not sure if this is related).

Item Version
generator-angular-fullstack 3.0.2
Node 4.2.3
npm 2.14.7
Operating System Windows 7
Browser IE 11.0.9600.18314
Item Answer
Transpiler Babel
Markup HTML
CSS CSS
Router ngRoute
Build Tool Grunt
Client Tests Jasmine
DB MongoDB
SocketIO n
Auth Y
Bootstrap Y
UiBootstrap Y
@Awk34
Copy link
Member

Awk34 commented Jul 7, 2016

Is #1880 related? See if the problem still exists on a brand new scaffold using 3.7.6

@bestconsultant
Copy link
Author

I don't believe it is. I avoided the token issue by neutralizing Util.isSameOrigin() which always returns true and authentication works fine in IE in a basic scenario.
I will update my generator, try with the latest version and keep you posted.

@bestconsultant
Copy link
Author

Couldn't deploy the latest version (3.7.6) to heroku. See #1950

@bestconsultant
Copy link
Author

My solution for heroku #1966

@bestconsultant
Copy link
Author

I confirm that the problem also occurs with scaffolding 3.7.6 on IE11 (other parameters are the same).

@bestconsultant
Copy link
Author

Am I the only one around here who thinks this is a BIG bug?

@Awk34
Copy link
Member

Awk34 commented Jul 15, 2016

@flaurian do you have a solution to this that could be put into the generator? If so, I would apprectiate a PR.

@bestconsultant
Copy link
Author

Unfortunately my only idea would be to force a reload to simulate the F5 click with this code in the successful promise of the login function in the auth.service:

if (functions.isInternetExplorer()) {
window.location.href = window.location.href;
}

But there should be a more elegant way to do this. My feeling is that the $cookies service may have some trouble with IE11 but I cannot find the exact spot where it fails.

@Awk34
Copy link
Member

Awk34 commented Jul 15, 2016

That's pretty ugly, yeah, but if it's the only real solution, then it's better than nothing. Especially if it's something that most likely wouldn't be encountered by an actual user.

@bestconsultant
Copy link
Author

I tested my idea to reload but it didn't work properly. I really don't get why IE is behaving like this. I guess it has something to do with the headers, but this is beyond my knowledge.

@Awk34 Awk34 added the V3 label Nov 29, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants