3.9.5.1.1 Version Identifier Response

ConnectionState MUST be "Negotiating". Otherwise, it is a protocol error and the SOCKS connection MUST be closed, as specified in section 3.9.4.2.

The client verifies that the response message VER field number equals the client SOCKS version number, "0x05". If the versions are not equal, it is a protocol error, and the SOCKS connection MUST be closed, as specified in section 3.9.4.2.

If the response message METHODS field contains the method "0xFF" (NO ACCEPTABLE METHOD), it means that the server does not support any authentication methods supported by the client. The client MUST close the SOCKS connection, as specified in section 3.9.4.2.

If the response message METHODS field is "0x00" (NO AUTHENTICATION REQUIRED), the client sets the ConnectionState to "Negotiated" and continues as specified in section 3.9.5.1.2 to send the SOCKS connect request.

If the response message METHODS field is "0x01" (GSSAPI), the client MAY perform GSSAPI authentication negotiation, as specified in [RFC1961].<65>

If the response message METHODS field is "0x02" (USERNAME and PASSWORD), the client MUST perform USERNAME and PASSWORD authentication negotiation, as specified in [RFC1929].

After successfully completing the proxy authentication, the ConnectionState MUST transition to the "Negotiated" state.

The client MUST send a SOCKS connect request message, as specified in section 3.9.5.1.2.