问题描述
现在我的OpenAPI yaml看起来像这样:
Right now my OpenAPI yaml looks like this:
从我的JWT中以原始格式发出的访问令牌看起来像这样:
And my Access Token coming out of my JWT in raw format looks like this:
Google-Issuer和JWT iss完全相同,JWT kid匹配google-jwks_uri提供的链接内的键ID,而google-audits匹配aud.所以,实际上,我不能看看为什么这行不通,但是当我使用Bearer访问令牌调用api时,我会收到401,并且未配置Jwt颁发者".
The Google-Issuer and the JWT iss are the exact same, the JWT kid matches the key ids inside the link provided by the google-jwks_uri, and the google-audiences match the aud.So, really, I can't see why this wouldn't work, and yet when i call the api with the Bearer access token i receive a 401 and "Jwt issuer is not configured".
推荐答案
@BryceSoker我遇到了类似的问题,发现正在改变
@BryceSoker I ran into a similar problem and found that changing
x-google-issuer:" https://accounts.google.com "到x-google-issuer:"accounts.google.com"
x-google-issuer: "https://accounts.google.com"tox-google-issuer: "accounts.google.com"
与ID令牌中的"iss":"accounts.google.com"相匹配,解决了该问题.
to match the "iss": "accounts.google.com" in the ID token fixed the problem.
这篇关于使用CICP/Firebase身份验证中的访问令牌时,未配置返回JWT Issuer的Cloud Endpoints Auth的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!