From e56ae1426cb7a0a4a427cf8d6099a821fdaae428 Mon Sep 17 00:00:00 2001 From: Daniel Stenberg Date: Tue, 10 Jun 2003 12:22:19 +0000 Subject: Daniel Kouril's patch that adds HTTP negotiation support to libcurl was added. --- src/main.c | 19 +++++++++++++++++++ src/version.h | 2 +- 2 files changed, 20 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/main.c b/src/main.c index 3a52401e0..0e740f3ed 100644 --- a/src/main.c +++ b/src/main.c @@ -359,6 +359,9 @@ static void help(void) " -d/--data HTTP POST data (H)\n" " --data-ascii HTTP POST ASCII data (H)\n" " --data-binary HTTP POST binary data (H)\n" +#ifdef GSSAPI + " --negotiate Enable HTTP Negotiate Authentication\n" +#endif " --digest Enable HTTP Digest Authentication"); puts(" --disable-eprt Prevents curl from using EPRT or LPRT (F)\n" " --disable-epsv Prevents curl from using EPSV (F)\n" @@ -461,6 +464,9 @@ struct Configurable { bool cookiesession; /* new session? */ bool encoding; /* Accept-Encoding please */ bool digest; /* Digest Authentication */ +#ifdef GSSAPI + bool negotiate; /* Negotiate Authentication */ +#endif bool use_resume; bool resume_from_current; bool disable_epsv; @@ -1053,6 +1059,9 @@ static ParameterError getparameter(char *flag, /* f or -long-flag */ {"5i", "limit-rate", TRUE}, {"5j", "compressed", FALSE}, /* might take an arg someday */ {"5k", "digest", FALSE}, +#ifdef GSSAPI + {"5l", "negotiate", FALSE}, +#endif {"0", "http1.0", FALSE}, {"1", "tlsv1", FALSE}, {"2", "sslv2", FALSE}, @@ -1281,6 +1290,12 @@ static ParameterError getparameter(char *flag, /* f or -long-flag */ config->digest ^= TRUE; break; +#ifdef GSSAPI + case 'l': /* --negotiate */ + config->negotiate ^= TRUE; + break; +#endif + default: /* the URL! */ { struct getout *url; @@ -2976,6 +2991,10 @@ operate(struct Configurable *config, int argc, char *argv[]) /* new in libcurl 7.10.6 */ curl_easy_setopt(curl, CURLOPT_HTTPDIGEST, config->digest); + +#ifdef GSSAPI + curl_easy_setopt(curl, CURLOPT_HTTPNEGOTIATE, config->negotiate); +#endif /* new in curl 7.9.7 */ if(config->trace_dump) { diff --git a/src/version.h b/src/version.h index 897334a59..be9b11869 100644 --- a/src/version.h +++ b/src/version.h @@ -1,3 +1,3 @@ #define CURL_NAME "curl" -#define CURL_VERSION "7.10.5" +#define CURL_VERSION "7.10.6-pre1" #define CURL_ID CURL_NAME " " CURL_VERSION " (" OS ") " -- cgit v1.2.3