通用HTTP身份验证有几种身份验证模式,每种模式在安全强度不同,在客户机或服务器软件中的可用性方面可能有所不同。
最常见的认证方案是“基本”认证方案,下面将详细介绍它。
参考:https://javascript.net.cn/article?id=628
IANA维护着一个认证方案列表,但是主机服务也提供了其他的认证方案,比如Amazon AWS。常见的认证方案包括:
Basic
See RFC 7617, base64-encoded credentials. More information below.
https://tools.ietf.org/html/rfc7617
Bearer
See RFC 6750, bearer tokens to access OAuth 2.0-protected resources
https://tools.ietf.org/html/rfc6750
Digest
See RFC 7616, only md5 hashing is supported in Firefox, see bug 472823 for SHA encryption support
https://tools.ietf.org/html/rfc7616
HOBA
See RFC 7486, Section 3, HTTP Origin-Bound Authentication, digital-signature-based
https://tools.ietf.org/html/rfc7486
Mutual
See RFC 8120
https://tools.ietf.org/html/rfc8120
AWS4-HMAC-SHA256
See AWS docs
http://docs.aws.amazon.com/AmazonS3/latest/API/sigv4-auth-using-authorization-header.html
参考:
https://developer.mozilla.org/en-US/docs/Web/HTTP/Authentication#authentication_schemes