Skip to content
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

Session Error #98

Closed
emanuelcoelho1986 opened this issue Jul 3, 2014 · 8 comments
Closed

Session Error #98

emanuelcoelho1986 opened this issue Jul 3, 2014 · 8 comments
Labels
Milestone

Comments

@emanuelcoelho1986
Copy link

It seems that is something wrong with the Session Library File in the 2.2.0 version. If we downgrade the file to the 2.1.4 the login works properly. But with the 2.2.0, even if you put your credentials correct, its doesn't log us in in the system.

@StorytellerCZ StorytellerCZ added this to the 1.x milestone Jul 4, 2014
@Timps
Copy link

Timps commented Jul 11, 2014

Yeah looks like Codeigniter had a colossal flaw in their session security so they patched it in 2.2.0 but it's killed something in how A3M is doing sessions.

This is what's generated in the log file:ERROR - 2014-07-11 07:05:55 --> Session: HMAC mismatch. The session cookie data did not match what was expected.

And for some odd reason everytime I attempt a login it creates 4 sessions in the database. Only one of which contains the user id data.

@StorytellerCZ
Copy link
Collaborator

I see two changelog items related to sessions:
Security: The Session Library now uses HMAC authentication instead of a simple MD5 checksum.
Fixed a bug in the Session Library where authentication was not performed for encrypted cookies.

I think the issue we have is with the first one.

@Timps
Copy link

Timps commented Jul 11, 2014

That makes sense.
Looks like the second one is what started the discussion about codeigniters session security, so they changed the encryption while they were in there.

@StorytellerCZ
Copy link
Collaborator

I think I have the fix. Will push in a moment.

@StorytellerCZ
Copy link
Collaborator

Can you test it to make sure I got it?

@Timps
Copy link

Timps commented Jul 11, 2014

Worked like a charm.
Thank you.

@StorytellerCZ
Copy link
Collaborator

Great! I still have one more bug that I discovered while working on v2 to fix and then I'll release the new version.

@emanuelcoelho1986
Copy link
Author

Cheers ;) Thanks.
I made a workaround in the development environment by adding the Session.php file of the 2.1.4, since the only change was the HMAC authentication, like AdwinTrave said. With this fix i can get the Session.php from 2.2.0.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants