schollz commented on issue #25740:
URL: https://github.com/apache/superset/issues/25740#issuecomment-2936082273

   @rusackas I resolved the issue, there were a couple of issues at hand in my 
case.
   
   Firstly I needed to include the correct ROLE configuration variables in my 
config:
   
   ```python
   GUEST_ROLE_NAME = "Gamma"
   PUBLIC_ROLE_LIKE = "Gamma"
   ```
   
   Once they were in, I no longer got the 401 error. I did have a new error, 
though, related to the audience. I was using the guest token generated from the 
app:
   
   ```javascript
   {
     "user": {
       "username": "[email protected]",
       "first_name": "embedded",
       "last_name": "embedded"
     },
     "resources": [
       {
         "type": "dashboard",
         "id": "d73e7841-9342-4afd-8e29-b4a416a2498c"
       }
     ],
     "rls_rules": [],
     "iat": 1730883214,
     "exp": 1732956814,
     "aud": "superset",
     "type": "guest"
   }
   ```
   
   And the `aud` was specified as `superset`. So to get this to work I realized 
I needed to include that in the configuration as well:
   
   ```python
   GUEST_TOKEN_JWT_AUDIENCE = "superset"
   ```
   
   After that, it is working as expected in 5.0.0rc2 (and probably 4.1.1 as 
well, but I haven't checked). But in the end it was a configuration error on my 
end. 


-- 
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]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to