1--- 2c: Copyright (C) Daniel Stenberg, <daniel.se>, et al. 3SPDX-License-Identifier: curl 4Title: CURLOPT_SOCKS5_GSSAPI_NEC 5Section: 3 6Source: libcurl 7See-also: 8 - CURLOPT_PROXY (3) 9 - CURLOPT_SOCKS5_GSSAPI_SERVICE (3) 10--- 11 12# NAME 13 14CURLOPT_SOCKS5_GSSAPI_NEC - SOCKS proxy GSSAPI negotiation protection 15 16# SYNOPSIS 17 18~~~c 19#include <curl/curl.h> 20 21CURLcode curl_easy_setopt(CURL *handle, CURLOPT_SOCKS5_GSSAPI_NEC, long nec); 22~~~ 23 24# DESCRIPTION 25 26Pass a long set to 1 to enable or 0 to disable. As part of the GSSAPI 27negotiation a protection mode is negotiated. The RFC 1961 says in section 284.3/4.4 it should be protected, but the NEC reference implementation does not. 29If enabled, this option allows the unprotected exchange of the protection mode 30negotiation. 31 32# DEFAULT 33 34? 35 36# PROTOCOLS 37 38Most 39 40# EXAMPLE 41 42~~~c 43int main(void) 44{ 45 CURL *curl = curl_easy_init(); 46 if(curl) { 47 CURLcode res; 48 curl_easy_setopt(curl, CURLOPT_URL, "https://example.com/"); 49 curl_easy_setopt(curl, CURLOPT_PROXY, "socks5://proxy"); 50 curl_easy_setopt(curl, CURLOPT_SOCKS5_GSSAPI_NEC, 1L); 51 res = curl_easy_perform(curl); 52 curl_easy_cleanup(curl); 53 } 54} 55~~~ 56 57# AVAILABILITY 58 59Added in 7.19.4 60 61# RETURN VALUE 62 63Returns CURLE_OK if the option is supported, and CURLE_UNKNOWN_OPTION if not. 64