anderson-fachini opened a new issue, #61270:
URL: https://github.com/apache/airflow/issues/61270

   ### Apache Airflow Provider(s)
   
   fab
   
   ### Versions of Apache Airflow Providers
   
   _No response_
   
   ### Apache Airflow version
   
   3.12
   
   ### Operating System
   
   Debian GNU/Linux 12 (bookworm)
   
   ### Deployment
   
   Official Apache Airflow Helm Chart
   
   ### Deployment details
   
   _No response_
   
   ### What happened
   
   JyPWT just released version 2.11.0 that included  "iss, issuer type checks" 
and this breaks the authentication flow after login (in my case, with azure 
credentials).
   
   Error log:
   2026-01-30T21:17:20.830242Z [info     ] Updated user xxx 
[airflow.providers.fab.auth_manager.security_manager.override] 
loc=override.py:1463
   2026-01-30T21:17:20.831304Z [error    ] Exception on /oauth-authorized/azure 
[GET] [airflow.providers.fab.www.app] loc=app.py:1744
   Traceback (most recent call last):
     File "/home/airflow/.local/lib/python3.12/site-packages/flask/app.py", 
line 2529, in wsgi_app
       response = self.full_dispatch_request()
                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     File "/home/airflow/.local/lib/python3.12/site-packages/flask/app.py", 
line 1825, in full_dispatch_request
       rv = self.handle_user_exception(e)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     File "/home/airflow/.local/lib/python3.12/site-packages/flask/app.py", 
line 1823, in full_dispatch_request
       rv = self.dispatch_request()
            ^^^^^^^^^^^^^^^^^^^^^^^
     File "/home/airflow/.local/lib/python3.12/site-packages/flask/app.py", 
line 1799, in dispatch_request
       return self.ensure_sync(self.view_functions[rule.endpoint])(**view_args)
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     File 
"/home/airflow/.local/lib/python3.12/site-packages/flask_appbuilder/security/views.py",
 line 732, in oauth_authorized
       return redirect(next_url)
              ^^^^^^^^^^^^^^^^^^
     File 
"/home/airflow/.local/lib/python3.12/site-packages/airflow/providers/fab/www/views.py",
 line 114, in redirect
       token = get_auth_manager().generate_jwt(g.user)
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     File 
"/home/airflow/.local/lib/python3.12/site-packages/airflow/api_fastapi/auth/managers/base_auth_manager.py",
 line 120, in generate_jwt
       return 
self._get_token_signer(expiration_time_in_seconds=expiration_time_in_seconds).generate(
              
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     File 
"/home/airflow/.local/lib/python3.12/site-packages/airflow/api_fastapi/auth/tokens.py",
 line 459, in generate
       return jwt.encode(claims, self.signing_arg, algorithm=self.algorithm, 
headers=headers)
              
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     File "/home/airflow/.local/lib/python3.12/site-packages/jwt/api_jwt.py", 
line 145, in encode
       raise TypeError("Issuer (iss) must be a string.")
   TypeError: Issuer (iss) must be a string.
   
   ### What you think should happen instead
   
   _No response_
   
   ### How to reproduce
   
   Configure Fab provider with azure login and try to log in. The following 
error will appear:
   
   <img width="876" height="465" alt="Image" 
src="https://github.com/user-attachments/assets/88ddff8b-022a-4aab-84d2-61ba0510ef07";
 />
   
   ### Anything else
   
   _No response_
   
   ### Are you willing to submit PR?
   
   - [ ] Yes I am willing to submit a PR!
   
   ### Code of Conduct
   
   - [x] I agree to follow this project's [Code of 
Conduct](https://github.com/apache/airflow/blob/main/CODE_OF_CONDUCT.md)
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to