Support the ongoing development of Laravel.io →
posted 8 years ago
Authentication
Last updated 2 years ago.
0
Solution

Found the root of the problem !

It was a wrong comparative inside Illuminate\Auth\SessionGuard between values of identifiers.

My identifier is a String of numbers and must be able to have leading zeroes.

Inside my model I have overloaded the getAuthIdentifier() to return the original value which comes from database without converting into integer:

public function getAuthIdentifier(){
        /*
         * Get the original value from database without integer conversion
         */
        return $this->getOriginal('uregistration');
    }

I think there should be an exception when the SessionGuard tries to update the session with the wrong identification. The problem happens here:

https://github.com/laravel/framework/blob/5.3/src/Illuminate/Auth/SessionGuard.php#L443

Thanks !

0

Sign in to participate in this thread!

Eventy

Your banner here too?

Hodes hodes Joined 29 Aug 2016

Moderators

We'd like to thank these amazing companies for supporting us

Your logo here?

Laravel.io

The Laravel portal for problem solving, knowledge sharing and community building.

© 2024 Laravel.io - All rights reserved.