authentication - 为什么error login和password server return status 200 ok

标签 authentication server status

所有主要的网络应用程序(谷歌、Facebook 等)在身份验证失败的情况下返回页面状态 200 ok,即错误的登录名/密码对。

虽然通过 definition ,如果未找到具有请求 URI 的资源 - 返回状态 404 Not found

维基百科说:

[404 Not Found] Used when the requested resource is not found, whether it doesn't exist or if there was a 401 or 403 that, for security reasons, the service wants to mask

login 的情况有何不同?

最佳答案

服务器代码 200 表示您收到响应。是否是您的凭据错误。如果您的请求尚未处理,则服务器返回不同的错误代码。但是对于你的情况,

您的登录请求已被处理,与数据库的连接已建立,您从中得到了错误的凭据消息。所以代码 200 是你成功处​​理的请求。

关于authentication - 为什么error login和password server return status 200 ok,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/47427371/

相关文章:

error-handling - 服务器的响应缺少必填字段时,是否可以使用状态代码?

javascript - 使用 react 路由器进行模态对话框身份验证

javascript - MarkLogic 应用程序服务器自定义登录页面 sessionID cookie 与 GET 请求

python - 如何通过重新启动应用程序来克服ModbusTcpServer中的 "Address already in use"?

python - 如何在Ubuntu服务器后台运行Python程序

svn - 结帐后无法解释的 Subversion 目录状态

javascript - Node js 中的身份验证过程中出现无效盐错误

android - 谷歌身份验证器作为单一登录方法

node.js - GraphQL/Prisma 客户端服务器错误 : Variable '$data' cannot be non input type 'LinkCreateInput!' .(第 1 行,第 18 列)

安卓短信状态