【发布时间】:2017-10-04 13:05:28
【问题描述】:
我有一个使用 grant_type=password 作为 oauth 方法的应用程序。
请求看起来像:
请求
POST https://myLync.mydomain.com/WebTicket/oauthtoken HTTP/1.1
Content-Type: application/x-www-form-urlencoded; charset=utf-8
Content-Length: 61
grant_type=password&username=usr@domain.invalid&password=pass
这将导致 400 Bad Request 响应,正文告诉我:
回应
HTTP/1.1 400 Bad Request
Cache-Control: no-store
Pragma: no-cache
Content-Type: application/json
X-Ms-diagnostics: 28020;source="sfb-fe.mydomain.com";reason="No valid security token."
X-MS-Server-Fqdn: sfb-fe.mydomain.com
X-MS-Correlation-Id: 2147484275
client-request-id: f623a18b-c1d1-476f-9e58-f9745322b3e5
Strict-Transport-Security: max-age=31536000; includeSubDomains
X-Content-Type-Options: nosniff
Content-Length: 25
Connection: close
{"error":"invalid_grant"}
我已经搜索了好几个小时,但找不到任何可以为我提供解决方案提示的东西。
有人偶然发现了同样的问题,也许对此有解决方案?不幸的是,“没有有效的安全令牌”并没有告诉我太多。
【问题讨论】: