s3-auth rename auth_ntlmssp_state -> auth_generic_state
[mat/samba.git] / source3 / include / ntlmssp_wrap.h
1 /*
2    NLTMSSP wrappers
3
4    Copyright (C) Andrew Tridgell      2001
5    Copyright (C) Andrew Bartlett 2001-2003
6
7    This program is free software; you can redistribute it and/or modify
8    it under the terms of the GNU General Public License as published by
9    the Free Software Foundation; either version 3 of the License, or
10    (at your option) any later version.
11
12    This program is distributed in the hope that it will be useful,
13    but WITHOUT ANY WARRANTY; without even the implied warranty of
14    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
15    GNU General Public License for more details.
16
17    You should have received a copy of the GNU General Public License
18    along with this program.  If not, see <http://www.gnu.org/licenses/>.
19 */
20
21 #ifndef _NTLMSSP_WRAP_
22 #define _NTLMSSP_WRAP_
23
24 struct gensec_security;
25
26 struct auth_generic_state {
27         /* used only by server implementation */
28         struct auth_context *auth_context;
29         
30         /* used only by the client implementation */
31         struct cli_credentials *credentials;
32
33         /* used by both */
34         struct gensec_security *gensec_security;
35 };
36
37 NTSTATUS auth_ntlmssp_set_username(struct auth_generic_state *ans,
38                                    const char *user);
39 NTSTATUS auth_ntlmssp_set_domain(struct auth_generic_state *ans,
40                                  const char *domain);
41 NTSTATUS auth_ntlmssp_set_password(struct auth_generic_state *ans,
42                                    const char *password);
43 NTSTATUS auth_ntlmssp_client_prepare(TALLOC_CTX *mem_ctx,
44                                      struct auth_generic_state **_ans);
45 NTSTATUS auth_ntlmssp_client_start(struct auth_generic_state *ans);
46
47 #endif /* _NTLMSSP_WRAP_ */