For detail information, we can check https://en.wikipedia.org/wiki/Basic_access_authentication
In the context of an HTTP transaction, basic access authentication is a method for an HTTP user agent to provide a user name and password when making a request.
Client side
When the user agent wants to send the server authentication credentials it may use the Authorization field.[7]The Authorization field is constructed as follows:[8][9][10]
- The username and password are combined into a string separated by a colon, e.g.:
username:password
- The resulting string is encoded using the RFC2045-MIME variant of Base64, except not limited to 76 char/line.
- The authorization method and a space i.e. "Basic " is then put before the encoded string.
Authorization: Basic QWxhZGRpbjpPcGVuU2VzYW1l
沒有留言:
張貼留言