使用 Azure APIM 添加入站策略以验证 JWT 时,配置编辑器会引发以下错误:
One or more fields contain incorrect values: Error in element 'validate-jwt' on line 16, column 10: Certificate '' could not be resolved.
我可以看到它是issuer-signing-keys
导致问题的节点,因为删除它可以保存它。以下是策略文件的示例:
<policies>
<inbound>
<base />
<validate-jwt header-name="Authorization" require-scheme="Bearer">
<issuer-signing-keys>
<key>YmVlZg==</key>
</issuer-signing-keys>
</validate-jwt>
</inbound>
<backend>
<base />
</backend>
<outbound>
<base />
</outbound>
<on-error>
<base />
</on-error>
</policies>
提前感谢您的帮助