title: Replicating claims as headers is deprecated and will removed from v4.0 - Laravel Passport Problem in lcobucci/jwt package
body: <p>I'm using <code>laravel/passport:7.5.1</code> package in my laravel project and recently faced with this exception. Any Idea? I temperory downgrade the  <code>lcobucci/jwt:3.4.0</code> package to <code>lcobucci/jwt:3.3.3</code></p>
  <pre><code>Replicating claims as headers is deprecated and will removed from v4.0. Please manually set the header if you need it replicated.
  </code></pre>
  <p><strong>Stack Trace:</strong></p>
  <pre><code>&quot;exception&quot;: {
    &quot;trace&quot;: [
      &quot;/var/www/app/vendor/lcobucci/jwt/src/Builder.php:334&quot;,
      &quot;/var/www/app/vendor/lcobucci/jwt/src/Builder.php:185&quot;,
      &quot;/var/www/app/vendor/lcobucci/jwt/src/Builder.php:201&quot;,
      &quot;/var/www/app/vendor/league/oauth2-server/src/Entities/Traits/AccessTokenTrait.php:34&quot;,
      &quot;/var/www/app/vendor/league/oauth2-server/src/ResponseTypes/BearerTokenResponse.php:28&quot;,
      &quot;/var/www/app/vendor/league/oauth2-server/src/AuthorizationServer.php:202&quot;,
      &quot;/var/www/app/vendor/laravel/passport/src/PersonalAccessTokenFactory.php:114&quot;,
      &quot;/var/www/app/vendor/laravel/passport/src/PersonalAccessTokenFactory.php:71&quot;,
      &quot;/var/www/app/vendor/laravel/passport/src/HasApiTokens.php:67&quot;,
      &quot;/var/www/app/app/Http/Controllers/Auth/Shop/GetTokenController.php:84&quot;,
      &quot;/var/www/app/vendor/laravel/framework/src/Illuminate/Routing/Controller.php:54&quot;,
      &quot;/var/www/app/vendor/laravel/framework/src/Illuminate/Routing/ControllerDispatcher.php:45&quot;,
      &quot;/var/www/app/vendor/laravel/framework/src/Illuminate/Routing/Route.php:219&quot;,
      &quot;/var/www/app/vendor/laravel/framework/src/Illuminate/Routing/Route.php:176&quot;,
      &quot;/var/www/app/vendor/laravel/framework/src/Illuminate/Routing/Router.php:680&quot;,
      &quot;/var/www/app/vendor/laravel/framework/src/Illuminate/Routing/Pipeline.php:30&quot;,
      &quot;/var/www/app/vendor/laravel/framework/src/Illuminate/Routing/Middleware/SubstituteBindings.php:41&quot;,
      &quot;/var/www/app/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:163&quot;,
      &quot;/var/www/app/vendor/laravel/framework/src/Illuminate/Routing/Pipeline.php:53&quot;,
      &quot;/var/www/app/vendor/laravel/framework/src/Illuminate/Routing/Middleware/ThrottleRequests.php:58&quot;,
      &quot;/var/www/app/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:163&quot;,
      &quot;/var/www/app/vendor/laravel/framework/src/Illuminate/Routing/Pipeline.php:53&quot;,
      &quot;/var/www/app/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:104&quot;,
      &quot;/var/www/app/vendor/laravel/framework/src/Illuminate/Routing/Router.php:682&quot;,
      &quot;/var/www/app/vendor/laravel/framework/src/Illuminate/Routing/Router.php:657&quot;,
      &quot;/var/www/app/vendor/laravel/framework/src/Illuminate/Routing/Router.php:623&quot;,
      &quot;/var/www/app/vendor/laravel/framework/src/Illuminate/Routing/Router.php:612&quot;,
      &quot;/var/www/app/vendor/laravel/framework/src/Illuminate/Foundation/Http/Kernel.php:176&quot;,
      &quot;/var/www/app/vendor/laravel/framework/src/Illuminate/Routing/Pipeline.php:30&quot;,
      &quot;/var/www/app/vendor/barryvdh/laravel-debugbar/src/Middleware/InjectDebugbar.php:65&quot;,
      &quot;/var/www/app/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:163&quot;,
      &quot;/var/www/app/vendor/laravel/framework/src/Illuminate/Routing/Pipeline.php:53&quot;,
      &quot;/var/www/app/vendor/app/dms-pubsub/src/Middlewares/CaptureCorrelationIdMiddleware.php:40&quot;,
      &quot;/var/www/app/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:163&quot;,
      &quot;/var/www/app/vendor/laravel/framework/src/Illuminate/Routing/Pipeline.php:53&quot;,
      &quot;/var/www/app/app/Http/Middleware/TrimData.php:31&quot;,
      &quot;/var/www/app/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:163&quot;,
      &quot;/var/www/app/vendor/laravel/framework/src/Illuminate/Routing/Pipeline.php:53&quot;,
      &quot;/var/www/app/vendor/fideloper/proxy/src/TrustProxies.php:57&quot;,
      &quot;/var/www/app/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:163&quot;,
      &quot;/var/www/app/vendor/laravel/framework/src/Illuminate/Routing/Pipeline.php:53&quot;,
      &quot;/var/www/app/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/TransformsRequest.php:21&quot;,
      &quot;/var/www/app/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:163&quot;,
      &quot;/var/www/app/vendor/laravel/framework/src/Illuminate/Routing/Pipeline.php:53&quot;,
      &quot;/var/www/app/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/TransformsRequest.php:21&quot;,
      &quot;/var/www/app/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:163&quot;,
      &quot;/var/www/app/vendor/laravel/framework/src/Illuminate/Routing/Pipeline.php:53&quot;,
      &quot;/var/www/app/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/ValidatePostSize.php:27&quot;,
      &quot;/var/www/app/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:163&quot;,
      &quot;/var/www/app/vendor/laravel/framework/src/Illuminate/Routing/Pipeline.php:53&quot;,
      &quot;/var/www/app/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/CheckForMaintenanceMode.php:62&quot;,
      &quot;/var/www/app/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:163&quot;,
      &quot;/var/www/app/vendor/laravel/framework/src/Illuminate/Routing/Pipeline.php:53&quot;,
      &quot;/var/www/app/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:104&quot;,
      &quot;/var/www/app/vendor/laravel/framework/src/Illuminate/Foundation/Http/Kernel.php:151&quot;,
      &quot;/var/www/app/vendor/laravel/framework/src/Illuminate/Foundation/Http/Kernel.php:116&quot;,
      &quot;/var/www/app/public/index.php:55&quot;
    ],
    &quot;class&quot;: &quot;ErrorException&quot;,
    &quot;file&quot;: &quot;/var/www/app/vendor/lcobucci/jwt/src/Builder.php:334&quot;,
    &quot;message&quot;: &quot;Replicating claims as headers is deprecated and will removed from v4.0. Please manually set the header if you need it replicated.&quot;,
    &quot;code&quot;: 0
  }
  </code></pre>