rfc3310.txt

来自「RFC 的详细文档!」· 文本 代码 · 共 1,012 行 · 第 1/3 页

TXT
1,012 行
字号

RFC 3310          HTTP Digest Authentication Using AKA    September 2002


      Example:

          nonce="MzQ0a2xrbGtmbGtsZm9wb2tsc2tqaHJzZXNy9uQyMzMzMzQK="

       0                   1                   2                   3
       0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
      +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
      |                                                               |
      |                            RAND                               |
      |                                                               |
      |                                                               |
      +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
      |                                                               |
      |                            AUTN                               |
      |                                                               |
      |                                                               |
      +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
      |  Server Data...
      +-+-+-+-+-+-+-+-+-+-+-+

                    Figure 1: Generating the nonce value.

   If the server receives a client authentication containing the "auts"
   parameter defined in Section 3.4, that includes a valid AKA AUTS
   parameter, the server MUST use it to generate a new challenge to the
   client.  Note that when the AUTS is present, the included "response"
   parameter is calculated using an empty password (password of ""),
   instead of a RES.

3.3 Client Authentication

   When a client receives a Digest AKA authentication challenge, it
   extracts the RAND and AUTN from the "nonce" parameter, and assesses
   the AUTN token provided by the server.  If the client successfully
   authenticates the server with the AUTN, and determines that the SQN
   used in generating the challenge is within expected range, the AKA
   algorithms are run with the RAND challenge and shared secret K.

   The resulting AKA RES parameter is treated as a "password" when
   calculating the response directive of RFC 2617.

3.4 Synchronization Failure

   For indicating an AKA sequence number synchronization failure, and to
   re-synchronize the SQN in the AuC using the AUTS token, a new
   directive is defined for the "digest-response" of the "Authorization"
   request header defined in RFC 2617:




Niemi, et. al.               Informational                      [Page 7]

RFC 3310          HTTP Digest Authentication Using AKA    September 2002


           auts                =  "auts" EQUAL auts-param
           auts-param          =  LDQUOT auts-value RDQUOT
           auts-value          =  <base64 encoding of AUTS>


   auts
      A string carrying a base64 encoded AKA AUTS parameter.  This
      directive is used to re-synchronize the server side SQN.  If the
      directive is present, the client doesn't use any password when
      calculating its credentials.  Instead, the client MUST calculate
      its credentials using an empty password (password of "").

      Example:

            auts="CjkyMzRfOiwg5CfkJ2UK="

   Upon receiving the "auts" parameter, the server will check the
   validity of the parameter value using the shared secret K.  A valid
   AUTS parameter is used to re-synchronize the SQN in the AuC.  The
   synchronized SQN is then used to generate a fresh authentication
   vector AV, with which the client is then re-challenged.

3.5 Server Authentication

   Even though AKA provides inherent mutual authentication with the AKA
   AUTN token, mutual authentication mechanisms provided by Digest may
   still be useful in order to provide message integrity.

   In Digest AKA, the server uses the AKA XRES parameter as "password"
   when calculating the "response-auth" of the "Authentication-Info"
   header defined in RFC 2617.

4. Example Digest AKA Operation

   Figure 2 below describes a message flow describing a Digest AKA
   process of authenticating a SIP request, namely the SIP REGISTER
   request.














Niemi, et. al.               Informational                      [Page 8]

RFC 3310          HTTP Digest Authentication Using AKA    September 2002


      Client                                                  Server

        | 1) REGISTER                                           |
        |------------------------------------------------------>|
        |                                                       |
        |                            +-----------------------------+
        |                            | Server runs AKA algorithms, |
        |                            | generates RAND and AUTN.    |
        |                            +-----------------------------+
        |                                                       |
        |              2) 401 Unauthorized                      |
        |                 WWW-Authenticate: Digest              |
        |                                (RAND, AUTN delivered) |
        |<------------------------------------------------------|
        |                                                       |
    +------------------------------------+                      |
    | Client runs AKA algorithms on ISIM,|                      |
    | verifies AUTN, derives RES         |                      |
    | and session keys.                  |                      |
    +------------------------------------+                      |
        |                                                       |
        | 3) REGISTER                                           |
        |    Authorization: Digest (RES is used)                |
        |------------------------------------------------------>|
        |                                                       |
        |                            +------------------------------+
        |                            | Server checks the given RES, |
        |                            | and finds it correct.        |
        |                            +------------------------------+
        |                                                       |
        |               4) 200 OK                               |
        |                  Authentication-Info: (XRES is used)  |
        |<------------------------------------------------------|
        |                                                       |

     Figure 2: Message flow representing a successful authentication.

   1) Initial request

      REGISTER sip:home.mobile.biz SIP/2.0











Niemi, et. al.               Informational                      [Page 9]

RFC 3310          HTTP Digest Authentication Using AKA    September 2002


   2) Response containing a challenge

      SIP/2.0 401 Unauthorized
      WWW-Authenticate: Digest
              realm="RoamingUsers@mobile.biz",
              nonce="CjPk9mRqNuT25eRkajM09uTl9nM09uTl9nMz5OX25PZz==",
              qop="auth,auth-int",
              opaque="5ccc069c403ebaf9f0171e9517f40e41",
              algorithm=AKAv1-MD5

   3) Request containing credentials

      REGISTER sip:home.mobile.biz SIP/2.0
      Authorization: Digest
              username="jon.dough@mobile.biz",
              realm="RoamingUsers@mobile.biz",
              nonce="CjPk9mRqNuT25eRkajM09uTl9nM09uTl9nMz5OX25PZz==",
              uri="sip:home.mobile.biz",
              qop=auth-int,
              nc=00000001,
              cnonce="0a4f113b",
              response="6629fae49393a05397450978507c4ef1",
              opaque="5ccc069c403ebaf9f0171e9517f40e41"

   4) Successful response

      SIP/2.0 200 OK
      Authentication-Info:
              qop=auth-int,
              rspauth="6629fae49393a05397450978507c4ef1",
              cnonce="0a4f113b",
              nc=00000001



















Niemi, et. al.               Informational                     [Page 10]

RFC 3310          HTTP Digest Authentication Using AKA    September 2002


   Figure 3 below describes a message flow describing a Digest AKA
   authentication process, in which there is a synchronization failure.

      Client                                                 Server

        | 1) REGISTER                                           |
        |------------------------------------------------------>|
        |                                                       |
        |                            +-----------------------------+
        |                            | Server runs AKA algorithms, |
        |                            | generates RAND and AUTN.    |
        |                            +-----------------------------+
        |                                                       |
        |              2) 401 Unauthorized                      |
        |                 WWW-Authenticate: Digest              |
        |                                (RAND, AUTN delivered) |
        |<------------------------------------------------------|
        |                                                       |
    +------------------------------------+                      |
    | Client runs AKA algorithms on ISIM,|                      |
    | verifies the AUTN, but discovers   |                      |
    | that it contains an invalid        |                      |
    | sequence number. The client then   |                      |
    | generates an AUTS token.           |                      |
    +------------------------------------+                      |
        |                                                       |
        | 3) REGISTER                                           |
        |    Authorization: Digest (AUTS is delivered)          |
        |------------------------------------------------------>|
        |                                                       |
        |                                  +-----------------------+
        |                                  | Server performs       |
        |                                  | re-synchronization    |
        |                                  | using AUTS and RAND.  |
        |                                  +-----------------------+
        |                                                       |
        |              4) 401 Unauthorized                      |
        |                 WWW-Authenticate: Digest              |
        |                                (re-synchronized RAND, |
        |                                 AUTN delivered)       |
        |<------------------------------------------------------|
        |                                                       |

   Figure 3: Message flow representing an authentication synchronization
   failure.






Niemi, et. al.               Informational                     [Page 11]

RFC 3310          HTTP Digest Authentication Using AKA    September 2002


   1) Initial request

      REGISTER sip:home.mobile.biz SIP/2.0

   2) Response containing a challenge

      SIP/2.0 401 Unauthorized
      WWW-Authenticate: Digest
            realm="RoamingUsers@mobile.biz",
            qop="auth",
            nonce="CjPk9mRqNuT25eRkajM09uTl9nM09uTl9nMz5OX25PZz==",
            opaque="5ccc069c403ebaf9f0171e9517f40e41",
            algorithm=AKAv1-MD5

   3) Request containing credentials

      REGISTER sip:home.mobile.biz SIP/2.0
      Authorization: Digest
            username="jon.dough@mobile.biz",
            realm="RoamingUsers@mobile.biz",
            nonce="CjPk9mRqNuT25eRkajM09uTl9nM09uTl9nMz5OX25PZz==",
            uri="sip:home.mobile.biz",
            qop=auth,
            nc=00000001,
            cnonce="0a4f113b",
            response="4429ffe49393c02397450934607c4ef1",
            opaque="5ccc069c403ebaf9f0171e9517f40e41",
            auts="5PYxMuX2NOT2NeQ="

   4) Response containing a new challenge

      SIP/2.0 401 Unauthorized
      WWW-Authenticate: Digest
            realm="RoamingUsers@mobile.biz",
            qop="auth,auth-int",
            nonce="9uQzNPbk9jM05Pbl5Pbl5DIz9uTl9uTl9jM0NTHk9uXk==",
            opaque="dcd98b7102dd2f0e8b11d0f600bfb0c093",
            algorithm=AKAv1-MD5

5. Security Considerations

   In general, Digest AKA is vulnerable to the same security threats as
   HTTP authentication [2].  This chapter discusses the relevant
   exceptions.







Niemi, et. al.               Informational                     [Page 12]

RFC 3310          HTTP Digest Authentication Using AKA    September 2002

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?