Can JWT audience checking be disabled in ESPv2?

40 views
Skip to first unread message

hans.r...@impact.com

unread,
Jun 7, 2022, 9:42:42 AM6/7/22
to Google Cloud Endpoints
Hi, there

I'd like to at least temporarily disable the JWT "aud" claim check in ESPv2 as it'll take a while to get it added to the token. Is there a way to do this?

It seems that the JWT RFC calls out "aud" as optional. I've tried removing aud from the token and x-google-audiences from the OpenAPI doc, but I'm getting the "Audience not allowed" error still. Same error when using x-google-audiences: "", so setting it to an empty string. I suspect the answer is "no, this is not possible as it would be less secure". 

Thanks,
Hans

qiwz...@google.com

unread,
Jun 7, 2022, 11:49:29 AM6/7/22
to Google Cloud Endpoints
Just checked ESPv2 code,   you could not disable "aud" checking.   If you don't specify `x-google-audiences`,  we will set the default one for you. 

-Wayne

qiwz...@google.com

unread,
Jun 7, 2022, 11:50:38 AM6/7/22
to Google Cloud Endpoints
BTW, could you open an issue at this repo.  Thanks
Reply all
Reply to author
Forward
0 new messages