Websockets授权函数不会被查询字符串标识符触发。

0

【以下的问题经过翻译处理】 当我们的 Authorizer 函数的标识符从 sourcetype Header 更改为 sourcetype Querystring 时,我们的 Authorization Lambda 没有启动并且没有创建日志。

举个例子:

https://i.imgur.com/IYCasYp.png

()=>new WebSocket('wss://x0x0x0x0x0.execute-api.eu-central-1.amazonaws.com/dev?authorizationToken=' + headers.Auth)

profile picture
EXPERT
asked 6 months ago5 views
1 Answer
0

【以下的回答经过翻译处理】 根据您的截图,您没有更改身份来源,但添加了其他身份来源。除非请求同时具有标题和查询字符串,否则您的授权器将不会触发。

如果要使用查询字符串,请删除标题身份来源。

profile picture
EXPERT
answered 6 months ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions