1#ifndef __HTTP_NTLM_H
2#define __HTTP_NTLM_H
3/* Declarations for http_ntlm.c
4   Copyright (C) 1995, 1996, 1997, 2000, 2007, 2008, 2009, 2010, 2011
5   Free Software Foundation, Inc.
6   Contributed by Daniel Stenberg.
7
8This file is part of GNU Wget.
9
10GNU Wget is free software; you can redistribute it and/or modify
11it under the terms of the GNU General Public License as published by
12the Free Software Foundation; either version 3 of the License, or
13 (at your option) any later version.
14
15GNU Wget is distributed in the hope that it will be useful,
16but WITHOUT ANY WARRANTY; without even the implied warranty of
17MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
18GNU General Public License for more details.
19
20You should have received a copy of the GNU General Public License
21along with Wget.  If not, see <http://www.gnu.org/licenses/>.
22
23Additional permission under GNU GPL version 3 section 7
24
25If you modify this program, or any covered work, by linking or
26combining it with the OpenSSL project's OpenSSL library (or a
27modified version of that library), containing parts covered by the
28terms of the OpenSSL or SSLeay licenses, the Free Software Foundation
29grants you additional permission to convey the resulting work.
30Corresponding Source for a non-source form of such a combination
31shall include the source code for the parts of OpenSSL used as well
32as that of the covered work.  */
33
34typedef enum {
35  NTLMSTATE_NONE,
36  NTLMSTATE_TYPE1,
37  NTLMSTATE_TYPE2,
38  NTLMSTATE_TYPE3,
39  NTLMSTATE_LAST
40} wgetntlm;
41
42/* Struct used for NTLM challenge-response authentication */
43struct ntlmdata {
44  wgetntlm state;
45  unsigned char nonce[8];
46};
47
48/* this is for ntlm header input */
49bool ntlm_input (struct ntlmdata *, const char *);
50
51/* this is for creating ntlm header output */
52char *ntlm_output (struct ntlmdata *, const char *, const char *, bool *);
53#endif
54