Skip to content

Infinite loop, stack overflow #632

Closed
@iget-master

Description

@iget-master

Hi,

I have two projects, both using L5.5 and latest Laravel Passport.

Both projects runs under a docker environment, but the first one works, the last don't.
Actually, both worked, but after some permission changes (my docker env was setting 777 for everything), it stopped working, but only one of them.

I've tried to revert the changes, clear install the environment, with no success.

The failing project just gives me 500 error, with exceeded execution time (30s).

Looking the logs, I've found the following log, see the bin, only for the last 3 entries, but the entire file grows very fast to 1GB.

Observe that this part repeats a lot of times, indicating an infinite loop:

#16 [internal function]: Laravel\Passport\PassportServiceProvider->Laravel\Passport\{closure}(Object(Illuminate\Http\Request), NULL)
#17 /var/www/vendor/laravel/framework/src/Illuminate/Auth/RequestGuard.php(58): call_user_func(Object(Closure), Object(Illuminate\Http\Request), NULL)
#18 /var/www/vendor/laravel/framework/src/Illuminate/Auth/GuardHelpers.php(70): Illuminate\Auth\RequestGuard->user()
#19 /var/www/vendor/laravel/framework/src/Illuminate/Auth/AuthManager.php(292): Illuminate\Auth\RequestGuard->id()
#20 /var/www/vendor/laravel/framework/src/Illuminate/Support/Facades/Facade.php(221): Illuminate\Auth\AuthManager->__call('id', Array)
#21 /var/www/vendor/laravel/framework/src/Illuminate/Foundation/Exceptions/Handler.php(152): Illuminate\Support\Facades\Facade::__callStatic('id', Array)
#22 /var/www/vendor/laravel/framework/src/Illuminate/Foundation/Exceptions/Handler.php(113): Illuminate\Foundation\Exceptions\Handler->context()
#23 /var/www/app/Exceptions/Handler.php(43): Illuminate\Foundation\Exceptions\Handler->report(Object(League\OAuth2\Server\Exception\OAuthServerException))
#24 /var/www/vendor/laravel/passport/src/Guards/TokenGuard.php(143): App\Exceptions\Handler->report(Object(League\OAuth2\Server\Exception\OAuthServerException))
#25 /var/www/vendor/laravel/passport/src/Guards/TokenGuard.php(90): Laravel\Passport\Guards\TokenGuard->authenticateViaBearerToken(Object(Illuminate\Http\Request))
#26 /var/www/vendor/laravel/passport/src/PassportServiceProvider.php(267): Laravel\Passport\Guards\TokenGuard->user(Object(Illuminate\Http\Request))
#27 [internal function]: Laravel\Passport\PassportServiceProvider->Laravel\Passport\{closure}(Object(Illuminate\Http\Request), NULL)

Since the issue is a little complex, I'm able to provide some necessary information that you need.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions