2011-06-10 15:07:16 +02:00
/*
Unix SMB / CIFS implementation .
NT Domain Authentication SMB / MSRPC client
Copyright ( C ) Andrew Tridgell 1992 - 2000
Copyright ( C ) Jeremy Allison 1998.
Largely re - written by Jeremy Allison ( C ) 2005.
Copyright ( C ) Guenther Deschner 2008.
This program is free software ; you can redistribute it and / or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation ; either version 3 of the License , or
( at your option ) any later version .
This program is distributed in the hope that it will be useful ,
but WITHOUT ANY WARRANTY ; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE . See the
GNU General Public License for more details .
You should have received a copy of the GNU General Public License
along with this program . If not , see < http : //www.gnu.org/licenses/>.
*/
# ifndef _RPC_CLIENT_CLI_NETLOGON_H_
# define _RPC_CLIENT_CLI_NETLOGON_H_
2013-08-07 11:27:25 +02:00
struct cli_state ;
struct messaging_context ;
2014-12-17 08:40:49 +00:00
struct cli_credentials ;
2013-08-07 11:27:25 +02:00
struct netlogon_creds_cli_context ;
2013-08-27 14:36:24 +02:00
struct dcerpc_binding_handle ;
2014-09-05 16:59:00 +12:00
# include "librpc/rpc/rpc_common.h"
2013-08-07 11:27:25 +02:00
2010-05-18 18:26:03 +02:00
/* The following definitions come from rpc_client/cli_netlogon.c */
2013-12-17 20:05:56 +01:00
NTSTATUS rpccli_pre_open_netlogon_creds ( void ) ;
2017-09-06 17:23:47 +02:00
NTSTATUS rpccli_create_netlogon_creds_ctx (
struct cli_credentials * creds ,
const char * server_computer ,
struct messaging_context * msg_ctx ,
TALLOC_CTX * mem_ctx ,
2017-09-05 16:17:58 +02:00
struct netlogon_creds_cli_context * * creds_ctx ) ;
2017-09-06 17:31:38 +02:00
NTSTATUS rpccli_setup_netlogon_creds (
struct cli_state * cli ,
enum dcerpc_transport_t transport ,
2024-09-27 09:38:19 +02:00
const char * remote_name ,
const struct sockaddr_storage * remote_sockaddr ,
2017-09-05 16:17:58 +02:00
struct netlogon_creds_cli_context * creds_ctx ,
2017-09-06 17:31:38 +02:00
bool force_reauth ,
struct cli_credentials * cli_creds ) ;
2017-09-18 13:26:03 -07:00
NTSTATUS rpccli_connect_netlogon (
struct cli_state * cli ,
enum dcerpc_transport_t transport ,
2024-09-20 10:03:11 +02:00
const char * remote_name ,
const struct sockaddr_storage * remote_sockaddr ,
2017-09-18 13:26:03 -07:00
struct netlogon_creds_cli_context * creds_ctx ,
bool force_reauth ,
struct cli_credentials * trust_creds ,
struct rpc_pipe_client * * _rpccli ) ;
2017-12-01 07:58:07 +01:00
NTSTATUS rpccli_netlogon_password_logon (
struct netlogon_creds_cli_context * creds ,
struct dcerpc_binding_handle * binding_handle ,
TALLOC_CTX * mem_ctx ,
uint32_t logon_parameters ,
const char * domain ,
const char * username ,
const char * password ,
const char * workstation ,
2019-02-01 13:49:49 +13:00
const uint64_t logon_id ,
2017-12-01 07:58:07 +01:00
enum netr_LogonInfoClass logon_type ,
uint8_t * authoritative ,
uint32_t * flags ,
2017-11-30 23:35:40 +01:00
uint16_t * _validation_level ,
union netr_Validation * * _validation ) ;
2017-12-01 07:58:07 +01:00
NTSTATUS rpccli_netlogon_network_logon (
2017-11-30 23:35:40 +01:00
struct netlogon_creds_cli_context * creds_ctx ,
2017-12-01 07:58:07 +01:00
struct dcerpc_binding_handle * binding_handle ,
TALLOC_CTX * mem_ctx ,
uint32_t logon_parameters ,
const char * username ,
const char * domain ,
const char * workstation ,
2019-02-01 13:49:49 +13:00
const uint64_t logon_id ,
2021-06-15 14:06:27 +02:00
DATA_BLOB chal ,
2017-12-01 07:58:07 +01:00
DATA_BLOB lm_response ,
DATA_BLOB nt_response ,
2018-01-15 12:00:19 +01:00
enum netr_LogonInfoClass logon_type ,
2017-12-01 07:58:07 +01:00
uint8_t * authoritative ,
uint32_t * flags ,
2017-11-30 23:35:40 +01:00
uint16_t * _validation_level ,
union netr_Validation * * _validation ) ;
2018-02-09 16:15:18 +01:00
NTSTATUS rpccli_netlogon_interactive_logon (
struct netlogon_creds_cli_context * creds_ctx ,
struct dcerpc_binding_handle * binding_handle ,
TALLOC_CTX * mem_ctx ,
uint32_t logon_parameters ,
const char * username ,
const char * domain ,
const char * workstation ,
2019-02-01 13:49:49 +13:00
const uint64_t logon_id ,
2018-02-09 16:15:18 +01:00
DATA_BLOB lm_hash ,
DATA_BLOB nt_hash ,
enum netr_LogonInfoClass logon_type ,
uint8_t * authoritative ,
uint32_t * flags ,
uint16_t * _validation_level ,
union netr_Validation * * _validation ) ;
2010-05-18 18:26:03 +02:00
2011-06-10 15:07:16 +02:00
# endif /* _RPC_CLIENT_CLI_NETLOGON_H_ */