summaryrefslogtreecommitdiff
path: root/source3/librpc/gen_ndr
diff options
context:
space:
mode:
authorJelmer Vernooij <jelmer@samba.org>2008-03-05 19:42:15 +0100
committerJelmer Vernooij <jelmer@samba.org>2008-03-05 19:42:15 +0100
commit63036a6f3380652c0cb54627bdeabcd212fa2f8c (patch)
tree90194f23cb1e6ca483e7773233c326a9b705f85f /source3/librpc/gen_ndr
parentd41d580c600e3228ff8fee5c16c47580f661a240 (diff)
parent932c287a406048759fa1ac4bf86e29d96991ded1 (diff)
downloadsamba-63036a6f3380652c0cb54627bdeabcd212fa2f8c.tar.gz
samba-63036a6f3380652c0cb54627bdeabcd212fa2f8c.tar.bz2
samba-63036a6f3380652c0cb54627bdeabcd212fa2f8c.zip
Merge branch 'v3-2-test' of ssh://git.samba.org/data/git/samba into v3-2-test
(This used to be commit 3482cd9b0e81bbc801f1cec33fca82fc45a3ddef)
Diffstat (limited to 'source3/librpc/gen_ndr')
-rw-r--r--source3/librpc/gen_ndr/cli_lsa.c56
-rw-r--r--source3/librpc/gen_ndr/cli_lsa.h22
-rw-r--r--source3/librpc/gen_ndr/cli_netlogon.c37
-rw-r--r--source3/librpc/gen_ndr/cli_netlogon.h31
-rw-r--r--source3/librpc/gen_ndr/cli_ntsvcs.c2783
-rw-r--r--source3/librpc/gen_ndr/cli_ntsvcs.h218
-rw-r--r--source3/librpc/gen_ndr/cli_srvsvc.c10
-rw-r--r--source3/librpc/gen_ndr/cli_srvsvc.h6
-rw-r--r--source3/librpc/gen_ndr/cli_svcctl.c18
-rw-r--r--source3/librpc/gen_ndr/cli_svcctl.h9
-rw-r--r--source3/librpc/gen_ndr/cli_unixinfo.c216
-rw-r--r--source3/librpc/gen_ndr/cli_unixinfo.h25
-rw-r--r--source3/librpc/gen_ndr/krb5pac.h137
-rw-r--r--source3/librpc/gen_ndr/libnet_join.h5
-rw-r--r--source3/librpc/gen_ndr/lsa.h46
-rw-r--r--source3/librpc/gen_ndr/ndr_dfs.c33
-rw-r--r--source3/librpc/gen_ndr/ndr_echo.c3
-rw-r--r--source3/librpc/gen_ndr/ndr_epmapper.c15
-rw-r--r--source3/librpc/gen_ndr/ndr_eventlog.c5
-rw-r--r--source3/librpc/gen_ndr/ndr_krb5pac.c949
-rw-r--r--source3/librpc/gen_ndr/ndr_krb5pac.h56
-rw-r--r--source3/librpc/gen_ndr/ndr_libnet_join.c3
-rw-r--r--source3/librpc/gen_ndr/ndr_libnet_join.h6
-rw-r--r--source3/librpc/gen_ndr/ndr_lsa.c558
-rw-r--r--source3/librpc/gen_ndr/ndr_lsa.h6
-rw-r--r--source3/librpc/gen_ndr/ndr_messaging.c3
-rw-r--r--source3/librpc/gen_ndr/ndr_netlogon.c353
-rw-r--r--source3/librpc/gen_ndr/ndr_notify.c6
-rw-r--r--source3/librpc/gen_ndr/ndr_ntsvcs.c3616
-rw-r--r--source3/librpc/gen_ndr/ndr_ntsvcs.h211
-rw-r--r--source3/librpc/gen_ndr/ndr_samr.c46
-rw-r--r--source3/librpc/gen_ndr/ndr_security.c6
-rw-r--r--source3/librpc/gen_ndr/ndr_srvsvc.c173
-rw-r--r--source3/librpc/gen_ndr/ndr_svcctl.c106
-rw-r--r--source3/librpc/gen_ndr/ndr_unixinfo.c538
-rw-r--r--source3/librpc/gen_ndr/ndr_unixinfo.h31
-rw-r--r--source3/librpc/gen_ndr/ndr_winreg.c8
-rw-r--r--source3/librpc/gen_ndr/ndr_wkssvc.c27
-rw-r--r--source3/librpc/gen_ndr/ndr_xattr.c3
-rw-r--r--source3/librpc/gen_ndr/netlogon.h26
-rw-r--r--source3/librpc/gen_ndr/ntsvcs.h568
-rw-r--r--source3/librpc/gen_ndr/samr.h6
-rw-r--r--source3/librpc/gen_ndr/srv_lsa.c16
-rw-r--r--source3/librpc/gen_ndr/srv_netlogon.c25
-rw-r--r--source3/librpc/gen_ndr/srv_ntsvcs.c4859
-rw-r--r--source3/librpc/gen_ndr/srv_ntsvcs.h71
-rw-r--r--source3/librpc/gen_ndr/srv_srvsvc.c2
-rw-r--r--source3/librpc/gen_ndr/srv_svcctl.c13
-rw-r--r--source3/librpc/gen_ndr/srv_unixinfo.c430
-rw-r--r--source3/librpc/gen_ndr/srv_unixinfo.h11
-rw-r--r--source3/librpc/gen_ndr/srvsvc.h6
-rw-r--r--source3/librpc/gen_ndr/svcctl.h15
-rw-r--r--source3/librpc/gen_ndr/unixinfo.h82
53 files changed, 14562 insertions, 1948 deletions
diff --git a/source3/librpc/gen_ndr/cli_lsa.c b/source3/librpc/gen_ndr/cli_lsa.c
index 27ed572a19..b1609ea97b 100644
--- a/source3/librpc/gen_ndr/cli_lsa.c
+++ b/source3/librpc/gen_ndr/cli_lsa.c
@@ -471,8 +471,8 @@ NTSTATUS rpccli_lsa_EnumAccounts(struct rpc_pipe_client *cli,
TALLOC_CTX *mem_ctx,
struct policy_handle *handle,
uint32_t *resume_handle,
- uint32_t num_entries,
- struct lsa_SidArray *sids)
+ struct lsa_SidArray *sids,
+ uint32_t num_entries)
{
struct lsa_EnumAccounts r;
NTSTATUS status;
@@ -609,7 +609,7 @@ NTSTATUS rpccli_lsa_LookupNames(struct rpc_pipe_client *cli,
struct policy_handle *handle,
uint32_t num_names,
struct lsa_String *names,
- struct lsa_RefDomainList *domains,
+ struct lsa_RefDomainList **domains,
struct lsa_TransSidArray *sids,
enum lsa_LookupNamesLevel level,
uint32_t *count)
@@ -649,9 +649,7 @@ NTSTATUS rpccli_lsa_LookupNames(struct rpc_pipe_client *cli,
}
/* Return variables */
- if (domains && r.out.domains) {
- *domains = *r.out.domains;
- }
+ *domains = *r.out.domains;
*sids = *r.out.sids;
*count = *r.out.count;
@@ -663,7 +661,7 @@ NTSTATUS rpccli_lsa_LookupSids(struct rpc_pipe_client *cli,
TALLOC_CTX *mem_ctx,
struct policy_handle *handle,
struct lsa_SidArray *sids,
- struct lsa_RefDomainList *domains,
+ struct lsa_RefDomainList **domains,
struct lsa_TransNameArray *names,
uint16_t level,
uint32_t *count)
@@ -702,9 +700,7 @@ NTSTATUS rpccli_lsa_LookupSids(struct rpc_pipe_client *cli,
}
/* Return variables */
- if (domains && r.out.domains) {
- *domains = *r.out.domains;
- }
+ *domains = *r.out.domains;
*names = *r.out.names;
*count = *r.out.count;
@@ -805,7 +801,7 @@ NTSTATUS rpccli_lsa_OpenAccount(struct rpc_pipe_client *cli,
NTSTATUS rpccli_lsa_EnumPrivsAccount(struct rpc_pipe_client *cli,
TALLOC_CTX *mem_ctx,
struct policy_handle *handle,
- struct lsa_PrivilegeSet *privs)
+ struct lsa_PrivilegeSet **privs)
{
struct lsa_EnumPrivsAccount r;
NTSTATUS status;
@@ -837,9 +833,7 @@ NTSTATUS rpccli_lsa_EnumPrivsAccount(struct rpc_pipe_client *cli,
}
/* Return variables */
- if (privs && r.out.privs) {
- *privs = *r.out.privs;
- }
+ *privs = *r.out.privs;
/* Return result */
return r.out.result;
@@ -1669,7 +1663,7 @@ NTSTATUS rpccli_lsa_RemoveAccountRights(struct rpc_pipe_client *cli,
TALLOC_CTX *mem_ctx,
struct policy_handle *handle,
struct dom_sid2 *sid,
- uint32_t unknown,
+ uint8_t remove_all,
struct lsa_RightSet *rights)
{
struct lsa_RemoveAccountRights r;
@@ -1678,7 +1672,7 @@ NTSTATUS rpccli_lsa_RemoveAccountRights(struct rpc_pipe_client *cli,
/* In parameters */
r.in.handle = handle;
r.in.sid = sid;
- r.in.unknown = unknown;
+ r.in.remove_all = remove_all;
r.in.rights = rights;
if (DEBUGLEVEL >= 10) {
@@ -2474,7 +2468,7 @@ NTSTATUS rpccli_lsa_LookupSids2(struct rpc_pipe_client *cli,
TALLOC_CTX *mem_ctx,
struct policy_handle *handle,
struct lsa_SidArray *sids,
- struct lsa_RefDomainList *domains,
+ struct lsa_RefDomainList **domains,
struct lsa_TransNameArray2 *names,
uint16_t level,
uint32_t *count,
@@ -2517,9 +2511,7 @@ NTSTATUS rpccli_lsa_LookupSids2(struct rpc_pipe_client *cli,
}
/* Return variables */
- if (domains && r.out.domains) {
- *domains = *r.out.domains;
- }
+ *domains = *r.out.domains;
*names = *r.out.names;
*count = *r.out.count;
@@ -2532,7 +2524,7 @@ NTSTATUS rpccli_lsa_LookupNames2(struct rpc_pipe_client *cli,
struct policy_handle *handle,
uint32_t num_names,
struct lsa_String *names,
- struct lsa_RefDomainList *domains,
+ struct lsa_RefDomainList **domains,
struct lsa_TransSidArray2 *sids,
enum lsa_LookupNamesLevel level,
uint32_t *count,
@@ -2576,9 +2568,7 @@ NTSTATUS rpccli_lsa_LookupNames2(struct rpc_pipe_client *cli,
}
/* Return variables */
- if (domains && r.out.domains) {
- *domains = *r.out.domains;
- }
+ *domains = *r.out.domains;
*sids = *r.out.sids;
*count = *r.out.count;
@@ -2924,7 +2914,7 @@ NTSTATUS rpccli_lsa_LookupNames3(struct rpc_pipe_client *cli,
struct policy_handle *handle,
uint32_t num_names,
struct lsa_String *names,
- struct lsa_RefDomainList *domains,
+ struct lsa_RefDomainList **domains,
struct lsa_TransSidArray3 *sids,
enum lsa_LookupNamesLevel level,
uint32_t *count,
@@ -2968,9 +2958,7 @@ NTSTATUS rpccli_lsa_LookupNames3(struct rpc_pipe_client *cli,
}
/* Return variables */
- if (domains && r.out.domains) {
- *domains = *r.out.domains;
- }
+ *domains = *r.out.domains;
*sids = *r.out.sids;
*count = *r.out.count;
@@ -3248,7 +3236,7 @@ NTSTATUS rpccli_lsa_CREDRRENAME(struct rpc_pipe_client *cli,
NTSTATUS rpccli_lsa_LookupSids3(struct rpc_pipe_client *cli,
TALLOC_CTX *mem_ctx,
struct lsa_SidArray *sids,
- struct lsa_RefDomainList *domains,
+ struct lsa_RefDomainList **domains,
struct lsa_TransNameArray2 *names,
uint16_t level,
uint32_t *count,
@@ -3290,9 +3278,7 @@ NTSTATUS rpccli_lsa_LookupSids3(struct rpc_pipe_client *cli,
}
/* Return variables */
- if (domains && r.out.domains) {
- *domains = *r.out.domains;
- }
+ *domains = *r.out.domains;
*names = *r.out.names;
*count = *r.out.count;
@@ -3304,7 +3290,7 @@ NTSTATUS rpccli_lsa_LookupNames4(struct rpc_pipe_client *cli,
TALLOC_CTX *mem_ctx,
uint32_t num_names,
struct lsa_String *names,
- struct lsa_RefDomainList *domains,
+ struct lsa_RefDomainList **domains,
struct lsa_TransSidArray3 *sids,
enum lsa_LookupNamesLevel level,
uint32_t *count,
@@ -3347,9 +3333,7 @@ NTSTATUS rpccli_lsa_LookupNames4(struct rpc_pipe_client *cli,
}
/* Return variables */
- if (domains && r.out.domains) {
- *domains = *r.out.domains;
- }
+ *domains = *r.out.domains;
*sids = *r.out.sids;
*count = *r.out.count;
diff --git a/source3/librpc/gen_ndr/cli_lsa.h b/source3/librpc/gen_ndr/cli_lsa.h
index ddcd161413..7d69926484 100644
--- a/source3/librpc/gen_ndr/cli_lsa.h
+++ b/source3/librpc/gen_ndr/cli_lsa.h
@@ -53,8 +53,8 @@ NTSTATUS rpccli_lsa_EnumAccounts(struct rpc_pipe_client *cli,
TALLOC_CTX *mem_ctx,
struct policy_handle *handle,
uint32_t *resume_handle,
- uint32_t num_entries,
- struct lsa_SidArray *sids);
+ struct lsa_SidArray *sids,
+ uint32_t num_entries);
NTSTATUS rpccli_lsa_CreateTrustedDomain(struct rpc_pipe_client *cli,
TALLOC_CTX *mem_ctx,
struct policy_handle *handle,
@@ -72,7 +72,7 @@ NTSTATUS rpccli_lsa_LookupNames(struct rpc_pipe_client *cli,
struct policy_handle *handle,
uint32_t num_names,
struct lsa_String *names,
- struct lsa_RefDomainList *domains,
+ struct lsa_RefDomainList **domains,
struct lsa_TransSidArray *sids,
enum lsa_LookupNamesLevel level,
uint32_t *count);
@@ -80,7 +80,7 @@ NTSTATUS rpccli_lsa_LookupSids(struct rpc_pipe_client *cli,
TALLOC_CTX *mem_ctx,
struct policy_handle *handle,
struct lsa_SidArray *sids,
- struct lsa_RefDomainList *domains,
+ struct lsa_RefDomainList **domains,
struct lsa_TransNameArray *names,
uint16_t level,
uint32_t *count);
@@ -99,7 +99,7 @@ NTSTATUS rpccli_lsa_OpenAccount(struct rpc_pipe_client *cli,
NTSTATUS rpccli_lsa_EnumPrivsAccount(struct rpc_pipe_client *cli,
TALLOC_CTX *mem_ctx,
struct policy_handle *handle,
- struct lsa_PrivilegeSet *privs);
+ struct lsa_PrivilegeSet **privs);
NTSTATUS rpccli_lsa_AddPrivilegesToAccount(struct rpc_pipe_client *cli,
TALLOC_CTX *mem_ctx,
struct policy_handle *handle,
@@ -192,7 +192,7 @@ NTSTATUS rpccli_lsa_RemoveAccountRights(struct rpc_pipe_client *cli,
TALLOC_CTX *mem_ctx,
struct policy_handle *handle,
struct dom_sid2 *sid,
- uint32_t unknown,
+ uint8_t remove_all,
struct lsa_RightSet *rights);
NTSTATUS rpccli_lsa_QueryTrustedDomainInfoBySid(struct rpc_pipe_client *cli,
TALLOC_CTX *mem_ctx,
@@ -276,7 +276,7 @@ NTSTATUS rpccli_lsa_LookupSids2(struct rpc_pipe_client *cli,
TALLOC_CTX *mem_ctx,
struct policy_handle *handle,
struct lsa_SidArray *sids,
- struct lsa_RefDomainList *domains,
+ struct lsa_RefDomainList **domains,
struct lsa_TransNameArray2 *names,
uint16_t level,
uint32_t *count,
@@ -287,7 +287,7 @@ NTSTATUS rpccli_lsa_LookupNames2(struct rpc_pipe_client *cli,
struct policy_handle *handle,
uint32_t num_names,
struct lsa_String *names,
- struct lsa_RefDomainList *domains,
+ struct lsa_RefDomainList **domains,
struct lsa_TransSidArray2 *sids,
enum lsa_LookupNamesLevel level,
uint32_t *count,
@@ -316,7 +316,7 @@ NTSTATUS rpccli_lsa_LookupNames3(struct rpc_pipe_client *cli,
struct policy_handle *handle,
uint32_t num_names,
struct lsa_String *names,
- struct lsa_RefDomainList *domains,
+ struct lsa_RefDomainList **domains,
struct lsa_TransSidArray3 *sids,
enum lsa_LookupNamesLevel level,
uint32_t *count,
@@ -343,7 +343,7 @@ NTSTATUS rpccli_lsa_CREDRRENAME(struct rpc_pipe_client *cli,
NTSTATUS rpccli_lsa_LookupSids3(struct rpc_pipe_client *cli,
TALLOC_CTX *mem_ctx,
struct lsa_SidArray *sids,
- struct lsa_RefDomainList *domains,
+ struct lsa_RefDomainList **domains,
struct lsa_TransNameArray2 *names,
uint16_t level,
uint32_t *count,
@@ -353,7 +353,7 @@ NTSTATUS rpccli_lsa_LookupNames4(struct rpc_pipe_client *cli,
TALLOC_CTX *mem_ctx,
uint32_t num_names,
struct lsa_String *names,
- struct lsa_RefDomainList *domains,
+ struct lsa_RefDomainList **domains,
struct lsa_TransSidArray3 *sids,
enum lsa_LookupNamesLevel level,
uint32_t *count,
diff --git a/source3/librpc/gen_ndr/cli_netlogon.c b/source3/librpc/gen_ndr/cli_netlogon.c
index de04c21dc5..2937cc09b9 100644
--- a/source3/librpc/gen_ndr/cli_netlogon.c
+++ b/source3/librpc/gen_ndr/cli_netlogon.c
@@ -113,7 +113,7 @@ NTSTATUS rpccli_netr_LogonSamLogon(struct rpc_pipe_client *cli,
struct netr_Authenticator *credential,
struct netr_Authenticator *return_authenticator,
uint16_t logon_level,
- union netr_LogonLevel logon,
+ union netr_LogonLevel *logon,
uint16_t validation_level,
union netr_Validation *validation,
uint8_t *authoritative)
@@ -220,7 +220,8 @@ NTSTATUS rpccli_netr_ServerReqChallenge(struct rpc_pipe_client *cli,
TALLOC_CTX *mem_ctx,
const char *server_name,
const char *computer_name,
- struct netr_Credential *credentials)
+ struct netr_Credential *credentials,
+ struct netr_Credential *return_credentials)
{
struct netr_ServerReqChallenge r;
NTSTATUS status;
@@ -254,7 +255,7 @@ NTSTATUS rpccli_netr_ServerReqChallenge(struct rpc_pipe_client *cli,
}
/* Return variables */
- *credentials = *r.out.credentials;
+ *return_credentials = *r.out.return_credentials;
/* Return result */
return r.out.result;
@@ -266,7 +267,8 @@ NTSTATUS rpccli_netr_ServerAuthenticate(struct rpc_pipe_client *cli,
const char *account_name,
enum netr_SchannelType secure_channel_type,
const char *computer_name,
- struct netr_Credential *credentials)
+ struct netr_Credential *credentials,
+ struct netr_Credential *return_credentials)
{
struct netr_ServerAuthenticate r;
NTSTATUS status;
@@ -302,7 +304,7 @@ NTSTATUS rpccli_netr_ServerAuthenticate(struct rpc_pipe_client *cli,
}
/* Return variables */
- *credentials = *r.out.credentials;
+ *return_credentials = *r.out.return_credentials;
/* Return result */
return r.out.result;
@@ -314,9 +316,9 @@ NTSTATUS rpccli_netr_ServerPasswordSet(struct rpc_pipe_client *cli,
const char *account_name,
enum netr_SchannelType secure_channel_type,
const char *computer_name,
- struct netr_Authenticator credential,
- struct samr_Password new_password,
- struct netr_Authenticator *return_authenticator)
+ struct netr_Authenticator *credential,
+ struct netr_Authenticator *return_authenticator,
+ struct samr_Password *new_password)
{
struct netr_ServerPasswordSet r;
NTSTATUS status;
@@ -363,12 +365,12 @@ NTSTATUS rpccli_netr_DatabaseDeltas(struct rpc_pipe_client *cli,
TALLOC_CTX *mem_ctx,
const char *logon_server,
const char *computername,
- struct netr_Authenticator credential,
+ struct netr_Authenticator *credential,
struct netr_Authenticator *return_authenticator,
enum netr_SamDatabaseID database_id,
uint64_t *sequence_num,
- uint32_t preferredmaximumlength,
- struct netr_DELTA_ENUM_ARRAY *delta_enum_array)
+ struct netr_DELTA_ENUM_ARRAY **delta_enum_array,
+ uint32_t preferredmaximumlength)
{
struct netr_DatabaseDeltas r;
NTSTATUS status;
@@ -745,7 +747,7 @@ NTSTATUS rpccli_netr_LogonControl2(struct rpc_pipe_client *cli,
const char *logon_server,
uint32_t function_code,
uint32_t level,
- union netr_CONTROL_DATA_INFORMATION data,
+ union netr_CONTROL_DATA_INFORMATION *data,
union netr_CONTROL_QUERY_INFORMATION *query,
WERROR *werror)
{
@@ -799,6 +801,7 @@ NTSTATUS rpccli_netr_ServerAuthenticate2(struct rpc_pipe_client *cli,
enum netr_SchannelType secure_channel_type,
const char *computer_name,
struct netr_Credential *credentials,
+ struct netr_Credential *return_credentials,
uint32_t *negotiate_flags)
{
struct netr_ServerAuthenticate2 r;
@@ -836,7 +839,7 @@ NTSTATUS rpccli_netr_ServerAuthenticate2(struct rpc_pipe_client *cli,
}
/* Return variables */
- *credentials = *r.out.credentials;
+ *return_credentials = *r.out.return_credentials;
*negotiate_flags = *r.out.negotiate_flags;
/* Return result */
@@ -847,13 +850,13 @@ NTSTATUS rpccli_netr_DatabaseSync2(struct rpc_pipe_client *cli,
TALLOC_CTX *mem_ctx,
const char *logon_server,
const char *computername,
- struct netr_Authenticator credential,
+ struct netr_Authenticator *credential,
struct netr_Authenticator *return_authenticator,
enum netr_SamDatabaseID database_id,
uint16_t restart_state,
uint32_t *sync_context,
- uint32_t preferredmaximumlength,
- struct netr_DELTA_ENUM_ARRAY *delta_enum_array)
+ struct netr_DELTA_ENUM_ARRAY **delta_enum_array,
+ uint32_t preferredmaximumlength)
{
struct netr_DatabaseSync2 r;
NTSTATUS status;
@@ -1971,7 +1974,7 @@ NTSTATUS rpccli_netr_LogonSamLogonEx(struct rpc_pipe_client *cli,
const char *server_name,
const char *computer_name,
uint16_t logon_level,
- union netr_LogonLevel logon,
+ union netr_LogonLevel *logon,
uint16_t validation_level,
union netr_Validation *validation,
uint8_t *authoritative,
diff --git a/source3/librpc/gen_ndr/cli_netlogon.h b/source3/librpc/gen_ndr/cli_netlogon.h
index 4aa0f9fa73..1fdc1f6c46 100644
--- a/source3/librpc/gen_ndr/cli_netlogon.h
+++ b/source3/librpc/gen_ndr/cli_netlogon.h
@@ -22,7 +22,7 @@ NTSTATUS rpccli_netr_LogonSamLogon(struct rpc_pipe_client *cli,
struct netr_Authenticator *credential,
struct netr_Authenticator *return_authenticator,
uint16_t logon_level,
- union netr_LogonLevel logon,
+ union netr_LogonLevel *logon,
uint16_t validation_level,
union netr_Validation *validation,
uint8_t *authoritative);
@@ -38,33 +38,35 @@ NTSTATUS rpccli_netr_ServerReqChallenge(struct rpc_pipe_client *cli,
TALLOC_CTX *mem_ctx,
const char *server_name,
const char *computer_name,
- struct netr_Credential *credentials);
+ struct netr_Credential *credentials,
+ struct netr_Credential *return_credentials);
NTSTATUS rpccli_netr_ServerAuthenticate(struct rpc_pipe_client *cli,
TALLOC_CTX *mem_ctx,
const char *server_name,
const char *account_name,
enum netr_SchannelType secure_channel_type,
const char *computer_name,
- struct netr_Credential *credentials);
+ struct netr_Credential *credentials,
+ struct netr_Credential *return_credentials);
NTSTATUS rpccli_netr_ServerPasswordSet(struct rpc_pipe_client *cli,
TALLOC_CTX *mem_ctx,
const char *server_name,
const char *account_name,
enum netr_SchannelType secure_channel_type,
const char *computer_name,
- struct netr_Authenticator credential,
- struct samr_Password new_password,
- struct netr_Authenticator *return_authenticator);
+ struct netr_Authenticator *credential,
+ struct netr_Authenticator *return_authenticator,
+ struct samr_Password *new_password);
NTSTATUS rpccli_netr_DatabaseDeltas(struct rpc_pipe_client *cli,
TALLOC_CTX *mem_ctx,
const char *logon_server,
const char *computername,
- struct netr_Authenticator credential,
+ struct netr_Authenticator *credential,
struct netr_Authenticator *return_authenticator,
enum netr_SamDatabaseID database_id,
uint64_t *sequence_num,
- uint32_t preferredmaximumlength,
- struct netr_DELTA_ENUM_ARRAY *delta_enum_array);
+ struct netr_DELTA_ENUM_ARRAY **delta_enum_array,
+ uint32_t preferredmaximumlength);
NTSTATUS rpccli_netr_DatabaseSync(struct rpc_pipe_client *cli,
TALLOC_CTX *mem_ctx,
const char *logon_server,
@@ -127,7 +129,7 @@ NTSTATUS rpccli_netr_LogonControl2(struct rpc_pipe_client *cli,
const char *logon_server,
uint32_t function_code,
uint32_t level,
- union netr_CONTROL_DATA_INFORMATION data,
+ union netr_CONTROL_DATA_INFORMATION *data,
union netr_CONTROL_QUERY_INFORMATION *query,
WERROR *werror);
NTSTATUS rpccli_netr_ServerAuthenticate2(struct rpc_pipe_client *cli,
@@ -137,18 +139,19 @@ NTSTATUS rpccli_netr_ServerAuthenticate2(struct rpc_pipe_client *cli,
enum netr_SchannelType secure_channel_type,
const char *computer_name,
struct netr_Credential *credentials,
+ struct netr_Credential *return_credentials,
uint32_t *negotiate_flags);
NTSTATUS rpccli_netr_DatabaseSync2(struct rpc_pipe_client *cli,
TALLOC_CTX *mem_ctx,
const char *logon_server,
const char *computername,
- struct netr_Authenticator credential,
+ struct netr_Authenticator *credential,
struct netr_Authenticator *return_authenticator,
enum netr_SamDatabaseID database_id,
uint16_t restart_state,
uint32_t *sync_context,
- uint32_t preferredmaximumlength,
- struct netr_DELTA_ENUM_ARRAY *delta_enum_array);
+ struct netr_DELTA_ENUM_ARRAY **delta_enum_array,
+ uint32_t preferredmaximumlength);
NTSTATUS rpccli_netr_DatabaseRedo(struct rpc_pipe_client *cli,
TALLOC_CTX *mem_ctx,
const char *logon_server,
@@ -295,7 +298,7 @@ NTSTATUS rpccli_netr_LogonSamLogonEx(struct rpc_pipe_client *cli,
const char *server_name,
const char *computer_name,
uint16_t logon_level,
- union netr_LogonLevel logon,
+ union netr_LogonLevel *logon,
uint16_t validation_level,
union netr_Validation *validation,
uint8_t *authoritative,
diff --git a/source3/librpc/gen_ndr/cli_ntsvcs.c b/source3/librpc/gen_ndr/cli_ntsvcs.c
new file mode 100644
index 0000000000..5597fccdb5
--- /dev/null
+++ b/source3/librpc/gen_ndr/cli_ntsvcs.c
@@ -0,0 +1,2783 @@
+/*
+ * Unix SMB/CIFS implementation.
+ * client auto-generated by pidl. DO NOT MODIFY!
+ */
+
+#include "includes.h"
+#include "librpc/gen_ndr/cli_ntsvcs.h"
+
+NTSTATUS rpccli_PNP_Disconnect(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_Disconnect r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_Disconnect, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_DISCONNECT,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_Disconnect, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_Connect(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_Connect r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_Connect, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_CONNECT,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_Connect, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_GetVersion(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ uint16_t *version,
+ WERROR *werror)
+{
+ struct PNP_GetVersion r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetVersion, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_GETVERSION,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetVersion, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+ *version = *r.out.version;
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_GetGlobalState(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_GetGlobalState r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetGlobalState, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_GETGLOBALSTATE,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetGlobalState, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_InitDetection(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_InitDetection r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_InitDetection, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_INITDETECTION,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_InitDetection, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_ReportLogOn(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_ReportLogOn r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_ReportLogOn, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_REPORTLOGON,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_ReportLogOn, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_ValidateDeviceInstance(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ const char *devicepath,
+ uint32_t flags,
+ WERROR *werror)
+{
+ struct PNP_ValidateDeviceInstance r;
+ NTSTATUS status;
+
+ /* In parameters */
+ r.in.devicepath = devicepath;
+ r.in.flags = flags;
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_ValidateDeviceInstance, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_VALIDATEDEVICEINSTANCE,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_ValidateDeviceInstance, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_GetRootDeviceInstance(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_GetRootDeviceInstance r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetRootDeviceInstance, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_GETROOTDEVICEINSTANCE,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetRootDeviceInstance, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_GetRelatedDeviceInstance(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_GetRelatedDeviceInstance r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetRelatedDeviceInstance, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_GETRELATEDDEVICEINSTANCE,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetRelatedDeviceInstance, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_EnumerateSubKeys(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_EnumerateSubKeys r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_EnumerateSubKeys, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_ENUMERATESUBKEYS,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_EnumerateSubKeys, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_GetDeviceList(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_GetDeviceList r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetDeviceList, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_GETDEVICELIST,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetDeviceList, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_GetDeviceListSize(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ const char *devicename,
+ uint32_t *size,
+ uint32_t flags,
+ WERROR *werror)
+{
+ struct PNP_GetDeviceListSize r;
+ NTSTATUS status;
+
+ /* In parameters */
+ r.in.devicename = devicename;
+ r.in.flags = flags;
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetDeviceListSize, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_GETDEVICELISTSIZE,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetDeviceListSize, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+ *size = *r.out.size;
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_GetDepth(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_GetDepth r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetDepth, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_GETDEPTH,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetDepth, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_GetDeviceRegProp(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_GetDeviceRegProp r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetDeviceRegProp, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_GETDEVICEREGPROP,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetDeviceRegProp, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_SetDeviceRegProp(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_SetDeviceRegProp r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_SetDeviceRegProp, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_SETDEVICEREGPROP,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_SetDeviceRegProp, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_GetClassInstance(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_GetClassInstance r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetClassInstance, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_GETCLASSINSTANCE,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetClassInstance, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_CreateKey(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_CreateKey r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_CreateKey, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_CREATEKEY,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_CreateKey, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_DeleteRegistryKey(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_DeleteRegistryKey r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_DeleteRegistryKey, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_DELETEREGISTRYKEY,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_DeleteRegistryKey, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_GetClassCount(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_GetClassCount r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetClassCount, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_GETCLASSCOUNT,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetClassCount, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_GetClassName(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_GetClassName r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetClassName, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_GETCLASSNAME,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetClassName, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_DeleteClassKey(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_DeleteClassKey r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_DeleteClassKey, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_DELETECLASSKEY,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_DeleteClassKey, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_GetInterfaceDeviceAlias(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_GetInterfaceDeviceAlias r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetInterfaceDeviceAlias, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_GETINTERFACEDEVICEALIAS,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetInterfaceDeviceAlias, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_GetInterfaceDeviceList(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_GetInterfaceDeviceList r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetInterfaceDeviceList, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_GETINTERFACEDEVICELIST,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetInterfaceDeviceList, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_GetInterfaceDeviceListSize(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_GetInterfaceDeviceListSize r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetInterfaceDeviceListSize, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_GETINTERFACEDEVICELISTSIZE,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetInterfaceDeviceListSize, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_RegisterDeviceClassAssociation(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_RegisterDeviceClassAssociation r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_RegisterDeviceClassAssociation, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_REGISTERDEVICECLASSASSOCIATION,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_RegisterDeviceClassAssociation, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_UnregisterDeviceClassAssociation(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_UnregisterDeviceClassAssociation r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_UnregisterDeviceClassAssociation, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_UNREGISTERDEVICECLASSASSOCIATION,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_UnregisterDeviceClassAssociation, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_GetClassRegProp(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_GetClassRegProp r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetClassRegProp, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_GETCLASSREGPROP,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetClassRegProp, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_SetClassRegProp(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_SetClassRegProp r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_SetClassRegProp, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_SETCLASSREGPROP,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_SetClassRegProp, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_CreateDevInst(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_CreateDevInst r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_CreateDevInst, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_CREATEDEVINST,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_CreateDevInst, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_DeviceInstanceAction(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_DeviceInstanceAction r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_DeviceInstanceAction, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_DEVICEINSTANCEACTION,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_DeviceInstanceAction, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_GetDeviceStatus(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_GetDeviceStatus r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetDeviceStatus, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_GETDEVICESTATUS,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetDeviceStatus, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_SetDeviceProblem(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_SetDeviceProblem r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_SetDeviceProblem, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_SETDEVICEPROBLEM,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_SetDeviceProblem, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_DisableDevInst(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_DisableDevInst r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_DisableDevInst, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_DISABLEDEVINST,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_DisableDevInst, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_UninstallDevInst(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_UninstallDevInst r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_UninstallDevInst, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_UNINSTALLDEVINST,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_UninstallDevInst, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_AddID(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_AddID r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_AddID, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_ADDID,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_AddID, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_RegisterDriver(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_RegisterDriver r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_RegisterDriver, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_REGISTERDRIVER,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_RegisterDriver, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_QueryRemove(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_QueryRemove r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_QueryRemove, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_QUERYREMOVE,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_QueryRemove, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_RequestDeviceEject(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_RequestDeviceEject r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_RequestDeviceEject, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_REQUESTDEVICEEJECT,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_RequestDeviceEject, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_IsDockStationPresent(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_IsDockStationPresent r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_IsDockStationPresent, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_ISDOCKSTATIONPRESENT,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_IsDockStationPresent, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_RequestEjectPC(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_RequestEjectPC r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_RequestEjectPC, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_REQUESTEJECTPC,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_RequestEjectPC, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_HwProfFlags(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ uint32_t unknown1,
+ const char *devicepath,
+ uint32_t unknown2,
+ uint32_t *unknown3,
+ uint16_t *unknown4,
+ const char *unknown5,
+ const char **unknown5a,
+ uint32_t unknown6,
+ uint32_t unknown7,
+ WERROR *werror)
+{
+ struct PNP_HwProfFlags r;
+ NTSTATUS status;
+
+ /* In parameters */
+ r.in.unknown1 = unknown1;
+ r.in.devicepath = devicepath;
+ r.in.unknown2 = unknown2;
+ r.in.unknown3 = unknown3;
+ r.in.unknown4 = unknown4;
+ r.in.unknown5 = unknown5;
+ r.in.unknown6 = unknown6;
+ r.in.unknown7 = unknown7;
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_HwProfFlags, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_HWPROFFLAGS,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_HwProfFlags, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+ *unknown3 = *r.out.unknown3;
+ if (unknown4 && r.out.unknown4) {
+ *unknown4 = *r.out.unknown4;
+ }
+ if (unknown5a && r.out.unknown5a) {
+ *unknown5a = *r.out.unknown5a;
+ }
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_GetHwProfInfo(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ uint32_t idx,
+ struct PNP_HwProfInfo *info,
+ uint32_t unknown1,
+ uint32_t unknown2,
+ WERROR *werror)
+{
+ struct PNP_GetHwProfInfo r;
+ NTSTATUS status;
+
+ /* In parameters */
+ r.in.idx = idx;
+ r.in.info = info;
+ r.in.unknown1 = unknown1;
+ r.in.unknown2 = unknown2;
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetHwProfInfo, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_GETHWPROFINFO,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetHwProfInfo, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+ *info = *r.out.info;
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_AddEmptyLogConf(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_AddEmptyLogConf r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_AddEmptyLogConf, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_ADDEMPTYLOGCONF,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_AddEmptyLogConf, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_FreeLogConf(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_FreeLogConf r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_FreeLogConf, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_FREELOGCONF,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_FreeLogConf, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_GetFirstLogConf(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_GetFirstLogConf r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetFirstLogConf, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_GETFIRSTLOGCONF,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetFirstLogConf, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_GetNextLogConf(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_GetNextLogConf r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetNextLogConf, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_GETNEXTLOGCONF,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetNextLogConf, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_GetLogConfPriority(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_GetLogConfPriority r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetLogConfPriority, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_GETLOGCONFPRIORITY,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetLogConfPriority, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_AddResDes(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_AddResDes r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_AddResDes, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_ADDRESDES,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_AddResDes, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_FreeResDes(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_FreeResDes r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_FreeResDes, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_FREERESDES,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_FreeResDes, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_GetNextResDes(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_GetNextResDes r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetNextResDes, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_GETNEXTRESDES,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetNextResDes, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_GetResDesData(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_GetResDesData r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetResDesData, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_GETRESDESDATA,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetResDesData, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_GetResDesDataSize(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_GetResDesDataSize r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetResDesDataSize, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_GETRESDESDATASIZE,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetResDesDataSize, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_ModifyResDes(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_ModifyResDes r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_ModifyResDes, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_MODIFYRESDES,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_ModifyResDes, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_DetectResourceLimit(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_DetectResourceLimit r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_DetectResourceLimit, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_DETECTRESOURCELIMIT,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_DetectResourceLimit, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_QueryResConfList(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_QueryResConfList r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_QueryResConfList, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_QUERYRESCONFLIST,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_QueryResConfList, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_SetHwProf(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_SetHwProf r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_SetHwProf, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_SETHWPROF,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_SetHwProf, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_QueryArbitratorFreeData(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_QueryArbitratorFreeData r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_QueryArbitratorFreeData, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_QUERYARBITRATORFREEDATA,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_QueryArbitratorFreeData, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_QueryArbitratorFreeSize(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_QueryArbitratorFreeSize r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_QueryArbitratorFreeSize, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_QUERYARBITRATORFREESIZE,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_QueryArbitratorFreeSize, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_RunDetection(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_RunDetection r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_RunDetection, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_RUNDETECTION,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_RunDetection, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_RegisterNotification(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_RegisterNotification r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_RegisterNotification, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_REGISTERNOTIFICATION,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_RegisterNotification, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_UnregisterNotification(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_UnregisterNotification r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_UnregisterNotification, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_UNREGISTERNOTIFICATION,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_UnregisterNotification, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_GetCustomDevProp(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_GetCustomDevProp r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetCustomDevProp, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_GETCUSTOMDEVPROP,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetCustomDevProp, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_GetVersionInternal(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_GetVersionInternal r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetVersionInternal, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_GETVERSIONINTERNAL,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetVersionInternal, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_GetBlockedDriverInfo(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_GetBlockedDriverInfo r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetBlockedDriverInfo, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_GETBLOCKEDDRIVERINFO,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetBlockedDriverInfo, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
+NTSTATUS rpccli_PNP_GetServerSideDeviceInstallFlags(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror)
+{
+ struct PNP_GetServerSideDeviceInstallFlags r;
+ NTSTATUS status;
+
+ /* In parameters */
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetServerSideDeviceInstallFlags, &r);
+ }
+
+ status = cli_do_rpc_ndr(cli,
+ mem_ctx,
+ PI_NTSVCS,
+ &ndr_table_ntsvcs,
+ NDR_PNP_GETSERVERSIDEDEVICEINSTALLFLAGS,
+ &r);
+
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetServerSideDeviceInstallFlags, &r);
+ }
+
+ if (NT_STATUS_IS_ERR(status)) {
+ return status;
+ }
+
+ /* Return variables */
+
+ /* Return result */
+ if (werror) {
+ *werror = r.out.result;
+ }
+
+ return werror_to_ntstatus(r.out.result);
+}
+
diff --git a/source3/librpc/gen_ndr/cli_ntsvcs.h b/source3/librpc/gen_ndr/cli_ntsvcs.h
new file mode 100644
index 0000000000..33df63ee5d
--- /dev/null
+++ b/source3/librpc/gen_ndr/cli_ntsvcs.h
@@ -0,0 +1,218 @@
+#include "librpc/gen_ndr/ndr_ntsvcs.h"
+#ifndef __CLI_NTSVCS__
+#define __CLI_NTSVCS__
+NTSTATUS rpccli_PNP_Disconnect(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_Connect(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_GetVersion(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ uint16_t *version,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_GetGlobalState(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_InitDetection(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_ReportLogOn(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_ValidateDeviceInstance(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ const char *devicepath,
+ uint32_t flags,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_GetRootDeviceInstance(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_GetRelatedDeviceInstance(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_EnumerateSubKeys(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_GetDeviceList(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_GetDeviceListSize(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ const char *devicename,
+ uint32_t *size,
+ uint32_t flags,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_GetDepth(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_GetDeviceRegProp(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_SetDeviceRegProp(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_GetClassInstance(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_CreateKey(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_DeleteRegistryKey(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_GetClassCount(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_GetClassName(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_DeleteClassKey(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_GetInterfaceDeviceAlias(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_GetInterfaceDeviceList(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_GetInterfaceDeviceListSize(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_RegisterDeviceClassAssociation(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_UnregisterDeviceClassAssociation(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_GetClassRegProp(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_SetClassRegProp(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_CreateDevInst(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_DeviceInstanceAction(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_GetDeviceStatus(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_SetDeviceProblem(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_DisableDevInst(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_UninstallDevInst(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_AddID(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_RegisterDriver(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_QueryRemove(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_RequestDeviceEject(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_IsDockStationPresent(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_RequestEjectPC(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_HwProfFlags(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ uint32_t unknown1,
+ const char *devicepath,
+ uint32_t unknown2,
+ uint32_t *unknown3,
+ uint16_t *unknown4,
+ const char *unknown5,
+ const char **unknown5a,
+ uint32_t unknown6,
+ uint32_t unknown7,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_GetHwProfInfo(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ uint32_t idx,
+ struct PNP_HwProfInfo *info,
+ uint32_t unknown1,
+ uint32_t unknown2,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_AddEmptyLogConf(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_FreeLogConf(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_GetFirstLogConf(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_GetNextLogConf(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_GetLogConfPriority(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_AddResDes(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_FreeResDes(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_GetNextResDes(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_GetResDesData(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_GetResDesDataSize(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_ModifyResDes(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_DetectResourceLimit(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_QueryResConfList(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_SetHwProf(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_QueryArbitratorFreeData(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_QueryArbitratorFreeSize(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_RunDetection(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_RegisterNotification(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_UnregisterNotification(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_GetCustomDevProp(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_GetVersionInternal(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_GetBlockedDriverInfo(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+NTSTATUS rpccli_PNP_GetServerSideDeviceInstallFlags(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ WERROR *werror);
+#endif /* __CLI_NTSVCS__ */
diff --git a/source3/librpc/gen_ndr/cli_srvsvc.c b/source3/librpc/gen_ndr/cli_srvsvc.c
index 2b1d050a14..3624fb0dd4 100644
--- a/source3/librpc/gen_ndr/cli_srvsvc.c
+++ b/source3/librpc/gen_ndr/cli_srvsvc.c
@@ -923,7 +923,7 @@ NTSTATUS rpccli_srvsvc_NetShareSetInfo(struct rpc_pipe_client *cli,
const char *server_unc,
const char *share_name,
uint32_t level,
- union srvsvc_NetShareInfo info,
+ union srvsvc_NetShareInfo *info,
uint32_t *parm_error,
WERROR *werror)
{
@@ -1169,7 +1169,7 @@ NTSTATUS rpccli_srvsvc_NetSrvSetInfo(struct rpc_pipe_client *cli,
TALLOC_CTX *mem_ctx,
const char *server_unc,
uint32_t level,
- union srvsvc_NetSrvInfo info,
+ union srvsvc_NetSrvInfo *info,
uint32_t *parm_error,
WERROR *werror)
{
@@ -1486,7 +1486,7 @@ NTSTATUS rpccli_srvsvc_NetTransportDel(struct rpc_pipe_client *cli,
NTSTATUS rpccli_srvsvc_NetRemoteTOD(struct rpc_pipe_client *cli,
TALLOC_CTX *mem_ctx,
const char *server_unc,
- struct srvsvc_NetRemoteTODInfo *info,
+ struct srvsvc_NetRemoteTODInfo **info,
WERROR *werror)
{
struct srvsvc_NetRemoteTOD r;
@@ -1519,9 +1519,7 @@ NTSTATUS rpccli_srvsvc_NetRemoteTOD(struct rpc_pipe_client *cli,
}
/* Return variables */
- if (info && r.out.info) {
- *info = *r.out.info;
- }
+ *info = *r.out.info;
/* Return result */
if (werror) {
diff --git a/source3/librpc/gen_ndr/cli_srvsvc.h b/source3/librpc/gen_ndr/cli_srvsvc.h
index eb19db37bd..4f52600a99 100644
--- a/source3/librpc/gen_ndr/cli_srvsvc.h
+++ b/source3/librpc/gen_ndr/cli_srvsvc.h
@@ -138,7 +138,7 @@ NTSTATUS rpccli_srvsvc_NetShareSetInfo(struct rpc_pipe_client *cli,
const char *server_unc,
const char *share_name,
uint32_t level,
- union srvsvc_NetShareInfo info,
+ union srvsvc_NetShareInfo *info,
uint32_t *parm_error,
WERROR *werror);
NTSTATUS rpccli_srvsvc_NetShareDel(struct rpc_pipe_client *cli,
@@ -169,7 +169,7 @@ NTSTATUS rpccli_srvsvc_NetSrvSetInfo(struct rpc_pipe_client *cli,
TALLOC_CTX *mem_ctx,
const char *server_unc,
uint32_t level,
- union srvsvc_NetSrvInfo info,
+ union srvsvc_NetSrvInfo *info,
uint32_t *parm_error,
WERROR *werror);
NTSTATUS rpccli_srvsvc_NetDiskEnum(struct rpc_pipe_client *cli,
@@ -213,7 +213,7 @@ NTSTATUS rpccli_srvsvc_NetTransportDel(struct rpc_pipe_client *cli,
NTSTATUS rpccli_srvsvc_NetRemoteTOD(struct rpc_pipe_client *cli,
TALLOC_CTX *mem_ctx,
const char *server_unc,
- struct srvsvc_NetRemoteTODInfo *info,
+ struct srvsvc_NetRemoteTODInfo **info,
WERROR *werror);
NTSTATUS rpccli_srvsvc_NetSetServiceBits(struct rpc_pipe_client *cli,
TALLOC_CTX *mem_ctx,
diff --git a/source3/librpc/gen_ndr/cli_svcctl.c b/source3/librpc/gen_ndr/cli_svcctl.c
index 2a5d6badc6..b8f18afe1c 100644
--- a/source3/librpc/gen_ndr/cli_svcctl.c
+++ b/source3/librpc/gen_ndr/cli_svcctl.c
@@ -191,12 +191,20 @@ NTSTATUS rpccli_svcctl_LockServiceDatabase(struct rpc_pipe_client *cli,
NTSTATUS rpccli_svcctl_QueryServiceObjectSecurity(struct rpc_pipe_client *cli,
TALLOC_CTX *mem_ctx,
+ struct policy_handle *handle,
+ uint32_t security_flags,
+ uint8_t *buffer,
+ uint32_t buffer_size,
+ uint32_t *needed,
WERROR *werror)
{
struct svcctl_QueryServiceObjectSecurity r;
NTSTATUS status;
/* In parameters */
+ r.in.handle = handle;
+ r.in.security_flags = security_flags;
+ r.in.buffer_size = buffer_size;
if (DEBUGLEVEL >= 10) {
NDR_PRINT_IN_DEBUG(svcctl_QueryServiceObjectSecurity, &r);
@@ -222,6 +230,8 @@ NTSTATUS rpccli_svcctl_QueryServiceObjectSecurity(struct rpc_pipe_client *cli,
}
/* Return variables */
+ memcpy(buffer, r.out.buffer, r.in.buffer_size);
+ *needed = *r.out.needed;
/* Return result */
if (werror) {
@@ -233,12 +243,20 @@ NTSTATUS rpccli_svcctl_QueryServiceObjectSecurity(struct rpc_pipe_client *cli,
NTSTATUS rpccli_svcctl_SetServiceObjectSecurity(struct rpc_pipe_client *cli,
TALLOC_CTX *mem_ctx,
+ struct policy_handle *handle,
+ uint32_t security_flags,
+ uint8_t *buffer,
+ uint32_t buffer_size,
WERROR *werror)
{
struct svcctl_SetServiceObjectSecurity r;
NTSTATUS status;
/* In parameters */
+ r.in.handle = handle;
+ r.in.security_flags = security_flags;
+ r.in.buffer = buffer;
+ r.in.buffer_size = buffer_size;
if (DEBUGLEVEL >= 10) {
NDR_PRINT_IN_DEBUG(svcctl_SetServiceObjectSecurity, &r);
diff --git a/source3/librpc/gen_ndr/cli_svcctl.h b/source3/librpc/gen_ndr/cli_svcctl.h
index e9eeb2d9e2..7c62519187 100644
--- a/source3/librpc/gen_ndr/cli_svcctl.h
+++ b/source3/librpc/gen_ndr/cli_svcctl.h
@@ -22,9 +22,18 @@ NTSTATUS rpccli_svcctl_LockServiceDatabase(struct rpc_pipe_client *cli,
WERROR *werror);
NTSTATUS rpccli_svcctl_QueryServiceObjectSecurity(struct rpc_pipe_client *cli,
TALLOC_CTX *mem_ctx,
+ struct policy_handle *handle,
+ uint32_t security_flags,
+ uint8_t *buffer,
+ uint32_t buffer_size,
+ uint32_t *needed,
WERROR *werror);
NTSTATUS rpccli_svcctl_SetServiceObjectSecurity(struct rpc_pipe_client *cli,
TALLOC_CTX *mem_ctx,
+ struct policy_handle *handle,
+ uint32_t security_flags,
+ uint8_t *buffer,
+ uint32_t buffer_size,
WERROR *werror);
NTSTATUS rpccli_svcctl_QueryServiceStatus(struct rpc_pipe_client *cli,
TALLOC_CTX *mem_ctx,
diff --git a/source3/librpc/gen_ndr/cli_unixinfo.c b/source3/librpc/gen_ndr/cli_unixinfo.c
deleted file mode 100644
index c8a6c926ef..0000000000
--- a/source3/librpc/gen_ndr/cli_unixinfo.c
+++ /dev/null
@@ -1,216 +0,0 @@
-/*
- * Unix SMB/CIFS implementation.
- * client auto-generated by pidl. DO NOT MODIFY!
- */
-
-#include "includes.h"
-#include "librpc/gen_ndr/cli_unixinfo.h"
-
-NTSTATUS rpccli_unixinfo_SidToUid(struct rpc_pipe_client *cli,
- TALLOC_CTX *mem_ctx,
- struct dom_sid sid,
- uint64_t *uid)
-{
- struct unixinfo_SidToUid r;
- NTSTATUS status;
-
- /* In parameters */
- r.in.sid = sid;
-
- if (DEBUGLEVEL >= 10) {
- NDR_PRINT_IN_DEBUG(unixinfo_SidToUid, &r);
- }
-
- status = cli_do_rpc_ndr(cli,
- mem_ctx,
- PI_UNIXINFO,
- &ndr_table_unixinfo,
- NDR_UNIXINFO_SIDTOUID,
- &r);
-
- if (!NT_STATUS_IS_OK(status)) {
- return status;
- }
-
- if (DEBUGLEVEL >= 10) {
- NDR_PRINT_OUT_DEBUG(unixinfo_SidToUid, &r);
- }
-
- if (NT_STATUS_IS_ERR(status)) {
- return status;
- }
-
- /* Return variables */
- *uid = *r.out.uid;
-
- /* Return result */
- return r.out.result;
-}
-
-NTSTATUS rpccli_unixinfo_UidToSid(struct rpc_pipe_client *cli,
- TALLOC_CTX *mem_ctx,
- uint64_t uid,
- struct dom_sid *sid)
-{
- struct unixinfo_UidToSid r;
- NTSTATUS status;
-
- /* In parameters */
- r.in.uid = uid;
-
- if (DEBUGLEVEL >= 10) {
- NDR_PRINT_IN_DEBUG(unixinfo_UidToSid, &r);
- }
-
- status = cli_do_rpc_ndr(cli,
- mem_ctx,
- PI_UNIXINFO,
- &ndr_table_unixinfo,
- NDR_UNIXINFO_UIDTOSID,
- &r);
-
- if (!NT_STATUS_IS_OK(status)) {
- return status;
- }
-
- if (DEBUGLEVEL >= 10) {
- NDR_PRINT_OUT_DEBUG(unixinfo_UidToSid, &r);
- }
-
- if (NT_STATUS_IS_ERR(status)) {
- return status;
- }
-
- /* Return variables */
- *sid = *r.out.sid;
-
- /* Return result */
- return r.out.result;
-}
-
-NTSTATUS rpccli_unixinfo_SidToGid(struct rpc_pipe_client *cli,
- TALLOC_CTX *mem_ctx,
- struct dom_sid sid,
- uint64_t *gid)
-{
- struct unixinfo_SidToGid r;
- NTSTATUS status;
-
- /* In parameters */
- r.in.sid = sid;
-
- if (DEBUGLEVEL >= 10) {
- NDR_PRINT_IN_DEBUG(unixinfo_SidToGid, &r);
- }
-
- status = cli_do_rpc_ndr(cli,
- mem_ctx,
- PI_UNIXINFO,
- &ndr_table_unixinfo,
- NDR_UNIXINFO_SIDTOGID,
- &r);
-
- if (!NT_STATUS_IS_OK(status)) {
- return status;
- }
-
- if (DEBUGLEVEL >= 10) {
- NDR_PRINT_OUT_DEBUG(unixinfo_SidToGid, &r);
- }
-
- if (NT_STATUS_IS_ERR(status)) {
- return status;
- }
-
- /* Return variables */
- *gid = *r.out.gid;
-
- /* Return result */
- return r.out.result;
-}
-
-NTSTATUS rpccli_unixinfo_GidToSid(struct rpc_pipe_client *cli,
- TALLOC_CTX *mem_ctx,
- uint64_t gid,
- struct dom_sid *sid)
-{
- struct unixinfo_GidToSid r;
- NTSTATUS status;
-
- /* In parameters */
- r.in.gid = gid;
-
- if (DEBUGLEVEL >= 10) {
- NDR_PRINT_IN_DEBUG(unixinfo_GidToSid, &r);
- }
-
- status = cli_do_rpc_ndr(cli,
- mem_ctx,
- PI_UNIXINFO,
- &ndr_table_unixinfo,
- NDR_UNIXINFO_GIDTOSID,
- &r);
-
- if (!NT_STATUS_IS_OK(status)) {
- return status;
- }
-
- if (DEBUGLEVEL >= 10) {
- NDR_PRINT_OUT_DEBUG(unixinfo_GidToSid, &r);
- }
-
- if (NT_STATUS_IS_ERR(status)) {
- return status;
- }
-
- /* Return variables */
- *sid = *r.out.sid;
-
- /* Return result */
- return r.out.result;
-}
-
-NTSTATUS rpccli_unixinfo_GetPWUid(struct rpc_pipe_client *cli,
- TALLOC_CTX *mem_ctx,
- uint32_t *count,
- uint64_t *uids,
- struct unixinfo_GetPWUidInfo *infos)
-{
- struct unixinfo_GetPWUid r;
- NTSTATUS status;
-
- /* In parameters */
- r.in.count = count;
- r.in.uids = uids;
-
- if (DEBUGLEVEL >= 10) {
- NDR_PRINT_IN_DEBUG(unixinfo_GetPWUid, &r);
- }
-
- status = cli_do_rpc_ndr(cli,
- mem_ctx,
- PI_UNIXINFO,
- &ndr_table_unixinfo,
- NDR_UNIXINFO_GETPWUID,
- &r);
-
- if (!NT_STATUS_IS_OK(status)) {
- return status;
- }
-
- if (DEBUGLEVEL >= 10) {
- NDR_PRINT_OUT_DEBUG(unixinfo_GetPWUid, &r);
- }
-
- if (NT_STATUS_IS_ERR(status)) {
- return status;
- }
-
- /* Return variables */
- *count = *r.out.count;
- memcpy(infos, r.out.infos, *r.in.count);
-
- /* Return result */
- return r.out.result;
-}
-
diff --git a/source3/librpc/gen_ndr/cli_unixinfo.h b/source3/librpc/gen_ndr/cli_unixinfo.h
deleted file mode 100644
index fa084cc75d..0000000000
--- a/source3/librpc/gen_ndr/cli_unixinfo.h
+++ /dev/null
@@ -1,25 +0,0 @@
-#include "librpc/gen_ndr/ndr_unixinfo.h"
-#ifndef __CLI_UNIXINFO__
-#define __CLI_UNIXINFO__
-NTSTATUS rpccli_unixinfo_SidToUid(struct rpc_pipe_client *cli,
- TALLOC_CTX *mem_ctx,
- struct dom_sid sid,
- uint64_t *uid);
-NTSTATUS rpccli_unixinfo_UidToSid(struct rpc_pipe_client *cli,
- TALLOC_CTX *mem_ctx,
- uint64_t uid,
- struct dom_sid *sid);
-NTSTATUS rpccli_unixinfo_SidToGid(struct rpc_pipe_client *cli,
- TALLOC_CTX *mem_ctx,
- struct dom_sid sid,
- uint64_t *gid);
-NTSTATUS rpccli_unixinfo_GidToSid(struct rpc_pipe_client *cli,
- TALLOC_CTX *mem_ctx,
- uint64_t gid,
- struct dom_sid *sid);
-NTSTATUS rpccli_unixinfo_GetPWUid(struct rpc_pipe_client *cli,
- TALLOC_CTX *mem_ctx,
- uint32_t *count,
- uint64_t *uids,
- struct unixinfo_GetPWUidInfo *infos);
-#endif /* __CLI_UNIXINFO__ */
diff --git a/source3/librpc/gen_ndr/krb5pac.h b/source3/librpc/gen_ndr/krb5pac.h
new file mode 100644
index 0000000000..8a148253ae
--- /dev/null
+++ b/source3/librpc/gen_ndr/krb5pac.h
@@ -0,0 +1,137 @@
+/* header auto-generated by pidl */
+
+#include <stdint.h>
+
+#include "librpc/gen_ndr/security.h"
+#include "librpc/gen_ndr/netlogon.h"
+#include "librpc/gen_ndr/samr.h"
+#ifndef _HEADER_krb5pac
+#define _HEADER_krb5pac
+
+struct PAC_LOGON_NAME {
+ NTTIME logon_time;
+ uint16_t size;/* [value(2*strlen_m(account_name))] */
+ const char *account_name;/* [charset(UTF16)] */
+};
+
+struct PAC_SIGNATURE_DATA {
+ uint32_t type;
+ DATA_BLOB signature;/* [flag(LIBNDR_FLAG_REMAINING)] */
+}/* [public,flag(LIBNDR_PRINT_ARRAY_HEX)] */;
+
+struct PAC_LOGON_INFO {
+ struct netr_SamInfo3 info3;
+ struct dom_sid2 *res_group_dom_sid;/* [unique] */
+ struct samr_RidWithAttributeArray res_groups;
+}/* [gensize] */;
+
+struct PAC_UNKNOWN_12 {
+ uint16_t upn_size;/* [value(2*strlen_m(upn_name))] */
+ uint16_t unknown1;
+ uint16_t domain_size;/* [value(2*strlen_m(domain_name))] */
+ uint16_t unknown2;
+ uint16_t unknown3;
+ uint16_t unknown4;
+ uint32_t unknown5;
+ const char *upn_name;/* [charset(UTF16)] */
+ const char *domain_name;/* [charset(UTF16)] */
+ uint32_t unknown6;
+};
+
+struct PAC_LOGON_INFO_CTR {
+ uint32_t unknown1;/* [value(0x00081001)] */
+ uint32_t unknown2;/* [value(0xCCCCCCCC)] */
+ uint32_t _ndr_size;/* [value(NDR_ROUND(ndr_size_PAC_LOGON_INFO(info,ndr->flags)+4,8))] */
+ uint32_t unknown3;/* [value(0x00000000)] */
+ struct PAC_LOGON_INFO *info;/* [unique] */
+}/* [public] */;
+
+enum PAC_TYPE
+#ifndef USE_UINT_ENUMS
+ {
+ PAC_TYPE_LOGON_INFO=1,
+ PAC_TYPE_SRV_CHECKSUM=6,
+ PAC_TYPE_KDC_CHECKSUM=7,
+ PAC_TYPE_LOGON_NAME=10,
+ PAC_TYPE_CONSTRAINED_DELEGATION=11,
+ PAC_TYPE_UNKNOWN_12=12
+}
+#else
+ { __donnot_use_enum_PAC_TYPE=0x7FFFFFFF}
+#define PAC_TYPE_LOGON_INFO ( 1 )
+#define PAC_TYPE_SRV_CHECKSUM ( 6 )
+#define PAC_TYPE_KDC_CHECKSUM ( 7 )
+#define PAC_TYPE_LOGON_NAME ( 10 )
+#define PAC_TYPE_CONSTRAINED_DELEGATION ( 11 )
+#define PAC_TYPE_UNKNOWN_12 ( 12 )
+#endif
+;
+
+union PAC_INFO {
+ struct PAC_LOGON_INFO_CTR logon_info;/* [case(PAC_TYPE_LOGON_INFO)] */
+ struct PAC_SIGNATURE_DATA srv_cksum;/* [case(PAC_TYPE_SRV_CHECKSUM)] */
+ struct PAC_SIGNATURE_DATA kdc_cksum;/* [case(PAC_TYPE_KDC_CHECKSUM)] */
+ struct PAC_LOGON_NAME logon_name;/* [case(PAC_TYPE_LOGON_NAME)] */
+ struct PAC_UNKNOWN_12 unknown;/* [case(PAC_TYPE_UNKNOWN_12)] */
+}/* [gensize,nodiscriminant,public] */;
+
+struct PAC_BUFFER {
+ enum PAC_TYPE type;
+ uint32_t _ndr_size;/* [value(_ndr_size_PAC_INFO(info,type,0))] */
+ union PAC_INFO *info;/* [relative,subcontext_size(_subcontext_size_PAC_INFO(r,ndr->flags)),subcontext(0),switch_is(type),flag(LIBNDR_FLAG_ALIGN8)] */
+ uint32_t _pad;/* [value(0)] */
+}/* [noprint,nopull,public,nopush] */;
+
+struct PAC_DATA {
+ uint32_t num_buffers;
+ uint32_t version;
+ struct PAC_BUFFER *buffers;
+}/* [public] */;
+
+struct DATA_BLOB_REM {
+ DATA_BLOB remaining;/* [flag(LIBNDR_FLAG_REMAINING)] */
+};
+
+struct PAC_BUFFER_RAW {
+ enum PAC_TYPE type;
+ uint32_t ndr_size;
+ struct DATA_BLOB_REM *info;/* [relative,subcontext_size(NDR_ROUND(ndr_size,8)),subcontext(0),flag(LIBNDR_FLAG_ALIGN8)] */
+ uint32_t _pad;/* [value(0)] */
+}/* [public] */;
+
+struct PAC_DATA_RAW {
+ uint32_t num_buffers;
+ uint32_t version;
+ struct PAC_BUFFER_RAW *buffers;
+}/* [public] */;
+
+struct netsamlogoncache_entry {
+ time_t timestamp;
+ struct netr_SamInfo3 info3;
+}/* [public] */;
+
+
+struct decode_pac {
+ struct {
+ struct PAC_DATA pac;
+ } in;
+
+};
+
+
+struct decode_pac_raw {
+ struct {
+ struct PAC_DATA_RAW pac;
+ } in;
+
+};
+
+
+struct decode_login_info {
+ struct {
+ struct PAC_LOGON_INFO logon_info;
+ } in;
+
+};
+
+#endif /* _HEADER_krb5pac */
diff --git a/source3/librpc/gen_ndr/libnet_join.h b/source3/librpc/gen_ndr/libnet_join.h
index 40759cb489..0415f030b4 100644
--- a/source3/librpc/gen_ndr/libnet_join.h
+++ b/source3/librpc/gen_ndr/libnet_join.h
@@ -7,7 +7,7 @@
#ifndef _HEADER_libnetjoin
#define _HEADER_libnetjoin
-;
+enum netr_SchannelType;
struct libnet_JoinCtx {
@@ -27,6 +27,7 @@ struct libnet_JoinCtx {
uint8_t modify_config;
struct ads_struct *ads;/* [ref] */
uint8_t debug;
+ enum netr_SchannelType secure_channel_type;
} in;
struct {
@@ -65,6 +66,8 @@ struct libnet_UnjoinCtx {
const char * dns_domain_name;
uint8_t modified_config;
const char * error_string;
+ uint8_t disabled_machine_account;
+ uint8_t deleted_machine_account;
WERROR result;
} out;
diff --git a/source3/librpc/gen_ndr/lsa.h b/source3/librpc/gen_ndr/lsa.h
index 14d46a6542..4fea08e99d 100644
--- a/source3/librpc/gen_ndr/lsa.h
+++ b/source3/librpc/gen_ndr/lsa.h
@@ -8,6 +8,8 @@
#define LSA_ENUM_TRUST_DOMAIN_MULTIPLIER ( 60 )
#define LSA_REF_DOMAIN_LIST_MULTIPLIER ( 32 )
+#define MAX_REF_DOMAINS ( LSA_REF_DOMAIN_LIST_MULTIPLIER )
+#define MAX_LOOKUP_SIDS ( 0x5000 )
#define LSA_ENUM_TRUST_DOMAIN_EX_MULTIPLIER ( 82 )
struct lsa_String {
uint16_t length;/* [value(2*strlen_m(string))] */
@@ -17,7 +19,7 @@ struct lsa_String {
struct lsa_StringLarge {
uint16_t length;/* [value(2*strlen_m(string))] */
- uint16_t size;/* [value(2*(strlen_m(string)+1))] */
+ uint16_t size;/* [value(2*strlen_m_term(string))] */
const char *string;/* [unique,charset(UTF16),length_is(length/2),size_is(size/2)] */
}/* [public] */;
@@ -29,7 +31,13 @@ struct lsa_Strings {
struct lsa_AsciiString {
uint16_t length;/* [value(strlen_m(string))] */
uint16_t size;/* [value(strlen_m(string))] */
- const char * string;/* [unique,flag(LIBNDR_FLAG_STR_NOTERM|LIBNDR_FLAG_STR_ASCII|LIBNDR_FLAG_STR_SIZE4|LIBNDR_FLAG_STR_LEN4)] */
+ const char *string;/* [unique,charset(DOS),length_is(length),size_is(size)] */
+}/* [public] */;
+
+struct lsa_AsciiStringLarge {
+ uint16_t length;/* [value(strlen_m(string))] */
+ uint16_t size;/* [value(strlen_m_term(string))] */
+ const char *string;/* [unique,charset(DOS),length_is(length),size_is(size)] */
}/* [public] */;
struct lsa_LUID {
@@ -63,6 +71,20 @@ struct lsa_ObjectAttribute {
struct lsa_QosInfo *sec_qos;/* [unique] */
};
+/* bitmap lsa_PolicyAccessMask */
+#define LSA_POLICY_VIEW_LOCAL_INFORMATION ( 0x00000001 )
+#define LSA_POLICY_VIEW_AUDIT_INFORMATION ( 0x00000002 )
+#define LSA_POLICY_GET_PRIVATE_INFORMATION ( 0x00000004 )
+#define LSA_POLICY_TRUST_ADMIN ( 0x00000008 )
+#define LSA_POLICY_CREATE_ACCOUNT ( 0x00000010 )
+#define LSA_POLICY_CREATE_SECRET ( 0x00000020 )
+#define LSA_POLICY_CREATE_PRIVILEGE ( 0x00000040 )
+#define LSA_POLICY_SET_DEFAULT_QUOTA_LIMITS ( 0x00000080 )
+#define LSA_POLICY_SET_AUDIT_REQUIREMENTS ( 0x00000100 )
+#define LSA_POLICY_AUDIT_LOG_ADMIN ( 0x00000200 )
+#define LSA_POLICY_SERVER_ADMIN ( 0x00000400 )
+#define LSA_POLICY_LOOKUP_NAMES ( 0x00000800 )
+
struct lsa_AuditLogInfo {
uint32_t percent_full;
uint32_t log_size;
@@ -448,7 +470,7 @@ struct lsa_RightAttribute {
};
struct lsa_RightSet {
- uint32_t count;
+ uint32_t count;/* [range(0,256)] */
struct lsa_StringLarge *names;/* [unique,size_is(count)] */
};
@@ -774,7 +796,7 @@ struct lsa_LookupNames {
} in;
struct {
- struct lsa_RefDomainList *domains;/* [unique] */
+ struct lsa_RefDomainList **domains;/* [ref] */
struct lsa_TransSidArray *sids;/* [ref] */
uint32_t *count;/* [ref] */
NTSTATUS result;
@@ -793,7 +815,7 @@ struct lsa_LookupSids {
} in;
struct {
- struct lsa_RefDomainList *domains;/* [unique] */
+ struct lsa_RefDomainList **domains;/* [ref] */
struct lsa_TransNameArray *names;/* [ref] */
uint32_t *count;/* [ref] */
NTSTATUS result;
@@ -838,7 +860,7 @@ struct lsa_EnumPrivsAccount {
} in;
struct {
- struct lsa_PrivilegeSet *privs;/* [unique] */
+ struct lsa_PrivilegeSet **privs;/* [ref] */
NTSTATUS result;
} out;
@@ -1104,7 +1126,7 @@ struct lsa_RemoveAccountRights {
struct {
struct policy_handle *handle;/* [ref] */
struct dom_sid2 *sid;/* [ref] */
- uint32_t unknown;
+ uint8_t remove_all;
struct lsa_RightSet *rights;/* [ref] */
} in;
@@ -1356,7 +1378,7 @@ struct lsa_LookupSids2 {
} in;
struct {
- struct lsa_RefDomainList *domains;/* [unique] */
+ struct lsa_RefDomainList **domains;/* [ref] */
struct lsa_TransNameArray2 *names;/* [ref] */
uint32_t *count;/* [ref] */
NTSTATUS result;
@@ -1378,7 +1400,7 @@ struct lsa_LookupNames2 {
} in;
struct {
- struct lsa_RefDomainList *domains;/* [unique] */
+ struct lsa_RefDomainList **domains;/* [ref] */
struct lsa_TransSidArray2 *sids;/* [ref] */
uint32_t *count;/* [ref] */
NTSTATUS result;
@@ -1472,7 +1494,7 @@ struct lsa_LookupNames3 {
} in;
struct {
- struct lsa_RefDomainList *domains;/* [unique] */
+ struct lsa_RefDomainList **domains;/* [ref] */
struct lsa_TransSidArray3 *sids;/* [ref] */
uint32_t *count;/* [ref] */
NTSTATUS result;
@@ -1555,7 +1577,7 @@ struct lsa_LookupSids3 {
} in;
struct {
- struct lsa_RefDomainList *domains;/* [unique] */
+ struct lsa_RefDomainList **domains;/* [ref] */
struct lsa_TransNameArray2 *names;/* [ref] */
uint32_t *count;/* [ref] */
NTSTATUS result;
@@ -1576,7 +1598,7 @@ struct lsa_LookupNames4 {
} in;
struct {
- struct lsa_RefDomainList *domains;/* [unique] */
+ struct lsa_RefDomainList **domains;/* [ref] */
struct lsa_TransSidArray3 *sids;/* [ref] */
uint32_t *count;/* [ref] */
NTSTATUS result;
diff --git a/source3/librpc/gen_ndr/ndr_dfs.c b/source3/librpc/gen_ndr/ndr_dfs.c
index f5ce913bd2..2e9873e929 100644
--- a/source3/librpc/gen_ndr/ndr_dfs.c
+++ b/source3/librpc/gen_ndr/ndr_dfs.c
@@ -506,8 +506,7 @@ _PUBLIC_ void ndr_print_dfs_Info3(struct ndr_print *ndr, const char *name, const
ndr->depth++;
for (cntr_stores_1=0;cntr_stores_1<r->num_stores;cntr_stores_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_stores_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_stores_1) != -1) {
ndr_print_dfs_StorageInfo(ndr, "stores", &r->stores[cntr_stores_1]);
free(idx_1);
}
@@ -670,8 +669,7 @@ _PUBLIC_ void ndr_print_dfs_Info4(struct ndr_print *ndr, const char *name, const
ndr->depth++;
for (cntr_stores_1=0;cntr_stores_1<r->num_stores;cntr_stores_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_stores_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_stores_1) != -1) {
ndr_print_dfs_StorageInfo(ndr, "stores", &r->stores[cntr_stores_1]);
free(idx_1);
}
@@ -1079,8 +1077,7 @@ _PUBLIC_ void ndr_print_dfs_Info6(struct ndr_print *ndr, const char *name, const
ndr->depth++;
for (cntr_stores_1=0;cntr_stores_1<r->num_stores;cntr_stores_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_stores_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_stores_1) != -1) {
ndr_print_dfs_StorageInfo2(ndr, "stores", &r->stores[cntr_stores_1]);
free(idx_1);
}
@@ -2271,8 +2268,7 @@ _PUBLIC_ void ndr_print_dfs_EnumArray1(struct ndr_print *ndr, const char *name,
ndr->depth++;
for (cntr_s_1=0;cntr_s_1<r->count;cntr_s_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_s_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_s_1) != -1) {
ndr_print_dfs_Info1(ndr, "s", &r->s[cntr_s_1]);
free(idx_1);
}
@@ -2358,8 +2354,7 @@ _PUBLIC_ void ndr_print_dfs_EnumArray2(struct ndr_print *ndr, const char *name,
ndr->depth++;
for (cntr_s_1=0;cntr_s_1<r->count;cntr_s_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_s_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_s_1) != -1) {
ndr_print_dfs_Info2(ndr, "s", &r->s[cntr_s_1]);
free(idx_1);
}
@@ -2445,8 +2440,7 @@ _PUBLIC_ void ndr_print_dfs_EnumArray3(struct ndr_print *ndr, const char *name,
ndr->depth++;
for (cntr_s_1=0;cntr_s_1<r->count;cntr_s_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_s_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_s_1) != -1) {
ndr_print_dfs_Info3(ndr, "s", &r->s[cntr_s_1]);
free(idx_1);
}
@@ -2532,8 +2526,7 @@ _PUBLIC_ void ndr_print_dfs_EnumArray4(struct ndr_print *ndr, const char *name,
ndr->depth++;
for (cntr_s_1=0;cntr_s_1<r->count;cntr_s_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_s_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_s_1) != -1) {
ndr_print_dfs_Info4(ndr, "s", &r->s[cntr_s_1]);
free(idx_1);
}
@@ -2619,8 +2612,7 @@ _PUBLIC_ void ndr_print_dfs_EnumArray5(struct ndr_print *ndr, const char *name,
ndr->depth++;
for (cntr_s_1=0;cntr_s_1<r->count;cntr_s_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_s_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_s_1) != -1) {
ndr_print_dfs_Info5(ndr, "s", &r->s[cntr_s_1]);
free(idx_1);
}
@@ -2706,8 +2698,7 @@ _PUBLIC_ void ndr_print_dfs_EnumArray6(struct ndr_print *ndr, const char *name,
ndr->depth++;
for (cntr_s_1=0;cntr_s_1<r->count;cntr_s_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_s_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_s_1) != -1) {
ndr_print_dfs_Info6(ndr, "s", &r->s[cntr_s_1]);
free(idx_1);
}
@@ -2793,8 +2784,7 @@ _PUBLIC_ void ndr_print_dfs_EnumArray200(struct ndr_print *ndr, const char *name
ndr->depth++;
for (cntr_s_1=0;cntr_s_1<r->count;cntr_s_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_s_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_s_1) != -1) {
ndr_print_dfs_Info200(ndr, "s", &r->s[cntr_s_1]);
free(idx_1);
}
@@ -2880,8 +2870,7 @@ _PUBLIC_ void ndr_print_dfs_EnumArray300(struct ndr_print *ndr, const char *name
ndr->depth++;
for (cntr_s_1=0;cntr_s_1<r->count;cntr_s_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_s_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_s_1) != -1) {
ndr_print_dfs_Info300(ndr, "s", &r->s[cntr_s_1]);
free(idx_1);
}
diff --git a/source3/librpc/gen_ndr/ndr_echo.c b/source3/librpc/gen_ndr/ndr_echo.c
index 67ff0f2df4..340167cf73 100644
--- a/source3/librpc/gen_ndr/ndr_echo.c
+++ b/source3/librpc/gen_ndr/ndr_echo.c
@@ -627,8 +627,7 @@ _PUBLIC_ void ndr_print_echo_Surrounding(struct ndr_print *ndr, const char *name
ndr->depth++;
for (cntr_surrounding_0=0;cntr_surrounding_0<r->x;cntr_surrounding_0++) {
char *idx_0=NULL;
- asprintf(&idx_0, "[%d]", cntr_surrounding_0);
- if (idx_0) {
+ if (asprintf(&idx_0, "[%d]", cntr_surrounding_0) != -1) {
ndr_print_uint16(ndr, "surrounding", r->surrounding[cntr_surrounding_0]);
free(idx_0);
}
diff --git a/source3/librpc/gen_ndr/ndr_epmapper.c b/source3/librpc/gen_ndr/ndr_epmapper.c
index 4f9422ea57..2e709e11e0 100644
--- a/source3/librpc/gen_ndr/ndr_epmapper.c
+++ b/source3/librpc/gen_ndr/ndr_epmapper.c
@@ -1566,8 +1566,7 @@ _PUBLIC_ void ndr_print_epm_tower(struct ndr_print *ndr, const char *name, const
ndr->depth++;
for (cntr_floors_0=0;cntr_floors_0<r->num_floors;cntr_floors_0++) {
char *idx_0=NULL;
- asprintf(&idx_0, "[%d]", cntr_floors_0);
- if (idx_0) {
+ if (asprintf(&idx_0, "[%d]", cntr_floors_0) != -1) {
ndr_print_epm_floor(ndr, "floors", &r->floors[cntr_floors_0]);
free(idx_0);
}
@@ -1849,8 +1848,7 @@ _PUBLIC_ void ndr_print_epm_Insert(struct ndr_print *ndr, const char *name, int
ndr->depth++;
for (cntr_entries_0=0;cntr_entries_0<r->in.num_ents;cntr_entries_0++) {
char *idx_0=NULL;
- asprintf(&idx_0, "[%d]", cntr_entries_0);
- if (idx_0) {
+ if (asprintf(&idx_0, "[%d]", cntr_entries_0) != -1) {
ndr_print_epm_entry_t(ndr, "entries", &r->in.entries[cntr_entries_0]);
free(idx_0);
}
@@ -1930,8 +1928,7 @@ _PUBLIC_ void ndr_print_epm_Delete(struct ndr_print *ndr, const char *name, int
ndr->depth++;
for (cntr_entries_0=0;cntr_entries_0<r->in.num_ents;cntr_entries_0++) {
char *idx_0=NULL;
- asprintf(&idx_0, "[%d]", cntr_entries_0);
- if (idx_0) {
+ if (asprintf(&idx_0, "[%d]", cntr_entries_0) != -1) {
ndr_print_epm_entry_t(ndr, "entries", &r->in.entries[cntr_entries_0]);
free(idx_0);
}
@@ -2131,8 +2128,7 @@ _PUBLIC_ void ndr_print_epm_Lookup(struct ndr_print *ndr, const char *name, int
ndr->depth++;
for (cntr_entries_0=0;cntr_entries_0<*r->out.num_ents;cntr_entries_0++) {
char *idx_0=NULL;
- asprintf(&idx_0, "[%d]", cntr_entries_0);
- if (idx_0) {
+ if (asprintf(&idx_0, "[%d]", cntr_entries_0) != -1) {
ndr_print_epm_entry_t(ndr, "entries", &r->out.entries[cntr_entries_0]);
free(idx_0);
}
@@ -2321,8 +2317,7 @@ _PUBLIC_ void ndr_print_epm_Map(struct ndr_print *ndr, const char *name, int fla
ndr->depth++;
for (cntr_towers_0=0;cntr_towers_0<*r->out.num_towers;cntr_towers_0++) {
char *idx_0=NULL;
- asprintf(&idx_0, "[%d]", cntr_towers_0);
- if (idx_0) {
+ if (asprintf(&idx_0, "[%d]", cntr_towers_0) != -1) {
ndr_print_epm_twr_p_t(ndr, "towers", &r->out.towers[cntr_towers_0]);
free(idx_0);
}
diff --git a/source3/librpc/gen_ndr/ndr_eventlog.c b/source3/librpc/gen_ndr/ndr_eventlog.c
index c6a77c54e5..c5461d99ab 100644
--- a/source3/librpc/gen_ndr/ndr_eventlog.c
+++ b/source3/librpc/gen_ndr/ndr_eventlog.c
@@ -176,8 +176,7 @@ _PUBLIC_ void ndr_print_eventlog_Record(struct ndr_print *ndr, const char *name,
ndr->depth++;
for (cntr_strings_0=0;cntr_strings_0<r->num_of_strings;cntr_strings_0++) {
char *idx_0=NULL;
- asprintf(&idx_0, "[%d]", cntr_strings_0);
- if (idx_0) {
+ if (asprintf(&idx_0, "[%d]", cntr_strings_0) != -1) {
ndr_print_string(ndr, "strings", r->strings[cntr_strings_0]);
free(idx_0);
}
@@ -878,7 +877,7 @@ static enum ndr_err_code ndr_pull_eventlog_ReadEventLogW(struct ndr_pull *ndr, i
return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
}
NDR_PULL_ALLOC_N(ndr, r->out.data, r->in.number_of_bytes);
- memset(r->out.data, 0, r->in.number_of_bytes * sizeof(*r->out.data));
+ memset(r->out.data, 0, (r->in.number_of_bytes) * sizeof(*r->out.data));
NDR_PULL_ALLOC(ndr, r->out.sent_size);
ZERO_STRUCTP(r->out.sent_size);
NDR_PULL_ALLOC(ndr, r->out.real_size);
diff --git a/source3/librpc/gen_ndr/ndr_krb5pac.c b/source3/librpc/gen_ndr/ndr_krb5pac.c
new file mode 100644
index 0000000000..be9e2e1e4e
--- /dev/null
+++ b/source3/librpc/gen_ndr/ndr_krb5pac.c
@@ -0,0 +1,949 @@
+/* parser auto-generated by pidl */
+
+#include "includes.h"
+#include "librpc/gen_ndr/ndr_krb5pac.h"
+
+#include "librpc/gen_ndr/ndr_security.h"
+#include "librpc/gen_ndr/ndr_netlogon.h"
+#include "librpc/gen_ndr/ndr_samr.h"
+static enum ndr_err_code ndr_push_PAC_LOGON_NAME(struct ndr_push *ndr, int ndr_flags, const struct PAC_LOGON_NAME *r)
+{
+ if (ndr_flags & NDR_SCALARS) {
+ NDR_CHECK(ndr_push_align(ndr, 4));
+ NDR_CHECK(ndr_push_NTTIME(ndr, NDR_SCALARS, r->logon_time));
+ NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, 2 * strlen_m(r->account_name)));
+ NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->account_name, 2 * strlen_m(r->account_name), sizeof(uint8_t), CH_UTF16));
+ }
+ if (ndr_flags & NDR_BUFFERS) {
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PAC_LOGON_NAME(struct ndr_pull *ndr, int ndr_flags, struct PAC_LOGON_NAME *r)
+{
+ if (ndr_flags & NDR_SCALARS) {
+ NDR_CHECK(ndr_pull_align(ndr, 4));
+ NDR_CHECK(ndr_pull_NTTIME(ndr, NDR_SCALARS, &r->logon_time));
+ NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->size));
+ NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->account_name, r->size, sizeof(uint8_t), CH_UTF16));
+ }
+ if (ndr_flags & NDR_BUFFERS) {
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PAC_LOGON_NAME(struct ndr_print *ndr, const char *name, const struct PAC_LOGON_NAME *r)
+{
+ ndr_print_struct(ndr, name, "PAC_LOGON_NAME");
+ ndr->depth++;
+ ndr_print_NTTIME(ndr, "logon_time", r->logon_time);
+ ndr_print_uint16(ndr, "size", (ndr->flags & LIBNDR_PRINT_SET_VALUES)?2 * strlen_m(r->account_name):r->size);
+ ndr_print_string(ndr, "account_name", r->account_name);
+ ndr->depth--;
+}
+
+_PUBLIC_ enum ndr_err_code ndr_push_PAC_SIGNATURE_DATA(struct ndr_push *ndr, int ndr_flags, const struct PAC_SIGNATURE_DATA *r)
+{
+ {
+ uint32_t _flags_save_STRUCT = ndr->flags;
+ ndr_set_flags(&ndr->flags, LIBNDR_PRINT_ARRAY_HEX);
+ if (ndr_flags & NDR_SCALARS) {
+ NDR_CHECK(ndr_push_align(ndr, 4));
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->type));
+ {
+ uint32_t _flags_save_DATA_BLOB = ndr->flags;
+ ndr_set_flags(&ndr->flags, LIBNDR_FLAG_REMAINING);
+ NDR_CHECK(ndr_push_DATA_BLOB(ndr, NDR_SCALARS, r->signature));
+ ndr->flags = _flags_save_DATA_BLOB;
+ }
+ }
+ if (ndr_flags & NDR_BUFFERS) {
+ }
+ ndr->flags = _flags_save_STRUCT;
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ enum ndr_err_code ndr_pull_PAC_SIGNATURE_DATA(struct ndr_pull *ndr, int ndr_flags, struct PAC_SIGNATURE_DATA *r)
+{
+ {
+ uint32_t _flags_save_STRUCT = ndr->flags;
+ ndr_set_flags(&ndr->flags, LIBNDR_PRINT_ARRAY_HEX);
+ if (ndr_flags & NDR_SCALARS) {
+ NDR_CHECK(ndr_pull_align(ndr, 4));
+ NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->type));
+ {
+ uint32_t _flags_save_DATA_BLOB = ndr->flags;
+ ndr_set_flags(&ndr->flags, LIBNDR_FLAG_REMAINING);
+ NDR_CHECK(ndr_pull_DATA_BLOB(ndr, NDR_SCALARS, &r->signature));
+ ndr->flags = _flags_save_DATA_BLOB;
+ }
+ }
+ if (ndr_flags & NDR_BUFFERS) {
+ }
+ ndr->flags = _flags_save_STRUCT;
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PAC_SIGNATURE_DATA(struct ndr_print *ndr, const char *name, const struct PAC_SIGNATURE_DATA *r)
+{
+ ndr_print_struct(ndr, name, "PAC_SIGNATURE_DATA");
+ {
+ uint32_t _flags_save_STRUCT = ndr->flags;
+ ndr_set_flags(&ndr->flags, LIBNDR_PRINT_ARRAY_HEX);
+ ndr->depth++;
+ ndr_print_uint32(ndr, "type", r->type);
+ ndr_print_DATA_BLOB(ndr, "signature", r->signature);
+ ndr->depth--;
+ ndr->flags = _flags_save_STRUCT;
+ }
+}
+
+static enum ndr_err_code ndr_push_PAC_LOGON_INFO(struct ndr_push *ndr, int ndr_flags, const struct PAC_LOGON_INFO *r)
+{
+ if (ndr_flags & NDR_SCALARS) {
+ NDR_CHECK(ndr_push_align(ndr, 4));
+ NDR_CHECK(ndr_push_netr_SamInfo3(ndr, NDR_SCALARS, &r->info3));
+ NDR_CHECK(ndr_push_unique_ptr(ndr, r->res_group_dom_sid));
+ NDR_CHECK(ndr_push_samr_RidWithAttributeArray(ndr, NDR_SCALARS, &r->res_groups));
+ }
+ if (ndr_flags & NDR_BUFFERS) {
+ NDR_CHECK(ndr_push_netr_SamInfo3(ndr, NDR_BUFFERS, &r->info3));
+ if (r->res_group_dom_sid) {
+ NDR_CHECK(ndr_push_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, r->res_group_dom_sid));
+ }
+ NDR_CHECK(ndr_push_samr_RidWithAttributeArray(ndr, NDR_BUFFERS, &r->res_groups));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PAC_LOGON_INFO(struct ndr_pull *ndr, int ndr_flags, struct PAC_LOGON_INFO *r)
+{
+ uint32_t _ptr_res_group_dom_sid;
+ TALLOC_CTX *_mem_save_res_group_dom_sid_0;
+ if (ndr_flags & NDR_SCALARS) {
+ NDR_CHECK(ndr_pull_align(ndr, 4));
+ NDR_CHECK(ndr_pull_netr_SamInfo3(ndr, NDR_SCALARS, &r->info3));
+ NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_res_group_dom_sid));
+ if (_ptr_res_group_dom_sid) {
+ NDR_PULL_ALLOC(ndr, r->res_group_dom_sid);
+ } else {
+ r->res_group_dom_sid = NULL;
+ }
+ NDR_CHECK(ndr_pull_samr_RidWithAttributeArray(ndr, NDR_SCALARS, &r->res_groups));
+ }
+ if (ndr_flags & NDR_BUFFERS) {
+ NDR_CHECK(ndr_pull_netr_SamInfo3(ndr, NDR_BUFFERS, &r->info3));
+ if (r->res_group_dom_sid) {
+ _mem_save_res_group_dom_sid_0 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, r->res_group_dom_sid, 0);
+ NDR_CHECK(ndr_pull_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, r->res_group_dom_sid));
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_res_group_dom_sid_0, 0);
+ }
+ NDR_CHECK(ndr_pull_samr_RidWithAttributeArray(ndr, NDR_BUFFERS, &r->res_groups));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PAC_LOGON_INFO(struct ndr_print *ndr, const char *name, const struct PAC_LOGON_INFO *r)
+{
+ ndr_print_struct(ndr, name, "PAC_LOGON_INFO");
+ ndr->depth++;
+ ndr_print_netr_SamInfo3(ndr, "info3", &r->info3);
+ ndr_print_ptr(ndr, "res_group_dom_sid", r->res_group_dom_sid);
+ ndr->depth++;
+ if (r->res_group_dom_sid) {
+ ndr_print_dom_sid2(ndr, "res_group_dom_sid", r->res_group_dom_sid);
+ }
+ ndr->depth--;
+ ndr_print_samr_RidWithAttributeArray(ndr, "res_groups", &r->res_groups);
+ ndr->depth--;
+}
+
+static size_t ndr_size_PAC_LOGON_INFO(const struct PAC_LOGON_INFO *r, int flags)
+{
+ return ndr_size_struct(r, flags, (ndr_push_flags_fn_t)ndr_push_PAC_LOGON_INFO);
+}
+
+static enum ndr_err_code ndr_push_PAC_UNKNOWN_12(struct ndr_push *ndr, int ndr_flags, const struct PAC_UNKNOWN_12 *r)
+{
+ if (ndr_flags & NDR_SCALARS) {
+ NDR_CHECK(ndr_push_align(ndr, 4));
+ NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, 2 * strlen_m(r->upn_name)));
+ NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->unknown1));
+ NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, 2 * strlen_m(r->domain_name)));
+ NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->unknown2));
+ NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->unknown3));
+ NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->unknown4));
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->unknown5));
+ NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->upn_name, 2 * strlen_m(r->upn_name) + 2, sizeof(uint8_t), CH_UTF16));
+ NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->domain_name, 2 * strlen_m(r->domain_name) + 2, sizeof(uint8_t), CH_UTF16));
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->unknown6));
+ }
+ if (ndr_flags & NDR_BUFFERS) {
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PAC_UNKNOWN_12(struct ndr_pull *ndr, int ndr_flags, struct PAC_UNKNOWN_12 *r)
+{
+ if (ndr_flags & NDR_SCALARS) {
+ NDR_CHECK(ndr_pull_align(ndr, 4));
+ NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->upn_size));
+ NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->unknown1));
+ NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->domain_size));
+ NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->unknown2));
+ NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->unknown3));
+ NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->unknown4));
+ NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->unknown5));
+ NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->upn_name, r->upn_size + 2, sizeof(uint8_t), CH_UTF16));
+ NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->domain_name, r->domain_size + 2, sizeof(uint8_t), CH_UTF16));
+ NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->unknown6));
+ }
+ if (ndr_flags & NDR_BUFFERS) {
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PAC_UNKNOWN_12(struct ndr_print *ndr, const char *name, const struct PAC_UNKNOWN_12 *r)
+{
+ ndr_print_struct(ndr, name, "PAC_UNKNOWN_12");
+ ndr->depth++;
+ ndr_print_uint16(ndr, "upn_size", (ndr->flags & LIBNDR_PRINT_SET_VALUES)?2 * strlen_m(r->upn_name):r->upn_size);
+ ndr_print_uint16(ndr, "unknown1", r->unknown1);
+ ndr_print_uint16(ndr, "domain_size", (ndr->flags & LIBNDR_PRINT_SET_VALUES)?2 * strlen_m(r->domain_name):r->domain_size);
+ ndr_print_uint16(ndr, "unknown2", r->unknown2);
+ ndr_print_uint16(ndr, "unknown3", r->unknown3);
+ ndr_print_uint16(ndr, "unknown4", r->unknown4);
+ ndr_print_uint32(ndr, "unknown5", r->unknown5);
+ ndr_print_string(ndr, "upn_name", r->upn_name);
+ ndr_print_string(ndr, "domain_name", r->domain_name);
+ ndr_print_uint32(ndr, "unknown6", r->unknown6);
+ ndr->depth--;
+}
+
+_PUBLIC_ enum ndr_err_code ndr_push_PAC_LOGON_INFO_CTR(struct ndr_push *ndr, int ndr_flags, const struct PAC_LOGON_INFO_CTR *r)
+{
+ if (ndr_flags & NDR_SCALARS) {
+ NDR_CHECK(ndr_push_align(ndr, 4));
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, 0x00081001));
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, 0xCCCCCCCC));
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, NDR_ROUND(ndr_size_PAC_LOGON_INFO(r->info, ndr->flags) + 4, 8)));
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, 0x00000000));
+ NDR_CHECK(ndr_push_unique_ptr(ndr, r->info));
+ }
+ if (ndr_flags & NDR_BUFFERS) {
+ if (r->info) {
+ NDR_CHECK(ndr_push_PAC_LOGON_INFO(ndr, NDR_SCALARS|NDR_BUFFERS, r->info));
+ }
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ enum ndr_err_code ndr_pull_PAC_LOGON_INFO_CTR(struct ndr_pull *ndr, int ndr_flags, struct PAC_LOGON_INFO_CTR *r)
+{
+ uint32_t _ptr_info;
+ TALLOC_CTX *_mem_save_info_0;
+ if (ndr_flags & NDR_SCALARS) {
+ NDR_CHECK(ndr_pull_align(ndr, 4));
+ NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->unknown1));
+ NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->unknown2));
+ NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->_ndr_size));
+ NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->unknown3));
+ NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info));
+ if (_ptr_info) {
+ NDR_PULL_ALLOC(ndr, r->info);
+ } else {
+ r->info = NULL;
+ }
+ }
+ if (ndr_flags & NDR_BUFFERS) {
+ if (r->info) {
+ _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, r->info, 0);
+ NDR_CHECK(ndr_pull_PAC_LOGON_INFO(ndr, NDR_SCALARS|NDR_BUFFERS, r->info));
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, 0);
+ }
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PAC_LOGON_INFO_CTR(struct ndr_print *ndr, const char *name, const struct PAC_LOGON_INFO_CTR *r)
+{
+ ndr_print_struct(ndr, name, "PAC_LOGON_INFO_CTR");
+ ndr->depth++;
+ ndr_print_uint32(ndr, "unknown1", (ndr->flags & LIBNDR_PRINT_SET_VALUES)?0x00081001:r->unknown1);
+ ndr_print_uint32(ndr, "unknown2", (ndr->flags & LIBNDR_PRINT_SET_VALUES)?0xCCCCCCCC:r->unknown2);
+ ndr_print_uint32(ndr, "_ndr_size", (ndr->flags & LIBNDR_PRINT_SET_VALUES)?NDR_ROUND(ndr_size_PAC_LOGON_INFO(r->info, ndr->flags) + 4, 8):r->_ndr_size);
+ ndr_print_uint32(ndr, "unknown3", (ndr->flags & LIBNDR_PRINT_SET_VALUES)?0x00000000:r->unknown3);
+ ndr_print_ptr(ndr, "info", r->info);
+ ndr->depth++;
+ if (r->info) {
+ ndr_print_PAC_LOGON_INFO(ndr, "info", r->info);
+ }
+ ndr->depth--;
+ ndr->depth--;
+}
+
+_PUBLIC_ enum ndr_err_code ndr_push_PAC_TYPE(struct ndr_push *ndr, int ndr_flags, enum PAC_TYPE r)
+{
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r));
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ enum ndr_err_code ndr_pull_PAC_TYPE(struct ndr_pull *ndr, int ndr_flags, enum PAC_TYPE *r)
+{
+ uint32_t v;
+ NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &v));
+ *r = v;
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PAC_TYPE(struct ndr_print *ndr, const char *name, enum PAC_TYPE r)
+{
+ const char *val = NULL;
+
+ switch (r) {
+ case PAC_TYPE_LOGON_INFO: val = "PAC_TYPE_LOGON_INFO"; break;
+ case PAC_TYPE_SRV_CHECKSUM: val = "PAC_TYPE_SRV_CHECKSUM"; break;
+ case PAC_TYPE_KDC_CHECKSUM: val = "PAC_TYPE_KDC_CHECKSUM"; break;
+ case PAC_TYPE_LOGON_NAME: val = "PAC_TYPE_LOGON_NAME"; break;
+ case PAC_TYPE_CONSTRAINED_DELEGATION: val = "PAC_TYPE_CONSTRAINED_DELEGATION"; break;
+ case PAC_TYPE_UNKNOWN_12: val = "PAC_TYPE_UNKNOWN_12"; break;
+ }
+ ndr_print_enum(ndr, name, "ENUM", val, r);
+}
+
+_PUBLIC_ enum ndr_err_code ndr_push_PAC_INFO(struct ndr_push *ndr, int ndr_flags, const union PAC_INFO *r)
+{
+ if (ndr_flags & NDR_SCALARS) {
+ int level = ndr_push_get_switch_value(ndr, r);
+ switch (level) {
+ case PAC_TYPE_LOGON_INFO: {
+ NDR_CHECK(ndr_push_PAC_LOGON_INFO_CTR(ndr, NDR_SCALARS, &r->logon_info));
+ break; }
+
+ case PAC_TYPE_SRV_CHECKSUM: {
+ NDR_CHECK(ndr_push_PAC_SIGNATURE_DATA(ndr, NDR_SCALARS, &r->srv_cksum));
+ break; }
+
+ case PAC_TYPE_KDC_CHECKSUM: {
+ NDR_CHECK(ndr_push_PAC_SIGNATURE_DATA(ndr, NDR_SCALARS, &r->kdc_cksum));
+ break; }
+
+ case PAC_TYPE_LOGON_NAME: {
+ NDR_CHECK(ndr_push_PAC_LOGON_NAME(ndr, NDR_SCALARS, &r->logon_name));
+ break; }
+
+ case PAC_TYPE_UNKNOWN_12: {
+ NDR_CHECK(ndr_push_PAC_UNKNOWN_12(ndr, NDR_SCALARS, &r->unknown));
+ break; }
+
+ default:
+ return ndr_push_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %u", level);
+ }
+ }
+ if (ndr_flags & NDR_BUFFERS) {
+ int level = ndr_push_get_switch_value(ndr, r);
+ switch (level) {
+ case PAC_TYPE_LOGON_INFO:
+ NDR_CHECK(ndr_push_PAC_LOGON_INFO_CTR(ndr, NDR_BUFFERS, &r->logon_info));
+ break;
+
+ case PAC_TYPE_SRV_CHECKSUM:
+ break;
+
+ case PAC_TYPE_KDC_CHECKSUM:
+ break;
+
+ case PAC_TYPE_LOGON_NAME:
+ break;
+
+ case PAC_TYPE_UNKNOWN_12:
+ break;
+
+ default:
+ return ndr_push_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %u", level);
+ }
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ enum ndr_err_code ndr_pull_PAC_INFO(struct ndr_pull *ndr, int ndr_flags, union PAC_INFO *r)
+{
+ int level;
+ level = ndr_pull_get_switch_value(ndr, r);
+ if (ndr_flags & NDR_SCALARS) {
+ switch (level) {
+ case PAC_TYPE_LOGON_INFO: {
+ NDR_CHECK(ndr_pull_PAC_LOGON_INFO_CTR(ndr, NDR_SCALARS, &r->logon_info));
+ break; }
+
+ case PAC_TYPE_SRV_CHECKSUM: {
+ NDR_CHECK(ndr_pull_PAC_SIGNATURE_DATA(ndr, NDR_SCALARS, &r->srv_cksum));
+ break; }
+
+ case PAC_TYPE_KDC_CHECKSUM: {
+ NDR_CHECK(ndr_pull_PAC_SIGNATURE_DATA(ndr, NDR_SCALARS, &r->kdc_cksum));
+ break; }
+
+ case PAC_TYPE_LOGON_NAME: {
+ NDR_CHECK(ndr_pull_PAC_LOGON_NAME(ndr, NDR_SCALARS, &r->logon_name));
+ break; }
+
+ case PAC_TYPE_UNKNOWN_12: {
+ NDR_CHECK(ndr_pull_PAC_UNKNOWN_12(ndr, NDR_SCALARS, &r->unknown));
+ break; }
+
+ default:
+ return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %u", level);
+ }
+ }
+ if (ndr_flags & NDR_BUFFERS) {
+ switch (level) {
+ case PAC_TYPE_LOGON_INFO:
+ NDR_CHECK(ndr_pull_PAC_LOGON_INFO_CTR(ndr, NDR_BUFFERS, &r->logon_info));
+ break;
+
+ case PAC_TYPE_SRV_CHECKSUM:
+ break;
+
+ case PAC_TYPE_KDC_CHECKSUM:
+ break;
+
+ case PAC_TYPE_LOGON_NAME:
+ break;
+
+ case PAC_TYPE_UNKNOWN_12:
+ break;
+
+ default:
+ return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %u", level);
+ }
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PAC_INFO(struct ndr_print *ndr, const char *name, const union PAC_INFO *r)
+{
+ int level;
+ level = ndr_print_get_switch_value(ndr, r);
+ ndr_print_union(ndr, name, level, "PAC_INFO");
+ switch (level) {
+ case PAC_TYPE_LOGON_INFO:
+ ndr_print_PAC_LOGON_INFO_CTR(ndr, "logon_info", &r->logon_info);
+ break;
+
+ case PAC_TYPE_SRV_CHECKSUM:
+ ndr_print_PAC_SIGNATURE_DATA(ndr, "srv_cksum", &r->srv_cksum);
+ break;
+
+ case PAC_TYPE_KDC_CHECKSUM:
+ ndr_print_PAC_SIGNATURE_DATA(ndr, "kdc_cksum", &r->kdc_cksum);
+ break;
+
+ case PAC_TYPE_LOGON_NAME:
+ ndr_print_PAC_LOGON_NAME(ndr, "logon_name", &r->logon_name);
+ break;
+
+ case PAC_TYPE_UNKNOWN_12:
+ ndr_print_PAC_UNKNOWN_12(ndr, "unknown", &r->unknown);
+ break;
+
+ default:
+ ndr_print_bad_level(ndr, name, level);
+ }
+}
+
+_PUBLIC_ size_t ndr_size_PAC_INFO(const union PAC_INFO *r, uint32_t level, int flags)
+{
+ return ndr_size_union(r, flags, level, (ndr_push_flags_fn_t)ndr_push_PAC_INFO);
+}
+
+_PUBLIC_ enum ndr_err_code ndr_push_PAC_DATA(struct ndr_push *ndr, int ndr_flags, const struct PAC_DATA *r)
+{
+ uint32_t cntr_buffers_0;
+ if (ndr_flags & NDR_SCALARS) {
+ NDR_CHECK(ndr_push_align(ndr, 4));
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->num_buffers));
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->version));
+ for (cntr_buffers_0 = 0; cntr_buffers_0 < r->num_buffers; cntr_buffers_0++) {
+ NDR_CHECK(ndr_push_PAC_BUFFER(ndr, NDR_SCALARS, &r->buffers[cntr_buffers_0]));
+ }
+ }
+ if (ndr_flags & NDR_BUFFERS) {
+ for (cntr_buffers_0 = 0; cntr_buffers_0 < r->num_buffers; cntr_buffers_0++) {
+ NDR_CHECK(ndr_push_PAC_BUFFER(ndr, NDR_BUFFERS, &r->buffers[cntr_buffers_0]));
+ }
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ enum ndr_err_code ndr_pull_PAC_DATA(struct ndr_pull *ndr, int ndr_flags, struct PAC_DATA *r)
+{
+ uint32_t cntr_buffers_0;
+ TALLOC_CTX *_mem_save_buffers_0;
+ if (ndr_flags & NDR_SCALARS) {
+ NDR_CHECK(ndr_pull_align(ndr, 4));
+ NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->num_buffers));
+ NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->version));
+ NDR_PULL_ALLOC_N(ndr, r->buffers, r->num_buffers);
+ _mem_save_buffers_0 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, r->buffers, 0);
+ for (cntr_buffers_0 = 0; cntr_buffers_0 < r->num_buffers; cntr_buffers_0++) {
+ NDR_CHECK(ndr_pull_PAC_BUFFER(ndr, NDR_SCALARS, &r->buffers[cntr_buffers_0]));
+ }
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_buffers_0, 0);
+ }
+ if (ndr_flags & NDR_BUFFERS) {
+ _mem_save_buffers_0 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, r->buffers, 0);
+ for (cntr_buffers_0 = 0; cntr_buffers_0 < r->num_buffers; cntr_buffers_0++) {
+ NDR_CHECK(ndr_pull_PAC_BUFFER(ndr, NDR_BUFFERS, &r->buffers[cntr_buffers_0]));
+ }
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_buffers_0, 0);
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PAC_DATA(struct ndr_print *ndr, const char *name, const struct PAC_DATA *r)
+{
+ uint32_t cntr_buffers_0;
+ ndr_print_struct(ndr, name, "PAC_DATA");
+ ndr->depth++;
+ ndr_print_uint32(ndr, "num_buffers", r->num_buffers);
+ ndr_print_uint32(ndr, "version", r->version);
+ ndr->print(ndr, "%s: ARRAY(%d)", "buffers", r->num_buffers);
+ ndr->depth++;
+ for (cntr_buffers_0=0;cntr_buffers_0<r->num_buffers;cntr_buffers_0++) {
+ char *idx_0=NULL;
+ if (asprintf(&idx_0, "[%d]", cntr_buffers_0) != -1) {
+ ndr_print_PAC_BUFFER(ndr, "buffers", &r->buffers[cntr_buffers_0]);
+ free(idx_0);
+ }
+ }
+ ndr->depth--;
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_DATA_BLOB_REM(struct ndr_push *ndr, int ndr_flags, const struct DATA_BLOB_REM *r)
+{
+ if (ndr_flags & NDR_SCALARS) {
+ NDR_CHECK(ndr_push_align(ndr, 4));
+ {
+ uint32_t _flags_save_DATA_BLOB = ndr->flags;
+ ndr_set_flags(&ndr->flags, LIBNDR_FLAG_REMAINING);
+ NDR_CHECK(ndr_push_DATA_BLOB(ndr, NDR_SCALARS, r->remaining));
+ ndr->flags = _flags_save_DATA_BLOB;
+ }
+ }
+ if (ndr_flags & NDR_BUFFERS) {
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_DATA_BLOB_REM(struct ndr_pull *ndr, int ndr_flags, struct DATA_BLOB_REM *r)
+{
+ if (ndr_flags & NDR_SCALARS) {
+ NDR_CHECK(ndr_pull_align(ndr, 4));
+ {
+ uint32_t _flags_save_DATA_BLOB = ndr->flags;
+ ndr_set_flags(&ndr->flags, LIBNDR_FLAG_REMAINING);
+ NDR_CHECK(ndr_pull_DATA_BLOB(ndr, NDR_SCALARS, &r->remaining));
+ ndr->flags = _flags_save_DATA_BLOB;
+ }
+ }
+ if (ndr_flags & NDR_BUFFERS) {
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_DATA_BLOB_REM(struct ndr_print *ndr, const char *name, const struct DATA_BLOB_REM *r)
+{
+ ndr_print_struct(ndr, name, "DATA_BLOB_REM");
+ ndr->depth++;
+ ndr_print_DATA_BLOB(ndr, "remaining", r->remaining);
+ ndr->depth--;
+}
+
+_PUBLIC_ enum ndr_err_code ndr_push_PAC_BUFFER_RAW(struct ndr_push *ndr, int ndr_flags, const struct PAC_BUFFER_RAW *r)
+{
+ if (ndr_flags & NDR_SCALARS) {
+ NDR_CHECK(ndr_push_align(ndr, 4));
+ NDR_CHECK(ndr_push_PAC_TYPE(ndr, NDR_SCALARS, r->type));
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->ndr_size));
+ {
+ uint32_t _flags_save_DATA_BLOB_REM = ndr->flags;
+ ndr_set_flags(&ndr->flags, LIBNDR_FLAG_ALIGN8);
+ NDR_CHECK(ndr_push_relative_ptr1(ndr, r->info));
+ ndr->flags = _flags_save_DATA_BLOB_REM;
+ }
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, 0));
+ }
+ if (ndr_flags & NDR_BUFFERS) {
+ {
+ uint32_t _flags_save_DATA_BLOB_REM = ndr->flags;
+ ndr_set_flags(&ndr->flags, LIBNDR_FLAG_ALIGN8);
+ if (r->info) {
+ NDR_CHECK(ndr_push_relative_ptr2(ndr, r->info));
+ {
+ struct ndr_push *_ndr_info;
+ NDR_CHECK(ndr_push_subcontext_start(ndr, &_ndr_info, 0, NDR_ROUND(r->ndr_size, 8)));
+ NDR_CHECK(ndr_push_DATA_BLOB_REM(_ndr_info, NDR_SCALARS, r->info));
+ NDR_CHECK(ndr_push_subcontext_end(ndr, _ndr_info, 0, NDR_ROUND(r->ndr_size, 8)));
+ }
+ }
+ ndr->flags = _flags_save_DATA_BLOB_REM;
+ }
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ enum ndr_err_code ndr_pull_PAC_BUFFER_RAW(struct ndr_pull *ndr, int ndr_flags, struct PAC_BUFFER_RAW *r)
+{
+ uint32_t _ptr_info;
+ TALLOC_CTX *_mem_save_info_0;
+ if (ndr_flags & NDR_SCALARS) {
+ NDR_CHECK(ndr_pull_align(ndr, 4));
+ NDR_CHECK(ndr_pull_PAC_TYPE(ndr, NDR_SCALARS, &r->type));
+ NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->ndr_size));
+ {
+ uint32_t _flags_save_DATA_BLOB_REM = ndr->flags;
+ ndr_set_flags(&ndr->flags, LIBNDR_FLAG_ALIGN8);
+ NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info));
+ if (_ptr_info) {
+ NDR_PULL_ALLOC(ndr, r->info);
+ NDR_CHECK(ndr_pull_relative_ptr1(ndr, r->info, _ptr_info));
+ } else {
+ r->info = NULL;
+ }
+ ndr->flags = _flags_save_DATA_BLOB_REM;
+ }
+ NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->_pad));
+ }
+ if (ndr_flags & NDR_BUFFERS) {
+ {
+ uint32_t _flags_save_DATA_BLOB_REM = ndr->flags;
+ ndr_set_flags(&ndr->flags, LIBNDR_FLAG_ALIGN8);
+ if (r->info) {
+ uint32_t _relative_save_offset;
+ _relative_save_offset = ndr->offset;
+ NDR_CHECK(ndr_pull_relative_ptr2(ndr, r->info));
+ _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, r->info, 0);
+ {
+ struct ndr_pull *_ndr_info;
+ NDR_CHECK(ndr_pull_subcontext_start(ndr, &_ndr_info, 0, NDR_ROUND(r->ndr_size, 8)));
+ NDR_CHECK(ndr_pull_DATA_BLOB_REM(_ndr_info, NDR_SCALARS, r->info));
+ NDR_CHECK(ndr_pull_subcontext_end(ndr, _ndr_info, 0, NDR_ROUND(r->ndr_size, 8)));
+ }
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, 0);
+ ndr->offset = _relative_save_offset;
+ }
+ ndr->flags = _flags_save_DATA_BLOB_REM;
+ }
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PAC_BUFFER_RAW(struct ndr_print *ndr, const char *name, const struct PAC_BUFFER_RAW *r)
+{
+ ndr_print_struct(ndr, name, "PAC_BUFFER_RAW");
+ ndr->depth++;
+ ndr_print_PAC_TYPE(ndr, "type", r->type);
+ ndr_print_uint32(ndr, "ndr_size", r->ndr_size);
+ ndr_print_ptr(ndr, "info", r->info);
+ ndr->depth++;
+ if (r->info) {
+ ndr_print_DATA_BLOB_REM(ndr, "info", r->info);
+ }
+ ndr->depth--;
+ ndr_print_uint32(ndr, "_pad", (ndr->flags & LIBNDR_PRINT_SET_VALUES)?0:r->_pad);
+ ndr->depth--;
+}
+
+_PUBLIC_ enum ndr_err_code ndr_push_PAC_DATA_RAW(struct ndr_push *ndr, int ndr_flags, const struct PAC_DATA_RAW *r)
+{
+ uint32_t cntr_buffers_0;
+ if (ndr_flags & NDR_SCALARS) {
+ NDR_CHECK(ndr_push_align(ndr, 4));
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->num_buffers));
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->version));
+ for (cntr_buffers_0 = 0; cntr_buffers_0 < r->num_buffers; cntr_buffers_0++) {
+ NDR_CHECK(ndr_push_PAC_BUFFER_RAW(ndr, NDR_SCALARS, &r->buffers[cntr_buffers_0]));
+ }
+ }
+ if (ndr_flags & NDR_BUFFERS) {
+ for (cntr_buffers_0 = 0; cntr_buffers_0 < r->num_buffers; cntr_buffers_0++) {
+ NDR_CHECK(ndr_push_PAC_BUFFER_RAW(ndr, NDR_BUFFERS, &r->buffers[cntr_buffers_0]));
+ }
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ enum ndr_err_code ndr_pull_PAC_DATA_RAW(struct ndr_pull *ndr, int ndr_flags, struct PAC_DATA_RAW *r)
+{
+ uint32_t cntr_buffers_0;
+ TALLOC_CTX *_mem_save_buffers_0;
+ if (ndr_flags & NDR_SCALARS) {
+ NDR_CHECK(ndr_pull_align(ndr, 4));
+ NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->num_buffers));
+ NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->version));
+ NDR_PULL_ALLOC_N(ndr, r->buffers, r->num_buffers);
+ _mem_save_buffers_0 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, r->buffers, 0);
+ for (cntr_buffers_0 = 0; cntr_buffers_0 < r->num_buffers; cntr_buffers_0++) {
+ NDR_CHECK(ndr_pull_PAC_BUFFER_RAW(ndr, NDR_SCALARS, &r->buffers[cntr_buffers_0]));
+ }
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_buffers_0, 0);
+ }
+ if (ndr_flags & NDR_BUFFERS) {
+ _mem_save_buffers_0 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, r->buffers, 0);
+ for (cntr_buffers_0 = 0; cntr_buffers_0 < r->num_buffers; cntr_buffers_0++) {
+ NDR_CHECK(ndr_pull_PAC_BUFFER_RAW(ndr, NDR_BUFFERS, &r->buffers[cntr_buffers_0]));
+ }
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_buffers_0, 0);
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PAC_DATA_RAW(struct ndr_print *ndr, const char *name, const struct PAC_DATA_RAW *r)
+{
+ uint32_t cntr_buffers_0;
+ ndr_print_struct(ndr, name, "PAC_DATA_RAW");
+ ndr->depth++;
+ ndr_print_uint32(ndr, "num_buffers", r->num_buffers);
+ ndr_print_uint32(ndr, "version", r->version);
+ ndr->print(ndr, "%s: ARRAY(%d)", "buffers", r->num_buffers);
+ ndr->depth++;
+ for (cntr_buffers_0=0;cntr_buffers_0<r->num_buffers;cntr_buffers_0++) {
+ char *idx_0=NULL;
+ if (asprintf(&idx_0, "[%d]", cntr_buffers_0) != -1) {
+ ndr_print_PAC_BUFFER_RAW(ndr, "buffers", &r->buffers[cntr_buffers_0]);
+ free(idx_0);
+ }
+ }
+ ndr->depth--;
+ ndr->depth--;
+}
+
+_PUBLIC_ enum ndr_err_code ndr_push_netsamlogoncache_entry(struct ndr_push *ndr, int ndr_flags, const struct netsamlogoncache_entry *r)
+{
+ if (ndr_flags & NDR_SCALARS) {
+ NDR_CHECK(ndr_push_align(ndr, 4));
+ NDR_CHECK(ndr_push_time_t(ndr, NDR_SCALARS, r->timestamp));
+ NDR_CHECK(ndr_push_netr_SamInfo3(ndr, NDR_SCALARS, &r->info3));
+ }
+ if (ndr_flags & NDR_BUFFERS) {
+ NDR_CHECK(ndr_push_netr_SamInfo3(ndr, NDR_BUFFERS, &r->info3));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ enum ndr_err_code ndr_pull_netsamlogoncache_entry(struct ndr_pull *ndr, int ndr_flags, struct netsamlogoncache_entry *r)
+{
+ if (ndr_flags & NDR_SCALARS) {
+ NDR_CHECK(ndr_pull_align(ndr, 4));
+ NDR_CHECK(ndr_pull_time_t(ndr, NDR_SCALARS, &r->timestamp));
+ NDR_CHECK(ndr_pull_netr_SamInfo3(ndr, NDR_SCALARS, &r->info3));
+ }
+ if (ndr_flags & NDR_BUFFERS) {
+ NDR_CHECK(ndr_pull_netr_SamInfo3(ndr, NDR_BUFFERS, &r->info3));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_netsamlogoncache_entry(struct ndr_print *ndr, const char *name, const struct netsamlogoncache_entry *r)
+{
+ ndr_print_struct(ndr, name, "netsamlogoncache_entry");
+ ndr->depth++;
+ ndr_print_time_t(ndr, "timestamp", r->timestamp);
+ ndr_print_netr_SamInfo3(ndr, "info3", &r->info3);
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_decode_pac(struct ndr_push *ndr, int flags, const struct decode_pac *r)
+{
+ if (flags & NDR_IN) {
+ NDR_CHECK(ndr_push_PAC_DATA(ndr, NDR_SCALARS|NDR_BUFFERS, &r->in.pac));
+ }
+ if (flags & NDR_OUT) {
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_decode_pac(struct ndr_pull *ndr, int flags, struct decode_pac *r)
+{
+ if (flags & NDR_IN) {
+ NDR_CHECK(ndr_pull_PAC_DATA(ndr, NDR_SCALARS|NDR_BUFFERS, &r->in.pac));
+ }
+ if (flags & NDR_OUT) {
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_decode_pac(struct ndr_print *ndr, const char *name, int flags, const struct decode_pac *r)
+{
+ ndr_print_struct(ndr, name, "decode_pac");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "decode_pac");
+ ndr->depth++;
+ ndr_print_PAC_DATA(ndr, "pac", &r->in.pac);
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "decode_pac");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_decode_pac_raw(struct ndr_push *ndr, int flags, const struct decode_pac_raw *r)
+{
+ if (flags & NDR_IN) {
+ NDR_CHECK(ndr_push_PAC_DATA_RAW(ndr, NDR_SCALARS|NDR_BUFFERS, &r->in.pac));
+ }
+ if (flags & NDR_OUT) {
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_decode_pac_raw(struct ndr_pull *ndr, int flags, struct decode_pac_raw *r)
+{
+ if (flags & NDR_IN) {
+ NDR_CHECK(ndr_pull_PAC_DATA_RAW(ndr, NDR_SCALARS|NDR_BUFFERS, &r->in.pac));
+ }
+ if (flags & NDR_OUT) {
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_decode_pac_raw(struct ndr_print *ndr, const char *name, int flags, const struct decode_pac_raw *r)
+{
+ ndr_print_struct(ndr, name, "decode_pac_raw");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "decode_pac_raw");
+ ndr->depth++;
+ ndr_print_PAC_DATA_RAW(ndr, "pac", &r->in.pac);
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "decode_pac_raw");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_decode_login_info(struct ndr_push *ndr, int flags, const struct decode_login_info *r)
+{
+ if (flags & NDR_IN) {
+ NDR_CHECK(ndr_push_PAC_LOGON_INFO(ndr, NDR_SCALARS|NDR_BUFFERS, &r->in.logon_info));
+ }
+ if (flags & NDR_OUT) {
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_decode_login_info(struct ndr_pull *ndr, int flags, struct decode_login_info *r)
+{
+ if (flags & NDR_IN) {
+ NDR_CHECK(ndr_pull_PAC_LOGON_INFO(ndr, NDR_SCALARS|NDR_BUFFERS, &r->in.logon_info));
+ }
+ if (flags & NDR_OUT) {
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_decode_login_info(struct ndr_print *ndr, const char *name, int flags, const struct decode_login_info *r)
+{
+ ndr_print_struct(ndr, name, "decode_login_info");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "decode_login_info");
+ ndr->depth++;
+ ndr_print_PAC_LOGON_INFO(ndr, "logon_info", &r->in.logon_info);
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "decode_login_info");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static const struct ndr_interface_call krb5pac_calls[] = {
+ {
+ "decode_pac",
+ sizeof(struct decode_pac),
+ (ndr_push_flags_fn_t) ndr_push_decode_pac,
+ (ndr_pull_flags_fn_t) ndr_pull_decode_pac,
+ (ndr_print_function_t) ndr_print_decode_pac,
+ false,
+ },
+ {
+ "decode_pac_raw",
+ sizeof(struct decode_pac_raw),
+ (ndr_push_flags_fn_t) ndr_push_decode_pac_raw,
+ (ndr_pull_flags_fn_t) ndr_pull_decode_pac_raw,
+ (ndr_print_function_t) ndr_print_decode_pac_raw,
+ false,
+ },
+ {
+ "decode_login_info",
+ sizeof(struct decode_login_info),
+ (ndr_push_flags_fn_t) ndr_push_decode_login_info,
+ (ndr_pull_flags_fn_t) ndr_pull_decode_login_info,
+ (ndr_print_function_t) ndr_print_decode_login_info,
+ false,
+ },
+ { NULL, 0, NULL, NULL, NULL, false }
+};
+
+static const char * const krb5pac_endpoint_strings[] = {
+ "ncacn_np:[\\pipe\\krb5pac]",
+};
+
+static const struct ndr_interface_string_array krb5pac_endpoints = {
+ .count = 1,
+ .names = krb5pac_endpoint_strings
+};
+
+static const char * const krb5pac_authservice_strings[] = {
+ "host",
+};
+
+static const struct ndr_interface_string_array krb5pac_authservices = {
+ .count = 1,
+ .names = krb5pac_authservice_strings
+};
+
+
+const struct ndr_interface_table ndr_table_krb5pac = {
+ .name = "krb5pac",
+ .syntax_id = {
+ {0x12345778,0x1234,0xabcd,{0x00,0x00},{0x00,0x00,0x00,0x00}},
+ NDR_KRB5PAC_VERSION
+ },
+ .helpstring = NDR_KRB5PAC_HELPSTRING,
+ .num_calls = 3,
+ .calls = krb5pac_calls,
+ .endpoints = &krb5pac_endpoints,
+ .authservices = &krb5pac_authservices
+};
+
diff --git a/source3/librpc/gen_ndr/ndr_krb5pac.h b/source3/librpc/gen_ndr/ndr_krb5pac.h
new file mode 100644
index 0000000000..1d60382dc3
--- /dev/null
+++ b/source3/librpc/gen_ndr/ndr_krb5pac.h
@@ -0,0 +1,56 @@
+/* header auto-generated by pidl */
+
+#include "librpc/ndr/libndr.h"
+#include "librpc/gen_ndr/krb5pac.h"
+
+#ifndef _HEADER_NDR_krb5pac
+#define _HEADER_NDR_krb5pac
+
+#define NDR_KRB5PAC_UUID "12345778-1234-abcd-0000-00000000"
+#define NDR_KRB5PAC_VERSION 0.0
+#define NDR_KRB5PAC_NAME "krb5pac"
+#define NDR_KRB5PAC_HELPSTRING "Active Directory KRB5 PAC"
+extern const struct ndr_interface_table ndr_table_krb5pac;
+#define NDR_DECODE_PAC (0x00)
+
+#define NDR_DECODE_PAC_RAW (0x01)
+
+#define NDR_DECODE_LOGIN_INFO (0x02)
+
+#define NDR_KRB5PAC_CALL_COUNT (3)
+void ndr_print_PAC_LOGON_NAME(struct ndr_print *ndr, const char *name, const struct PAC_LOGON_NAME *r);
+enum ndr_err_code ndr_push_PAC_SIGNATURE_DATA(struct ndr_push *ndr, int ndr_flags, const struct PAC_SIGNATURE_DATA *r);
+enum ndr_err_code ndr_pull_PAC_SIGNATURE_DATA(struct ndr_pull *ndr, int ndr_flags, struct PAC_SIGNATURE_DATA *r);
+void ndr_print_PAC_SIGNATURE_DATA(struct ndr_print *ndr, const char *name, const struct PAC_SIGNATURE_DATA *r);
+void ndr_print_PAC_LOGON_INFO(struct ndr_print *ndr, const char *name, const struct PAC_LOGON_INFO *r);
+void ndr_print_PAC_UNKNOWN_12(struct ndr_print *ndr, const char *name, const struct PAC_UNKNOWN_12 *r);
+enum ndr_err_code ndr_push_PAC_LOGON_INFO_CTR(struct ndr_push *ndr, int ndr_flags, const struct PAC_LOGON_INFO_CTR *r);
+enum ndr_err_code ndr_pull_PAC_LOGON_INFO_CTR(struct ndr_pull *ndr, int ndr_flags, struct PAC_LOGON_INFO_CTR *r);
+void ndr_print_PAC_LOGON_INFO_CTR(struct ndr_print *ndr, const char *name, const struct PAC_LOGON_INFO_CTR *r);
+enum ndr_err_code ndr_push_PAC_TYPE(struct ndr_push *ndr, int ndr_flags, enum PAC_TYPE r);
+enum ndr_err_code ndr_pull_PAC_TYPE(struct ndr_pull *ndr, int ndr_flags, enum PAC_TYPE *r);
+void ndr_print_PAC_TYPE(struct ndr_print *ndr, const char *name, enum PAC_TYPE r);
+enum ndr_err_code ndr_push_PAC_INFO(struct ndr_push *ndr, int ndr_flags, const union PAC_INFO *r);
+enum ndr_err_code ndr_pull_PAC_INFO(struct ndr_pull *ndr, int ndr_flags, union PAC_INFO *r);
+void ndr_print_PAC_INFO(struct ndr_print *ndr, const char *name, const union PAC_INFO *r);
+size_t ndr_size_PAC_INFO(const union PAC_INFO *r, uint32_t level, int flags);
+enum ndr_err_code ndr_push_PAC_BUFFER(struct ndr_push *ndr, int ndr_flags, const struct PAC_BUFFER *r);
+enum ndr_err_code ndr_pull_PAC_BUFFER(struct ndr_pull *ndr, int ndr_flags, struct PAC_BUFFER *r);
+void ndr_print_PAC_BUFFER(struct ndr_print *ndr, const char *name, const struct PAC_BUFFER *r);
+enum ndr_err_code ndr_push_PAC_DATA(struct ndr_push *ndr, int ndr_flags, const struct PAC_DATA *r);
+enum ndr_err_code ndr_pull_PAC_DATA(struct ndr_pull *ndr, int ndr_flags, struct PAC_DATA *r);
+void ndr_print_PAC_DATA(struct ndr_print *ndr, const char *name, const struct PAC_DATA *r);
+void ndr_print_DATA_BLOB_REM(struct ndr_print *ndr, const char *name, const struct DATA_BLOB_REM *r);
+enum ndr_err_code ndr_push_PAC_BUFFER_RAW(struct ndr_push *ndr, int ndr_flags, const struct PAC_BUFFER_RAW *r);
+enum ndr_err_code ndr_pull_PAC_BUFFER_RAW(struct ndr_pull *ndr, int ndr_flags, struct PAC_BUFFER_RAW *r);
+void ndr_print_PAC_BUFFER_RAW(struct ndr_print *ndr, const char *name, const struct PAC_BUFFER_RAW *r);
+enum ndr_err_code ndr_push_PAC_DATA_RAW(struct ndr_push *ndr, int ndr_flags, const struct PAC_DATA_RAW *r);
+enum ndr_err_code ndr_pull_PAC_DATA_RAW(struct ndr_pull *ndr, int ndr_flags, struct PAC_DATA_RAW *r);
+void ndr_print_PAC_DATA_RAW(struct ndr_print *ndr, const char *name, const struct PAC_DATA_RAW *r);
+enum ndr_err_code ndr_push_netsamlogoncache_entry(struct ndr_push *ndr, int ndr_flags, const struct netsamlogoncache_entry *r);
+enum ndr_err_code ndr_pull_netsamlogoncache_entry(struct ndr_pull *ndr, int ndr_flags, struct netsamlogoncache_entry *r);
+void ndr_print_netsamlogoncache_entry(struct ndr_print *ndr, const char *name, const struct netsamlogoncache_entry *r);
+void ndr_print_decode_pac(struct ndr_print *ndr, const char *name, int flags, const struct decode_pac *r);
+void ndr_print_decode_pac_raw(struct ndr_print *ndr, const char *name, int flags, const struct decode_pac_raw *r);
+void ndr_print_decode_login_info(struct ndr_print *ndr, const char *name, int flags, const struct decode_login_info *r);
+#endif /* _HEADER_NDR_krb5pac */
diff --git a/source3/librpc/gen_ndr/ndr_libnet_join.c b/source3/librpc/gen_ndr/ndr_libnet_join.c
index 5345bc0ad4..ac8f7ee71d 100644
--- a/source3/librpc/gen_ndr/ndr_libnet_join.c
+++ b/source3/librpc/gen_ndr/ndr_libnet_join.c
@@ -36,6 +36,7 @@ _PUBLIC_ void ndr_print_libnet_JoinCtx(struct ndr_print *ndr, const char *name,
ndr_print_ads_struct(ndr, "ads", r->in.ads);
ndr->depth--;
ndr_print_uint8(ndr, "debug", r->in.debug);
+ ndr_print_netr_SchannelType(ndr, "secure_channel_type", r->in.secure_channel_type);
ndr->depth--;
}
if (flags & NDR_OUT) {
@@ -95,6 +96,8 @@ _PUBLIC_ void ndr_print_libnet_UnjoinCtx(struct ndr_print *ndr, const char *name
ndr_print_string(ndr, "dns_domain_name", r->out.dns_domain_name);
ndr_print_uint8(ndr, "modified_config", r->out.modified_config);
ndr_print_string(ndr, "error_string", r->out.error_string);
+ ndr_print_uint8(ndr, "disabled_machine_account", r->out.disabled_machine_account);
+ ndr_print_uint8(ndr, "deleted_machine_account", r->out.deleted_machine_account);
ndr_print_WERROR(ndr, "result", r->out.result);
ndr->depth--;
}
diff --git a/source3/librpc/gen_ndr/ndr_libnet_join.h b/source3/librpc/gen_ndr/ndr_libnet_join.h
index 4a5fdf0d50..14c8a863aa 100644
--- a/source3/librpc/gen_ndr/ndr_libnet_join.h
+++ b/source3/librpc/gen_ndr/ndr_libnet_join.h
@@ -6,11 +6,7 @@
#ifndef _HEADER_NDR_libnetjoin
#define _HEADER_NDR_libnetjoin
-#define NDR_LIBNET_JOINCTX (0x00)
-
-#define NDR_LIBNET_UNJOINCTX (0x01)
-
-#define NDR_LIBNETJOIN_CALL_COUNT (2)
+#define NDR_LIBNETJOIN_CALL_COUNT (0)
enum ndr_err_code ndr_push_libnet_JoinCtx(struct ndr_push *ndr, int flags, const struct libnet_JoinCtx *r);
enum ndr_err_code ndr_pull_libnet_JoinCtx(struct ndr_pull *ndr, int flags, struct libnet_JoinCtx *r);
void ndr_print_libnet_JoinCtx(struct ndr_print *ndr, const char *name, int flags, const struct libnet_JoinCtx *r);
diff --git a/source3/librpc/gen_ndr/ndr_lsa.c b/source3/librpc/gen_ndr/ndr_lsa.c
index 84f99749fe..03e1c21e55 100644
--- a/source3/librpc/gen_ndr/ndr_lsa.c
+++ b/source3/librpc/gen_ndr/ndr_lsa.c
@@ -80,12 +80,12 @@ _PUBLIC_ enum ndr_err_code ndr_push_lsa_StringLarge(struct ndr_push *ndr, int nd
if (ndr_flags & NDR_SCALARS) {
NDR_CHECK(ndr_push_align(ndr, 4));
NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, 2 * strlen_m(r->string)));
- NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, 2 * (strlen_m(r->string) + 1)));
+ NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, 2 * strlen_m_term(r->string)));
NDR_CHECK(ndr_push_unique_ptr(ndr, r->string));
}
if (ndr_flags & NDR_BUFFERS) {
if (r->string) {
- NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, 2 * (strlen_m(r->string) + 1) / 2));
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, 2 * strlen_m_term(r->string) / 2));
NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, 0));
NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, 2 * strlen_m(r->string) / 2));
NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->string, 2 * strlen_m(r->string) / 2, sizeof(uint16_t), CH_UTF16));
@@ -136,7 +136,7 @@ _PUBLIC_ void ndr_print_lsa_StringLarge(struct ndr_print *ndr, const char *name,
ndr_print_struct(ndr, name, "lsa_StringLarge");
ndr->depth++;
ndr_print_uint16(ndr, "length", (ndr->flags & LIBNDR_PRINT_SET_VALUES)?2 * strlen_m(r->string):r->length);
- ndr_print_uint16(ndr, "size", (ndr->flags & LIBNDR_PRINT_SET_VALUES)?2 * (strlen_m(r->string) + 1):r->size);
+ ndr_print_uint16(ndr, "size", (ndr->flags & LIBNDR_PRINT_SET_VALUES)?2 * strlen_m_term(r->string):r->size);
ndr_print_ptr(ndr, "string", r->string);
ndr->depth++;
if (r->string) {
@@ -221,8 +221,7 @@ _PUBLIC_ void ndr_print_lsa_Strings(struct ndr_print *ndr, const char *name, con
ndr->depth++;
for (cntr_names_1=0;cntr_names_1<r->count;cntr_names_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_names_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_names_1) != -1) {
ndr_print_lsa_String(ndr, "names", &r->names[cntr_names_1]);
free(idx_1);
}
@@ -239,21 +238,14 @@ _PUBLIC_ enum ndr_err_code ndr_push_lsa_AsciiString(struct ndr_push *ndr, int nd
NDR_CHECK(ndr_push_align(ndr, 4));
NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, strlen_m(r->string)));
NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, strlen_m(r->string)));
- {
- uint32_t _flags_save_string = ndr->flags;
- ndr_set_flags(&ndr->flags, LIBNDR_FLAG_STR_NOTERM|LIBNDR_FLAG_STR_ASCII|LIBNDR_FLAG_STR_SIZE4|LIBNDR_FLAG_STR_LEN4);
- NDR_CHECK(ndr_push_unique_ptr(ndr, r->string));
- ndr->flags = _flags_save_string;
- }
+ NDR_CHECK(ndr_push_unique_ptr(ndr, r->string));
}
if (ndr_flags & NDR_BUFFERS) {
- {
- uint32_t _flags_save_string = ndr->flags;
- ndr_set_flags(&ndr->flags, LIBNDR_FLAG_STR_NOTERM|LIBNDR_FLAG_STR_ASCII|LIBNDR_FLAG_STR_SIZE4|LIBNDR_FLAG_STR_LEN4);
- if (r->string) {
- NDR_CHECK(ndr_push_string(ndr, NDR_SCALARS, r->string));
- }
- ndr->flags = _flags_save_string;
+ if (r->string) {
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, strlen_m(r->string)));
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, 0));
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, strlen_m(r->string)));
+ NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->string, strlen_m(r->string), sizeof(uint8_t), CH_DOS));
}
}
return NDR_ERR_SUCCESS;
@@ -267,29 +259,30 @@ _PUBLIC_ enum ndr_err_code ndr_pull_lsa_AsciiString(struct ndr_pull *ndr, int nd
NDR_CHECK(ndr_pull_align(ndr, 4));
NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->length));
NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->size));
- {
- uint32_t _flags_save_string = ndr->flags;
- ndr_set_flags(&ndr->flags, LIBNDR_FLAG_STR_NOTERM|LIBNDR_FLAG_STR_ASCII|LIBNDR_FLAG_STR_SIZE4|LIBNDR_FLAG_STR_LEN4);
- NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_string));
- if (_ptr_string) {
- NDR_PULL_ALLOC(ndr, r->string);
- } else {
- r->string = NULL;
- }
- ndr->flags = _flags_save_string;
+ NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_string));
+ if (_ptr_string) {
+ NDR_PULL_ALLOC(ndr, r->string);
+ } else {
+ r->string = NULL;
}
}
if (ndr_flags & NDR_BUFFERS) {
- {
- uint32_t _flags_save_string = ndr->flags;
- ndr_set_flags(&ndr->flags, LIBNDR_FLAG_STR_NOTERM|LIBNDR_FLAG_STR_ASCII|LIBNDR_FLAG_STR_SIZE4|LIBNDR_FLAG_STR_LEN4);
- if (r->string) {
- _mem_save_string_0 = NDR_PULL_GET_MEM_CTX(ndr);
- NDR_PULL_SET_MEM_CTX(ndr, r->string, 0);
- NDR_CHECK(ndr_pull_string(ndr, NDR_SCALARS, &r->string));
- NDR_PULL_SET_MEM_CTX(ndr, _mem_save_string_0, 0);
+ if (r->string) {
+ _mem_save_string_0 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, r->string, 0);
+ NDR_CHECK(ndr_pull_array_size(ndr, &r->string));
+ NDR_CHECK(ndr_pull_array_length(ndr, &r->string));
+ if (ndr_get_array_length(ndr, &r->string) > ndr_get_array_size(ndr, &r->string)) {
+ return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr, &r->string), ndr_get_array_length(ndr, &r->string));
}
- ndr->flags = _flags_save_string;
+ NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->string, ndr_get_array_length(ndr, &r->string), sizeof(uint8_t), CH_DOS));
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_string_0, 0);
+ }
+ if (r->string) {
+ NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->string, r->size));
+ }
+ if (r->string) {
+ NDR_CHECK(ndr_check_array_length(ndr, (void*)&r->string, r->length));
}
}
return NDR_ERR_SUCCESS;
@@ -310,6 +303,77 @@ _PUBLIC_ void ndr_print_lsa_AsciiString(struct ndr_print *ndr, const char *name,
ndr->depth--;
}
+_PUBLIC_ enum ndr_err_code ndr_push_lsa_AsciiStringLarge(struct ndr_push *ndr, int ndr_flags, const struct lsa_AsciiStringLarge *r)
+{
+ if (ndr_flags & NDR_SCALARS) {
+ NDR_CHECK(ndr_push_align(ndr, 4));
+ NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, strlen_m(r->string)));
+ NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, strlen_m_term(r->string)));
+ NDR_CHECK(ndr_push_unique_ptr(ndr, r->string));
+ }
+ if (ndr_flags & NDR_BUFFERS) {
+ if (r->string) {
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, strlen_m_term(r->string)));
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, 0));
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, strlen_m(r->string)));
+ NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->string, strlen_m(r->string), sizeof(uint8_t), CH_DOS));
+ }
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ enum ndr_err_code ndr_pull_lsa_AsciiStringLarge(struct ndr_pull *ndr, int ndr_flags, struct lsa_AsciiStringLarge *r)
+{
+ uint32_t _ptr_string;
+ TALLOC_CTX *_mem_save_string_0;
+ if (ndr_flags & NDR_SCALARS) {
+ NDR_CHECK(ndr_pull_align(ndr, 4));
+ NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->length));
+ NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->size));
+ NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_string));
+ if (_ptr_string) {
+ NDR_PULL_ALLOC(ndr, r->string);
+ } else {
+ r->string = NULL;
+ }
+ }
+ if (ndr_flags & NDR_BUFFERS) {
+ if (r->string) {
+ _mem_save_string_0 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, r->string, 0);
+ NDR_CHECK(ndr_pull_array_size(ndr, &r->string));
+ NDR_CHECK(ndr_pull_array_length(ndr, &r->string));
+ if (ndr_get_array_length(ndr, &r->string) > ndr_get_array_size(ndr, &r->string)) {
+ return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr, &r->string), ndr_get_array_length(ndr, &r->string));
+ }
+ NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->string, ndr_get_array_length(ndr, &r->string), sizeof(uint8_t), CH_DOS));
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_string_0, 0);
+ }
+ if (r->string) {
+ NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->string, r->size));
+ }
+ if (r->string) {
+ NDR_CHECK(ndr_check_array_length(ndr, (void*)&r->string, r->length));
+ }
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_lsa_AsciiStringLarge(struct ndr_print *ndr, const char *name, const struct lsa_AsciiStringLarge *r)
+{
+ ndr_print_struct(ndr, name, "lsa_AsciiStringLarge");
+ ndr->depth++;
+ ndr_print_uint16(ndr, "length", (ndr->flags & LIBNDR_PRINT_SET_VALUES)?strlen_m(r->string):r->length);
+ ndr_print_uint16(ndr, "size", (ndr->flags & LIBNDR_PRINT_SET_VALUES)?strlen_m_term(r->string):r->size);
+ ndr_print_ptr(ndr, "string", r->string);
+ ndr->depth++;
+ if (r->string) {
+ ndr_print_string(ndr, "string", r->string);
+ }
+ ndr->depth--;
+ ndr->depth--;
+}
+
static enum ndr_err_code ndr_push_lsa_LUID(struct ndr_push *ndr, int ndr_flags, const struct lsa_LUID *r)
{
if (ndr_flags & NDR_SCALARS) {
@@ -453,8 +517,7 @@ _PUBLIC_ void ndr_print_lsa_PrivArray(struct ndr_print *ndr, const char *name, c
ndr->depth++;
for (cntr_privs_1=0;cntr_privs_1<r->count;cntr_privs_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_privs_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_privs_1) != -1) {
ndr_print_lsa_PrivEntry(ndr, "privs", &r->privs[cntr_privs_1]);
free(idx_1);
}
@@ -642,6 +705,39 @@ _PUBLIC_ void ndr_print_lsa_ObjectAttribute(struct ndr_print *ndr, const char *n
ndr->depth--;
}
+_PUBLIC_ enum ndr_err_code ndr_push_lsa_PolicyAccessMask(struct ndr_push *ndr, int ndr_flags, uint32_t r)
+{
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r));
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ enum ndr_err_code ndr_pull_lsa_PolicyAccessMask(struct ndr_pull *ndr, int ndr_flags, uint32_t *r)
+{
+ uint32_t v;
+ NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &v));
+ *r = v;
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_lsa_PolicyAccessMask(struct ndr_print *ndr, const char *name, uint32_t r)
+{
+ ndr_print_uint32(ndr, name, r);
+ ndr->depth++;
+ ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_POLICY_VIEW_LOCAL_INFORMATION", LSA_POLICY_VIEW_LOCAL_INFORMATION, r);
+ ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_POLICY_VIEW_AUDIT_INFORMATION", LSA_POLICY_VIEW_AUDIT_INFORMATION, r);
+ ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_POLICY_GET_PRIVATE_INFORMATION", LSA_POLICY_GET_PRIVATE_INFORMATION, r);
+ ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_POLICY_TRUST_ADMIN", LSA_POLICY_TRUST_ADMIN, r);
+ ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_POLICY_CREATE_ACCOUNT", LSA_POLICY_CREATE_ACCOUNT, r);
+ ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_POLICY_CREATE_SECRET", LSA_POLICY_CREATE_SECRET, r);
+ ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_POLICY_CREATE_PRIVILEGE", LSA_POLICY_CREATE_PRIVILEGE, r);
+ ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_POLICY_SET_DEFAULT_QUOTA_LIMITS", LSA_POLICY_SET_DEFAULT_QUOTA_LIMITS, r);
+ ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_POLICY_SET_AUDIT_REQUIREMENTS", LSA_POLICY_SET_AUDIT_REQUIREMENTS, r);
+ ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_POLICY_AUDIT_LOG_ADMIN", LSA_POLICY_AUDIT_LOG_ADMIN, r);
+ ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_POLICY_SERVER_ADMIN", LSA_POLICY_SERVER_ADMIN, r);
+ ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_POLICY_LOOKUP_NAMES", LSA_POLICY_LOOKUP_NAMES, r);
+ ndr->depth--;
+}
+
static enum ndr_err_code ndr_push_lsa_AuditLogInfo(struct ndr_push *ndr, int ndr_flags, const struct lsa_AuditLogInfo *r)
{
if (ndr_flags & NDR_SCALARS) {
@@ -789,8 +885,7 @@ _PUBLIC_ void ndr_print_lsa_AuditEventsInfo(struct ndr_print *ndr, const char *n
ndr->depth++;
for (cntr_settings_1=0;cntr_settings_1<r->count;cntr_settings_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_settings_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_settings_1) != -1) {
ndr_print_lsa_PolicyAuditPolicy(ndr, "settings", r->settings[cntr_settings_1]);
free(idx_1);
}
@@ -1622,8 +1717,7 @@ _PUBLIC_ void ndr_print_lsa_SidArray(struct ndr_print *ndr, const char *name, co
ndr->depth++;
for (cntr_sids_1=0;cntr_sids_1<r->num_sids;cntr_sids_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_sids_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_sids_1) != -1) {
ndr_print_lsa_SidPtr(ndr, "sids", &r->sids[cntr_sids_1]);
free(idx_1);
}
@@ -1709,8 +1803,7 @@ _PUBLIC_ void ndr_print_lsa_DomainList(struct ndr_print *ndr, const char *name,
ndr->depth++;
for (cntr_domains_1=0;cntr_domains_1<r->count;cntr_domains_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_domains_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_domains_1) != -1) {
ndr_print_lsa_DomainInfo(ndr, "domains", &r->domains[cntr_domains_1]);
free(idx_1);
}
@@ -1862,8 +1955,7 @@ _PUBLIC_ void ndr_print_lsa_TransSidArray(struct ndr_print *ndr, const char *nam
ndr->depth++;
for (cntr_sids_1=0;cntr_sids_1<r->count;cntr_sids_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_sids_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_sids_1) != -1) {
ndr_print_lsa_TranslatedSid(ndr, "sids", &r->sids[cntr_sids_1]);
free(idx_1);
}
@@ -1954,8 +2046,7 @@ _PUBLIC_ void ndr_print_lsa_RefDomainList(struct ndr_print *ndr, const char *nam
ndr->depth++;
for (cntr_domains_1=0;cntr_domains_1<r->count;cntr_domains_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_domains_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_domains_1) != -1) {
ndr_print_lsa_DomainInfo(ndr, "domains", &r->domains[cntr_domains_1]);
free(idx_1);
}
@@ -2112,8 +2203,7 @@ _PUBLIC_ void ndr_print_lsa_TransNameArray(struct ndr_print *ndr, const char *na
ndr->depth++;
for (cntr_names_1=0;cntr_names_1<r->count;cntr_names_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_names_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_names_1) != -1) {
ndr_print_lsa_TranslatedName(ndr, "names", &r->names[cntr_names_1]);
free(idx_1);
}
@@ -2213,8 +2303,7 @@ _PUBLIC_ void ndr_print_lsa_PrivilegeSet(struct ndr_print *ndr, const char *name
ndr->depth++;
for (cntr_set_0=0;cntr_set_0<r->count;cntr_set_0++) {
char *idx_0=NULL;
- asprintf(&idx_0, "[%d]", cntr_set_0);
- if (idx_0) {
+ if (asprintf(&idx_0, "[%d]", cntr_set_0) != -1) {
ndr_print_lsa_LUIDAttribute(ndr, "set", &r->set[cntr_set_0]);
free(idx_0);
}
@@ -3288,6 +3377,9 @@ static enum ndr_err_code ndr_pull_lsa_RightSet(struct ndr_pull *ndr, int ndr_fla
if (ndr_flags & NDR_SCALARS) {
NDR_CHECK(ndr_pull_align(ndr, 4));
NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
+ if (r->count < 0 || r->count > 256) {
+ return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
+ }
NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_names));
if (_ptr_names) {
NDR_PULL_ALLOC(ndr, r->names);
@@ -3332,8 +3424,7 @@ _PUBLIC_ void ndr_print_lsa_RightSet(struct ndr_print *ndr, const char *name, co
ndr->depth++;
for (cntr_names_1=0;cntr_names_1<r->count;cntr_names_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_names_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_names_1) != -1) {
ndr_print_lsa_StringLarge(ndr, "names", &r->names[cntr_names_1]);
free(idx_1);
}
@@ -3419,8 +3510,7 @@ _PUBLIC_ void ndr_print_lsa_DomainListEx(struct ndr_print *ndr, const char *name
ndr->depth++;
for (cntr_domains_1=0;cntr_domains_1<r->count;cntr_domains_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_domains_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_domains_1) != -1) {
ndr_print_lsa_TrustDomainInfoInfoEx(ndr, "domains", &r->domains[cntr_domains_1]);
free(idx_1);
}
@@ -3748,8 +3838,7 @@ _PUBLIC_ void ndr_print_lsa_TransNameArray2(struct ndr_print *ndr, const char *n
ndr->depth++;
for (cntr_names_1=0;cntr_names_1<r->count;cntr_names_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_names_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_names_1) != -1) {
ndr_print_lsa_TranslatedName2(ndr, "names", &r->names[cntr_names_1]);
free(idx_1);
}
@@ -3871,8 +3960,7 @@ _PUBLIC_ void ndr_print_lsa_TransSidArray2(struct ndr_print *ndr, const char *na
ndr->depth++;
for (cntr_sids_1=0;cntr_sids_1<r->count;cntr_sids_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_sids_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_sids_1) != -1) {
ndr_print_lsa_TranslatedSid2(ndr, "sids", &r->sids[cntr_sids_1]);
free(idx_1);
}
@@ -4021,8 +4109,7 @@ _PUBLIC_ void ndr_print_lsa_TransSidArray3(struct ndr_print *ndr, const char *na
ndr->depth++;
for (cntr_sids_1=0;cntr_sids_1<r->count;cntr_sids_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_sids_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_sids_1) != -1) {
ndr_print_lsa_TranslatedSid3(ndr, "sids", &r->sids[cntr_sids_1]);
free(idx_1);
}
@@ -4444,8 +4531,7 @@ _PUBLIC_ void ndr_print_lsa_ForestTrustInformation(struct ndr_print *ndr, const
ndr->depth++;
for (cntr_entries_1=0;cntr_entries_1<r->count;cntr_entries_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_entries_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_entries_1) != -1) {
ndr_print_ptr(ndr, "entries", r->entries[cntr_entries_1]);
ndr->depth++;
if (r->entries[cntr_entries_1]) {
@@ -4936,7 +5022,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_lsa_OpenPolicy(struct ndr_push *ndr, int fla
return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
}
NDR_CHECK(ndr_push_lsa_ObjectAttribute(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.attr));
- NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.access_mask));
+ NDR_CHECK(ndr_push_lsa_PolicyAccessMask(ndr, NDR_SCALARS, r->in.access_mask));
}
if (flags & NDR_OUT) {
if (r->out.handle == NULL) {
@@ -4976,7 +5062,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_lsa_OpenPolicy(struct ndr_pull *ndr, int fla
NDR_PULL_SET_MEM_CTX(ndr, r->in.attr, LIBNDR_FLAG_REF_ALLOC);
NDR_CHECK(ndr_pull_lsa_ObjectAttribute(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.attr));
NDR_PULL_SET_MEM_CTX(ndr, _mem_save_attr_0, LIBNDR_FLAG_REF_ALLOC);
- NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.access_mask));
+ NDR_CHECK(ndr_pull_lsa_PolicyAccessMask(ndr, NDR_SCALARS, &r->in.access_mask));
NDR_PULL_ALLOC(ndr, r->out.handle);
ZERO_STRUCTP(r->out.handle);
}
@@ -5013,7 +5099,7 @@ _PUBLIC_ void ndr_print_lsa_OpenPolicy(struct ndr_print *ndr, const char *name,
ndr->depth++;
ndr_print_lsa_ObjectAttribute(ndr, "attr", r->in.attr);
ndr->depth--;
- ndr_print_uint32(ndr, "access_mask", r->in.access_mask);
+ ndr_print_lsa_PolicyAccessMask(ndr, "access_mask", r->in.access_mask);
ndr->depth--;
}
if (flags & NDR_OUT) {
@@ -5701,9 +5787,12 @@ _PUBLIC_ enum ndr_err_code ndr_push_lsa_LookupNames(struct ndr_push *ndr, int fl
NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->in.count));
}
if (flags & NDR_OUT) {
- NDR_CHECK(ndr_push_unique_ptr(ndr, r->out.domains));
- if (r->out.domains) {
- NDR_CHECK(ndr_push_lsa_RefDomainList(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.domains));
+ if (r->out.domains == NULL) {
+ return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
+ }
+ NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.domains));
+ if (*r->out.domains) {
+ NDR_CHECK(ndr_push_lsa_RefDomainList(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.domains));
}
if (r->out.sids == NULL) {
return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
@@ -5725,6 +5814,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_lsa_LookupNames(struct ndr_pull *ndr, int fl
TALLOC_CTX *_mem_save_handle_0;
TALLOC_CTX *_mem_save_names_0;
TALLOC_CTX *_mem_save_domains_0;
+ TALLOC_CTX *_mem_save_domains_1;
TALLOC_CTX *_mem_save_sids_0;
TALLOC_CTX *_mem_save_count_0;
if (flags & NDR_IN) {
@@ -5767,6 +5857,8 @@ _PUBLIC_ enum ndr_err_code ndr_pull_lsa_LookupNames(struct ndr_pull *ndr, int fl
NDR_PULL_SET_MEM_CTX(ndr, r->in.count, LIBNDR_FLAG_REF_ALLOC);
NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->in.count));
NDR_PULL_SET_MEM_CTX(ndr, _mem_save_count_0, LIBNDR_FLAG_REF_ALLOC);
+ NDR_PULL_ALLOC(ndr, r->out.domains);
+ ZERO_STRUCTP(r->out.domains);
NDR_PULL_ALLOC(ndr, r->out.sids);
*r->out.sids = *r->in.sids;
NDR_PULL_ALLOC(ndr, r->out.count);
@@ -5776,18 +5868,24 @@ _PUBLIC_ enum ndr_err_code ndr_pull_lsa_LookupNames(struct ndr_pull *ndr, int fl
}
}
if (flags & NDR_OUT) {
+ if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
+ NDR_PULL_ALLOC(ndr, r->out.domains);
+ }
+ _mem_save_domains_0 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, r->out.domains, LIBNDR_FLAG_REF_ALLOC);
NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_domains));
if (_ptr_domains) {
- NDR_PULL_ALLOC(ndr, r->out.domains);
+ NDR_PULL_ALLOC(ndr, *r->out.domains);
} else {
- r->out.domains = NULL;
+ *r->out.domains = NULL;
}
- if (r->out.domains) {
- _mem_save_domains_0 = NDR_PULL_GET_MEM_CTX(ndr);
- NDR_PULL_SET_MEM_CTX(ndr, r->out.domains, 0);
- NDR_CHECK(ndr_pull_lsa_RefDomainList(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.domains));
- NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domains_0, 0);
+ if (*r->out.domains) {
+ _mem_save_domains_1 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, *r->out.domains, 0);
+ NDR_CHECK(ndr_pull_lsa_RefDomainList(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.domains));
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domains_1, 0);
}
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domains_0, LIBNDR_FLAG_REF_ALLOC);
if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
NDR_PULL_ALLOC(ndr, r->out.sids);
}
@@ -5827,8 +5925,7 @@ _PUBLIC_ void ndr_print_lsa_LookupNames(struct ndr_print *ndr, const char *name,
ndr->depth++;
for (cntr_names_0=0;cntr_names_0<r->in.num_names;cntr_names_0++) {
char *idx_0=NULL;
- asprintf(&idx_0, "[%d]", cntr_names_0);
- if (idx_0) {
+ if (asprintf(&idx_0, "[%d]", cntr_names_0) != -1) {
ndr_print_lsa_String(ndr, "names", &r->in.names[cntr_names_0]);
free(idx_0);
}
@@ -5850,10 +5947,13 @@ _PUBLIC_ void ndr_print_lsa_LookupNames(struct ndr_print *ndr, const char *name,
ndr->depth++;
ndr_print_ptr(ndr, "domains", r->out.domains);
ndr->depth++;
- if (r->out.domains) {
- ndr_print_lsa_RefDomainList(ndr, "domains", r->out.domains);
+ ndr_print_ptr(ndr, "domains", *r->out.domains);
+ ndr->depth++;
+ if (*r->out.domains) {
+ ndr_print_lsa_RefDomainList(ndr, "domains", *r->out.domains);
}
ndr->depth--;
+ ndr->depth--;
ndr_print_ptr(ndr, "sids", r->out.sids);
ndr->depth++;
ndr_print_lsa_TransSidArray(ndr, "sids", r->out.sids);
@@ -5890,9 +5990,12 @@ _PUBLIC_ enum ndr_err_code ndr_push_lsa_LookupSids(struct ndr_push *ndr, int fla
NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->in.count));
}
if (flags & NDR_OUT) {
- NDR_CHECK(ndr_push_unique_ptr(ndr, r->out.domains));
- if (r->out.domains) {
- NDR_CHECK(ndr_push_lsa_RefDomainList(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.domains));
+ if (r->out.domains == NULL) {
+ return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
+ }
+ NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.domains));
+ if (*r->out.domains) {
+ NDR_CHECK(ndr_push_lsa_RefDomainList(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.domains));
}
if (r->out.names == NULL) {
return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
@@ -5913,6 +6016,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_lsa_LookupSids(struct ndr_pull *ndr, int fla
TALLOC_CTX *_mem_save_handle_0;
TALLOC_CTX *_mem_save_sids_0;
TALLOC_CTX *_mem_save_domains_0;
+ TALLOC_CTX *_mem_save_domains_1;
TALLOC_CTX *_mem_save_names_0;
TALLOC_CTX *_mem_save_count_0;
if (flags & NDR_IN) {
@@ -5947,24 +6051,32 @@ _PUBLIC_ enum ndr_err_code ndr_pull_lsa_LookupSids(struct ndr_pull *ndr, int fla
NDR_PULL_SET_MEM_CTX(ndr, r->in.count, LIBNDR_FLAG_REF_ALLOC);
NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->in.count));
NDR_PULL_SET_MEM_CTX(ndr, _mem_save_count_0, LIBNDR_FLAG_REF_ALLOC);
+ NDR_PULL_ALLOC(ndr, r->out.domains);
+ ZERO_STRUCTP(r->out.domains);
NDR_PULL_ALLOC(ndr, r->out.names);
*r->out.names = *r->in.names;
NDR_PULL_ALLOC(ndr, r->out.count);
*r->out.count = *r->in.count;
}
if (flags & NDR_OUT) {
+ if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
+ NDR_PULL_ALLOC(ndr, r->out.domains);
+ }
+ _mem_save_domains_0 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, r->out.domains, LIBNDR_FLAG_REF_ALLOC);
NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_domains));
if (_ptr_domains) {
- NDR_PULL_ALLOC(ndr, r->out.domains);
+ NDR_PULL_ALLOC(ndr, *r->out.domains);
} else {
- r->out.domains = NULL;
+ *r->out.domains = NULL;
}
- if (r->out.domains) {
- _mem_save_domains_0 = NDR_PULL_GET_MEM_CTX(ndr);
- NDR_PULL_SET_MEM_CTX(ndr, r->out.domains, 0);
- NDR_CHECK(ndr_pull_lsa_RefDomainList(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.domains));
- NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domains_0, 0);
+ if (*r->out.domains) {
+ _mem_save_domains_1 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, *r->out.domains, 0);
+ NDR_CHECK(ndr_pull_lsa_RefDomainList(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.domains));
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domains_1, 0);
}
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domains_0, LIBNDR_FLAG_REF_ALLOC);
if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
NDR_PULL_ALLOC(ndr, r->out.names);
}
@@ -6018,10 +6130,13 @@ _PUBLIC_ void ndr_print_lsa_LookupSids(struct ndr_print *ndr, const char *name,
ndr->depth++;
ndr_print_ptr(ndr, "domains", r->out.domains);
ndr->depth++;
- if (r->out.domains) {
- ndr_print_lsa_RefDomainList(ndr, "domains", r->out.domains);
+ ndr_print_ptr(ndr, "domains", *r->out.domains);
+ ndr->depth++;
+ if (*r->out.domains) {
+ ndr_print_lsa_RefDomainList(ndr, "domains", *r->out.domains);
}
ndr->depth--;
+ ndr->depth--;
ndr_print_ptr(ndr, "names", r->out.names);
ndr->depth++;
ndr_print_lsa_TransNameArray(ndr, "names", r->out.names);
@@ -6224,9 +6339,12 @@ static enum ndr_err_code ndr_push_lsa_EnumPrivsAccount(struct ndr_push *ndr, int
NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.handle));
}
if (flags & NDR_OUT) {
- NDR_CHECK(ndr_push_unique_ptr(ndr, r->out.privs));
- if (r->out.privs) {
- NDR_CHECK(ndr_push_lsa_PrivilegeSet(ndr, NDR_SCALARS, r->out.privs));
+ if (r->out.privs == NULL) {
+ return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
+ }
+ NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.privs));
+ if (*r->out.privs) {
+ NDR_CHECK(ndr_push_lsa_PrivilegeSet(ndr, NDR_SCALARS, *r->out.privs));
}
NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
}
@@ -6238,6 +6356,7 @@ static enum ndr_err_code ndr_pull_lsa_EnumPrivsAccount(struct ndr_pull *ndr, int
uint32_t _ptr_privs;
TALLOC_CTX *_mem_save_handle_0;
TALLOC_CTX *_mem_save_privs_0;
+ TALLOC_CTX *_mem_save_privs_1;
if (flags & NDR_IN) {
ZERO_STRUCT(r->out);
@@ -6248,20 +6367,28 @@ static enum ndr_err_code ndr_pull_lsa_EnumPrivsAccount(struct ndr_pull *ndr, int
NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.handle));
NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
+ NDR_PULL_ALLOC(ndr, r->out.privs);
+ ZERO_STRUCTP(r->out.privs);
}
if (flags & NDR_OUT) {
+ if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
+ NDR_PULL_ALLOC(ndr, r->out.privs);
+ }
+ _mem_save_privs_0 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, r->out.privs, LIBNDR_FLAG_REF_ALLOC);
NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_privs));
if (_ptr_privs) {
- NDR_PULL_ALLOC(ndr, r->out.privs);
+ NDR_PULL_ALLOC(ndr, *r->out.privs);
} else {
- r->out.privs = NULL;
+ *r->out.privs = NULL;
}
- if (r->out.privs) {
- _mem_save_privs_0 = NDR_PULL_GET_MEM_CTX(ndr);
- NDR_PULL_SET_MEM_CTX(ndr, r->out.privs, 0);
- NDR_CHECK(ndr_pull_lsa_PrivilegeSet(ndr, NDR_SCALARS, r->out.privs));
- NDR_PULL_SET_MEM_CTX(ndr, _mem_save_privs_0, 0);
+ if (*r->out.privs) {
+ _mem_save_privs_1 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, *r->out.privs, 0);
+ NDR_CHECK(ndr_pull_lsa_PrivilegeSet(ndr, NDR_SCALARS, *r->out.privs));
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_privs_1, 0);
}
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_privs_0, LIBNDR_FLAG_REF_ALLOC);
NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
}
return NDR_ERR_SUCCESS;
@@ -6288,10 +6415,13 @@ _PUBLIC_ void ndr_print_lsa_EnumPrivsAccount(struct ndr_print *ndr, const char *
ndr->depth++;
ndr_print_ptr(ndr, "privs", r->out.privs);
ndr->depth++;
- if (r->out.privs) {
- ndr_print_lsa_PrivilegeSet(ndr, "privs", r->out.privs);
+ ndr_print_ptr(ndr, "privs", *r->out.privs);
+ ndr->depth++;
+ if (*r->out.privs) {
+ ndr_print_lsa_PrivilegeSet(ndr, "privs", *r->out.privs);
}
ndr->depth--;
+ ndr->depth--;
ndr_print_NTSTATUS(ndr, "result", r->out.result);
ndr->depth--;
}
@@ -8031,7 +8161,7 @@ static enum ndr_err_code ndr_push_lsa_RemoveAccountRights(struct ndr_push *ndr,
return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
}
NDR_CHECK(ndr_push_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sid));
- NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.unknown));
+ NDR_CHECK(ndr_push_uint8(ndr, NDR_SCALARS, r->in.remove_all));
if (r->in.rights == NULL) {
return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
}
@@ -8063,7 +8193,7 @@ static enum ndr_err_code ndr_pull_lsa_RemoveAccountRights(struct ndr_pull *ndr,
NDR_PULL_SET_MEM_CTX(ndr, r->in.sid, LIBNDR_FLAG_REF_ALLOC);
NDR_CHECK(ndr_pull_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sid));
NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sid_0, LIBNDR_FLAG_REF_ALLOC);
- NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.unknown));
+ NDR_CHECK(ndr_pull_uint8(ndr, NDR_SCALARS, &r->in.remove_all));
if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
NDR_PULL_ALLOC(ndr, r->in.rights);
}
@@ -8096,7 +8226,7 @@ _PUBLIC_ void ndr_print_lsa_RemoveAccountRights(struct ndr_print *ndr, const cha
ndr->depth++;
ndr_print_dom_sid2(ndr, "sid", r->in.sid);
ndr->depth--;
- ndr_print_uint32(ndr, "unknown", r->in.unknown);
+ ndr_print_uint8(ndr, "remove_all", r->in.remove_all);
ndr_print_ptr(ndr, "rights", r->in.rights);
ndr->depth++;
ndr_print_lsa_RightSet(ndr, "rights", r->in.rights);
@@ -8427,7 +8557,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_lsa_OpenPolicy2(struct ndr_push *ndr, int fl
return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
}
NDR_CHECK(ndr_push_lsa_ObjectAttribute(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.attr));
- NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.access_mask));
+ NDR_CHECK(ndr_push_lsa_PolicyAccessMask(ndr, NDR_SCALARS, r->in.access_mask));
}
if (flags & NDR_OUT) {
if (r->out.handle == NULL) {
@@ -8473,7 +8603,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_lsa_OpenPolicy2(struct ndr_pull *ndr, int fl
NDR_PULL_SET_MEM_CTX(ndr, r->in.attr, LIBNDR_FLAG_REF_ALLOC);
NDR_CHECK(ndr_pull_lsa_ObjectAttribute(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.attr));
NDR_PULL_SET_MEM_CTX(ndr, _mem_save_attr_0, LIBNDR_FLAG_REF_ALLOC);
- NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.access_mask));
+ NDR_CHECK(ndr_pull_lsa_PolicyAccessMask(ndr, NDR_SCALARS, &r->in.access_mask));
NDR_PULL_ALLOC(ndr, r->out.handle);
ZERO_STRUCTP(r->out.handle);
}
@@ -8510,7 +8640,7 @@ _PUBLIC_ void ndr_print_lsa_OpenPolicy2(struct ndr_print *ndr, const char *name,
ndr->depth++;
ndr_print_lsa_ObjectAttribute(ndr, "attr", r->in.attr);
ndr->depth--;
- ndr_print_uint32(ndr, "access_mask", r->in.access_mask);
+ ndr_print_lsa_PolicyAccessMask(ndr, "access_mask", r->in.access_mask);
ndr->depth--;
}
if (flags & NDR_OUT) {
@@ -9686,9 +9816,12 @@ _PUBLIC_ enum ndr_err_code ndr_push_lsa_LookupSids2(struct ndr_push *ndr, int fl
NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.unknown2));
}
if (flags & NDR_OUT) {
- NDR_CHECK(ndr_push_unique_ptr(ndr, r->out.domains));
- if (r->out.domains) {
- NDR_CHECK(ndr_push_lsa_RefDomainList(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.domains));
+ if (r->out.domains == NULL) {
+ return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
+ }
+ NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.domains));
+ if (*r->out.domains) {
+ NDR_CHECK(ndr_push_lsa_RefDomainList(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.domains));
}
if (r->out.names == NULL) {
return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
@@ -9709,6 +9842,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_lsa_LookupSids2(struct ndr_pull *ndr, int fl
TALLOC_CTX *_mem_save_handle_0;
TALLOC_CTX *_mem_save_sids_0;
TALLOC_CTX *_mem_save_domains_0;
+ TALLOC_CTX *_mem_save_domains_1;
TALLOC_CTX *_mem_save_names_0;
TALLOC_CTX *_mem_save_count_0;
if (flags & NDR_IN) {
@@ -9745,24 +9879,32 @@ _PUBLIC_ enum ndr_err_code ndr_pull_lsa_LookupSids2(struct ndr_pull *ndr, int fl
NDR_PULL_SET_MEM_CTX(ndr, _mem_save_count_0, LIBNDR_FLAG_REF_ALLOC);
NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.unknown1));
NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.unknown2));
+ NDR_PULL_ALLOC(ndr, r->out.domains);
+ ZERO_STRUCTP(r->out.domains);
NDR_PULL_ALLOC(ndr, r->out.names);
*r->out.names = *r->in.names;
NDR_PULL_ALLOC(ndr, r->out.count);
*r->out.count = *r->in.count;
}
if (flags & NDR_OUT) {
+ if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
+ NDR_PULL_ALLOC(ndr, r->out.domains);
+ }
+ _mem_save_domains_0 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, r->out.domains, LIBNDR_FLAG_REF_ALLOC);
NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_domains));
if (_ptr_domains) {
- NDR_PULL_ALLOC(ndr, r->out.domains);
+ NDR_PULL_ALLOC(ndr, *r->out.domains);
} else {
- r->out.domains = NULL;
+ *r->out.domains = NULL;
}
- if (r->out.domains) {
- _mem_save_domains_0 = NDR_PULL_GET_MEM_CTX(ndr);
- NDR_PULL_SET_MEM_CTX(ndr, r->out.domains, 0);
- NDR_CHECK(ndr_pull_lsa_RefDomainList(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.domains));
- NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domains_0, 0);
+ if (*r->out.domains) {
+ _mem_save_domains_1 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, *r->out.domains, 0);
+ NDR_CHECK(ndr_pull_lsa_RefDomainList(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.domains));
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domains_1, 0);
}
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domains_0, LIBNDR_FLAG_REF_ALLOC);
if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
NDR_PULL_ALLOC(ndr, r->out.names);
}
@@ -9818,10 +9960,13 @@ _PUBLIC_ void ndr_print_lsa_LookupSids2(struct ndr_print *ndr, const char *name,
ndr->depth++;
ndr_print_ptr(ndr, "domains", r->out.domains);
ndr->depth++;
- if (r->out.domains) {
- ndr_print_lsa_RefDomainList(ndr, "domains", r->out.domains);
+ ndr_print_ptr(ndr, "domains", *r->out.domains);
+ ndr->depth++;
+ if (*r->out.domains) {
+ ndr_print_lsa_RefDomainList(ndr, "domains", *r->out.domains);
}
ndr->depth--;
+ ndr->depth--;
ndr_print_ptr(ndr, "names", r->out.names);
ndr->depth++;
ndr_print_lsa_TransNameArray2(ndr, "names", r->out.names);
@@ -9865,9 +10010,12 @@ _PUBLIC_ enum ndr_err_code ndr_push_lsa_LookupNames2(struct ndr_push *ndr, int f
NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.unknown2));
}
if (flags & NDR_OUT) {
- NDR_CHECK(ndr_push_unique_ptr(ndr, r->out.domains));
- if (r->out.domains) {
- NDR_CHECK(ndr_push_lsa_RefDomainList(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.domains));
+ if (r->out.domains == NULL) {
+ return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
+ }
+ NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.domains));
+ if (*r->out.domains) {
+ NDR_CHECK(ndr_push_lsa_RefDomainList(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.domains));
}
if (r->out.sids == NULL) {
return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
@@ -9889,6 +10037,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_lsa_LookupNames2(struct ndr_pull *ndr, int f
TALLOC_CTX *_mem_save_handle_0;
TALLOC_CTX *_mem_save_names_0;
TALLOC_CTX *_mem_save_domains_0;
+ TALLOC_CTX *_mem_save_domains_1;
TALLOC_CTX *_mem_save_sids_0;
TALLOC_CTX *_mem_save_count_0;
if (flags & NDR_IN) {
@@ -9933,6 +10082,8 @@ _PUBLIC_ enum ndr_err_code ndr_pull_lsa_LookupNames2(struct ndr_pull *ndr, int f
NDR_PULL_SET_MEM_CTX(ndr, _mem_save_count_0, LIBNDR_FLAG_REF_ALLOC);
NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.unknown1));
NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.unknown2));
+ NDR_PULL_ALLOC(ndr, r->out.domains);
+ ZERO_STRUCTP(r->out.domains);
NDR_PULL_ALLOC(ndr, r->out.sids);
*r->out.sids = *r->in.sids;
NDR_PULL_ALLOC(ndr, r->out.count);
@@ -9942,18 +10093,24 @@ _PUBLIC_ enum ndr_err_code ndr_pull_lsa_LookupNames2(struct ndr_pull *ndr, int f
}
}
if (flags & NDR_OUT) {
+ if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
+ NDR_PULL_ALLOC(ndr, r->out.domains);
+ }
+ _mem_save_domains_0 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, r->out.domains, LIBNDR_FLAG_REF_ALLOC);
NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_domains));
if (_ptr_domains) {
- NDR_PULL_ALLOC(ndr, r->out.domains);
+ NDR_PULL_ALLOC(ndr, *r->out.domains);
} else {
- r->out.domains = NULL;
+ *r->out.domains = NULL;
}
- if (r->out.domains) {
- _mem_save_domains_0 = NDR_PULL_GET_MEM_CTX(ndr);
- NDR_PULL_SET_MEM_CTX(ndr, r->out.domains, 0);
- NDR_CHECK(ndr_pull_lsa_RefDomainList(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.domains));
- NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domains_0, 0);
+ if (*r->out.domains) {
+ _mem_save_domains_1 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, *r->out.domains, 0);
+ NDR_CHECK(ndr_pull_lsa_RefDomainList(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.domains));
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domains_1, 0);
}
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domains_0, LIBNDR_FLAG_REF_ALLOC);
if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
NDR_PULL_ALLOC(ndr, r->out.sids);
}
@@ -9993,8 +10150,7 @@ _PUBLIC_ void ndr_print_lsa_LookupNames2(struct ndr_print *ndr, const char *name
ndr->depth++;
for (cntr_names_0=0;cntr_names_0<r->in.num_names;cntr_names_0++) {
char *idx_0=NULL;
- asprintf(&idx_0, "[%d]", cntr_names_0);
- if (idx_0) {
+ if (asprintf(&idx_0, "[%d]", cntr_names_0) != -1) {
ndr_print_lsa_String(ndr, "names", &r->in.names[cntr_names_0]);
free(idx_0);
}
@@ -10018,10 +10174,13 @@ _PUBLIC_ void ndr_print_lsa_LookupNames2(struct ndr_print *ndr, const char *name
ndr->depth++;
ndr_print_ptr(ndr, "domains", r->out.domains);
ndr->depth++;
- if (r->out.domains) {
- ndr_print_lsa_RefDomainList(ndr, "domains", r->out.domains);
+ ndr_print_ptr(ndr, "domains", *r->out.domains);
+ ndr->depth++;
+ if (*r->out.domains) {
+ ndr_print_lsa_RefDomainList(ndr, "domains", *r->out.domains);
}
ndr->depth--;
+ ndr->depth--;
ndr_print_ptr(ndr, "sids", r->out.sids);
ndr->depth++;
ndr_print_lsa_TransSidArray2(ndr, "sids", r->out.sids);
@@ -10434,9 +10593,12 @@ _PUBLIC_ enum ndr_err_code ndr_push_lsa_LookupNames3(struct ndr_push *ndr, int f
NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.unknown2));
}
if (flags & NDR_OUT) {
- NDR_CHECK(ndr_push_unique_ptr(ndr, r->out.domains));
- if (r->out.domains) {
- NDR_CHECK(ndr_push_lsa_RefDomainList(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.domains));
+ if (r->out.domains == NULL) {
+ return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
+ }
+ NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.domains));
+ if (*r->out.domains) {
+ NDR_CHECK(ndr_push_lsa_RefDomainList(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.domains));
}
if (r->out.sids == NULL) {
return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
@@ -10458,6 +10620,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_lsa_LookupNames3(struct ndr_pull *ndr, int f
TALLOC_CTX *_mem_save_handle_0;
TALLOC_CTX *_mem_save_names_0;
TALLOC_CTX *_mem_save_domains_0;
+ TALLOC_CTX *_mem_save_domains_1;
TALLOC_CTX *_mem_save_sids_0;
TALLOC_CTX *_mem_save_count_0;
if (flags & NDR_IN) {
@@ -10502,6 +10665,8 @@ _PUBLIC_ enum ndr_err_code ndr_pull_lsa_LookupNames3(struct ndr_pull *ndr, int f
NDR_PULL_SET_MEM_CTX(ndr, _mem_save_count_0, LIBNDR_FLAG_REF_ALLOC);
NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.unknown1));
NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.unknown2));
+ NDR_PULL_ALLOC(ndr, r->out.domains);
+ ZERO_STRUCTP(r->out.domains);
NDR_PULL_ALLOC(ndr, r->out.sids);
*r->out.sids = *r->in.sids;
NDR_PULL_ALLOC(ndr, r->out.count);
@@ -10511,18 +10676,24 @@ _PUBLIC_ enum ndr_err_code ndr_pull_lsa_LookupNames3(struct ndr_pull *ndr, int f
}
}
if (flags & NDR_OUT) {
+ if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
+ NDR_PULL_ALLOC(ndr, r->out.domains);
+ }
+ _mem_save_domains_0 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, r->out.domains, LIBNDR_FLAG_REF_ALLOC);
NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_domains));
if (_ptr_domains) {
- NDR_PULL_ALLOC(ndr, r->out.domains);
+ NDR_PULL_ALLOC(ndr, *r->out.domains);
} else {
- r->out.domains = NULL;
+ *r->out.domains = NULL;
}
- if (r->out.domains) {
- _mem_save_domains_0 = NDR_PULL_GET_MEM_CTX(ndr);
- NDR_PULL_SET_MEM_CTX(ndr, r->out.domains, 0);
- NDR_CHECK(ndr_pull_lsa_RefDomainList(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.domains));
- NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domains_0, 0);
+ if (*r->out.domains) {
+ _mem_save_domains_1 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, *r->out.domains, 0);
+ NDR_CHECK(ndr_pull_lsa_RefDomainList(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.domains));
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domains_1, 0);
}
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domains_0, LIBNDR_FLAG_REF_ALLOC);
if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
NDR_PULL_ALLOC(ndr, r->out.sids);
}
@@ -10562,8 +10733,7 @@ _PUBLIC_ void ndr_print_lsa_LookupNames3(struct ndr_print *ndr, const char *name
ndr->depth++;
for (cntr_names_0=0;cntr_names_0<r->in.num_names;cntr_names_0++) {
char *idx_0=NULL;
- asprintf(&idx_0, "[%d]", cntr_names_0);
- if (idx_0) {
+ if (asprintf(&idx_0, "[%d]", cntr_names_0) != -1) {
ndr_print_lsa_String(ndr, "names", &r->in.names[cntr_names_0]);
free(idx_0);
}
@@ -10587,10 +10757,13 @@ _PUBLIC_ void ndr_print_lsa_LookupNames3(struct ndr_print *ndr, const char *name
ndr->depth++;
ndr_print_ptr(ndr, "domains", r->out.domains);
ndr->depth++;
- if (r->out.domains) {
- ndr_print_lsa_RefDomainList(ndr, "domains", r->out.domains);
+ ndr_print_ptr(ndr, "domains", *r->out.domains);
+ ndr->depth++;
+ if (*r->out.domains) {
+ ndr_print_lsa_RefDomainList(ndr, "domains", *r->out.domains);
}
ndr->depth--;
+ ndr->depth--;
ndr_print_ptr(ndr, "sids", r->out.sids);
ndr->depth++;
ndr_print_lsa_TransSidArray3(ndr, "sids", r->out.sids);
@@ -10988,9 +11161,12 @@ _PUBLIC_ enum ndr_err_code ndr_push_lsa_LookupSids3(struct ndr_push *ndr, int fl
NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.unknown2));
}
if (flags & NDR_OUT) {
- NDR_CHECK(ndr_push_unique_ptr(ndr, r->out.domains));
- if (r->out.domains) {
- NDR_CHECK(ndr_push_lsa_RefDomainList(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.domains));
+ if (r->out.domains == NULL) {
+ return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
+ }
+ NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.domains));
+ if (*r->out.domains) {
+ NDR_CHECK(ndr_push_lsa_RefDomainList(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.domains));
}
if (r->out.names == NULL) {
return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
@@ -11010,6 +11186,7 @@ _PUBLIC_ enum ndr_err_code ndr_pull_lsa_LookupSids3(struct ndr_pull *ndr, int fl
uint32_t _ptr_domains;
TALLOC_CTX *_mem_save_sids_0;
TALLOC_CTX *_mem_save_domains_0;
+ TALLOC_CTX *_mem_save_domains_1;
TALLOC_CTX *_mem_save_names_0;
TALLOC_CTX *_mem_save_count_0;
if (flags & NDR_IN) {
@@ -11039,24 +11216,32 @@ _PUBLIC_ enum ndr_err_code ndr_pull_lsa_LookupSids3(struct ndr_pull *ndr, int fl
NDR_PULL_SET_MEM_CTX(ndr, _mem_save_count_0, LIBNDR_FLAG_REF_ALLOC);
NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.unknown1));
NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.unknown2));
+ NDR_PULL_ALLOC(ndr, r->out.domains);
+ ZERO_STRUCTP(r->out.domains);
NDR_PULL_ALLOC(ndr, r->out.names);
*r->out.names = *r->in.names;
NDR_PULL_ALLOC(ndr, r->out.count);
*r->out.count = *r->in.count;
}
if (flags & NDR_OUT) {
+ if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
+ NDR_PULL_ALLOC(ndr, r->out.domains);
+ }
+ _mem_save_domains_0 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, r->out.domains, LIBNDR_FLAG_REF_ALLOC);
NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_domains));
if (_ptr_domains) {
- NDR_PULL_ALLOC(ndr, r->out.domains);
+ NDR_PULL_ALLOC(ndr, *r->out.domains);
} else {
- r->out.domains = NULL;
+ *r->out.domains = NULL;
}
- if (r->out.domains) {
- _mem_save_domains_0 = NDR_PULL_GET_MEM_CTX(ndr);
- NDR_PULL_SET_MEM_CTX(ndr, r->out.domains, 0);
- NDR_CHECK(ndr_pull_lsa_RefDomainList(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.domains));
- NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domains_0, 0);
+ if (*r->out.domains) {
+ _mem_save_domains_1 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, *r->out.domains, 0);
+ NDR_CHECK(ndr_pull_lsa_RefDomainList(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.domains));
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domains_1, 0);
}
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domains_0, LIBNDR_FLAG_REF_ALLOC);
if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
NDR_PULL_ALLOC(ndr, r->out.names);
}
@@ -11108,10 +11293,13 @@ _PUBLIC_ void ndr_print_lsa_LookupSids3(struct ndr_print *ndr, const char *name,
ndr->depth++;
ndr_print_ptr(ndr, "domains", r->out.domains);
ndr->depth++;
- if (r->out.domains) {
- ndr_print_lsa_RefDomainList(ndr, "domains", r->out.domains);
+ ndr_print_ptr(ndr, "domains", *r->out.domains);
+ ndr->depth++;
+ if (*r->out.domains) {
+ ndr_print_lsa_RefDomainList(ndr, "domains", *r->out.domains);
}
ndr->depth--;
+ ndr->depth--;
ndr_print_ptr(ndr, "names", r->out.names);
ndr->depth++;
ndr_print_lsa_TransNameArray2(ndr, "names", r->out.names);
@@ -11151,9 +11339,12 @@ static enum ndr_err_code ndr_push_lsa_LookupNames4(struct ndr_push *ndr, int fla
NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.unknown2));
}
if (flags & NDR_OUT) {
- NDR_CHECK(ndr_push_unique_ptr(ndr, r->out.domains));
- if (r->out.domains) {
- NDR_CHECK(ndr_push_lsa_RefDomainList(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.domains));
+ if (r->out.domains == NULL) {
+ return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
+ }
+ NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.domains));
+ if (*r->out.domains) {
+ NDR_CHECK(ndr_push_lsa_RefDomainList(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.domains));
}
if (r->out.sids == NULL) {
return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
@@ -11174,6 +11365,7 @@ static enum ndr_err_code ndr_pull_lsa_LookupNames4(struct ndr_pull *ndr, int fla
uint32_t _ptr_domains;
TALLOC_CTX *_mem_save_names_0;
TALLOC_CTX *_mem_save_domains_0;
+ TALLOC_CTX *_mem_save_domains_1;
TALLOC_CTX *_mem_save_sids_0;
TALLOC_CTX *_mem_save_count_0;
if (flags & NDR_IN) {
@@ -11211,6 +11403,8 @@ static enum ndr_err_code ndr_pull_lsa_LookupNames4(struct ndr_pull *ndr, int fla
NDR_PULL_SET_MEM_CTX(ndr, _mem_save_count_0, LIBNDR_FLAG_REF_ALLOC);
NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.unknown1));
NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.unknown2));
+ NDR_PULL_ALLOC(ndr, r->out.domains);
+ ZERO_STRUCTP(r->out.domains);
NDR_PULL_ALLOC(ndr, r->out.sids);
*r->out.sids = *r->in.sids;
NDR_PULL_ALLOC(ndr, r->out.count);
@@ -11220,18 +11414,24 @@ static enum ndr_err_code ndr_pull_lsa_LookupNames4(struct ndr_pull *ndr, int fla
}
}
if (flags & NDR_OUT) {
+ if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
+ NDR_PULL_ALLOC(ndr, r->out.domains);
+ }
+ _mem_save_domains_0 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, r->out.domains, LIBNDR_FLAG_REF_ALLOC);
NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_domains));
if (_ptr_domains) {
- NDR_PULL_ALLOC(ndr, r->out.domains);
+ NDR_PULL_ALLOC(ndr, *r->out.domains);
} else {
- r->out.domains = NULL;
+ *r->out.domains = NULL;
}
- if (r->out.domains) {
- _mem_save_domains_0 = NDR_PULL_GET_MEM_CTX(ndr);
- NDR_PULL_SET_MEM_CTX(ndr, r->out.domains, 0);
- NDR_CHECK(ndr_pull_lsa_RefDomainList(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.domains));
- NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domains_0, 0);
+ if (*r->out.domains) {
+ _mem_save_domains_1 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, *r->out.domains, 0);
+ NDR_CHECK(ndr_pull_lsa_RefDomainList(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.domains));
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domains_1, 0);
}
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domains_0, LIBNDR_FLAG_REF_ALLOC);
if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
NDR_PULL_ALLOC(ndr, r->out.sids);
}
@@ -11267,8 +11467,7 @@ _PUBLIC_ void ndr_print_lsa_LookupNames4(struct ndr_print *ndr, const char *name
ndr->depth++;
for (cntr_names_0=0;cntr_names_0<r->in.num_names;cntr_names_0++) {
char *idx_0=NULL;
- asprintf(&idx_0, "[%d]", cntr_names_0);
- if (idx_0) {
+ if (asprintf(&idx_0, "[%d]", cntr_names_0) != -1) {
ndr_print_lsa_String(ndr, "names", &r->in.names[cntr_names_0]);
free(idx_0);
}
@@ -11292,10 +11491,13 @@ _PUBLIC_ void ndr_print_lsa_LookupNames4(struct ndr_print *ndr, const char *name
ndr->depth++;
ndr_print_ptr(ndr, "domains", r->out.domains);
ndr->depth++;
- if (r->out.domains) {
- ndr_print_lsa_RefDomainList(ndr, "domains", r->out.domains);
+ ndr_print_ptr(ndr, "domains", *r->out.domains);
+ ndr->depth++;
+ if (*r->out.domains) {
+ ndr_print_lsa_RefDomainList(ndr, "domains", *r->out.domains);
}
ndr->depth--;
+ ndr->depth--;
ndr_print_ptr(ndr, "sids", r->out.sids);
ndr->depth++;
ndr_print_lsa_TransSidArray3(ndr, "sids", r->out.sids);
diff --git a/source3/librpc/gen_ndr/ndr_lsa.h b/source3/librpc/gen_ndr/ndr_lsa.h
index 76add459c2..a96f2d41b9 100644
--- a/source3/librpc/gen_ndr/ndr_lsa.h
+++ b/source3/librpc/gen_ndr/ndr_lsa.h
@@ -188,11 +188,17 @@ void ndr_print_lsa_Strings(struct ndr_print *ndr, const char *name, const struct
enum ndr_err_code ndr_push_lsa_AsciiString(struct ndr_push *ndr, int ndr_flags, const struct lsa_AsciiString *r);
enum ndr_err_code ndr_pull_lsa_AsciiString(struct ndr_pull *ndr, int ndr_flags, struct lsa_AsciiString *r);
void ndr_print_lsa_AsciiString(struct ndr_print *ndr, const char *name, const struct lsa_AsciiString *r);
+enum ndr_err_code ndr_push_lsa_AsciiStringLarge(struct ndr_push *ndr, int ndr_flags, const struct lsa_AsciiStringLarge *r);
+enum ndr_err_code ndr_pull_lsa_AsciiStringLarge(struct ndr_pull *ndr, int ndr_flags, struct lsa_AsciiStringLarge *r);
+void ndr_print_lsa_AsciiStringLarge(struct ndr_print *ndr, const char *name, const struct lsa_AsciiStringLarge *r);
void ndr_print_lsa_LUID(struct ndr_print *ndr, const char *name, const struct lsa_LUID *r);
void ndr_print_lsa_PrivEntry(struct ndr_print *ndr, const char *name, const struct lsa_PrivEntry *r);
void ndr_print_lsa_PrivArray(struct ndr_print *ndr, const char *name, const struct lsa_PrivArray *r);
void ndr_print_lsa_QosInfo(struct ndr_print *ndr, const char *name, const struct lsa_QosInfo *r);
void ndr_print_lsa_ObjectAttribute(struct ndr_print *ndr, const char *name, const struct lsa_ObjectAttribute *r);
+enum ndr_err_code ndr_push_lsa_PolicyAccessMask(struct ndr_push *ndr, int ndr_flags, uint32_t r);
+enum ndr_err_code ndr_pull_lsa_PolicyAccessMask(struct ndr_pull *ndr, int ndr_flags, uint32_t *r);
+void ndr_print_lsa_PolicyAccessMask(struct ndr_print *ndr, const char *name, uint32_t r);
void ndr_print_lsa_AuditLogInfo(struct ndr_print *ndr, const char *name, const struct lsa_AuditLogInfo *r);
void ndr_print_lsa_PolicyAuditPolicy(struct ndr_print *ndr, const char *name, enum lsa_PolicyAuditPolicy r);
void ndr_print_lsa_AuditEventsInfo(struct ndr_print *ndr, const char *name, const struct lsa_AuditEventsInfo *r);
diff --git a/source3/librpc/gen_ndr/ndr_messaging.c b/source3/librpc/gen_ndr/ndr_messaging.c
index 413421f770..db886316f1 100644
--- a/source3/librpc/gen_ndr/ndr_messaging.c
+++ b/source3/librpc/gen_ndr/ndr_messaging.c
@@ -103,8 +103,7 @@ _PUBLIC_ void ndr_print_messaging_array(struct ndr_print *ndr, const char *name,
ndr->depth++;
for (cntr_messages_0=0;cntr_messages_0<r->num_messages;cntr_messages_0++) {
char *idx_0=NULL;
- asprintf(&idx_0, "[%d]", cntr_messages_0);
- if (idx_0) {
+ if (asprintf(&idx_0, "[%d]", cntr_messages_0) != -1) {
ndr_print_messaging_rec(ndr, "messages", &r->messages[cntr_messages_0]);
free(idx_0);
}
diff --git a/source3/librpc/gen_ndr/ndr_netlogon.c b/source3/librpc/gen_ndr/ndr_netlogon.c
index b12a347ded..4c46fb0735 100644
--- a/source3/librpc/gen_ndr/ndr_netlogon.c
+++ b/source3/librpc/gen_ndr/ndr_netlogon.c
@@ -315,8 +315,7 @@ _PUBLIC_ void ndr_print_netr_AcctLockStr(struct ndr_print *ndr, const char *name
ndr->depth++;
for (cntr_bindata_1=0;cntr_bindata_1<r->length / 2;cntr_bindata_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_bindata_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_bindata_1) != -1) {
ndr_print_uint16(ndr, "bindata", r->bindata[cntr_bindata_1]);
free(idx_1);
}
@@ -1111,8 +1110,7 @@ _PUBLIC_ void ndr_print_netr_SamBaseInfo(struct ndr_print *ndr, const char *name
ndr->depth++;
for (cntr_unknown_0=0;cntr_unknown_0<7;cntr_unknown_0++) {
char *idx_0=NULL;
- asprintf(&idx_0, "[%d]", cntr_unknown_0);
- if (idx_0) {
+ if (asprintf(&idx_0, "[%d]", cntr_unknown_0) != -1) {
ndr_print_uint32(ndr, "unknown", r->unknown[cntr_unknown_0]);
free(idx_0);
}
@@ -1287,8 +1285,7 @@ _PUBLIC_ void ndr_print_netr_SamInfo3(struct ndr_print *ndr, const char *name, c
ndr->depth++;
for (cntr_sids_1=0;cntr_sids_1<r->sidcount;cntr_sids_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_sids_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_sids_1) != -1) {
ndr_print_netr_SidAttr(ndr, "sids", &r->sids[cntr_sids_1]);
free(idx_1);
}
@@ -1396,8 +1393,7 @@ _PUBLIC_ void ndr_print_netr_SamInfo6(struct ndr_print *ndr, const char *name, c
ndr->depth++;
for (cntr_sids_1=0;cntr_sids_1<r->sidcount;cntr_sids_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_sids_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_sids_1) != -1) {
ndr_print_netr_SidAttr(ndr, "sids", &r->sids[cntr_sids_1]);
free(idx_1);
}
@@ -1411,8 +1407,7 @@ _PUBLIC_ void ndr_print_netr_SamInfo6(struct ndr_print *ndr, const char *name, c
ndr->depth++;
for (cntr_unknown4_0=0;cntr_unknown4_0<20;cntr_unknown4_0++) {
char *idx_0=NULL;
- asprintf(&idx_0, "[%d]", cntr_unknown4_0);
- if (idx_0) {
+ if (asprintf(&idx_0, "[%d]", cntr_unknown4_0) != -1) {
ndr_print_uint32(ndr, "unknown4", r->unknown4[cntr_unknown4_0]);
free(idx_0);
}
@@ -1558,8 +1553,7 @@ _PUBLIC_ void ndr_print_netr_PacInfo(struct ndr_print *ndr, const char *name, co
ndr->depth++;
for (cntr_expansionroom_0=0;cntr_expansionroom_0<10;cntr_expansionroom_0++) {
char *idx_0=NULL;
- asprintf(&idx_0, "[%d]", cntr_expansionroom_0);
- if (idx_0) {
+ if (asprintf(&idx_0, "[%d]", cntr_expansionroom_0) != -1) {
ndr_print_uint32(ndr, "expansionroom", r->expansionroom[cntr_expansionroom_0]);
free(idx_0);
}
@@ -2810,8 +2804,7 @@ _PUBLIC_ void ndr_print_netr_DELTA_GROUP_MEMBER(struct ndr_print *ndr, const cha
ndr->depth++;
for (cntr_rids_1=0;cntr_rids_1<r->num_rids;cntr_rids_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_rids_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_rids_1) != -1) {
ndr_print_uint32(ndr, "rids", r->rids[cntr_rids_1]);
free(idx_1);
}
@@ -2826,8 +2819,7 @@ _PUBLIC_ void ndr_print_netr_DELTA_GROUP_MEMBER(struct ndr_print *ndr, const cha
ndr->depth++;
for (cntr_attribs_1=0;cntr_attribs_1<r->num_rids;cntr_attribs_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_attribs_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_attribs_1) != -1) {
ndr_print_uint32(ndr, "attribs", r->attribs[cntr_attribs_1]);
free(idx_1);
}
@@ -3143,8 +3135,7 @@ _PUBLIC_ void ndr_print_netr_DELTA_POLICY(struct ndr_print *ndr, const char *nam
ndr->depth++;
for (cntr_eventauditoptions_1=0;cntr_eventauditoptions_1<r->maxauditeventcount + 1;cntr_eventauditoptions_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_eventauditoptions_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_eventauditoptions_1) != -1) {
ndr_print_uint32(ndr, "eventauditoptions", r->eventauditoptions[cntr_eventauditoptions_1]);
free(idx_1);
}
@@ -3285,8 +3276,7 @@ _PUBLIC_ void ndr_print_netr_DELTA_TRUSTED_DOMAIN(struct ndr_print *ndr, const c
ndr->depth++;
for (cntr_controller_names_1=0;cntr_controller_names_1<r->num_controllers;cntr_controller_names_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_controller_names_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_controller_names_1) != -1) {
ndr_print_lsa_String(ndr, "controller_names", &r->controller_names[cntr_controller_names_1]);
free(idx_1);
}
@@ -3484,8 +3474,7 @@ _PUBLIC_ void ndr_print_netr_DELTA_ACCOUNT(struct ndr_print *ndr, const char *na
ndr->depth++;
for (cntr_privilege_attrib_1=0;cntr_privilege_attrib_1<r->privilege_entries;cntr_privilege_attrib_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_privilege_attrib_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_privilege_attrib_1) != -1) {
ndr_print_uint32(ndr, "privilege_attrib", r->privilege_attrib[cntr_privilege_attrib_1]);
free(idx_1);
}
@@ -3500,8 +3489,7 @@ _PUBLIC_ void ndr_print_netr_DELTA_ACCOUNT(struct ndr_print *ndr, const char *na
ndr->depth++;
for (cntr_privilege_name_1=0;cntr_privilege_name_1<r->privilege_entries;cntr_privilege_name_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_privilege_name_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_privilege_name_1) != -1) {
ndr_print_lsa_String(ndr, "privilege_name", &r->privilege_name[cntr_privilege_name_1]);
free(idx_1);
}
@@ -5291,8 +5279,7 @@ _PUBLIC_ void ndr_print_netr_DELTA_ENUM_ARRAY(struct ndr_print *ndr, const char
ndr->depth++;
for (cntr_delta_enum_1=0;cntr_delta_enum_1<r->num_deltas;cntr_delta_enum_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_delta_enum_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_delta_enum_1) != -1) {
ndr_print_netr_DELTA_ENUM(ndr, "delta_enum", &r->delta_enum[cntr_delta_enum_1]);
free(idx_1);
}
@@ -5714,6 +5701,7 @@ _PUBLIC_ void ndr_print_netr_LogonControlCode(struct ndr_print *ndr, const char
const char *val = NULL;
switch (r) {
+ case NETLOGON_CONTROL_SYNC: val = "NETLOGON_CONTROL_SYNC"; break;
case NETLOGON_CONTROL_REDISCOVER: val = "NETLOGON_CONTROL_REDISCOVER"; break;
case NETLOGON_CONTROL_TC_QUERY: val = "NETLOGON_CONTROL_TC_QUERY"; break;
case NETLOGON_CONTROL_TRANSPORT_NOTIFY: val = "NETLOGON_CONTROL_TRANSPORT_NOTIFY"; break;
@@ -6428,8 +6416,7 @@ _PUBLIC_ void ndr_print_netr_BinaryString(struct ndr_print *ndr, const char *nam
ndr->depth++;
for (cntr_data_1=0;cntr_data_1<r->length / 2;cntr_data_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_data_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_data_1) != -1) {
ndr_print_uint16(ndr, "data", r->data[cntr_data_1]);
free(idx_1);
}
@@ -6702,8 +6689,7 @@ _PUBLIC_ void ndr_print_netr_DomainQuery1(struct ndr_print *ndr, const char *nam
ndr->depth++;
for (cntr_unknown7_0=0;cntr_unknown7_0<4;cntr_unknown7_0++) {
char *idx_0=NULL;
- asprintf(&idx_0, "[%d]", cntr_unknown7_0);
- if (idx_0) {
+ if (asprintf(&idx_0, "[%d]", cntr_unknown7_0) != -1) {
ndr_print_uint32(ndr, "unknown7", r->unknown7[cntr_unknown7_0]);
free(idx_0);
}
@@ -6940,8 +6926,7 @@ _PUBLIC_ void ndr_print_netr_DomainTrustInfo(struct ndr_print *ndr, const char *
ndr->depth++;
for (cntr_unknown1_0=0;cntr_unknown1_0<4;cntr_unknown1_0++) {
char *idx_0=NULL;
- asprintf(&idx_0, "[%d]", cntr_unknown1_0);
- if (idx_0) {
+ if (asprintf(&idx_0, "[%d]", cntr_unknown1_0) != -1) {
ndr_print_netr_BinaryString(ndr, "unknown1", &r->unknown1[cntr_unknown1_0]);
free(idx_0);
}
@@ -6951,8 +6936,7 @@ _PUBLIC_ void ndr_print_netr_DomainTrustInfo(struct ndr_print *ndr, const char *
ndr->depth++;
for (cntr_unknown_0=0;cntr_unknown_0<4;cntr_unknown_0++) {
char *idx_0=NULL;
- asprintf(&idx_0, "[%d]", cntr_unknown_0);
- if (idx_0) {
+ if (asprintf(&idx_0, "[%d]", cntr_unknown_0) != -1) {
ndr_print_uint32(ndr, "unknown", r->unknown[cntr_unknown_0]);
free(idx_0);
}
@@ -7050,8 +7034,7 @@ _PUBLIC_ void ndr_print_netr_DomainInfo1(struct ndr_print *ndr, const char *name
ndr->depth++;
for (cntr_trusts_1=0;cntr_trusts_1<r->num_trusts;cntr_trusts_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_trusts_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_trusts_1) != -1) {
ndr_print_netr_DomainTrustInfo(ndr, "trusts", &r->trusts[cntr_trusts_1]);
free(idx_1);
}
@@ -7063,8 +7046,7 @@ _PUBLIC_ void ndr_print_netr_DomainInfo1(struct ndr_print *ndr, const char *name
ndr->depth++;
for (cntr_unknown_0=0;cntr_unknown_0<14;cntr_unknown_0++) {
char *idx_0=NULL;
- asprintf(&idx_0, "[%d]", cntr_unknown_0);
- if (idx_0) {
+ if (asprintf(&idx_0, "[%d]", cntr_unknown_0) != -1) {
ndr_print_uint32(ndr, "unknown", r->unknown[cntr_unknown_0]);
free(idx_0);
}
@@ -7328,8 +7310,7 @@ _PUBLIC_ void ndr_print_netr_DsRAddressToSitenamesWCtr(struct ndr_print *ndr, co
ndr->depth++;
for (cntr_sitename_1=0;cntr_sitename_1<r->count;cntr_sitename_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_sitename_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_sitename_1) != -1) {
ndr_print_lsa_String(ndr, "sitename", &r->sitename[cntr_sitename_1]);
free(idx_1);
}
@@ -7691,8 +7672,7 @@ _PUBLIC_ void ndr_print_netr_DomainTrustList(struct ndr_print *ndr, const char *
ndr->depth++;
for (cntr_array_1=0;cntr_array_1<r->count;cntr_array_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_array_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_array_1) != -1) {
ndr_print_netr_DomainTrust(ndr, "array", &r->array[cntr_array_1]);
free(idx_1);
}
@@ -7819,8 +7799,7 @@ _PUBLIC_ void ndr_print_netr_DsRAddressToSitenamesExWCtr(struct ndr_print *ndr,
ndr->depth++;
for (cntr_sitename_1=0;cntr_sitename_1<r->count;cntr_sitename_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_sitename_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_sitename_1) != -1) {
ndr_print_lsa_String(ndr, "sitename", &r->sitename[cntr_sitename_1]);
free(idx_1);
}
@@ -7835,8 +7814,7 @@ _PUBLIC_ void ndr_print_netr_DsRAddressToSitenamesExWCtr(struct ndr_print *ndr,
ndr->depth++;
for (cntr_subnetname_1=0;cntr_subnetname_1<r->count;cntr_subnetname_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_subnetname_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_subnetname_1) != -1) {
ndr_print_lsa_String(ndr, "subnetname", &r->subnetname[cntr_subnetname_1]);
free(idx_1);
}
@@ -7922,8 +7900,7 @@ _PUBLIC_ void ndr_print_DcSitesCtr(struct ndr_print *ndr, const char *name, cons
ndr->depth++;
for (cntr_sites_1=0;cntr_sites_1<r->num_sites;cntr_sites_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_sites_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_sites_1) != -1) {
ndr_print_lsa_String(ndr, "sites", &r->sites[cntr_sites_1]);
free(idx_1);
}
@@ -8196,8 +8173,11 @@ static enum ndr_err_code ndr_push_netr_LogonSamLogon(struct ndr_push *ndr, int f
NDR_CHECK(ndr_push_netr_Authenticator(ndr, NDR_SCALARS, r->in.return_authenticator));
}
NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->in.logon_level));
- NDR_CHECK(ndr_push_set_switch_value(ndr, &r->in.logon, r->in.logon_level));
- NDR_CHECK(ndr_push_netr_LogonLevel(ndr, NDR_SCALARS|NDR_BUFFERS, &r->in.logon));
+ if (r->in.logon == NULL) {
+ return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
+ }
+ NDR_CHECK(ndr_push_set_switch_value(ndr, r->in.logon, r->in.logon_level));
+ NDR_CHECK(ndr_push_netr_LogonLevel(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.logon));
NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->in.validation_level));
}
if (flags & NDR_OUT) {
@@ -8229,6 +8209,7 @@ static enum ndr_err_code ndr_pull_netr_LogonSamLogon(struct ndr_pull *ndr, int f
TALLOC_CTX *_mem_save_computer_name_0;
TALLOC_CTX *_mem_save_credential_0;
TALLOC_CTX *_mem_save_return_authenticator_0;
+ TALLOC_CTX *_mem_save_logon_0;
TALLOC_CTX *_mem_save_validation_0;
TALLOC_CTX *_mem_save_authoritative_0;
if (flags & NDR_IN) {
@@ -8295,8 +8276,14 @@ static enum ndr_err_code ndr_pull_netr_LogonSamLogon(struct ndr_pull *ndr, int f
NDR_PULL_SET_MEM_CTX(ndr, _mem_save_return_authenticator_0, 0);
}
NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->in.logon_level));
- NDR_CHECK(ndr_pull_set_switch_value(ndr, &r->in.logon, r->in.logon_level));
- NDR_CHECK(ndr_pull_netr_LogonLevel(ndr, NDR_SCALARS|NDR_BUFFERS, &r->in.logon));
+ if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
+ NDR_PULL_ALLOC(ndr, r->in.logon);
+ }
+ _mem_save_logon_0 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, r->in.logon, LIBNDR_FLAG_REF_ALLOC);
+ NDR_CHECK(ndr_pull_set_switch_value(ndr, r->in.logon, r->in.logon_level));
+ NDR_CHECK(ndr_pull_netr_LogonLevel(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.logon));
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_logon_0, LIBNDR_FLAG_REF_ALLOC);
NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->in.validation_level));
NDR_PULL_ALLOC(ndr, r->out.validation);
ZERO_STRUCTP(r->out.validation);
@@ -8371,8 +8358,11 @@ _PUBLIC_ void ndr_print_netr_LogonSamLogon(struct ndr_print *ndr, const char *na
}
ndr->depth--;
ndr_print_uint16(ndr, "logon_level", r->in.logon_level);
- ndr_print_set_switch_value(ndr, &r->in.logon, r->in.logon_level);
- ndr_print_netr_LogonLevel(ndr, "logon", &r->in.logon);
+ ndr_print_ptr(ndr, "logon", r->in.logon);
+ ndr->depth++;
+ ndr_print_set_switch_value(ndr, r->in.logon, r->in.logon_level);
+ ndr_print_netr_LogonLevel(ndr, "logon", r->in.logon);
+ ndr->depth--;
ndr_print_uint16(ndr, "validation_level", r->in.validation_level);
ndr->depth--;
}
@@ -8608,10 +8598,10 @@ static enum ndr_err_code ndr_push_netr_ServerReqChallenge(struct ndr_push *ndr,
NDR_CHECK(ndr_push_netr_Credential(ndr, NDR_SCALARS, r->in.credentials));
}
if (flags & NDR_OUT) {
- if (r->out.credentials == NULL) {
+ if (r->out.return_credentials == NULL) {
return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
}
- NDR_CHECK(ndr_push_netr_Credential(ndr, NDR_SCALARS, r->out.credentials));
+ NDR_CHECK(ndr_push_netr_Credential(ndr, NDR_SCALARS, r->out.return_credentials));
NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
}
return NDR_ERR_SUCCESS;
@@ -8622,6 +8612,7 @@ static enum ndr_err_code ndr_pull_netr_ServerReqChallenge(struct ndr_pull *ndr,
uint32_t _ptr_server_name;
TALLOC_CTX *_mem_save_server_name_0;
TALLOC_CTX *_mem_save_credentials_0;
+ TALLOC_CTX *_mem_save_return_credentials_0;
if (flags & NDR_IN) {
ZERO_STRUCT(r->out);
@@ -8657,17 +8648,17 @@ static enum ndr_err_code ndr_pull_netr_ServerReqChallenge(struct ndr_pull *ndr,
NDR_PULL_SET_MEM_CTX(ndr, r->in.credentials, LIBNDR_FLAG_REF_ALLOC);
NDR_CHECK(ndr_pull_netr_Credential(ndr, NDR_SCALARS, r->in.credentials));
NDR_PULL_SET_MEM_CTX(ndr, _mem_save_credentials_0, LIBNDR_FLAG_REF_ALLOC);
- NDR_PULL_ALLOC(ndr, r->out.credentials);
- *r->out.credentials = *r->in.credentials;
+ NDR_PULL_ALLOC(ndr, r->out.return_credentials);
+ ZERO_STRUCTP(r->out.return_credentials);
}
if (flags & NDR_OUT) {
if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
- NDR_PULL_ALLOC(ndr, r->out.credentials);
+ NDR_PULL_ALLOC(ndr, r->out.return_credentials);
}
- _mem_save_credentials_0 = NDR_PULL_GET_MEM_CTX(ndr);
- NDR_PULL_SET_MEM_CTX(ndr, r->out.credentials, LIBNDR_FLAG_REF_ALLOC);
- NDR_CHECK(ndr_pull_netr_Credential(ndr, NDR_SCALARS, r->out.credentials));
- NDR_PULL_SET_MEM_CTX(ndr, _mem_save_credentials_0, LIBNDR_FLAG_REF_ALLOC);
+ _mem_save_return_credentials_0 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, r->out.return_credentials, LIBNDR_FLAG_REF_ALLOC);
+ NDR_CHECK(ndr_pull_netr_Credential(ndr, NDR_SCALARS, r->out.return_credentials));
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_return_credentials_0, LIBNDR_FLAG_REF_ALLOC);
NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
}
return NDR_ERR_SUCCESS;
@@ -8699,9 +8690,9 @@ _PUBLIC_ void ndr_print_netr_ServerReqChallenge(struct ndr_print *ndr, const cha
if (flags & NDR_OUT) {
ndr_print_struct(ndr, "out", "netr_ServerReqChallenge");
ndr->depth++;
- ndr_print_ptr(ndr, "credentials", r->out.credentials);
+ ndr_print_ptr(ndr, "return_credentials", r->out.return_credentials);
ndr->depth++;
- ndr_print_netr_Credential(ndr, "credentials", r->out.credentials);
+ ndr_print_netr_Credential(ndr, "return_credentials", r->out.return_credentials);
ndr->depth--;
ndr_print_NTSTATUS(ndr, "result", r->out.result);
ndr->depth--;
@@ -8734,10 +8725,10 @@ static enum ndr_err_code ndr_push_netr_ServerAuthenticate(struct ndr_push *ndr,
NDR_CHECK(ndr_push_netr_Credential(ndr, NDR_SCALARS, r->in.credentials));
}
if (flags & NDR_OUT) {
- if (r->out.credentials == NULL) {
+ if (r->out.return_credentials == NULL) {
return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
}
- NDR_CHECK(ndr_push_netr_Credential(ndr, NDR_SCALARS, r->out.credentials));
+ NDR_CHECK(ndr_push_netr_Credential(ndr, NDR_SCALARS, r->out.return_credentials));
NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
}
return NDR_ERR_SUCCESS;
@@ -8748,6 +8739,7 @@ static enum ndr_err_code ndr_pull_netr_ServerAuthenticate(struct ndr_pull *ndr,
uint32_t _ptr_server_name;
TALLOC_CTX *_mem_save_server_name_0;
TALLOC_CTX *_mem_save_credentials_0;
+ TALLOC_CTX *_mem_save_return_credentials_0;
if (flags & NDR_IN) {
ZERO_STRUCT(r->out);
@@ -8791,17 +8783,17 @@ static enum ndr_err_code ndr_pull_netr_ServerAuthenticate(struct ndr_pull *ndr,
NDR_PULL_SET_MEM_CTX(ndr, r->in.credentials, LIBNDR_FLAG_REF_ALLOC);
NDR_CHECK(ndr_pull_netr_Credential(ndr, NDR_SCALARS, r->in.credentials));
NDR_PULL_SET_MEM_CTX(ndr, _mem_save_credentials_0, LIBNDR_FLAG_REF_ALLOC);
- NDR_PULL_ALLOC(ndr, r->out.credentials);
- *r->out.credentials = *r->in.credentials;
+ NDR_PULL_ALLOC(ndr, r->out.return_credentials);
+ ZERO_STRUCTP(r->out.return_credentials);
}
if (flags & NDR_OUT) {
if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
- NDR_PULL_ALLOC(ndr, r->out.credentials);
+ NDR_PULL_ALLOC(ndr, r->out.return_credentials);
}
- _mem_save_credentials_0 = NDR_PULL_GET_MEM_CTX(ndr);
- NDR_PULL_SET_MEM_CTX(ndr, r->out.credentials, LIBNDR_FLAG_REF_ALLOC);
- NDR_CHECK(ndr_pull_netr_Credential(ndr, NDR_SCALARS, r->out.credentials));
- NDR_PULL_SET_MEM_CTX(ndr, _mem_save_credentials_0, LIBNDR_FLAG_REF_ALLOC);
+ _mem_save_return_credentials_0 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, r->out.return_credentials, LIBNDR_FLAG_REF_ALLOC);
+ NDR_CHECK(ndr_pull_netr_Credential(ndr, NDR_SCALARS, r->out.return_credentials));
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_return_credentials_0, LIBNDR_FLAG_REF_ALLOC);
NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
}
return NDR_ERR_SUCCESS;
@@ -8835,9 +8827,9 @@ _PUBLIC_ void ndr_print_netr_ServerAuthenticate(struct ndr_print *ndr, const cha
if (flags & NDR_OUT) {
ndr_print_struct(ndr, "out", "netr_ServerAuthenticate");
ndr->depth++;
- ndr_print_ptr(ndr, "credentials", r->out.credentials);
+ ndr_print_ptr(ndr, "return_credentials", r->out.return_credentials);
ndr->depth++;
- ndr_print_netr_Credential(ndr, "credentials", r->out.credentials);
+ ndr_print_netr_Credential(ndr, "return_credentials", r->out.return_credentials);
ndr->depth--;
ndr_print_NTSTATUS(ndr, "result", r->out.result);
ndr->depth--;
@@ -8864,8 +8856,14 @@ static enum ndr_err_code ndr_push_netr_ServerPasswordSet(struct ndr_push *ndr, i
NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, 0));
NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, ndr_charset_length(r->in.computer_name, CH_UTF16)));
NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.computer_name, ndr_charset_length(r->in.computer_name, CH_UTF16), sizeof(uint16_t), CH_UTF16));
- NDR_CHECK(ndr_push_netr_Authenticator(ndr, NDR_SCALARS, &r->in.credential));
- NDR_CHECK(ndr_push_samr_Password(ndr, NDR_SCALARS|NDR_BUFFERS, &r->in.new_password));
+ if (r->in.credential == NULL) {
+ return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
+ }
+ NDR_CHECK(ndr_push_netr_Authenticator(ndr, NDR_SCALARS, r->in.credential));
+ if (r->in.new_password == NULL) {
+ return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
+ }
+ NDR_CHECK(ndr_push_samr_Password(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.new_password));
}
if (flags & NDR_OUT) {
if (r->out.return_authenticator == NULL) {
@@ -8881,7 +8879,9 @@ static enum ndr_err_code ndr_pull_netr_ServerPasswordSet(struct ndr_pull *ndr, i
{
uint32_t _ptr_server_name;
TALLOC_CTX *_mem_save_server_name_0;
+ TALLOC_CTX *_mem_save_credential_0;
TALLOC_CTX *_mem_save_return_authenticator_0;
+ TALLOC_CTX *_mem_save_new_password_0;
if (flags & NDR_IN) {
ZERO_STRUCT(r->out);
@@ -8918,8 +8918,20 @@ static enum ndr_err_code ndr_pull_netr_ServerPasswordSet(struct ndr_pull *ndr, i
}
NDR_CHECK(ndr_check_string_terminator(ndr, ndr_get_array_length(ndr, &r->in.computer_name), sizeof(uint16_t)));
NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.computer_name, ndr_get_array_length(ndr, &r->in.computer_name), sizeof(uint16_t), CH_UTF16));
- NDR_CHECK(ndr_pull_netr_Authenticator(ndr, NDR_SCALARS, &r->in.credential));
- NDR_CHECK(ndr_pull_samr_Password(ndr, NDR_SCALARS|NDR_BUFFERS, &r->in.new_password));
+ if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
+ NDR_PULL_ALLOC(ndr, r->in.credential);
+ }
+ _mem_save_credential_0 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, r->in.credential, LIBNDR_FLAG_REF_ALLOC);
+ NDR_CHECK(ndr_pull_netr_Authenticator(ndr, NDR_SCALARS, r->in.credential));
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_credential_0, LIBNDR_FLAG_REF_ALLOC);
+ if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
+ NDR_PULL_ALLOC(ndr, r->in.new_password);
+ }
+ _mem_save_new_password_0 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, r->in.new_password, LIBNDR_FLAG_REF_ALLOC);
+ NDR_CHECK(ndr_pull_samr_Password(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.new_password));
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_new_password_0, LIBNDR_FLAG_REF_ALLOC);
NDR_PULL_ALLOC(ndr, r->out.return_authenticator);
ZERO_STRUCTP(r->out.return_authenticator);
}
@@ -8955,8 +8967,14 @@ _PUBLIC_ void ndr_print_netr_ServerPasswordSet(struct ndr_print *ndr, const char
ndr_print_string(ndr, "account_name", r->in.account_name);
ndr_print_netr_SchannelType(ndr, "secure_channel_type", r->in.secure_channel_type);
ndr_print_string(ndr, "computer_name", r->in.computer_name);
- ndr_print_netr_Authenticator(ndr, "credential", &r->in.credential);
- ndr_print_samr_Password(ndr, "new_password", &r->in.new_password);
+ ndr_print_ptr(ndr, "credential", r->in.credential);
+ ndr->depth++;
+ ndr_print_netr_Authenticator(ndr, "credential", r->in.credential);
+ ndr->depth--;
+ ndr_print_ptr(ndr, "new_password", r->in.new_password);
+ ndr->depth++;
+ ndr_print_samr_Password(ndr, "new_password", r->in.new_password);
+ ndr->depth--;
ndr->depth--;
}
if (flags & NDR_OUT) {
@@ -8983,7 +9001,10 @@ static enum ndr_err_code ndr_push_netr_DatabaseDeltas(struct ndr_push *ndr, int
NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, 0));
NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, ndr_charset_length(r->in.computername, CH_UTF16)));
NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.computername, ndr_charset_length(r->in.computername, CH_UTF16), sizeof(uint16_t), CH_UTF16));
- NDR_CHECK(ndr_push_netr_Authenticator(ndr, NDR_SCALARS, &r->in.credential));
+ if (r->in.credential == NULL) {
+ return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
+ }
+ NDR_CHECK(ndr_push_netr_Authenticator(ndr, NDR_SCALARS, r->in.credential));
if (r->in.return_authenticator == NULL) {
return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
}
@@ -9007,7 +9028,10 @@ static enum ndr_err_code ndr_push_netr_DatabaseDeltas(struct ndr_push *ndr, int
if (r->out.delta_enum_array == NULL) {
return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
}
- NDR_CHECK(ndr_push_netr_DELTA_ENUM_ARRAY(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.delta_enum_array));
+ NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.delta_enum_array));
+ if (*r->out.delta_enum_array) {
+ NDR_CHECK(ndr_push_netr_DELTA_ENUM_ARRAY(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.delta_enum_array));
+ }
NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
}
return NDR_ERR_SUCCESS;
@@ -9015,9 +9039,12 @@ static enum ndr_err_code ndr_push_netr_DatabaseDeltas(struct ndr_push *ndr, int
static enum ndr_err_code ndr_pull_netr_DatabaseDeltas(struct ndr_pull *ndr, int flags, struct netr_DatabaseDeltas *r)
{
+ uint32_t _ptr_delta_enum_array;
+ TALLOC_CTX *_mem_save_credential_0;
TALLOC_CTX *_mem_save_return_authenticator_0;
TALLOC_CTX *_mem_save_sequence_num_0;
TALLOC_CTX *_mem_save_delta_enum_array_0;
+ TALLOC_CTX *_mem_save_delta_enum_array_1;
if (flags & NDR_IN) {
ZERO_STRUCT(r->out);
@@ -9035,7 +9062,13 @@ static enum ndr_err_code ndr_pull_netr_DatabaseDeltas(struct ndr_pull *ndr, int
}
NDR_CHECK(ndr_check_string_terminator(ndr, ndr_get_array_length(ndr, &r->in.computername), sizeof(uint16_t)));
NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.computername, ndr_get_array_length(ndr, &r->in.computername), sizeof(uint16_t), CH_UTF16));
- NDR_CHECK(ndr_pull_netr_Authenticator(ndr, NDR_SCALARS, &r->in.credential));
+ if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
+ NDR_PULL_ALLOC(ndr, r->in.credential);
+ }
+ _mem_save_credential_0 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, r->in.credential, LIBNDR_FLAG_REF_ALLOC);
+ NDR_CHECK(ndr_pull_netr_Authenticator(ndr, NDR_SCALARS, r->in.credential));
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_credential_0, LIBNDR_FLAG_REF_ALLOC);
if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
NDR_PULL_ALLOC(ndr, r->in.return_authenticator);
}
@@ -9079,7 +9112,18 @@ static enum ndr_err_code ndr_pull_netr_DatabaseDeltas(struct ndr_pull *ndr, int
}
_mem_save_delta_enum_array_0 = NDR_PULL_GET_MEM_CTX(ndr);
NDR_PULL_SET_MEM_CTX(ndr, r->out.delta_enum_array, LIBNDR_FLAG_REF_ALLOC);
- NDR_CHECK(ndr_pull_netr_DELTA_ENUM_ARRAY(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.delta_enum_array));
+ NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_delta_enum_array));
+ if (_ptr_delta_enum_array) {
+ NDR_PULL_ALLOC(ndr, *r->out.delta_enum_array);
+ } else {
+ *r->out.delta_enum_array = NULL;
+ }
+ if (*r->out.delta_enum_array) {
+ _mem_save_delta_enum_array_1 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, *r->out.delta_enum_array, 0);
+ NDR_CHECK(ndr_pull_netr_DELTA_ENUM_ARRAY(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.delta_enum_array));
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_delta_enum_array_1, 0);
+ }
NDR_PULL_SET_MEM_CTX(ndr, _mem_save_delta_enum_array_0, LIBNDR_FLAG_REF_ALLOC);
NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
}
@@ -9098,7 +9142,10 @@ _PUBLIC_ void ndr_print_netr_DatabaseDeltas(struct ndr_print *ndr, const char *n
ndr->depth++;
ndr_print_string(ndr, "logon_server", r->in.logon_server);
ndr_print_string(ndr, "computername", r->in.computername);
- ndr_print_netr_Authenticator(ndr, "credential", &r->in.credential);
+ ndr_print_ptr(ndr, "credential", r->in.credential);
+ ndr->depth++;
+ ndr_print_netr_Authenticator(ndr, "credential", r->in.credential);
+ ndr->depth--;
ndr_print_ptr(ndr, "return_authenticator", r->in.return_authenticator);
ndr->depth++;
ndr_print_netr_Authenticator(ndr, "return_authenticator", r->in.return_authenticator);
@@ -9124,7 +9171,12 @@ _PUBLIC_ void ndr_print_netr_DatabaseDeltas(struct ndr_print *ndr, const char *n
ndr->depth--;
ndr_print_ptr(ndr, "delta_enum_array", r->out.delta_enum_array);
ndr->depth++;
- ndr_print_netr_DELTA_ENUM_ARRAY(ndr, "delta_enum_array", r->out.delta_enum_array);
+ ndr_print_ptr(ndr, "delta_enum_array", *r->out.delta_enum_array);
+ ndr->depth++;
+ if (*r->out.delta_enum_array) {
+ ndr_print_netr_DELTA_ENUM_ARRAY(ndr, "delta_enum_array", *r->out.delta_enum_array);
+ }
+ ndr->depth--;
ndr->depth--;
ndr_print_NTSTATUS(ndr, "result", r->out.result);
ndr->depth--;
@@ -10166,8 +10218,11 @@ static enum ndr_err_code ndr_push_netr_LogonControl2(struct ndr_push *ndr, int f
}
NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.function_code));
NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.level));
- NDR_CHECK(ndr_push_set_switch_value(ndr, &r->in.data, r->in.function_code));
- NDR_CHECK(ndr_push_netr_CONTROL_DATA_INFORMATION(ndr, NDR_SCALARS|NDR_BUFFERS, &r->in.data));
+ if (r->in.data == NULL) {
+ return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
+ }
+ NDR_CHECK(ndr_push_set_switch_value(ndr, r->in.data, r->in.function_code));
+ NDR_CHECK(ndr_push_netr_CONTROL_DATA_INFORMATION(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.data));
}
if (flags & NDR_OUT) {
if (r->out.query == NULL) {
@@ -10184,6 +10239,7 @@ static enum ndr_err_code ndr_pull_netr_LogonControl2(struct ndr_pull *ndr, int f
{
uint32_t _ptr_logon_server;
TALLOC_CTX *_mem_save_logon_server_0;
+ TALLOC_CTX *_mem_save_data_0;
TALLOC_CTX *_mem_save_query_0;
if (flags & NDR_IN) {
ZERO_STRUCT(r->out);
@@ -10208,8 +10264,14 @@ static enum ndr_err_code ndr_pull_netr_LogonControl2(struct ndr_pull *ndr, int f
}
NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.function_code));
NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.level));
- NDR_CHECK(ndr_pull_set_switch_value(ndr, &r->in.data, r->in.function_code));
- NDR_CHECK(ndr_pull_netr_CONTROL_DATA_INFORMATION(ndr, NDR_SCALARS|NDR_BUFFERS, &r->in.data));
+ if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
+ NDR_PULL_ALLOC(ndr, r->in.data);
+ }
+ _mem_save_data_0 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, r->in.data, LIBNDR_FLAG_REF_ALLOC);
+ NDR_CHECK(ndr_pull_set_switch_value(ndr, r->in.data, r->in.function_code));
+ NDR_CHECK(ndr_pull_netr_CONTROL_DATA_INFORMATION(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.data));
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_data_0, LIBNDR_FLAG_REF_ALLOC);
NDR_PULL_ALLOC(ndr, r->out.query);
ZERO_STRUCTP(r->out.query);
}
@@ -10245,8 +10307,11 @@ _PUBLIC_ void ndr_print_netr_LogonControl2(struct ndr_print *ndr, const char *na
ndr->depth--;
ndr_print_uint32(ndr, "function_code", r->in.function_code);
ndr_print_uint32(ndr, "level", r->in.level);
- ndr_print_set_switch_value(ndr, &r->in.data, r->in.function_code);
- ndr_print_netr_CONTROL_DATA_INFORMATION(ndr, "data", &r->in.data);
+ ndr_print_ptr(ndr, "data", r->in.data);
+ ndr->depth++;
+ ndr_print_set_switch_value(ndr, r->in.data, r->in.function_code);
+ ndr_print_netr_CONTROL_DATA_INFORMATION(ndr, "data", r->in.data);
+ ndr->depth--;
ndr->depth--;
}
if (flags & NDR_OUT) {
@@ -10292,10 +10357,10 @@ static enum ndr_err_code ndr_push_netr_ServerAuthenticate2(struct ndr_push *ndr,
NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->in.negotiate_flags));
}
if (flags & NDR_OUT) {
- if (r->out.credentials == NULL) {
+ if (r->out.return_credentials == NULL) {
return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
}
- NDR_CHECK(ndr_push_netr_Credential(ndr, NDR_SCALARS, r->out.credentials));
+ NDR_CHECK(ndr_push_netr_Credential(ndr, NDR_SCALARS, r->out.return_credentials));
if (r->out.negotiate_flags == NULL) {
return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
}
@@ -10310,6 +10375,7 @@ static enum ndr_err_code ndr_pull_netr_ServerAuthenticate2(struct ndr_pull *ndr,
uint32_t _ptr_server_name;
TALLOC_CTX *_mem_save_server_name_0;
TALLOC_CTX *_mem_save_credentials_0;
+ TALLOC_CTX *_mem_save_return_credentials_0;
TALLOC_CTX *_mem_save_negotiate_flags_0;
if (flags & NDR_IN) {
ZERO_STRUCT(r->out);
@@ -10361,19 +10427,19 @@ static enum ndr_err_code ndr_pull_netr_ServerAuthenticate2(struct ndr_pull *ndr,
NDR_PULL_SET_MEM_CTX(ndr, r->in.negotiate_flags, LIBNDR_FLAG_REF_ALLOC);
NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->in.negotiate_flags));
NDR_PULL_SET_MEM_CTX(ndr, _mem_save_negotiate_flags_0, LIBNDR_FLAG_REF_ALLOC);
- NDR_PULL_ALLOC(ndr, r->out.credentials);
- *r->out.credentials = *r->in.credentials;
+ NDR_PULL_ALLOC(ndr, r->out.return_credentials);
+ ZERO_STRUCTP(r->out.return_credentials);
NDR_PULL_ALLOC(ndr, r->out.negotiate_flags);
*r->out.negotiate_flags = *r->in.negotiate_flags;
}
if (flags & NDR_OUT) {
if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
- NDR_PULL_ALLOC(ndr, r->out.credentials);
+ NDR_PULL_ALLOC(ndr, r->out.return_credentials);
}
- _mem_save_credentials_0 = NDR_PULL_GET_MEM_CTX(ndr);
- NDR_PULL_SET_MEM_CTX(ndr, r->out.credentials, LIBNDR_FLAG_REF_ALLOC);
- NDR_CHECK(ndr_pull_netr_Credential(ndr, NDR_SCALARS, r->out.credentials));
- NDR_PULL_SET_MEM_CTX(ndr, _mem_save_credentials_0, LIBNDR_FLAG_REF_ALLOC);
+ _mem_save_return_credentials_0 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, r->out.return_credentials, LIBNDR_FLAG_REF_ALLOC);
+ NDR_CHECK(ndr_pull_netr_Credential(ndr, NDR_SCALARS, r->out.return_credentials));
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_return_credentials_0, LIBNDR_FLAG_REF_ALLOC);
if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
NDR_PULL_ALLOC(ndr, r->out.negotiate_flags);
}
@@ -10418,9 +10484,9 @@ _PUBLIC_ void ndr_print_netr_ServerAuthenticate2(struct ndr_print *ndr, const ch
if (flags & NDR_OUT) {
ndr_print_struct(ndr, "out", "netr_ServerAuthenticate2");
ndr->depth++;
- ndr_print_ptr(ndr, "credentials", r->out.credentials);
+ ndr_print_ptr(ndr, "return_credentials", r->out.return_credentials);
ndr->depth++;
- ndr_print_netr_Credential(ndr, "credentials", r->out.credentials);
+ ndr_print_netr_Credential(ndr, "return_credentials", r->out.return_credentials);
ndr->depth--;
ndr_print_ptr(ndr, "negotiate_flags", r->out.negotiate_flags);
ndr->depth++;
@@ -10443,7 +10509,10 @@ static enum ndr_err_code ndr_push_netr_DatabaseSync2(struct ndr_push *ndr, int f
NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, 0));
NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, ndr_charset_length(r->in.computername, CH_UTF16)));
NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.computername, ndr_charset_length(r->in.computername, CH_UTF16), sizeof(uint16_t), CH_UTF16));
- NDR_CHECK(ndr_push_netr_Authenticator(ndr, NDR_SCALARS, &r->in.credential));
+ if (r->in.credential == NULL) {
+ return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
+ }
+ NDR_CHECK(ndr_push_netr_Authenticator(ndr, NDR_SCALARS, r->in.credential));
if (r->in.return_authenticator == NULL) {
return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
}
@@ -10468,7 +10537,10 @@ static enum ndr_err_code ndr_push_netr_DatabaseSync2(struct ndr_push *ndr, int f
if (r->out.delta_enum_array == NULL) {
return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
}
- NDR_CHECK(ndr_push_netr_DELTA_ENUM_ARRAY(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.delta_enum_array));
+ NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.delta_enum_array));
+ if (*r->out.delta_enum_array) {
+ NDR_CHECK(ndr_push_netr_DELTA_ENUM_ARRAY(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.delta_enum_array));
+ }
NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
}
return NDR_ERR_SUCCESS;
@@ -10476,9 +10548,12 @@ static enum ndr_err_code ndr_push_netr_DatabaseSync2(struct ndr_push *ndr, int f
static enum ndr_err_code ndr_pull_netr_DatabaseSync2(struct ndr_pull *ndr, int flags, struct netr_DatabaseSync2 *r)
{
+ uint32_t _ptr_delta_enum_array;
+ TALLOC_CTX *_mem_save_credential_0;
TALLOC_CTX *_mem_save_return_authenticator_0;
TALLOC_CTX *_mem_save_sync_context_0;
TALLOC_CTX *_mem_save_delta_enum_array_0;
+ TALLOC_CTX *_mem_save_delta_enum_array_1;
if (flags & NDR_IN) {
ZERO_STRUCT(r->out);
@@ -10496,7 +10571,13 @@ static enum ndr_err_code ndr_pull_netr_DatabaseSync2(struct ndr_pull *ndr, int f
}
NDR_CHECK(ndr_check_string_terminator(ndr, ndr_get_array_length(ndr, &r->in.computername), sizeof(uint16_t)));
NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.computername, ndr_get_array_length(ndr, &r->in.computername), sizeof(uint16_t), CH_UTF16));
- NDR_CHECK(ndr_pull_netr_Authenticator(ndr, NDR_SCALARS, &r->in.credential));
+ if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
+ NDR_PULL_ALLOC(ndr, r->in.credential);
+ }
+ _mem_save_credential_0 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, r->in.credential, LIBNDR_FLAG_REF_ALLOC);
+ NDR_CHECK(ndr_pull_netr_Authenticator(ndr, NDR_SCALARS, r->in.credential));
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_credential_0, LIBNDR_FLAG_REF_ALLOC);
if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
NDR_PULL_ALLOC(ndr, r->in.return_authenticator);
}
@@ -10541,7 +10622,18 @@ static enum ndr_err_code ndr_pull_netr_DatabaseSync2(struct ndr_pull *ndr, int f
}
_mem_save_delta_enum_array_0 = NDR_PULL_GET_MEM_CTX(ndr);
NDR_PULL_SET_MEM_CTX(ndr, r->out.delta_enum_array, LIBNDR_FLAG_REF_ALLOC);
- NDR_CHECK(ndr_pull_netr_DELTA_ENUM_ARRAY(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.delta_enum_array));
+ NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_delta_enum_array));
+ if (_ptr_delta_enum_array) {
+ NDR_PULL_ALLOC(ndr, *r->out.delta_enum_array);
+ } else {
+ *r->out.delta_enum_array = NULL;
+ }
+ if (*r->out.delta_enum_array) {
+ _mem_save_delta_enum_array_1 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, *r->out.delta_enum_array, 0);
+ NDR_CHECK(ndr_pull_netr_DELTA_ENUM_ARRAY(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.delta_enum_array));
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_delta_enum_array_1, 0);
+ }
NDR_PULL_SET_MEM_CTX(ndr, _mem_save_delta_enum_array_0, LIBNDR_FLAG_REF_ALLOC);
NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
}
@@ -10560,7 +10652,10 @@ _PUBLIC_ void ndr_print_netr_DatabaseSync2(struct ndr_print *ndr, const char *na
ndr->depth++;
ndr_print_string(ndr, "logon_server", r->in.logon_server);
ndr_print_string(ndr, "computername", r->in.computername);
- ndr_print_netr_Authenticator(ndr, "credential", &r->in.credential);
+ ndr_print_ptr(ndr, "credential", r->in.credential);
+ ndr->depth++;
+ ndr_print_netr_Authenticator(ndr, "credential", r->in.credential);
+ ndr->depth--;
ndr_print_ptr(ndr, "return_authenticator", r->in.return_authenticator);
ndr->depth++;
ndr_print_netr_Authenticator(ndr, "return_authenticator", r->in.return_authenticator);
@@ -10587,7 +10682,12 @@ _PUBLIC_ void ndr_print_netr_DatabaseSync2(struct ndr_print *ndr, const char *na
ndr->depth--;
ndr_print_ptr(ndr, "delta_enum_array", r->out.delta_enum_array);
ndr->depth++;
- ndr_print_netr_DELTA_ENUM_ARRAY(ndr, "delta_enum_array", r->out.delta_enum_array);
+ ndr_print_ptr(ndr, "delta_enum_array", *r->out.delta_enum_array);
+ ndr->depth++;
+ if (*r->out.delta_enum_array) {
+ ndr_print_netr_DELTA_ENUM_ARRAY(ndr, "delta_enum_array", *r->out.delta_enum_array);
+ }
+ ndr->depth--;
ndr->depth--;
ndr_print_NTSTATUS(ndr, "result", r->out.result);
ndr->depth--;
@@ -12588,8 +12688,7 @@ _PUBLIC_ void ndr_print_netr_DsRAddressToSitenamesW(struct ndr_print *ndr, const
ndr->depth++;
for (cntr_addresses_1=0;cntr_addresses_1<r->in.count;cntr_addresses_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_addresses_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_addresses_1) != -1) {
ndr_print_netr_DsRAddress(ndr, "addresses", &r->in.addresses[cntr_addresses_1]);
free(idx_1);
}
@@ -13132,8 +13231,7 @@ _PUBLIC_ void ndr_print_netr_DsRAddressToSitenamesExW(struct ndr_print *ndr, con
ndr->depth++;
for (cntr_addresses_1=0;cntr_addresses_1<r->in.count;cntr_addresses_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_addresses_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_addresses_1) != -1) {
ndr_print_netr_DsRAddress(ndr, "addresses", &r->in.addresses[cntr_addresses_1]);
free(idx_1);
}
@@ -13272,8 +13370,11 @@ static enum ndr_err_code ndr_push_netr_LogonSamLogonEx(struct ndr_push *ndr, int
NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.computer_name, ndr_charset_length(r->in.computer_name, CH_UTF16), sizeof(uint16_t), CH_UTF16));
}
NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->in.logon_level));
- NDR_CHECK(ndr_push_set_switch_value(ndr, &r->in.logon, r->in.logon_level));
- NDR_CHECK(ndr_push_netr_LogonLevel(ndr, NDR_SCALARS|NDR_BUFFERS, &r->in.logon));
+ if (r->in.logon == NULL) {
+ return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
+ }
+ NDR_CHECK(ndr_push_set_switch_value(ndr, r->in.logon, r->in.logon_level));
+ NDR_CHECK(ndr_push_netr_LogonLevel(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.logon));
NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->in.validation_level));
if (r->in.flags == NULL) {
return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
@@ -13305,6 +13406,7 @@ static enum ndr_err_code ndr_pull_netr_LogonSamLogonEx(struct ndr_pull *ndr, int
uint32_t _ptr_computer_name;
TALLOC_CTX *_mem_save_server_name_0;
TALLOC_CTX *_mem_save_computer_name_0;
+ TALLOC_CTX *_mem_save_logon_0;
TALLOC_CTX *_mem_save_validation_0;
TALLOC_CTX *_mem_save_authoritative_0;
TALLOC_CTX *_mem_save_flags_0;
@@ -13348,8 +13450,14 @@ static enum ndr_err_code ndr_pull_netr_LogonSamLogonEx(struct ndr_pull *ndr, int
NDR_PULL_SET_MEM_CTX(ndr, _mem_save_computer_name_0, 0);
}
NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->in.logon_level));
- NDR_CHECK(ndr_pull_set_switch_value(ndr, &r->in.logon, r->in.logon_level));
- NDR_CHECK(ndr_pull_netr_LogonLevel(ndr, NDR_SCALARS|NDR_BUFFERS, &r->in.logon));
+ if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
+ NDR_PULL_ALLOC(ndr, r->in.logon);
+ }
+ _mem_save_logon_0 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, r->in.logon, LIBNDR_FLAG_REF_ALLOC);
+ NDR_CHECK(ndr_pull_set_switch_value(ndr, r->in.logon, r->in.logon_level));
+ NDR_CHECK(ndr_pull_netr_LogonLevel(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.logon));
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_logon_0, LIBNDR_FLAG_REF_ALLOC);
NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->in.validation_level));
if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
NDR_PULL_ALLOC(ndr, r->in.flags);
@@ -13416,8 +13524,11 @@ _PUBLIC_ void ndr_print_netr_LogonSamLogonEx(struct ndr_print *ndr, const char *
}
ndr->depth--;
ndr_print_uint16(ndr, "logon_level", r->in.logon_level);
- ndr_print_set_switch_value(ndr, &r->in.logon, r->in.logon_level);
- ndr_print_netr_LogonLevel(ndr, "logon", &r->in.logon);
+ ndr_print_ptr(ndr, "logon", r->in.logon);
+ ndr->depth++;
+ ndr_print_set_switch_value(ndr, r->in.logon, r->in.logon_level);
+ ndr_print_netr_LogonLevel(ndr, "logon", r->in.logon);
+ ndr->depth--;
ndr_print_uint16(ndr, "validation_level", r->in.validation_level);
ndr_print_ptr(ndr, "flags", r->in.flags);
ndr->depth++;
diff --git a/source3/librpc/gen_ndr/ndr_notify.c b/source3/librpc/gen_ndr/ndr_notify.c
index 8abfdfdf92..195d421408 100644
--- a/source3/librpc/gen_ndr/ndr_notify.c
+++ b/source3/librpc/gen_ndr/ndr_notify.c
@@ -120,8 +120,7 @@ _PUBLIC_ void ndr_print_notify_depth(struct ndr_print *ndr, const char *name, co
ndr->depth++;
for (cntr_entries_0=0;cntr_entries_0<r->num_entries;cntr_entries_0++) {
char *idx_0=NULL;
- asprintf(&idx_0, "[%d]", cntr_entries_0);
- if (idx_0) {
+ if (asprintf(&idx_0, "[%d]", cntr_entries_0) != -1) {
ndr_print_notify_entry(ndr, "entries", &r->entries[cntr_entries_0]);
free(idx_0);
}
@@ -184,8 +183,7 @@ _PUBLIC_ void ndr_print_notify_array(struct ndr_print *ndr, const char *name, co
ndr->depth++;
for (cntr_depth_0=0;cntr_depth_0<r->num_depths;cntr_depth_0++) {
char *idx_0=NULL;
- asprintf(&idx_0, "[%d]", cntr_depth_0);
- if (idx_0) {
+ if (asprintf(&idx_0, "[%d]", cntr_depth_0) != -1) {
ndr_print_notify_depth(ndr, "depth", &r->depth[cntr_depth_0]);
free(idx_0);
}
diff --git a/source3/librpc/gen_ndr/ndr_ntsvcs.c b/source3/librpc/gen_ndr/ndr_ntsvcs.c
new file mode 100644
index 0000000000..9a0e2bcf4f
--- /dev/null
+++ b/source3/librpc/gen_ndr/ndr_ntsvcs.c
@@ -0,0 +1,3616 @@
+/* parser auto-generated by pidl */
+
+#include "includes.h"
+#include "librpc/gen_ndr/ndr_ntsvcs.h"
+
+static enum ndr_err_code ndr_push_PNP_HwProfInfo(struct ndr_push *ndr, int ndr_flags, const struct PNP_HwProfInfo *r)
+{
+ uint32_t cntr_unknown2_0;
+ if (ndr_flags & NDR_SCALARS) {
+ NDR_CHECK(ndr_push_align(ndr, 4));
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->unknown1));
+ for (cntr_unknown2_0 = 0; cntr_unknown2_0 < 160; cntr_unknown2_0++) {
+ NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->unknown2[cntr_unknown2_0]));
+ }
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->unknown3));
+ }
+ if (ndr_flags & NDR_BUFFERS) {
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_HwProfInfo(struct ndr_pull *ndr, int ndr_flags, struct PNP_HwProfInfo *r)
+{
+ uint32_t cntr_unknown2_0;
+ if (ndr_flags & NDR_SCALARS) {
+ NDR_CHECK(ndr_pull_align(ndr, 4));
+ NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->unknown1));
+ for (cntr_unknown2_0 = 0; cntr_unknown2_0 < 160; cntr_unknown2_0++) {
+ NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->unknown2[cntr_unknown2_0]));
+ }
+ NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->unknown3));
+ }
+ if (ndr_flags & NDR_BUFFERS) {
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_HwProfInfo(struct ndr_print *ndr, const char *name, const struct PNP_HwProfInfo *r)
+{
+ uint32_t cntr_unknown2_0;
+ ndr_print_struct(ndr, name, "PNP_HwProfInfo");
+ ndr->depth++;
+ ndr_print_uint32(ndr, "unknown1", r->unknown1);
+ ndr->print(ndr, "%s: ARRAY(%d)", "unknown2", 160);
+ ndr->depth++;
+ for (cntr_unknown2_0=0;cntr_unknown2_0<160;cntr_unknown2_0++) {
+ char *idx_0=NULL;
+ if (asprintf(&idx_0, "[%d]", cntr_unknown2_0) != -1) {
+ ndr_print_uint16(ndr, "unknown2", r->unknown2[cntr_unknown2_0]);
+ free(idx_0);
+ }
+ }
+ ndr->depth--;
+ ndr_print_uint32(ndr, "unknown3", r->unknown3);
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_Disconnect(struct ndr_push *ndr, int flags, const struct PNP_Disconnect *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_Disconnect(struct ndr_pull *ndr, int flags, struct PNP_Disconnect *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_Disconnect(struct ndr_print *ndr, const char *name, int flags, const struct PNP_Disconnect *r)
+{
+ ndr_print_struct(ndr, name, "PNP_Disconnect");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_Disconnect");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_Disconnect");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_Connect(struct ndr_push *ndr, int flags, const struct PNP_Connect *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_Connect(struct ndr_pull *ndr, int flags, struct PNP_Connect *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_Connect(struct ndr_print *ndr, const char *name, int flags, const struct PNP_Connect *r)
+{
+ ndr_print_struct(ndr, name, "PNP_Connect");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_Connect");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_Connect");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_GetVersion(struct ndr_push *ndr, int flags, const struct PNP_GetVersion *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ if (r->out.version == NULL) {
+ return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
+ }
+ NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, *r->out.version));
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_GetVersion(struct ndr_pull *ndr, int flags, struct PNP_GetVersion *r)
+{
+ TALLOC_CTX *_mem_save_version_0;
+ if (flags & NDR_IN) {
+ ZERO_STRUCT(r->out);
+
+ NDR_PULL_ALLOC(ndr, r->out.version);
+ ZERO_STRUCTP(r->out.version);
+ }
+ if (flags & NDR_OUT) {
+ if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
+ NDR_PULL_ALLOC(ndr, r->out.version);
+ }
+ _mem_save_version_0 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, r->out.version, LIBNDR_FLAG_REF_ALLOC);
+ NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, r->out.version));
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_version_0, LIBNDR_FLAG_REF_ALLOC);
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_GetVersion(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetVersion *r)
+{
+ ndr_print_struct(ndr, name, "PNP_GetVersion");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_GetVersion");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_GetVersion");
+ ndr->depth++;
+ ndr_print_ptr(ndr, "version", r->out.version);
+ ndr->depth++;
+ ndr_print_uint16(ndr, "version", *r->out.version);
+ ndr->depth--;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_GetGlobalState(struct ndr_push *ndr, int flags, const struct PNP_GetGlobalState *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_GetGlobalState(struct ndr_pull *ndr, int flags, struct PNP_GetGlobalState *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_GetGlobalState(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetGlobalState *r)
+{
+ ndr_print_struct(ndr, name, "PNP_GetGlobalState");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_GetGlobalState");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_GetGlobalState");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_InitDetection(struct ndr_push *ndr, int flags, const struct PNP_InitDetection *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_InitDetection(struct ndr_pull *ndr, int flags, struct PNP_InitDetection *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_InitDetection(struct ndr_print *ndr, const char *name, int flags, const struct PNP_InitDetection *r)
+{
+ ndr_print_struct(ndr, name, "PNP_InitDetection");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_InitDetection");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_InitDetection");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_ReportLogOn(struct ndr_push *ndr, int flags, const struct PNP_ReportLogOn *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_ReportLogOn(struct ndr_pull *ndr, int flags, struct PNP_ReportLogOn *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_ReportLogOn(struct ndr_print *ndr, const char *name, int flags, const struct PNP_ReportLogOn *r)
+{
+ ndr_print_struct(ndr, name, "PNP_ReportLogOn");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_ReportLogOn");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_ReportLogOn");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_ValidateDeviceInstance(struct ndr_push *ndr, int flags, const struct PNP_ValidateDeviceInstance *r)
+{
+ if (flags & NDR_IN) {
+ if (r->in.devicepath == NULL) {
+ return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
+ }
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, ndr_charset_length(r->in.devicepath, CH_UTF16)));
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, 0));
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, ndr_charset_length(r->in.devicepath, CH_UTF16)));
+ NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.devicepath, ndr_charset_length(r->in.devicepath, CH_UTF16), sizeof(uint16_t), CH_UTF16));
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.flags));
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_ValidateDeviceInstance(struct ndr_pull *ndr, int flags, struct PNP_ValidateDeviceInstance *r)
+{
+ if (flags & NDR_IN) {
+ NDR_CHECK(ndr_pull_array_size(ndr, &r->in.devicepath));
+ NDR_CHECK(ndr_pull_array_length(ndr, &r->in.devicepath));
+ if (ndr_get_array_length(ndr, &r->in.devicepath) > ndr_get_array_size(ndr, &r->in.devicepath)) {
+ return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr, &r->in.devicepath), ndr_get_array_length(ndr, &r->in.devicepath));
+ }
+ NDR_CHECK(ndr_check_string_terminator(ndr, ndr_get_array_length(ndr, &r->in.devicepath), sizeof(uint16_t)));
+ NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.devicepath, ndr_get_array_length(ndr, &r->in.devicepath), sizeof(uint16_t), CH_UTF16));
+ NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.flags));
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_ValidateDeviceInstance(struct ndr_print *ndr, const char *name, int flags, const struct PNP_ValidateDeviceInstance *r)
+{
+ ndr_print_struct(ndr, name, "PNP_ValidateDeviceInstance");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_ValidateDeviceInstance");
+ ndr->depth++;
+ ndr_print_ptr(ndr, "devicepath", r->in.devicepath);
+ ndr->depth++;
+ ndr_print_string(ndr, "devicepath", r->in.devicepath);
+ ndr->depth--;
+ ndr_print_uint32(ndr, "flags", r->in.flags);
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_ValidateDeviceInstance");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_GetRootDeviceInstance(struct ndr_push *ndr, int flags, const struct PNP_GetRootDeviceInstance *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_GetRootDeviceInstance(struct ndr_pull *ndr, int flags, struct PNP_GetRootDeviceInstance *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_GetRootDeviceInstance(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetRootDeviceInstance *r)
+{
+ ndr_print_struct(ndr, name, "PNP_GetRootDeviceInstance");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_GetRootDeviceInstance");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_GetRootDeviceInstance");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_GetRelatedDeviceInstance(struct ndr_push *ndr, int flags, const struct PNP_GetRelatedDeviceInstance *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_GetRelatedDeviceInstance(struct ndr_pull *ndr, int flags, struct PNP_GetRelatedDeviceInstance *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_GetRelatedDeviceInstance(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetRelatedDeviceInstance *r)
+{
+ ndr_print_struct(ndr, name, "PNP_GetRelatedDeviceInstance");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_GetRelatedDeviceInstance");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_GetRelatedDeviceInstance");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_EnumerateSubKeys(struct ndr_push *ndr, int flags, const struct PNP_EnumerateSubKeys *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_EnumerateSubKeys(struct ndr_pull *ndr, int flags, struct PNP_EnumerateSubKeys *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_EnumerateSubKeys(struct ndr_print *ndr, const char *name, int flags, const struct PNP_EnumerateSubKeys *r)
+{
+ ndr_print_struct(ndr, name, "PNP_EnumerateSubKeys");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_EnumerateSubKeys");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_EnumerateSubKeys");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_GetDeviceList(struct ndr_push *ndr, int flags, const struct PNP_GetDeviceList *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_GetDeviceList(struct ndr_pull *ndr, int flags, struct PNP_GetDeviceList *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_GetDeviceList(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetDeviceList *r)
+{
+ ndr_print_struct(ndr, name, "PNP_GetDeviceList");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_GetDeviceList");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_GetDeviceList");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_GetDeviceListSize(struct ndr_push *ndr, int flags, const struct PNP_GetDeviceListSize *r)
+{
+ if (flags & NDR_IN) {
+ NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.devicename));
+ if (r->in.devicename) {
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, ndr_charset_length(r->in.devicename, CH_UTF16)));
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, 0));
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, ndr_charset_length(r->in.devicename, CH_UTF16)));
+ NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.devicename, ndr_charset_length(r->in.devicename, CH_UTF16), sizeof(uint16_t), CH_UTF16));
+ }
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.flags));
+ }
+ if (flags & NDR_OUT) {
+ if (r->out.size == NULL) {
+ return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
+ }
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.size));
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_GetDeviceListSize(struct ndr_pull *ndr, int flags, struct PNP_GetDeviceListSize *r)
+{
+ uint32_t _ptr_devicename;
+ TALLOC_CTX *_mem_save_devicename_0;
+ TALLOC_CTX *_mem_save_size_0;
+ if (flags & NDR_IN) {
+ ZERO_STRUCT(r->out);
+
+ NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_devicename));
+ if (_ptr_devicename) {
+ NDR_PULL_ALLOC(ndr, r->in.devicename);
+ } else {
+ r->in.devicename = NULL;
+ }
+ if (r->in.devicename) {
+ _mem_save_devicename_0 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, r->in.devicename, 0);
+ NDR_CHECK(ndr_pull_array_size(ndr, &r->in.devicename));
+ NDR_CHECK(ndr_pull_array_length(ndr, &r->in.devicename));
+ if (ndr_get_array_length(ndr, &r->in.devicename) > ndr_get_array_size(ndr, &r->in.devicename)) {
+ return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr, &r->in.devicename), ndr_get_array_length(ndr, &r->in.devicename));
+ }
+ NDR_CHECK(ndr_check_string_terminator(ndr, ndr_get_array_length(ndr, &r->in.devicename), sizeof(uint16_t)));
+ NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.devicename, ndr_get_array_length(ndr, &r->in.devicename), sizeof(uint16_t), CH_UTF16));
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_devicename_0, 0);
+ }
+ NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.flags));
+ NDR_PULL_ALLOC(ndr, r->out.size);
+ ZERO_STRUCTP(r->out.size);
+ }
+ if (flags & NDR_OUT) {
+ if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
+ NDR_PULL_ALLOC(ndr, r->out.size);
+ }
+ _mem_save_size_0 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, r->out.size, LIBNDR_FLAG_REF_ALLOC);
+ NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.size));
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_size_0, LIBNDR_FLAG_REF_ALLOC);
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_GetDeviceListSize(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetDeviceListSize *r)
+{
+ ndr_print_struct(ndr, name, "PNP_GetDeviceListSize");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_GetDeviceListSize");
+ ndr->depth++;
+ ndr_print_ptr(ndr, "devicename", r->in.devicename);
+ ndr->depth++;
+ if (r->in.devicename) {
+ ndr_print_string(ndr, "devicename", r->in.devicename);
+ }
+ ndr->depth--;
+ ndr_print_uint32(ndr, "flags", r->in.flags);
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_GetDeviceListSize");
+ ndr->depth++;
+ ndr_print_ptr(ndr, "size", r->out.size);
+ ndr->depth++;
+ ndr_print_uint32(ndr, "size", *r->out.size);
+ ndr->depth--;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_GetDepth(struct ndr_push *ndr, int flags, const struct PNP_GetDepth *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_GetDepth(struct ndr_pull *ndr, int flags, struct PNP_GetDepth *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_GetDepth(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetDepth *r)
+{
+ ndr_print_struct(ndr, name, "PNP_GetDepth");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_GetDepth");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_GetDepth");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_GetDeviceRegProp(struct ndr_push *ndr, int flags, const struct PNP_GetDeviceRegProp *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_GetDeviceRegProp(struct ndr_pull *ndr, int flags, struct PNP_GetDeviceRegProp *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_GetDeviceRegProp(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetDeviceRegProp *r)
+{
+ ndr_print_struct(ndr, name, "PNP_GetDeviceRegProp");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_GetDeviceRegProp");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_GetDeviceRegProp");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_SetDeviceRegProp(struct ndr_push *ndr, int flags, const struct PNP_SetDeviceRegProp *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_SetDeviceRegProp(struct ndr_pull *ndr, int flags, struct PNP_SetDeviceRegProp *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_SetDeviceRegProp(struct ndr_print *ndr, const char *name, int flags, const struct PNP_SetDeviceRegProp *r)
+{
+ ndr_print_struct(ndr, name, "PNP_SetDeviceRegProp");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_SetDeviceRegProp");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_SetDeviceRegProp");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_GetClassInstance(struct ndr_push *ndr, int flags, const struct PNP_GetClassInstance *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_GetClassInstance(struct ndr_pull *ndr, int flags, struct PNP_GetClassInstance *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_GetClassInstance(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetClassInstance *r)
+{
+ ndr_print_struct(ndr, name, "PNP_GetClassInstance");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_GetClassInstance");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_GetClassInstance");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_CreateKey(struct ndr_push *ndr, int flags, const struct PNP_CreateKey *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_CreateKey(struct ndr_pull *ndr, int flags, struct PNP_CreateKey *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_CreateKey(struct ndr_print *ndr, const char *name, int flags, const struct PNP_CreateKey *r)
+{
+ ndr_print_struct(ndr, name, "PNP_CreateKey");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_CreateKey");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_CreateKey");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_DeleteRegistryKey(struct ndr_push *ndr, int flags, const struct PNP_DeleteRegistryKey *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_DeleteRegistryKey(struct ndr_pull *ndr, int flags, struct PNP_DeleteRegistryKey *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_DeleteRegistryKey(struct ndr_print *ndr, const char *name, int flags, const struct PNP_DeleteRegistryKey *r)
+{
+ ndr_print_struct(ndr, name, "PNP_DeleteRegistryKey");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_DeleteRegistryKey");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_DeleteRegistryKey");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_GetClassCount(struct ndr_push *ndr, int flags, const struct PNP_GetClassCount *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_GetClassCount(struct ndr_pull *ndr, int flags, struct PNP_GetClassCount *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_GetClassCount(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetClassCount *r)
+{
+ ndr_print_struct(ndr, name, "PNP_GetClassCount");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_GetClassCount");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_GetClassCount");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_GetClassName(struct ndr_push *ndr, int flags, const struct PNP_GetClassName *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_GetClassName(struct ndr_pull *ndr, int flags, struct PNP_GetClassName *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_GetClassName(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetClassName *r)
+{
+ ndr_print_struct(ndr, name, "PNP_GetClassName");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_GetClassName");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_GetClassName");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_DeleteClassKey(struct ndr_push *ndr, int flags, const struct PNP_DeleteClassKey *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_DeleteClassKey(struct ndr_pull *ndr, int flags, struct PNP_DeleteClassKey *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_DeleteClassKey(struct ndr_print *ndr, const char *name, int flags, const struct PNP_DeleteClassKey *r)
+{
+ ndr_print_struct(ndr, name, "PNP_DeleteClassKey");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_DeleteClassKey");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_DeleteClassKey");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_GetInterfaceDeviceAlias(struct ndr_push *ndr, int flags, const struct PNP_GetInterfaceDeviceAlias *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_GetInterfaceDeviceAlias(struct ndr_pull *ndr, int flags, struct PNP_GetInterfaceDeviceAlias *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_GetInterfaceDeviceAlias(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetInterfaceDeviceAlias *r)
+{
+ ndr_print_struct(ndr, name, "PNP_GetInterfaceDeviceAlias");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_GetInterfaceDeviceAlias");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_GetInterfaceDeviceAlias");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_GetInterfaceDeviceList(struct ndr_push *ndr, int flags, const struct PNP_GetInterfaceDeviceList *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_GetInterfaceDeviceList(struct ndr_pull *ndr, int flags, struct PNP_GetInterfaceDeviceList *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_GetInterfaceDeviceList(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetInterfaceDeviceList *r)
+{
+ ndr_print_struct(ndr, name, "PNP_GetInterfaceDeviceList");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_GetInterfaceDeviceList");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_GetInterfaceDeviceList");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_GetInterfaceDeviceListSize(struct ndr_push *ndr, int flags, const struct PNP_GetInterfaceDeviceListSize *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_GetInterfaceDeviceListSize(struct ndr_pull *ndr, int flags, struct PNP_GetInterfaceDeviceListSize *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_GetInterfaceDeviceListSize(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetInterfaceDeviceListSize *r)
+{
+ ndr_print_struct(ndr, name, "PNP_GetInterfaceDeviceListSize");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_GetInterfaceDeviceListSize");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_GetInterfaceDeviceListSize");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_RegisterDeviceClassAssociation(struct ndr_push *ndr, int flags, const struct PNP_RegisterDeviceClassAssociation *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_RegisterDeviceClassAssociation(struct ndr_pull *ndr, int flags, struct PNP_RegisterDeviceClassAssociation *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_RegisterDeviceClassAssociation(struct ndr_print *ndr, const char *name, int flags, const struct PNP_RegisterDeviceClassAssociation *r)
+{
+ ndr_print_struct(ndr, name, "PNP_RegisterDeviceClassAssociation");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_RegisterDeviceClassAssociation");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_RegisterDeviceClassAssociation");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_UnregisterDeviceClassAssociation(struct ndr_push *ndr, int flags, const struct PNP_UnregisterDeviceClassAssociation *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_UnregisterDeviceClassAssociation(struct ndr_pull *ndr, int flags, struct PNP_UnregisterDeviceClassAssociation *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_UnregisterDeviceClassAssociation(struct ndr_print *ndr, const char *name, int flags, const struct PNP_UnregisterDeviceClassAssociation *r)
+{
+ ndr_print_struct(ndr, name, "PNP_UnregisterDeviceClassAssociation");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_UnregisterDeviceClassAssociation");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_UnregisterDeviceClassAssociation");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_GetClassRegProp(struct ndr_push *ndr, int flags, const struct PNP_GetClassRegProp *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_GetClassRegProp(struct ndr_pull *ndr, int flags, struct PNP_GetClassRegProp *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_GetClassRegProp(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetClassRegProp *r)
+{
+ ndr_print_struct(ndr, name, "PNP_GetClassRegProp");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_GetClassRegProp");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_GetClassRegProp");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_SetClassRegProp(struct ndr_push *ndr, int flags, const struct PNP_SetClassRegProp *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_SetClassRegProp(struct ndr_pull *ndr, int flags, struct PNP_SetClassRegProp *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_SetClassRegProp(struct ndr_print *ndr, const char *name, int flags, const struct PNP_SetClassRegProp *r)
+{
+ ndr_print_struct(ndr, name, "PNP_SetClassRegProp");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_SetClassRegProp");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_SetClassRegProp");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_CreateDevInst(struct ndr_push *ndr, int flags, const struct PNP_CreateDevInst *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_CreateDevInst(struct ndr_pull *ndr, int flags, struct PNP_CreateDevInst *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_CreateDevInst(struct ndr_print *ndr, const char *name, int flags, const struct PNP_CreateDevInst *r)
+{
+ ndr_print_struct(ndr, name, "PNP_CreateDevInst");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_CreateDevInst");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_CreateDevInst");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_DeviceInstanceAction(struct ndr_push *ndr, int flags, const struct PNP_DeviceInstanceAction *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_DeviceInstanceAction(struct ndr_pull *ndr, int flags, struct PNP_DeviceInstanceAction *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_DeviceInstanceAction(struct ndr_print *ndr, const char *name, int flags, const struct PNP_DeviceInstanceAction *r)
+{
+ ndr_print_struct(ndr, name, "PNP_DeviceInstanceAction");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_DeviceInstanceAction");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_DeviceInstanceAction");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_GetDeviceStatus(struct ndr_push *ndr, int flags, const struct PNP_GetDeviceStatus *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_GetDeviceStatus(struct ndr_pull *ndr, int flags, struct PNP_GetDeviceStatus *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_GetDeviceStatus(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetDeviceStatus *r)
+{
+ ndr_print_struct(ndr, name, "PNP_GetDeviceStatus");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_GetDeviceStatus");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_GetDeviceStatus");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_SetDeviceProblem(struct ndr_push *ndr, int flags, const struct PNP_SetDeviceProblem *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_SetDeviceProblem(struct ndr_pull *ndr, int flags, struct PNP_SetDeviceProblem *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_SetDeviceProblem(struct ndr_print *ndr, const char *name, int flags, const struct PNP_SetDeviceProblem *r)
+{
+ ndr_print_struct(ndr, name, "PNP_SetDeviceProblem");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_SetDeviceProblem");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_SetDeviceProblem");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_DisableDevInst(struct ndr_push *ndr, int flags, const struct PNP_DisableDevInst *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_DisableDevInst(struct ndr_pull *ndr, int flags, struct PNP_DisableDevInst *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_DisableDevInst(struct ndr_print *ndr, const char *name, int flags, const struct PNP_DisableDevInst *r)
+{
+ ndr_print_struct(ndr, name, "PNP_DisableDevInst");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_DisableDevInst");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_DisableDevInst");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_UninstallDevInst(struct ndr_push *ndr, int flags, const struct PNP_UninstallDevInst *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_UninstallDevInst(struct ndr_pull *ndr, int flags, struct PNP_UninstallDevInst *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_UninstallDevInst(struct ndr_print *ndr, const char *name, int flags, const struct PNP_UninstallDevInst *r)
+{
+ ndr_print_struct(ndr, name, "PNP_UninstallDevInst");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_UninstallDevInst");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_UninstallDevInst");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_AddID(struct ndr_push *ndr, int flags, const struct PNP_AddID *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_AddID(struct ndr_pull *ndr, int flags, struct PNP_AddID *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_AddID(struct ndr_print *ndr, const char *name, int flags, const struct PNP_AddID *r)
+{
+ ndr_print_struct(ndr, name, "PNP_AddID");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_AddID");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_AddID");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_RegisterDriver(struct ndr_push *ndr, int flags, const struct PNP_RegisterDriver *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_RegisterDriver(struct ndr_pull *ndr, int flags, struct PNP_RegisterDriver *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_RegisterDriver(struct ndr_print *ndr, const char *name, int flags, const struct PNP_RegisterDriver *r)
+{
+ ndr_print_struct(ndr, name, "PNP_RegisterDriver");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_RegisterDriver");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_RegisterDriver");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_QueryRemove(struct ndr_push *ndr, int flags, const struct PNP_QueryRemove *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_QueryRemove(struct ndr_pull *ndr, int flags, struct PNP_QueryRemove *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_QueryRemove(struct ndr_print *ndr, const char *name, int flags, const struct PNP_QueryRemove *r)
+{
+ ndr_print_struct(ndr, name, "PNP_QueryRemove");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_QueryRemove");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_QueryRemove");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_RequestDeviceEject(struct ndr_push *ndr, int flags, const struct PNP_RequestDeviceEject *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_RequestDeviceEject(struct ndr_pull *ndr, int flags, struct PNP_RequestDeviceEject *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_RequestDeviceEject(struct ndr_print *ndr, const char *name, int flags, const struct PNP_RequestDeviceEject *r)
+{
+ ndr_print_struct(ndr, name, "PNP_RequestDeviceEject");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_RequestDeviceEject");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_RequestDeviceEject");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_IsDockStationPresent(struct ndr_push *ndr, int flags, const struct PNP_IsDockStationPresent *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_IsDockStationPresent(struct ndr_pull *ndr, int flags, struct PNP_IsDockStationPresent *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_IsDockStationPresent(struct ndr_print *ndr, const char *name, int flags, const struct PNP_IsDockStationPresent *r)
+{
+ ndr_print_struct(ndr, name, "PNP_IsDockStationPresent");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_IsDockStationPresent");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_IsDockStationPresent");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_RequestEjectPC(struct ndr_push *ndr, int flags, const struct PNP_RequestEjectPC *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_RequestEjectPC(struct ndr_pull *ndr, int flags, struct PNP_RequestEjectPC *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_RequestEjectPC(struct ndr_print *ndr, const char *name, int flags, const struct PNP_RequestEjectPC *r)
+{
+ ndr_print_struct(ndr, name, "PNP_RequestEjectPC");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_RequestEjectPC");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_RequestEjectPC");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_HwProfFlags(struct ndr_push *ndr, int flags, const struct PNP_HwProfFlags *r)
+{
+ if (flags & NDR_IN) {
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.unknown1));
+ if (r->in.devicepath == NULL) {
+ return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
+ }
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, ndr_charset_length(r->in.devicepath, CH_UTF16)));
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, 0));
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, ndr_charset_length(r->in.devicepath, CH_UTF16)));
+ NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.devicepath, ndr_charset_length(r->in.devicepath, CH_UTF16), sizeof(uint16_t), CH_UTF16));
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.unknown2));
+ if (r->in.unknown3 == NULL) {
+ return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
+ }
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->in.unknown3));
+ NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.unknown4));
+ if (r->in.unknown4) {
+ NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, *r->in.unknown4));
+ }
+ NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.unknown5));
+ if (r->in.unknown5) {
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, ndr_charset_length(r->in.unknown5, CH_UTF16)));
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, 0));
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, ndr_charset_length(r->in.unknown5, CH_UTF16)));
+ NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.unknown5, ndr_charset_length(r->in.unknown5, CH_UTF16), sizeof(uint16_t), CH_UTF16));
+ }
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.unknown6));
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.unknown7));
+ }
+ if (flags & NDR_OUT) {
+ if (r->out.unknown3 == NULL) {
+ return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
+ }
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.unknown3));
+ NDR_CHECK(ndr_push_unique_ptr(ndr, r->out.unknown4));
+ if (r->out.unknown4) {
+ NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, *r->out.unknown4));
+ }
+ NDR_CHECK(ndr_push_unique_ptr(ndr, r->out.unknown5a));
+ if (r->out.unknown5a) {
+ NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.unknown5a));
+ if (*r->out.unknown5a) {
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, ndr_charset_length(*r->out.unknown5a, CH_UTF16)));
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, 0));
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, ndr_charset_length(*r->out.unknown5a, CH_UTF16)));
+ NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, *r->out.unknown5a, ndr_charset_length(*r->out.unknown5a, CH_UTF16), sizeof(uint16_t), CH_UTF16));
+ }
+ }
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_HwProfFlags(struct ndr_pull *ndr, int flags, struct PNP_HwProfFlags *r)
+{
+ uint32_t _ptr_unknown4;
+ uint32_t _ptr_unknown5;
+ uint32_t _ptr_unknown5a;
+ TALLOC_CTX *_mem_save_unknown3_0;
+ TALLOC_CTX *_mem_save_unknown4_0;
+ TALLOC_CTX *_mem_save_unknown5_0;
+ TALLOC_CTX *_mem_save_unknown5a_0;
+ TALLOC_CTX *_mem_save_unknown5a_1;
+ if (flags & NDR_IN) {
+ ZERO_STRUCT(r->out);
+
+ NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.unknown1));
+ NDR_CHECK(ndr_pull_array_size(ndr, &r->in.devicepath));
+ NDR_CHECK(ndr_pull_array_length(ndr, &r->in.devicepath));
+ if (ndr_get_array_length(ndr, &r->in.devicepath) > ndr_get_array_size(ndr, &r->in.devicepath)) {
+ return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr, &r->in.devicepath), ndr_get_array_length(ndr, &r->in.devicepath));
+ }
+ NDR_CHECK(ndr_check_string_terminator(ndr, ndr_get_array_length(ndr, &r->in.devicepath), sizeof(uint16_t)));
+ NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.devicepath, ndr_get_array_length(ndr, &r->in.devicepath), sizeof(uint16_t), CH_UTF16));
+ NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.unknown2));
+ if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
+ NDR_PULL_ALLOC(ndr, r->in.unknown3);
+ }
+ _mem_save_unknown3_0 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, r->in.unknown3, LIBNDR_FLAG_REF_ALLOC);
+ NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->in.unknown3));
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_unknown3_0, LIBNDR_FLAG_REF_ALLOC);
+ NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_unknown4));
+ if (_ptr_unknown4) {
+ NDR_PULL_ALLOC(ndr, r->in.unknown4);
+ } else {
+ r->in.unknown4 = NULL;
+ }
+ if (r->in.unknown4) {
+ _mem_save_unknown4_0 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, r->in.unknown4, 0);
+ NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, r->in.unknown4));
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_unknown4_0, 0);
+ }
+ NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_unknown5));
+ if (_ptr_unknown5) {
+ NDR_PULL_ALLOC(ndr, r->in.unknown5);
+ } else {
+ r->in.unknown5 = NULL;
+ }
+ if (r->in.unknown5) {
+ _mem_save_unknown5_0 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, r->in.unknown5, 0);
+ NDR_CHECK(ndr_pull_array_size(ndr, &r->in.unknown5));
+ NDR_CHECK(ndr_pull_array_length(ndr, &r->in.unknown5));
+ if (ndr_get_array_length(ndr, &r->in.unknown5) > ndr_get_array_size(ndr, &r->in.unknown5)) {
+ return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr, &r->in.unknown5), ndr_get_array_length(ndr, &r->in.unknown5));
+ }
+ NDR_CHECK(ndr_check_string_terminator(ndr, ndr_get_array_length(ndr, &r->in.unknown5), sizeof(uint16_t)));
+ NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.unknown5, ndr_get_array_length(ndr, &r->in.unknown5), sizeof(uint16_t), CH_UTF16));
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_unknown5_0, 0);
+ }
+ NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.unknown6));
+ NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.unknown7));
+ NDR_PULL_ALLOC(ndr, r->out.unknown3);
+ *r->out.unknown3 = *r->in.unknown3;
+ }
+ if (flags & NDR_OUT) {
+ if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
+ NDR_PULL_ALLOC(ndr, r->out.unknown3);
+ }
+ _mem_save_unknown3_0 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, r->out.unknown3, LIBNDR_FLAG_REF_ALLOC);
+ NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.unknown3));
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_unknown3_0, LIBNDR_FLAG_REF_ALLOC);
+ NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_unknown4));
+ if (_ptr_unknown4) {
+ NDR_PULL_ALLOC(ndr, r->out.unknown4);
+ } else {
+ r->out.unknown4 = NULL;
+ }
+ if (r->out.unknown4) {
+ _mem_save_unknown4_0 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, r->out.unknown4, 0);
+ NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, r->out.unknown4));
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_unknown4_0, 0);
+ }
+ NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_unknown5a));
+ if (_ptr_unknown5a) {
+ NDR_PULL_ALLOC(ndr, r->out.unknown5a);
+ } else {
+ r->out.unknown5a = NULL;
+ }
+ if (r->out.unknown5a) {
+ _mem_save_unknown5a_0 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, r->out.unknown5a, 0);
+ NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_unknown5a));
+ if (_ptr_unknown5a) {
+ NDR_PULL_ALLOC(ndr, *r->out.unknown5a);
+ } else {
+ *r->out.unknown5a = NULL;
+ }
+ if (*r->out.unknown5a) {
+ _mem_save_unknown5a_1 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, *r->out.unknown5a, 0);
+ NDR_CHECK(ndr_pull_array_size(ndr, r->out.unknown5a));
+ NDR_CHECK(ndr_pull_array_length(ndr, r->out.unknown5a));
+ if (ndr_get_array_length(ndr, r->out.unknown5a) > ndr_get_array_size(ndr, r->out.unknown5a)) {
+ return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr, r->out.unknown5a), ndr_get_array_length(ndr, r->out.unknown5a));
+ }
+ NDR_CHECK(ndr_check_string_terminator(ndr, ndr_get_array_length(ndr, r->out.unknown5a), sizeof(uint16_t)));
+ NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, r->out.unknown5a, ndr_get_array_length(ndr, r->out.unknown5a), sizeof(uint16_t), CH_UTF16));
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_unknown5a_1, 0);
+ }
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_unknown5a_0, 0);
+ }
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_HwProfFlags(struct ndr_print *ndr, const char *name, int flags, const struct PNP_HwProfFlags *r)
+{
+ ndr_print_struct(ndr, name, "PNP_HwProfFlags");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_HwProfFlags");
+ ndr->depth++;
+ ndr_print_uint32(ndr, "unknown1", r->in.unknown1);
+ ndr_print_ptr(ndr, "devicepath", r->in.devicepath);
+ ndr->depth++;
+ ndr_print_string(ndr, "devicepath", r->in.devicepath);
+ ndr->depth--;
+ ndr_print_uint32(ndr, "unknown2", r->in.unknown2);
+ ndr_print_ptr(ndr, "unknown3", r->in.unknown3);
+ ndr->depth++;
+ ndr_print_uint32(ndr, "unknown3", *r->in.unknown3);
+ ndr->depth--;
+ ndr_print_ptr(ndr, "unknown4", r->in.unknown4);
+ ndr->depth++;
+ if (r->in.unknown4) {
+ ndr_print_uint16(ndr, "unknown4", *r->in.unknown4);
+ }
+ ndr->depth--;
+ ndr_print_ptr(ndr, "unknown5", r->in.unknown5);
+ ndr->depth++;
+ if (r->in.unknown5) {
+ ndr_print_string(ndr, "unknown5", r->in.unknown5);
+ }
+ ndr->depth--;
+ ndr_print_uint32(ndr, "unknown6", r->in.unknown6);
+ ndr_print_uint32(ndr, "unknown7", r->in.unknown7);
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_HwProfFlags");
+ ndr->depth++;
+ ndr_print_ptr(ndr, "unknown3", r->out.unknown3);
+ ndr->depth++;
+ ndr_print_uint32(ndr, "unknown3", *r->out.unknown3);
+ ndr->depth--;
+ ndr_print_ptr(ndr, "unknown4", r->out.unknown4);
+ ndr->depth++;
+ if (r->out.unknown4) {
+ ndr_print_uint16(ndr, "unknown4", *r->out.unknown4);
+ }
+ ndr->depth--;
+ ndr_print_ptr(ndr, "unknown5a", r->out.unknown5a);
+ ndr->depth++;
+ if (r->out.unknown5a) {
+ ndr_print_ptr(ndr, "unknown5a", *r->out.unknown5a);
+ ndr->depth++;
+ if (*r->out.unknown5a) {
+ ndr_print_string(ndr, "unknown5a", *r->out.unknown5a);
+ }
+ ndr->depth--;
+ }
+ ndr->depth--;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_GetHwProfInfo(struct ndr_push *ndr, int flags, const struct PNP_GetHwProfInfo *r)
+{
+ if (flags & NDR_IN) {
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.idx));
+ if (r->in.info == NULL) {
+ return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
+ }
+ NDR_CHECK(ndr_push_PNP_HwProfInfo(ndr, NDR_SCALARS, r->in.info));
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.unknown1));
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.unknown2));
+ }
+ if (flags & NDR_OUT) {
+ if (r->out.info == NULL) {
+ return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
+ }
+ NDR_CHECK(ndr_push_PNP_HwProfInfo(ndr, NDR_SCALARS, r->out.info));
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_GetHwProfInfo(struct ndr_pull *ndr, int flags, struct PNP_GetHwProfInfo *r)
+{
+ TALLOC_CTX *_mem_save_info_0;
+ if (flags & NDR_IN) {
+ ZERO_STRUCT(r->out);
+
+ NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.idx));
+ if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
+ NDR_PULL_ALLOC(ndr, r->in.info);
+ }
+ _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, r->in.info, LIBNDR_FLAG_REF_ALLOC);
+ NDR_CHECK(ndr_pull_PNP_HwProfInfo(ndr, NDR_SCALARS, r->in.info));
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
+ NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.unknown1));
+ NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.unknown2));
+ NDR_PULL_ALLOC(ndr, r->out.info);
+ *r->out.info = *r->in.info;
+ }
+ if (flags & NDR_OUT) {
+ if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
+ NDR_PULL_ALLOC(ndr, r->out.info);
+ }
+ _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, r->out.info, LIBNDR_FLAG_REF_ALLOC);
+ NDR_CHECK(ndr_pull_PNP_HwProfInfo(ndr, NDR_SCALARS, r->out.info));
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_GetHwProfInfo(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetHwProfInfo *r)
+{
+ ndr_print_struct(ndr, name, "PNP_GetHwProfInfo");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_GetHwProfInfo");
+ ndr->depth++;
+ ndr_print_uint32(ndr, "idx", r->in.idx);
+ ndr_print_ptr(ndr, "info", r->in.info);
+ ndr->depth++;
+ ndr_print_PNP_HwProfInfo(ndr, "info", r->in.info);
+ ndr->depth--;
+ ndr_print_uint32(ndr, "unknown1", r->in.unknown1);
+ ndr_print_uint32(ndr, "unknown2", r->in.unknown2);
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_GetHwProfInfo");
+ ndr->depth++;
+ ndr_print_ptr(ndr, "info", r->out.info);
+ ndr->depth++;
+ ndr_print_PNP_HwProfInfo(ndr, "info", r->out.info);
+ ndr->depth--;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_AddEmptyLogConf(struct ndr_push *ndr, int flags, const struct PNP_AddEmptyLogConf *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_AddEmptyLogConf(struct ndr_pull *ndr, int flags, struct PNP_AddEmptyLogConf *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_AddEmptyLogConf(struct ndr_print *ndr, const char *name, int flags, const struct PNP_AddEmptyLogConf *r)
+{
+ ndr_print_struct(ndr, name, "PNP_AddEmptyLogConf");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_AddEmptyLogConf");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_AddEmptyLogConf");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_FreeLogConf(struct ndr_push *ndr, int flags, const struct PNP_FreeLogConf *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_FreeLogConf(struct ndr_pull *ndr, int flags, struct PNP_FreeLogConf *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_FreeLogConf(struct ndr_print *ndr, const char *name, int flags, const struct PNP_FreeLogConf *r)
+{
+ ndr_print_struct(ndr, name, "PNP_FreeLogConf");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_FreeLogConf");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_FreeLogConf");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_GetFirstLogConf(struct ndr_push *ndr, int flags, const struct PNP_GetFirstLogConf *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_GetFirstLogConf(struct ndr_pull *ndr, int flags, struct PNP_GetFirstLogConf *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_GetFirstLogConf(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetFirstLogConf *r)
+{
+ ndr_print_struct(ndr, name, "PNP_GetFirstLogConf");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_GetFirstLogConf");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_GetFirstLogConf");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_GetNextLogConf(struct ndr_push *ndr, int flags, const struct PNP_GetNextLogConf *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_GetNextLogConf(struct ndr_pull *ndr, int flags, struct PNP_GetNextLogConf *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_GetNextLogConf(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetNextLogConf *r)
+{
+ ndr_print_struct(ndr, name, "PNP_GetNextLogConf");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_GetNextLogConf");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_GetNextLogConf");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_GetLogConfPriority(struct ndr_push *ndr, int flags, const struct PNP_GetLogConfPriority *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_GetLogConfPriority(struct ndr_pull *ndr, int flags, struct PNP_GetLogConfPriority *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_GetLogConfPriority(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetLogConfPriority *r)
+{
+ ndr_print_struct(ndr, name, "PNP_GetLogConfPriority");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_GetLogConfPriority");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_GetLogConfPriority");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_AddResDes(struct ndr_push *ndr, int flags, const struct PNP_AddResDes *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_AddResDes(struct ndr_pull *ndr, int flags, struct PNP_AddResDes *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_AddResDes(struct ndr_print *ndr, const char *name, int flags, const struct PNP_AddResDes *r)
+{
+ ndr_print_struct(ndr, name, "PNP_AddResDes");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_AddResDes");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_AddResDes");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_FreeResDes(struct ndr_push *ndr, int flags, const struct PNP_FreeResDes *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_FreeResDes(struct ndr_pull *ndr, int flags, struct PNP_FreeResDes *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_FreeResDes(struct ndr_print *ndr, const char *name, int flags, const struct PNP_FreeResDes *r)
+{
+ ndr_print_struct(ndr, name, "PNP_FreeResDes");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_FreeResDes");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_FreeResDes");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_GetNextResDes(struct ndr_push *ndr, int flags, const struct PNP_GetNextResDes *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_GetNextResDes(struct ndr_pull *ndr, int flags, struct PNP_GetNextResDes *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_GetNextResDes(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetNextResDes *r)
+{
+ ndr_print_struct(ndr, name, "PNP_GetNextResDes");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_GetNextResDes");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_GetNextResDes");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_GetResDesData(struct ndr_push *ndr, int flags, const struct PNP_GetResDesData *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_GetResDesData(struct ndr_pull *ndr, int flags, struct PNP_GetResDesData *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_GetResDesData(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetResDesData *r)
+{
+ ndr_print_struct(ndr, name, "PNP_GetResDesData");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_GetResDesData");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_GetResDesData");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_GetResDesDataSize(struct ndr_push *ndr, int flags, const struct PNP_GetResDesDataSize *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_GetResDesDataSize(struct ndr_pull *ndr, int flags, struct PNP_GetResDesDataSize *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_GetResDesDataSize(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetResDesDataSize *r)
+{
+ ndr_print_struct(ndr, name, "PNP_GetResDesDataSize");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_GetResDesDataSize");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_GetResDesDataSize");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_ModifyResDes(struct ndr_push *ndr, int flags, const struct PNP_ModifyResDes *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_ModifyResDes(struct ndr_pull *ndr, int flags, struct PNP_ModifyResDes *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_ModifyResDes(struct ndr_print *ndr, const char *name, int flags, const struct PNP_ModifyResDes *r)
+{
+ ndr_print_struct(ndr, name, "PNP_ModifyResDes");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_ModifyResDes");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_ModifyResDes");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_DetectResourceLimit(struct ndr_push *ndr, int flags, const struct PNP_DetectResourceLimit *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_DetectResourceLimit(struct ndr_pull *ndr, int flags, struct PNP_DetectResourceLimit *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_DetectResourceLimit(struct ndr_print *ndr, const char *name, int flags, const struct PNP_DetectResourceLimit *r)
+{
+ ndr_print_struct(ndr, name, "PNP_DetectResourceLimit");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_DetectResourceLimit");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_DetectResourceLimit");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_QueryResConfList(struct ndr_push *ndr, int flags, const struct PNP_QueryResConfList *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_QueryResConfList(struct ndr_pull *ndr, int flags, struct PNP_QueryResConfList *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_QueryResConfList(struct ndr_print *ndr, const char *name, int flags, const struct PNP_QueryResConfList *r)
+{
+ ndr_print_struct(ndr, name, "PNP_QueryResConfList");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_QueryResConfList");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_QueryResConfList");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_SetHwProf(struct ndr_push *ndr, int flags, const struct PNP_SetHwProf *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_SetHwProf(struct ndr_pull *ndr, int flags, struct PNP_SetHwProf *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_SetHwProf(struct ndr_print *ndr, const char *name, int flags, const struct PNP_SetHwProf *r)
+{
+ ndr_print_struct(ndr, name, "PNP_SetHwProf");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_SetHwProf");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_SetHwProf");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_QueryArbitratorFreeData(struct ndr_push *ndr, int flags, const struct PNP_QueryArbitratorFreeData *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_QueryArbitratorFreeData(struct ndr_pull *ndr, int flags, struct PNP_QueryArbitratorFreeData *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_QueryArbitratorFreeData(struct ndr_print *ndr, const char *name, int flags, const struct PNP_QueryArbitratorFreeData *r)
+{
+ ndr_print_struct(ndr, name, "PNP_QueryArbitratorFreeData");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_QueryArbitratorFreeData");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_QueryArbitratorFreeData");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_QueryArbitratorFreeSize(struct ndr_push *ndr, int flags, const struct PNP_QueryArbitratorFreeSize *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_QueryArbitratorFreeSize(struct ndr_pull *ndr, int flags, struct PNP_QueryArbitratorFreeSize *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_QueryArbitratorFreeSize(struct ndr_print *ndr, const char *name, int flags, const struct PNP_QueryArbitratorFreeSize *r)
+{
+ ndr_print_struct(ndr, name, "PNP_QueryArbitratorFreeSize");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_QueryArbitratorFreeSize");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_QueryArbitratorFreeSize");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_RunDetection(struct ndr_push *ndr, int flags, const struct PNP_RunDetection *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_RunDetection(struct ndr_pull *ndr, int flags, struct PNP_RunDetection *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_RunDetection(struct ndr_print *ndr, const char *name, int flags, const struct PNP_RunDetection *r)
+{
+ ndr_print_struct(ndr, name, "PNP_RunDetection");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_RunDetection");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_RunDetection");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_RegisterNotification(struct ndr_push *ndr, int flags, const struct PNP_RegisterNotification *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_RegisterNotification(struct ndr_pull *ndr, int flags, struct PNP_RegisterNotification *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_RegisterNotification(struct ndr_print *ndr, const char *name, int flags, const struct PNP_RegisterNotification *r)
+{
+ ndr_print_struct(ndr, name, "PNP_RegisterNotification");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_RegisterNotification");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_RegisterNotification");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_UnregisterNotification(struct ndr_push *ndr, int flags, const struct PNP_UnregisterNotification *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_UnregisterNotification(struct ndr_pull *ndr, int flags, struct PNP_UnregisterNotification *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_UnregisterNotification(struct ndr_print *ndr, const char *name, int flags, const struct PNP_UnregisterNotification *r)
+{
+ ndr_print_struct(ndr, name, "PNP_UnregisterNotification");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_UnregisterNotification");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_UnregisterNotification");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_GetCustomDevProp(struct ndr_push *ndr, int flags, const struct PNP_GetCustomDevProp *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_GetCustomDevProp(struct ndr_pull *ndr, int flags, struct PNP_GetCustomDevProp *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_GetCustomDevProp(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetCustomDevProp *r)
+{
+ ndr_print_struct(ndr, name, "PNP_GetCustomDevProp");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_GetCustomDevProp");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_GetCustomDevProp");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_GetVersionInternal(struct ndr_push *ndr, int flags, const struct PNP_GetVersionInternal *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_GetVersionInternal(struct ndr_pull *ndr, int flags, struct PNP_GetVersionInternal *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_GetVersionInternal(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetVersionInternal *r)
+{
+ ndr_print_struct(ndr, name, "PNP_GetVersionInternal");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_GetVersionInternal");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_GetVersionInternal");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_GetBlockedDriverInfo(struct ndr_push *ndr, int flags, const struct PNP_GetBlockedDriverInfo *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_GetBlockedDriverInfo(struct ndr_pull *ndr, int flags, struct PNP_GetBlockedDriverInfo *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_GetBlockedDriverInfo(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetBlockedDriverInfo *r)
+{
+ ndr_print_struct(ndr, name, "PNP_GetBlockedDriverInfo");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_GetBlockedDriverInfo");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_GetBlockedDriverInfo");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static enum ndr_err_code ndr_push_PNP_GetServerSideDeviceInstallFlags(struct ndr_push *ndr, int flags, const struct PNP_GetServerSideDeviceInstallFlags *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_PNP_GetServerSideDeviceInstallFlags(struct ndr_pull *ndr, int flags, struct PNP_GetServerSideDeviceInstallFlags *r)
+{
+ if (flags & NDR_IN) {
+ }
+ if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ }
+ return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_PNP_GetServerSideDeviceInstallFlags(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetServerSideDeviceInstallFlags *r)
+{
+ ndr_print_struct(ndr, name, "PNP_GetServerSideDeviceInstallFlags");
+ ndr->depth++;
+ if (flags & NDR_SET_VALUES) {
+ ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+ }
+ if (flags & NDR_IN) {
+ ndr_print_struct(ndr, "in", "PNP_GetServerSideDeviceInstallFlags");
+ ndr->depth++;
+ ndr->depth--;
+ }
+ if (flags & NDR_OUT) {
+ ndr_print_struct(ndr, "out", "PNP_GetServerSideDeviceInstallFlags");
+ ndr->depth++;
+ ndr_print_WERROR(ndr, "result", r->out.result);
+ ndr->depth--;
+ }
+ ndr->depth--;
+}
+
+static const struct ndr_interface_call ntsvcs_calls[] = {
+ {
+ "PNP_Disconnect",
+ sizeof(struct PNP_Disconnect),
+ (ndr_push_flags_fn_t) ndr_push_PNP_Disconnect,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_Disconnect,
+ (ndr_print_function_t) ndr_print_PNP_Disconnect,
+ false,
+ },
+ {
+ "PNP_Connect",
+ sizeof(struct PNP_Connect),
+ (ndr_push_flags_fn_t) ndr_push_PNP_Connect,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_Connect,
+ (ndr_print_function_t) ndr_print_PNP_Connect,
+ false,
+ },
+ {
+ "PNP_GetVersion",
+ sizeof(struct PNP_GetVersion),
+ (ndr_push_flags_fn_t) ndr_push_PNP_GetVersion,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_GetVersion,
+ (ndr_print_function_t) ndr_print_PNP_GetVersion,
+ false,
+ },
+ {
+ "PNP_GetGlobalState",
+ sizeof(struct PNP_GetGlobalState),
+ (ndr_push_flags_fn_t) ndr_push_PNP_GetGlobalState,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_GetGlobalState,
+ (ndr_print_function_t) ndr_print_PNP_GetGlobalState,
+ false,
+ },
+ {
+ "PNP_InitDetection",
+ sizeof(struct PNP_InitDetection),
+ (ndr_push_flags_fn_t) ndr_push_PNP_InitDetection,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_InitDetection,
+ (ndr_print_function_t) ndr_print_PNP_InitDetection,
+ false,
+ },
+ {
+ "PNP_ReportLogOn",
+ sizeof(struct PNP_ReportLogOn),
+ (ndr_push_flags_fn_t) ndr_push_PNP_ReportLogOn,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_ReportLogOn,
+ (ndr_print_function_t) ndr_print_PNP_ReportLogOn,
+ false,
+ },
+ {
+ "PNP_ValidateDeviceInstance",
+ sizeof(struct PNP_ValidateDeviceInstance),
+ (ndr_push_flags_fn_t) ndr_push_PNP_ValidateDeviceInstance,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_ValidateDeviceInstance,
+ (ndr_print_function_t) ndr_print_PNP_ValidateDeviceInstance,
+ false,
+ },
+ {
+ "PNP_GetRootDeviceInstance",
+ sizeof(struct PNP_GetRootDeviceInstance),
+ (ndr_push_flags_fn_t) ndr_push_PNP_GetRootDeviceInstance,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_GetRootDeviceInstance,
+ (ndr_print_function_t) ndr_print_PNP_GetRootDeviceInstance,
+ false,
+ },
+ {
+ "PNP_GetRelatedDeviceInstance",
+ sizeof(struct PNP_GetRelatedDeviceInstance),
+ (ndr_push_flags_fn_t) ndr_push_PNP_GetRelatedDeviceInstance,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_GetRelatedDeviceInstance,
+ (ndr_print_function_t) ndr_print_PNP_GetRelatedDeviceInstance,
+ false,
+ },
+ {
+ "PNP_EnumerateSubKeys",
+ sizeof(struct PNP_EnumerateSubKeys),
+ (ndr_push_flags_fn_t) ndr_push_PNP_EnumerateSubKeys,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_EnumerateSubKeys,
+ (ndr_print_function_t) ndr_print_PNP_EnumerateSubKeys,
+ false,
+ },
+ {
+ "PNP_GetDeviceList",
+ sizeof(struct PNP_GetDeviceList),
+ (ndr_push_flags_fn_t) ndr_push_PNP_GetDeviceList,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_GetDeviceList,
+ (ndr_print_function_t) ndr_print_PNP_GetDeviceList,
+ false,
+ },
+ {
+ "PNP_GetDeviceListSize",
+ sizeof(struct PNP_GetDeviceListSize),
+ (ndr_push_flags_fn_t) ndr_push_PNP_GetDeviceListSize,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_GetDeviceListSize,
+ (ndr_print_function_t) ndr_print_PNP_GetDeviceListSize,
+ false,
+ },
+ {
+ "PNP_GetDepth",
+ sizeof(struct PNP_GetDepth),
+ (ndr_push_flags_fn_t) ndr_push_PNP_GetDepth,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_GetDepth,
+ (ndr_print_function_t) ndr_print_PNP_GetDepth,
+ false,
+ },
+ {
+ "PNP_GetDeviceRegProp",
+ sizeof(struct PNP_GetDeviceRegProp),
+ (ndr_push_flags_fn_t) ndr_push_PNP_GetDeviceRegProp,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_GetDeviceRegProp,
+ (ndr_print_function_t) ndr_print_PNP_GetDeviceRegProp,
+ false,
+ },
+ {
+ "PNP_SetDeviceRegProp",
+ sizeof(struct PNP_SetDeviceRegProp),
+ (ndr_push_flags_fn_t) ndr_push_PNP_SetDeviceRegProp,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_SetDeviceRegProp,
+ (ndr_print_function_t) ndr_print_PNP_SetDeviceRegProp,
+ false,
+ },
+ {
+ "PNP_GetClassInstance",
+ sizeof(struct PNP_GetClassInstance),
+ (ndr_push_flags_fn_t) ndr_push_PNP_GetClassInstance,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_GetClassInstance,
+ (ndr_print_function_t) ndr_print_PNP_GetClassInstance,
+ false,
+ },
+ {
+ "PNP_CreateKey",
+ sizeof(struct PNP_CreateKey),
+ (ndr_push_flags_fn_t) ndr_push_PNP_CreateKey,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_CreateKey,
+ (ndr_print_function_t) ndr_print_PNP_CreateKey,
+ false,
+ },
+ {
+ "PNP_DeleteRegistryKey",
+ sizeof(struct PNP_DeleteRegistryKey),
+ (ndr_push_flags_fn_t) ndr_push_PNP_DeleteRegistryKey,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_DeleteRegistryKey,
+ (ndr_print_function_t) ndr_print_PNP_DeleteRegistryKey,
+ false,
+ },
+ {
+ "PNP_GetClassCount",
+ sizeof(struct PNP_GetClassCount),
+ (ndr_push_flags_fn_t) ndr_push_PNP_GetClassCount,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_GetClassCount,
+ (ndr_print_function_t) ndr_print_PNP_GetClassCount,
+ false,
+ },
+ {
+ "PNP_GetClassName",
+ sizeof(struct PNP_GetClassName),
+ (ndr_push_flags_fn_t) ndr_push_PNP_GetClassName,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_GetClassName,
+ (ndr_print_function_t) ndr_print_PNP_GetClassName,
+ false,
+ },
+ {
+ "PNP_DeleteClassKey",
+ sizeof(struct PNP_DeleteClassKey),
+ (ndr_push_flags_fn_t) ndr_push_PNP_DeleteClassKey,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_DeleteClassKey,
+ (ndr_print_function_t) ndr_print_PNP_DeleteClassKey,
+ false,
+ },
+ {
+ "PNP_GetInterfaceDeviceAlias",
+ sizeof(struct PNP_GetInterfaceDeviceAlias),
+ (ndr_push_flags_fn_t) ndr_push_PNP_GetInterfaceDeviceAlias,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_GetInterfaceDeviceAlias,
+ (ndr_print_function_t) ndr_print_PNP_GetInterfaceDeviceAlias,
+ false,
+ },
+ {
+ "PNP_GetInterfaceDeviceList",
+ sizeof(struct PNP_GetInterfaceDeviceList),
+ (ndr_push_flags_fn_t) ndr_push_PNP_GetInterfaceDeviceList,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_GetInterfaceDeviceList,
+ (ndr_print_function_t) ndr_print_PNP_GetInterfaceDeviceList,
+ false,
+ },
+ {
+ "PNP_GetInterfaceDeviceListSize",
+ sizeof(struct PNP_GetInterfaceDeviceListSize),
+ (ndr_push_flags_fn_t) ndr_push_PNP_GetInterfaceDeviceListSize,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_GetInterfaceDeviceListSize,
+ (ndr_print_function_t) ndr_print_PNP_GetInterfaceDeviceListSize,
+ false,
+ },
+ {
+ "PNP_RegisterDeviceClassAssociation",
+ sizeof(struct PNP_RegisterDeviceClassAssociation),
+ (ndr_push_flags_fn_t) ndr_push_PNP_RegisterDeviceClassAssociation,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_RegisterDeviceClassAssociation,
+ (ndr_print_function_t) ndr_print_PNP_RegisterDeviceClassAssociation,
+ false,
+ },
+ {
+ "PNP_UnregisterDeviceClassAssociation",
+ sizeof(struct PNP_UnregisterDeviceClassAssociation),
+ (ndr_push_flags_fn_t) ndr_push_PNP_UnregisterDeviceClassAssociation,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_UnregisterDeviceClassAssociation,
+ (ndr_print_function_t) ndr_print_PNP_UnregisterDeviceClassAssociation,
+ false,
+ },
+ {
+ "PNP_GetClassRegProp",
+ sizeof(struct PNP_GetClassRegProp),
+ (ndr_push_flags_fn_t) ndr_push_PNP_GetClassRegProp,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_GetClassRegProp,
+ (ndr_print_function_t) ndr_print_PNP_GetClassRegProp,
+ false,
+ },
+ {
+ "PNP_SetClassRegProp",
+ sizeof(struct PNP_SetClassRegProp),
+ (ndr_push_flags_fn_t) ndr_push_PNP_SetClassRegProp,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_SetClassRegProp,
+ (ndr_print_function_t) ndr_print_PNP_SetClassRegProp,
+ false,
+ },
+ {
+ "PNP_CreateDevInst",
+ sizeof(struct PNP_CreateDevInst),
+ (ndr_push_flags_fn_t) ndr_push_PNP_CreateDevInst,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_CreateDevInst,
+ (ndr_print_function_t) ndr_print_PNP_CreateDevInst,
+ false,
+ },
+ {
+ "PNP_DeviceInstanceAction",
+ sizeof(struct PNP_DeviceInstanceAction),
+ (ndr_push_flags_fn_t) ndr_push_PNP_DeviceInstanceAction,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_DeviceInstanceAction,
+ (ndr_print_function_t) ndr_print_PNP_DeviceInstanceAction,
+ false,
+ },
+ {
+ "PNP_GetDeviceStatus",
+ sizeof(struct PNP_GetDeviceStatus),
+ (ndr_push_flags_fn_t) ndr_push_PNP_GetDeviceStatus,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_GetDeviceStatus,
+ (ndr_print_function_t) ndr_print_PNP_GetDeviceStatus,
+ false,
+ },
+ {
+ "PNP_SetDeviceProblem",
+ sizeof(struct PNP_SetDeviceProblem),
+ (ndr_push_flags_fn_t) ndr_push_PNP_SetDeviceProblem,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_SetDeviceProblem,
+ (ndr_print_function_t) ndr_print_PNP_SetDeviceProblem,
+ false,
+ },
+ {
+ "PNP_DisableDevInst",
+ sizeof(struct PNP_DisableDevInst),
+ (ndr_push_flags_fn_t) ndr_push_PNP_DisableDevInst,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_DisableDevInst,
+ (ndr_print_function_t) ndr_print_PNP_DisableDevInst,
+ false,
+ },
+ {
+ "PNP_UninstallDevInst",
+ sizeof(struct PNP_UninstallDevInst),
+ (ndr_push_flags_fn_t) ndr_push_PNP_UninstallDevInst,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_UninstallDevInst,
+ (ndr_print_function_t) ndr_print_PNP_UninstallDevInst,
+ false,
+ },
+ {
+ "PNP_AddID",
+ sizeof(struct PNP_AddID),
+ (ndr_push_flags_fn_t) ndr_push_PNP_AddID,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_AddID,
+ (ndr_print_function_t) ndr_print_PNP_AddID,
+ false,
+ },
+ {
+ "PNP_RegisterDriver",
+ sizeof(struct PNP_RegisterDriver),
+ (ndr_push_flags_fn_t) ndr_push_PNP_RegisterDriver,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_RegisterDriver,
+ (ndr_print_function_t) ndr_print_PNP_RegisterDriver,
+ false,
+ },
+ {
+ "PNP_QueryRemove",
+ sizeof(struct PNP_QueryRemove),
+ (ndr_push_flags_fn_t) ndr_push_PNP_QueryRemove,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_QueryRemove,
+ (ndr_print_function_t) ndr_print_PNP_QueryRemove,
+ false,
+ },
+ {
+ "PNP_RequestDeviceEject",
+ sizeof(struct PNP_RequestDeviceEject),
+ (ndr_push_flags_fn_t) ndr_push_PNP_RequestDeviceEject,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_RequestDeviceEject,
+ (ndr_print_function_t) ndr_print_PNP_RequestDeviceEject,
+ false,
+ },
+ {
+ "PNP_IsDockStationPresent",
+ sizeof(struct PNP_IsDockStationPresent),
+ (ndr_push_flags_fn_t) ndr_push_PNP_IsDockStationPresent,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_IsDockStationPresent,
+ (ndr_print_function_t) ndr_print_PNP_IsDockStationPresent,
+ false,
+ },
+ {
+ "PNP_RequestEjectPC",
+ sizeof(struct PNP_RequestEjectPC),
+ (ndr_push_flags_fn_t) ndr_push_PNP_RequestEjectPC,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_RequestEjectPC,
+ (ndr_print_function_t) ndr_print_PNP_RequestEjectPC,
+ false,
+ },
+ {
+ "PNP_HwProfFlags",
+ sizeof(struct PNP_HwProfFlags),
+ (ndr_push_flags_fn_t) ndr_push_PNP_HwProfFlags,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_HwProfFlags,
+ (ndr_print_function_t) ndr_print_PNP_HwProfFlags,
+ false,
+ },
+ {
+ "PNP_GetHwProfInfo",
+ sizeof(struct PNP_GetHwProfInfo),
+ (ndr_push_flags_fn_t) ndr_push_PNP_GetHwProfInfo,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_GetHwProfInfo,
+ (ndr_print_function_t) ndr_print_PNP_GetHwProfInfo,
+ false,
+ },
+ {
+ "PNP_AddEmptyLogConf",
+ sizeof(struct PNP_AddEmptyLogConf),
+ (ndr_push_flags_fn_t) ndr_push_PNP_AddEmptyLogConf,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_AddEmptyLogConf,
+ (ndr_print_function_t) ndr_print_PNP_AddEmptyLogConf,
+ false,
+ },
+ {
+ "PNP_FreeLogConf",
+ sizeof(struct PNP_FreeLogConf),
+ (ndr_push_flags_fn_t) ndr_push_PNP_FreeLogConf,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_FreeLogConf,
+ (ndr_print_function_t) ndr_print_PNP_FreeLogConf,
+ false,
+ },
+ {
+ "PNP_GetFirstLogConf",
+ sizeof(struct PNP_GetFirstLogConf),
+ (ndr_push_flags_fn_t) ndr_push_PNP_GetFirstLogConf,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_GetFirstLogConf,
+ (ndr_print_function_t) ndr_print_PNP_GetFirstLogConf,
+ false,
+ },
+ {
+ "PNP_GetNextLogConf",
+ sizeof(struct PNP_GetNextLogConf),
+ (ndr_push_flags_fn_t) ndr_push_PNP_GetNextLogConf,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_GetNextLogConf,
+ (ndr_print_function_t) ndr_print_PNP_GetNextLogConf,
+ false,
+ },
+ {
+ "PNP_GetLogConfPriority",
+ sizeof(struct PNP_GetLogConfPriority),
+ (ndr_push_flags_fn_t) ndr_push_PNP_GetLogConfPriority,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_GetLogConfPriority,
+ (ndr_print_function_t) ndr_print_PNP_GetLogConfPriority,
+ false,
+ },
+ {
+ "PNP_AddResDes",
+ sizeof(struct PNP_AddResDes),
+ (ndr_push_flags_fn_t) ndr_push_PNP_AddResDes,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_AddResDes,
+ (ndr_print_function_t) ndr_print_PNP_AddResDes,
+ false,
+ },
+ {
+ "PNP_FreeResDes",
+ sizeof(struct PNP_FreeResDes),
+ (ndr_push_flags_fn_t) ndr_push_PNP_FreeResDes,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_FreeResDes,
+ (ndr_print_function_t) ndr_print_PNP_FreeResDes,
+ false,
+ },
+ {
+ "PNP_GetNextResDes",
+ sizeof(struct PNP_GetNextResDes),
+ (ndr_push_flags_fn_t) ndr_push_PNP_GetNextResDes,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_GetNextResDes,
+ (ndr_print_function_t) ndr_print_PNP_GetNextResDes,
+ false,
+ },
+ {
+ "PNP_GetResDesData",
+ sizeof(struct PNP_GetResDesData),
+ (ndr_push_flags_fn_t) ndr_push_PNP_GetResDesData,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_GetResDesData,
+ (ndr_print_function_t) ndr_print_PNP_GetResDesData,
+ false,
+ },
+ {
+ "PNP_GetResDesDataSize",
+ sizeof(struct PNP_GetResDesDataSize),
+ (ndr_push_flags_fn_t) ndr_push_PNP_GetResDesDataSize,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_GetResDesDataSize,
+ (ndr_print_function_t) ndr_print_PNP_GetResDesDataSize,
+ false,
+ },
+ {
+ "PNP_ModifyResDes",
+ sizeof(struct PNP_ModifyResDes),
+ (ndr_push_flags_fn_t) ndr_push_PNP_ModifyResDes,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_ModifyResDes,
+ (ndr_print_function_t) ndr_print_PNP_ModifyResDes,
+ false,
+ },
+ {
+ "PNP_DetectResourceLimit",
+ sizeof(struct PNP_DetectResourceLimit),
+ (ndr_push_flags_fn_t) ndr_push_PNP_DetectResourceLimit,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_DetectResourceLimit,
+ (ndr_print_function_t) ndr_print_PNP_DetectResourceLimit,
+ false,
+ },
+ {
+ "PNP_QueryResConfList",
+ sizeof(struct PNP_QueryResConfList),
+ (ndr_push_flags_fn_t) ndr_push_PNP_QueryResConfList,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_QueryResConfList,
+ (ndr_print_function_t) ndr_print_PNP_QueryResConfList,
+ false,
+ },
+ {
+ "PNP_SetHwProf",
+ sizeof(struct PNP_SetHwProf),
+ (ndr_push_flags_fn_t) ndr_push_PNP_SetHwProf,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_SetHwProf,
+ (ndr_print_function_t) ndr_print_PNP_SetHwProf,
+ false,
+ },
+ {
+ "PNP_QueryArbitratorFreeData",
+ sizeof(struct PNP_QueryArbitratorFreeData),
+ (ndr_push_flags_fn_t) ndr_push_PNP_QueryArbitratorFreeData,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_QueryArbitratorFreeData,
+ (ndr_print_function_t) ndr_print_PNP_QueryArbitratorFreeData,
+ false,
+ },
+ {
+ "PNP_QueryArbitratorFreeSize",
+ sizeof(struct PNP_QueryArbitratorFreeSize),
+ (ndr_push_flags_fn_t) ndr_push_PNP_QueryArbitratorFreeSize,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_QueryArbitratorFreeSize,
+ (ndr_print_function_t) ndr_print_PNP_QueryArbitratorFreeSize,
+ false,
+ },
+ {
+ "PNP_RunDetection",
+ sizeof(struct PNP_RunDetection),
+ (ndr_push_flags_fn_t) ndr_push_PNP_RunDetection,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_RunDetection,
+ (ndr_print_function_t) ndr_print_PNP_RunDetection,
+ false,
+ },
+ {
+ "PNP_RegisterNotification",
+ sizeof(struct PNP_RegisterNotification),
+ (ndr_push_flags_fn_t) ndr_push_PNP_RegisterNotification,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_RegisterNotification,
+ (ndr_print_function_t) ndr_print_PNP_RegisterNotification,
+ false,
+ },
+ {
+ "PNP_UnregisterNotification",
+ sizeof(struct PNP_UnregisterNotification),
+ (ndr_push_flags_fn_t) ndr_push_PNP_UnregisterNotification,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_UnregisterNotification,
+ (ndr_print_function_t) ndr_print_PNP_UnregisterNotification,
+ false,
+ },
+ {
+ "PNP_GetCustomDevProp",
+ sizeof(struct PNP_GetCustomDevProp),
+ (ndr_push_flags_fn_t) ndr_push_PNP_GetCustomDevProp,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_GetCustomDevProp,
+ (ndr_print_function_t) ndr_print_PNP_GetCustomDevProp,
+ false,
+ },
+ {
+ "PNP_GetVersionInternal",
+ sizeof(struct PNP_GetVersionInternal),
+ (ndr_push_flags_fn_t) ndr_push_PNP_GetVersionInternal,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_GetVersionInternal,
+ (ndr_print_function_t) ndr_print_PNP_GetVersionInternal,
+ false,
+ },
+ {
+ "PNP_GetBlockedDriverInfo",
+ sizeof(struct PNP_GetBlockedDriverInfo),
+ (ndr_push_flags_fn_t) ndr_push_PNP_GetBlockedDriverInfo,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_GetBlockedDriverInfo,
+ (ndr_print_function_t) ndr_print_PNP_GetBlockedDriverInfo,
+ false,
+ },
+ {
+ "PNP_GetServerSideDeviceInstallFlags",
+ sizeof(struct PNP_GetServerSideDeviceInstallFlags),
+ (ndr_push_flags_fn_t) ndr_push_PNP_GetServerSideDeviceInstallFlags,
+ (ndr_pull_flags_fn_t) ndr_pull_PNP_GetServerSideDeviceInstallFlags,
+ (ndr_print_function_t) ndr_print_PNP_GetServerSideDeviceInstallFlags,
+ false,
+ },
+ { NULL, 0, NULL, NULL, NULL, false }
+};
+
+static const char * const ntsvcs_endpoint_strings[] = {
+ "ncacn_np:[\\pipe\\ntsvcs]",
+};
+
+static const struct ndr_interface_string_array ntsvcs_endpoints = {
+ .count = 1,
+ .names = ntsvcs_endpoint_strings
+};
+
+static const char * const ntsvcs_authservice_strings[] = {
+ "host",
+};
+
+static const struct ndr_interface_string_array ntsvcs_authservices = {
+ .count = 1,
+ .names = ntsvcs_authservice_strings
+};
+
+
+const struct ndr_interface_table ndr_table_ntsvcs = {
+ .name = "ntsvcs",
+ .syntax_id = {
+ {0x8d9f4e40,0xa03d,0x11ce,{0x8f,0x69},{0x08,0x00,0x3e,0x30,0x05,0x1b}},
+ NDR_NTSVCS_VERSION
+ },
+ .helpstring = NDR_NTSVCS_HELPSTRING,
+ .num_calls = 65,
+ .calls = ntsvcs_calls,
+ .endpoints = &ntsvcs_endpoints,
+ .authservices = &ntsvcs_authservices
+};
+
diff --git a/source3/librpc/gen_ndr/ndr_ntsvcs.h b/source3/librpc/gen_ndr/ndr_ntsvcs.h
new file mode 100644
index 0000000000..0e3b6b91c4
--- /dev/null
+++ b/source3/librpc/gen_ndr/ndr_ntsvcs.h
@@ -0,0 +1,211 @@
+/* header auto-generated by pidl */
+
+#include "librpc/ndr/libndr.h"
+#include "librpc/gen_ndr/ntsvcs.h"
+
+#ifndef _HEADER_NDR_ntsvcs
+#define _HEADER_NDR_ntsvcs
+
+#define NDR_NTSVCS_UUID "8d9f4e40-a03d-11ce-8f69-08003e30051b"
+#define NDR_NTSVCS_VERSION 1.0
+#define NDR_NTSVCS_NAME "ntsvcs"
+#define NDR_NTSVCS_HELPSTRING "Plug and Play services"
+extern const struct ndr_interface_table ndr_table_ntsvcs;
+#define NDR_PNP_DISCONNECT (0x00)
+
+#define NDR_PNP_CONNECT (0x01)
+
+#define NDR_PNP_GETVERSION (0x02)
+
+#define NDR_PNP_GETGLOBALSTATE (0x03)
+
+#define NDR_PNP_INITDETECTION (0x04)
+
+#define NDR_PNP_REPORTLOGON (0x05)
+
+#define NDR_PNP_VALIDATEDEVICEINSTANCE (0x06)
+
+#define NDR_PNP_GETROOTDEVICEINSTANCE (0x07)
+
+#define NDR_PNP_GETRELATEDDEVICEINSTANCE (0x08)
+
+#define NDR_PNP_ENUMERATESUBKEYS (0x09)
+
+#define NDR_PNP_GETDEVICELIST (0x0a)
+
+#define NDR_PNP_GETDEVICELISTSIZE (0x0b)
+
+#define NDR_PNP_GETDEPTH (0x0c)
+
+#define NDR_PNP_GETDEVICEREGPROP (0x0d)
+
+#define NDR_PNP_SETDEVICEREGPROP (0x0e)
+
+#define NDR_PNP_GETCLASSINSTANCE (0x0f)
+
+#define NDR_PNP_CREATEKEY (0x10)
+
+#define NDR_PNP_DELETEREGISTRYKEY (0x11)
+
+#define NDR_PNP_GETCLASSCOUNT (0x12)
+
+#define NDR_PNP_GETCLASSNAME (0x13)
+
+#define NDR_PNP_DELETECLASSKEY (0x14)
+
+#define NDR_PNP_GETINTERFACEDEVICEALIAS (0x15)
+
+#define NDR_PNP_GETINTERFACEDEVICELIST (0x16)
+
+#define NDR_PNP_GETINTERFACEDEVICELISTSIZE (0x17)
+
+#define NDR_PNP_REGISTERDEVICECLASSASSOCIATION (0x18)
+
+#define NDR_PNP_UNREGISTERDEVICECLASSASSOCIATION (0x19)
+
+#define NDR_PNP_GETCLASSREGPROP (0x1a)
+
+#define NDR_PNP_SETCLASSREGPROP (0x1b)
+
+#define NDR_PNP_CREATEDEVINST (0x1c)
+
+#define NDR_PNP_DEVICEINSTANCEACTION (0x1d)
+
+#define NDR_PNP_GETDEVICESTATUS (0x1e)
+
+#define NDR_PNP_SETDEVICEPROBLEM (0x1f)
+
+#define NDR_PNP_DISABLEDEVINST (0x20)
+
+#define NDR_PNP_UNINSTALLDEVINST (0x21)
+
+#define NDR_PNP_ADDID (0x22)
+
+#define NDR_PNP_REGISTERDRIVER (0x23)
+
+#define NDR_PNP_QUERYREMOVE (0x24)
+
+#define NDR_PNP_REQUESTDEVICEEJECT (0x25)
+
+#define NDR_PNP_ISDOCKSTATIONPRESENT (0x26)
+
+#define NDR_PNP_REQUESTEJECTPC (0x27)
+
+#define NDR_PNP_HWPROFFLAGS (0x28)
+
+#define NDR_PNP_GETHWPROFINFO (0x29)
+
+#define NDR_PNP_ADDEMPTYLOGCONF (0x2a)
+
+#define NDR_PNP_FREELOGCONF (0x2b)
+
+#define NDR_PNP_GETFIRSTLOGCONF (0x2c)
+
+#define NDR_PNP_GETNEXTLOGCONF (0x2d)
+
+#define NDR_PNP_GETLOGCONFPRIORITY (0x2e)
+
+#define NDR_PNP_ADDRESDES (0x2f)
+
+#define NDR_PNP_FREERESDES (0x30)
+
+#define NDR_PNP_GETNEXTRESDES (0x31)
+
+#define NDR_PNP_GETRESDESDATA (0x32)
+
+#define NDR_PNP_GETRESDESDATASIZE (0x33)
+
+#define NDR_PNP_MODIFYRESDES (0x34)
+
+#define NDR_PNP_DETECTRESOURCELIMIT (0x35)
+
+#define NDR_PNP_QUERYRESCONFLIST (0x36)
+
+#define NDR_PNP_SETHWPROF (0x37)
+
+#define NDR_PNP_QUERYARBITRATORFREEDATA (0x38)
+
+#define NDR_PNP_QUERYARBITRATORFREESIZE (0x39)
+
+#define NDR_PNP_RUNDETECTION (0x3a)
+
+#define NDR_PNP_REGISTERNOTIFICATION (0x3b)
+
+#define NDR_PNP_UNREGISTERNOTIFICATION (0x3c)
+
+#define NDR_PNP_GETCUSTOMDEVPROP (0x3d)
+
+#define NDR_PNP_GETVERSIONINTERNAL (0x3e)
+
+#define NDR_PNP_GETBLOCKEDDRIVERINFO (0x3f)
+
+#define NDR_PNP_GETSERVERSIDEDEVICEINSTALLFLAGS (0x40)
+
+#define NDR_NTSVCS_CALL_COUNT (65)
+void ndr_print_PNP_HwProfInfo(struct ndr_print *ndr, const char *name, const struct PNP_HwProfInfo *r);
+void ndr_print_PNP_Disconnect(struct ndr_print *ndr, const char *name, int flags, const struct PNP_Disconnect *r);
+void ndr_print_PNP_Connect(struct ndr_print *ndr, const char *name, int flags, const struct PNP_Connect *r);
+void ndr_print_PNP_GetVersion(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetVersion *r);
+void ndr_print_PNP_GetGlobalState(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetGlobalState *r);
+void ndr_print_PNP_InitDetection(struct ndr_print *ndr, const char *name, int flags, const struct PNP_InitDetection *r);
+void ndr_print_PNP_ReportLogOn(struct ndr_print *ndr, const char *name, int flags, const struct PNP_ReportLogOn *r);
+void ndr_print_PNP_ValidateDeviceInstance(struct ndr_print *ndr, const char *name, int flags, const struct PNP_ValidateDeviceInstance *r);
+void ndr_print_PNP_GetRootDeviceInstance(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetRootDeviceInstance *r);
+void ndr_print_PNP_GetRelatedDeviceInstance(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetRelatedDeviceInstance *r);
+void ndr_print_PNP_EnumerateSubKeys(struct ndr_print *ndr, const char *name, int flags, const struct PNP_EnumerateSubKeys *r);
+void ndr_print_PNP_GetDeviceList(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetDeviceList *r);
+void ndr_print_PNP_GetDeviceListSize(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetDeviceListSize *r);
+void ndr_print_PNP_GetDepth(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetDepth *r);
+void ndr_print_PNP_GetDeviceRegProp(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetDeviceRegProp *r);
+void ndr_print_PNP_SetDeviceRegProp(struct ndr_print *ndr, const char *name, int flags, const struct PNP_SetDeviceRegProp *r);
+void ndr_print_PNP_GetClassInstance(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetClassInstance *r);
+void ndr_print_PNP_CreateKey(struct ndr_print *ndr, const char *name, int flags, const struct PNP_CreateKey *r);
+void ndr_print_PNP_DeleteRegistryKey(struct ndr_print *ndr, const char *name, int flags, const struct PNP_DeleteRegistryKey *r);
+void ndr_print_PNP_GetClassCount(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetClassCount *r);
+void ndr_print_PNP_GetClassName(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetClassName *r);
+void ndr_print_PNP_DeleteClassKey(struct ndr_print *ndr, const char *name, int flags, const struct PNP_DeleteClassKey *r);
+void ndr_print_PNP_GetInterfaceDeviceAlias(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetInterfaceDeviceAlias *r);
+void ndr_print_PNP_GetInterfaceDeviceList(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetInterfaceDeviceList *r);
+void ndr_print_PNP_GetInterfaceDeviceListSize(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetInterfaceDeviceListSize *r);
+void ndr_print_PNP_RegisterDeviceClassAssociation(struct ndr_print *ndr, const char *name, int flags, const struct PNP_RegisterDeviceClassAssociation *r);
+void ndr_print_PNP_UnregisterDeviceClassAssociation(struct ndr_print *ndr, const char *name, int flags, const struct PNP_UnregisterDeviceClassAssociation *r);
+void ndr_print_PNP_GetClassRegProp(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetClassRegProp *r);
+void ndr_print_PNP_SetClassRegProp(struct ndr_print *ndr, const char *name, int flags, const struct PNP_SetClassRegProp *r);
+void ndr_print_PNP_CreateDevInst(struct ndr_print *ndr, const char *name, int flags, const struct PNP_CreateDevInst *r);
+void ndr_print_PNP_DeviceInstanceAction(struct ndr_print *ndr, const char *name, int flags, const struct PNP_DeviceInstanceAction *r);
+void ndr_print_PNP_GetDeviceStatus(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetDeviceStatus *r);
+void ndr_print_PNP_SetDeviceProblem(struct ndr_print *ndr, const char *name, int flags, const struct PNP_SetDeviceProblem *r);
+void ndr_print_PNP_DisableDevInst(struct ndr_print *ndr, const char *name, int flags, const struct PNP_DisableDevInst *r);
+void ndr_print_PNP_UninstallDevInst(struct ndr_print *ndr, const char *name, int flags, const struct PNP_UninstallDevInst *r);
+void ndr_print_PNP_AddID(struct ndr_print *ndr, const char *name, int flags, const struct PNP_AddID *r);
+void ndr_print_PNP_RegisterDriver(struct ndr_print *ndr, const char *name, int flags, const struct PNP_RegisterDriver *r);
+void ndr_print_PNP_QueryRemove(struct ndr_print *ndr, const char *name, int flags, const struct PNP_QueryRemove *r);
+void ndr_print_PNP_RequestDeviceEject(struct ndr_print *ndr, const char *name, int flags, const struct PNP_RequestDeviceEject *r);
+void ndr_print_PNP_IsDockStationPresent(struct ndr_print *ndr, const char *name, int flags, const struct PNP_IsDockStationPresent *r);
+void ndr_print_PNP_RequestEjectPC(struct ndr_print *ndr, const char *name, int flags, const struct PNP_RequestEjectPC *r);
+void ndr_print_PNP_HwProfFlags(struct ndr_print *ndr, const char *name, int flags, const struct PNP_HwProfFlags *r);
+void ndr_print_PNP_GetHwProfInfo(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetHwProfInfo *r);
+void ndr_print_PNP_AddEmptyLogConf(struct ndr_print *ndr, const char *name, int flags, const struct PNP_AddEmptyLogConf *r);
+void ndr_print_PNP_FreeLogConf(struct ndr_print *ndr, const char *name, int flags, const struct PNP_FreeLogConf *r);
+void ndr_print_PNP_GetFirstLogConf(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetFirstLogConf *r);
+void ndr_print_PNP_GetNextLogConf(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetNextLogConf *r);
+void ndr_print_PNP_GetLogConfPriority(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetLogConfPriority *r);
+void ndr_print_PNP_AddResDes(struct ndr_print *ndr, const char *name, int flags, const struct PNP_AddResDes *r);
+void ndr_print_PNP_FreeResDes(struct ndr_print *ndr, const char *name, int flags, const struct PNP_FreeResDes *r);
+void ndr_print_PNP_GetNextResDes(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetNextResDes *r);
+void ndr_print_PNP_GetResDesData(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetResDesData *r);
+void ndr_print_PNP_GetResDesDataSize(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetResDesDataSize *r);
+void ndr_print_PNP_ModifyResDes(struct ndr_print *ndr, const char *name, int flags, const struct PNP_ModifyResDes *r);
+void ndr_print_PNP_DetectResourceLimit(struct ndr_print *ndr, const char *name, int flags, const struct PNP_DetectResourceLimit *r);
+void ndr_print_PNP_QueryResConfList(struct ndr_print *ndr, const char *name, int flags, const struct PNP_QueryResConfList *r);
+void ndr_print_PNP_SetHwProf(struct ndr_print *ndr, const char *name, int flags, const struct PNP_SetHwProf *r);
+void ndr_print_PNP_QueryArbitratorFreeData(struct ndr_print *ndr, const char *name, int flags, const struct PNP_QueryArbitratorFreeData *r);
+void ndr_print_PNP_QueryArbitratorFreeSize(struct ndr_print *ndr, const char *name, int flags, const struct PNP_QueryArbitratorFreeSize *r);
+void ndr_print_PNP_RunDetection(struct ndr_print *ndr, const char *name, int flags, const struct PNP_RunDetection *r);
+void ndr_print_PNP_RegisterNotification(struct ndr_print *ndr, const char *name, int flags, const struct PNP_RegisterNotification *r);
+void ndr_print_PNP_UnregisterNotification(struct ndr_print *ndr, const char *name, int flags, const struct PNP_UnregisterNotification *r);
+void ndr_print_PNP_GetCustomDevProp(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetCustomDevProp *r);
+void ndr_print_PNP_GetVersionInternal(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetVersionInternal *r);
+void ndr_print_PNP_GetBlockedDriverInfo(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetBlockedDriverInfo *r);
+void ndr_print_PNP_GetServerSideDeviceInstallFlags(struct ndr_print *ndr, const char *name, int flags, const struct PNP_GetServerSideDeviceInstallFlags *r);
+#endif /* _HEADER_NDR_ntsvcs */
diff --git a/source3/librpc/gen_ndr/ndr_samr.c b/source3/librpc/gen_ndr/ndr_samr.c
index eaa38e3a1f..3af589f393 100644
--- a/source3/librpc/gen_ndr/ndr_samr.c
+++ b/source3/librpc/gen_ndr/ndr_samr.c
@@ -299,8 +299,7 @@ _PUBLIC_ void ndr_print_samr_SamArray(struct ndr_print *ndr, const char *name, c
ndr->depth++;
for (cntr_entries_1=0;cntr_entries_1<r->count;cntr_entries_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_entries_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_entries_1) != -1) {
ndr_print_samr_SamEntry(ndr, "entries", &r->entries[cntr_entries_1]);
free(idx_1);
}
@@ -1161,8 +1160,7 @@ _PUBLIC_ void ndr_print_samr_Ids(struct ndr_print *ndr, const char *name, const
ndr->depth++;
for (cntr_ids_1=0;cntr_ids_1<r->count;cntr_ids_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_ids_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_ids_1) != -1) {
ndr_print_uint32(ndr, "ids", r->ids[cntr_ids_1]);
free(idx_1);
}
@@ -1559,8 +1557,7 @@ _PUBLIC_ void ndr_print_samr_RidTypeArray(struct ndr_print *ndr, const char *nam
ndr->depth++;
for (cntr_rids_1=0;cntr_rids_1<r->count;cntr_rids_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_rids_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_rids_1) != -1) {
ndr_print_uint32(ndr, "rids", r->rids[cntr_rids_1]);
free(idx_1);
}
@@ -1575,8 +1572,7 @@ _PUBLIC_ void ndr_print_samr_RidTypeArray(struct ndr_print *ndr, const char *nam
ndr->depth++;
for (cntr_types_1=0;cntr_types_1<r->count;cntr_types_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_types_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_types_1) != -1) {
ndr_print_uint32(ndr, "types", r->types[cntr_types_1]);
free(idx_1);
}
@@ -3711,8 +3707,7 @@ _PUBLIC_ void ndr_print_samr_RidWithAttributeArray(struct ndr_print *ndr, const
ndr->depth++;
for (cntr_rids_1=0;cntr_rids_1<r->count;cntr_rids_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_rids_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_rids_1) != -1) {
ndr_print_samr_RidWithAttribute(ndr, "rids", &r->rids[cntr_rids_1]);
free(idx_1);
}
@@ -3849,8 +3844,7 @@ _PUBLIC_ void ndr_print_samr_DispInfoGeneral(struct ndr_print *ndr, const char *
ndr->depth++;
for (cntr_entries_1=0;cntr_entries_1<r->count;cntr_entries_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_entries_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_entries_1) != -1) {
ndr_print_samr_DispEntryGeneral(ndr, "entries", &r->entries[cntr_entries_1]);
free(idx_1);
}
@@ -3982,8 +3976,7 @@ _PUBLIC_ void ndr_print_samr_DispInfoFull(struct ndr_print *ndr, const char *nam
ndr->depth++;
for (cntr_entries_1=0;cntr_entries_1<r->count;cntr_entries_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_entries_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_entries_1) != -1) {
ndr_print_samr_DispEntryFull(ndr, "entries", &r->entries[cntr_entries_1]);
free(idx_1);
}
@@ -4115,8 +4108,7 @@ _PUBLIC_ void ndr_print_samr_DispInfoFullGroups(struct ndr_print *ndr, const cha
ndr->depth++;
for (cntr_entries_1=0;cntr_entries_1<r->count;cntr_entries_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_entries_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_entries_1) != -1) {
ndr_print_samr_DispEntryFullGroup(ndr, "entries", &r->entries[cntr_entries_1]);
free(idx_1);
}
@@ -4132,10 +4124,10 @@ static enum ndr_err_code ndr_push_samr_DispEntryAscii(struct ndr_push *ndr, int
if (ndr_flags & NDR_SCALARS) {
NDR_CHECK(ndr_push_align(ndr, 4));
NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->idx));
- NDR_CHECK(ndr_push_lsa_AsciiString(ndr, NDR_SCALARS, &r->account_name));
+ NDR_CHECK(ndr_push_lsa_AsciiStringLarge(ndr, NDR_SCALARS, &r->account_name));
}
if (ndr_flags & NDR_BUFFERS) {
- NDR_CHECK(ndr_push_lsa_AsciiString(ndr, NDR_BUFFERS, &r->account_name));
+ NDR_CHECK(ndr_push_lsa_AsciiStringLarge(ndr, NDR_BUFFERS, &r->account_name));
}
return NDR_ERR_SUCCESS;
}
@@ -4145,10 +4137,10 @@ static enum ndr_err_code ndr_pull_samr_DispEntryAscii(struct ndr_pull *ndr, int
if (ndr_flags & NDR_SCALARS) {
NDR_CHECK(ndr_pull_align(ndr, 4));
NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->idx));
- NDR_CHECK(ndr_pull_lsa_AsciiString(ndr, NDR_SCALARS, &r->account_name));
+ NDR_CHECK(ndr_pull_lsa_AsciiStringLarge(ndr, NDR_SCALARS, &r->account_name));
}
if (ndr_flags & NDR_BUFFERS) {
- NDR_CHECK(ndr_pull_lsa_AsciiString(ndr, NDR_BUFFERS, &r->account_name));
+ NDR_CHECK(ndr_pull_lsa_AsciiStringLarge(ndr, NDR_BUFFERS, &r->account_name));
}
return NDR_ERR_SUCCESS;
}
@@ -4158,7 +4150,7 @@ _PUBLIC_ void ndr_print_samr_DispEntryAscii(struct ndr_print *ndr, const char *n
ndr_print_struct(ndr, name, "samr_DispEntryAscii");
ndr->depth++;
ndr_print_uint32(ndr, "idx", r->idx);
- ndr_print_lsa_AsciiString(ndr, "account_name", &r->account_name);
+ ndr_print_lsa_AsciiStringLarge(ndr, "account_name", &r->account_name);
ndr->depth--;
}
@@ -4237,8 +4229,7 @@ _PUBLIC_ void ndr_print_samr_DispInfoAscii(struct ndr_print *ndr, const char *na
ndr->depth++;
for (cntr_entries_1=0;cntr_entries_1<r->count;cntr_entries_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_entries_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_entries_1) != -1) {
ndr_print_samr_DispEntryAscii(ndr, "entries", &r->entries[cntr_entries_1]);
free(idx_1);
}
@@ -4840,8 +4831,7 @@ _PUBLIC_ void ndr_print_samr_ValidatePasswordInfo(struct ndr_print *ndr, const c
ndr->depth++;
for (cntr_pwd_history_1=0;cntr_pwd_history_1<r->pwd_history_len;cntr_pwd_history_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_pwd_history_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_pwd_history_1) != -1) {
ndr_print_samr_ValidationBlob(ndr, "pwd_history", &r->pwd_history[cntr_pwd_history_1]);
free(idx_1);
}
@@ -7212,8 +7202,7 @@ _PUBLIC_ void ndr_print_samr_LookupNames(struct ndr_print *ndr, const char *name
ndr->depth++;
for (cntr_names_0=0;cntr_names_0<r->in.num_names;cntr_names_0++) {
char *idx_0=NULL;
- asprintf(&idx_0, "[%d]", cntr_names_0);
- if (idx_0) {
+ if (asprintf(&idx_0, "[%d]", cntr_names_0) != -1) {
ndr_print_lsa_String(ndr, "names", &r->in.names[cntr_names_0]);
free(idx_0);
}
@@ -7352,8 +7341,7 @@ _PUBLIC_ void ndr_print_samr_LookupRids(struct ndr_print *ndr, const char *name,
ndr->depth++;
for (cntr_rids_0=0;cntr_rids_0<r->in.num_rids;cntr_rids_0++) {
char *idx_0=NULL;
- asprintf(&idx_0, "[%d]", cntr_rids_0);
- if (idx_0) {
+ if (asprintf(&idx_0, "[%d]", cntr_rids_0) != -1) {
ndr_print_uint32(ndr, "rids", r->in.rids[cntr_rids_0]);
free(idx_0);
}
diff --git a/source3/librpc/gen_ndr/ndr_security.c b/source3/librpc/gen_ndr/ndr_security.c
index 8ab56dd914..cbeabf48e5 100644
--- a/source3/librpc/gen_ndr/ndr_security.c
+++ b/source3/librpc/gen_ndr/ndr_security.c
@@ -552,8 +552,7 @@ _PUBLIC_ void ndr_print_security_acl(struct ndr_print *ndr, const char *name, co
ndr->depth++;
for (cntr_aces_0=0;cntr_aces_0<r->num_aces;cntr_aces_0++) {
char *idx_0=NULL;
- asprintf(&idx_0, "[%d]", cntr_aces_0);
- if (idx_0) {
+ if (asprintf(&idx_0, "[%d]", cntr_aces_0) != -1) {
ndr_print_security_ace(ndr, "aces", &r->aces[cntr_aces_0]);
free(idx_0);
}
@@ -981,8 +980,7 @@ _PUBLIC_ void ndr_print_security_token(struct ndr_print *ndr, const char *name,
ndr->depth++;
for (cntr_sids_0=0;cntr_sids_0<r->num_sids;cntr_sids_0++) {
char *idx_0=NULL;
- asprintf(&idx_0, "[%d]", cntr_sids_0);
- if (idx_0) {
+ if (asprintf(&idx_0, "[%d]", cntr_sids_0) != -1) {
ndr_print_ptr(ndr, "sids", r->sids[cntr_sids_0]);
ndr->depth++;
if (r->sids[cntr_sids_0]) {
diff --git a/source3/librpc/gen_ndr/ndr_srvsvc.c b/source3/librpc/gen_ndr/ndr_srvsvc.c
index 86d47a856c..22a04f86f8 100644
--- a/source3/librpc/gen_ndr/ndr_srvsvc.c
+++ b/source3/librpc/gen_ndr/ndr_srvsvc.c
@@ -140,8 +140,7 @@ _PUBLIC_ void ndr_print_srvsvc_NetCharDevCtr0(struct ndr_print *ndr, const char
ndr->depth++;
for (cntr_array_1=0;cntr_array_1<r->count;cntr_array_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_array_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_array_1) != -1) {
ndr_print_srvsvc_NetCharDevInfo0(ndr, "array", &r->array[cntr_array_1]);
free(idx_1);
}
@@ -326,8 +325,7 @@ _PUBLIC_ void ndr_print_srvsvc_NetCharDevCtr1(struct ndr_print *ndr, const char
ndr->depth++;
for (cntr_array_1=0;cntr_array_1<r->count;cntr_array_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_array_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_array_1) != -1) {
ndr_print_srvsvc_NetCharDevInfo1(ndr, "array", &r->array[cntr_array_1]);
free(idx_1);
}
@@ -749,8 +747,7 @@ _PUBLIC_ void ndr_print_srvsvc_NetCharDevQCtr0(struct ndr_print *ndr, const char
ndr->depth++;
for (cntr_array_1=0;cntr_array_1<r->count;cntr_array_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_array_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_array_1) != -1) {
ndr_print_srvsvc_NetCharDevQInfo0(ndr, "array", &r->array[cntr_array_1]);
free(idx_1);
}
@@ -938,8 +935,7 @@ _PUBLIC_ void ndr_print_srvsvc_NetCharDevQCtr1(struct ndr_print *ndr, const char
ndr->depth++;
for (cntr_array_1=0;cntr_array_1<r->count;cntr_array_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_array_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_array_1) != -1) {
ndr_print_srvsvc_NetCharDevQInfo1(ndr, "array", &r->array[cntr_array_1]);
free(idx_1);
}
@@ -1325,8 +1321,7 @@ _PUBLIC_ void ndr_print_srvsvc_NetConnCtr0(struct ndr_print *ndr, const char *na
ndr->depth++;
for (cntr_array_1=0;cntr_array_1<r->count;cntr_array_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_array_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_array_1) != -1) {
ndr_print_srvsvc_NetConnInfo0(ndr, "array", &r->array[cntr_array_1]);
free(idx_1);
}
@@ -1520,8 +1515,7 @@ _PUBLIC_ void ndr_print_srvsvc_NetConnCtr1(struct ndr_print *ndr, const char *na
ndr->depth++;
for (cntr_array_1=0;cntr_array_1<r->count;cntr_array_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_array_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_array_1) != -1) {
ndr_print_srvsvc_NetConnInfo1(ndr, "array", &r->array[cntr_array_1]);
free(idx_1);
}
@@ -1769,8 +1763,7 @@ _PUBLIC_ void ndr_print_srvsvc_NetFileCtr2(struct ndr_print *ndr, const char *na
ndr->depth++;
for (cntr_array_1=0;cntr_array_1<r->count;cntr_array_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_array_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_array_1) != -1) {
ndr_print_srvsvc_NetFileInfo2(ndr, "array", &r->array[cntr_array_1]);
free(idx_1);
}
@@ -1958,8 +1951,7 @@ _PUBLIC_ void ndr_print_srvsvc_NetFileCtr3(struct ndr_print *ndr, const char *na
ndr->depth++;
for (cntr_array_1=0;cntr_array_1<r->count;cntr_array_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_array_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_array_1) != -1) {
ndr_print_srvsvc_NetFileInfo3(ndr, "array", &r->array[cntr_array_1]);
free(idx_1);
}
@@ -2381,8 +2373,7 @@ _PUBLIC_ void ndr_print_srvsvc_NetSessCtr0(struct ndr_print *ndr, const char *na
ndr->depth++;
for (cntr_array_1=0;cntr_array_1<r->count;cntr_array_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_array_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_array_1) != -1) {
ndr_print_srvsvc_NetSessInfo0(ndr, "array", &r->array[cntr_array_1]);
free(idx_1);
}
@@ -2573,8 +2564,7 @@ _PUBLIC_ void ndr_print_srvsvc_NetSessCtr1(struct ndr_print *ndr, const char *na
ndr->depth++;
for (cntr_array_1=0;cntr_array_1<r->count;cntr_array_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_array_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_array_1) != -1) {
ndr_print_srvsvc_NetSessInfo1(ndr, "array", &r->array[cntr_array_1]);
free(idx_1);
}
@@ -2798,8 +2788,7 @@ _PUBLIC_ void ndr_print_srvsvc_NetSessCtr2(struct ndr_print *ndr, const char *na
ndr->depth++;
for (cntr_array_1=0;cntr_array_1<r->count;cntr_array_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_array_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_array_1) != -1) {
ndr_print_srvsvc_NetSessInfo2(ndr, "array", &r->array[cntr_array_1]);
free(idx_1);
}
@@ -2984,8 +2973,7 @@ _PUBLIC_ void ndr_print_srvsvc_NetSessCtr10(struct ndr_print *ndr, const char *n
ndr->depth++;
for (cntr_array_1=0;cntr_array_1<r->count;cntr_array_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_array_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_array_1) != -1) {
ndr_print_srvsvc_NetSessInfo10(ndr, "array", &r->array[cntr_array_1]);
free(idx_1);
}
@@ -3242,8 +3230,7 @@ _PUBLIC_ void ndr_print_srvsvc_NetSessCtr502(struct ndr_print *ndr, const char *
ndr->depth++;
for (cntr_array_1=0;cntr_array_1<r->count;cntr_array_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_array_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_array_1) != -1) {
ndr_print_srvsvc_NetSessInfo502(ndr, "array", &r->array[cntr_array_1]);
free(idx_1);
}
@@ -3694,8 +3681,7 @@ _PUBLIC_ void ndr_print_srvsvc_NetShareCtr0(struct ndr_print *ndr, const char *n
ndr->depth++;
for (cntr_array_1=0;cntr_array_1<r->count;cntr_array_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_array_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_array_1) != -1) {
ndr_print_srvsvc_NetShareInfo0(ndr, "array", &r->array[cntr_array_1]);
free(idx_1);
}
@@ -3877,8 +3863,7 @@ _PUBLIC_ void ndr_print_srvsvc_NetShareCtr1(struct ndr_print *ndr, const char *n
ndr->depth++;
for (cntr_array_1=0;cntr_array_1<r->count;cntr_array_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_array_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_array_1) != -1) {
ndr_print_srvsvc_NetShareInfo1(ndr, "array", &r->array[cntr_array_1]);
free(idx_1);
}
@@ -4135,8 +4120,7 @@ _PUBLIC_ void ndr_print_srvsvc_NetShareCtr2(struct ndr_print *ndr, const char *n
ndr->depth++;
for (cntr_array_1=0;cntr_array_1<r->count;cntr_array_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_array_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_array_1) != -1) {
ndr_print_srvsvc_NetShareInfo2(ndr, "array", &r->array[cntr_array_1]);
free(idx_1);
}
@@ -4321,8 +4305,7 @@ _PUBLIC_ void ndr_print_srvsvc_NetShareCtr501(struct ndr_print *ndr, const char
ndr->depth++;
for (cntr_array_1=0;cntr_array_1<r->count;cntr_array_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_array_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_array_1) != -1) {
ndr_print_srvsvc_NetShareInfo501(ndr, "array", &r->array[cntr_array_1]);
free(idx_1);
}
@@ -4616,8 +4599,7 @@ _PUBLIC_ void ndr_print_srvsvc_NetShareCtr502(struct ndr_print *ndr, const char
ndr->depth++;
for (cntr_array_1=0;cntr_array_1<r->count;cntr_array_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_array_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_array_1) != -1) {
ndr_print_srvsvc_NetShareInfo502(ndr, "array", &r->array[cntr_array_1]);
free(idx_1);
}
@@ -4763,8 +4745,7 @@ _PUBLIC_ void ndr_print_srvsvc_NetShareCtr1004(struct ndr_print *ndr, const char
ndr->depth++;
for (cntr_array_1=0;cntr_array_1<r->count;cntr_array_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_array_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_array_1) != -1) {
ndr_print_srvsvc_NetShareInfo1004(ndr, "array", &r->array[cntr_array_1]);
free(idx_1);
}
@@ -4897,8 +4878,7 @@ _PUBLIC_ void ndr_print_srvsvc_NetShareCtr1005(struct ndr_print *ndr, const char
ndr->depth++;
for (cntr_array_1=0;cntr_array_1<r->count;cntr_array_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_array_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_array_1) != -1) {
ndr_print_srvsvc_NetShareInfo1005(ndr, "array", &r->array[cntr_array_1]);
free(idx_1);
}
@@ -5008,8 +4988,7 @@ _PUBLIC_ void ndr_print_srvsvc_NetShareCtr1006(struct ndr_print *ndr, const char
ndr->depth++;
for (cntr_array_1=0;cntr_array_1<r->count;cntr_array_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_array_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_array_1) != -1) {
ndr_print_srvsvc_NetShareInfo1006(ndr, "array", &r->array[cntr_array_1]);
free(idx_1);
}
@@ -5158,8 +5137,7 @@ _PUBLIC_ void ndr_print_srvsvc_NetShareCtr1007(struct ndr_print *ndr, const char
ndr->depth++;
for (cntr_array_1=0;cntr_array_1<r->count;cntr_array_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_array_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_array_1) != -1) {
ndr_print_srvsvc_NetShareInfo1007(ndr, "array", &r->array[cntr_array_1]);
free(idx_1);
}
@@ -5245,8 +5223,7 @@ _PUBLIC_ void ndr_print_srvsvc_NetShareCtr1501(struct ndr_print *ndr, const char
ndr->depth++;
for (cntr_array_1=0;cntr_array_1<r->count;cntr_array_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_array_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_array_1) != -1) {
ndr_print_sec_desc_buf(ndr, "array", &r->array[cntr_array_1]);
free(idx_1);
}
@@ -11487,8 +11464,7 @@ _PUBLIC_ void ndr_print_srvsvc_NetDiskInfo(struct ndr_print *ndr, const char *na
ndr->depth++;
for (cntr_disks_1=0;cntr_disks_1<r->count;cntr_disks_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_disks_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_disks_1) != -1) {
ndr_print_srvsvc_NetDiskInfo0(ndr, "disks", &r->disks[cntr_disks_1]);
free(idx_1);
}
@@ -11781,8 +11757,7 @@ _PUBLIC_ void ndr_print_srvsvc_NetTransportCtr0(struct ndr_print *ndr, const cha
ndr->depth++;
for (cntr_array_1=0;cntr_array_1<r->count;cntr_array_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_array_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_array_1) != -1) {
ndr_print_srvsvc_NetTransportInfo0(ndr, "array", &r->array[cntr_array_1]);
free(idx_1);
}
@@ -12030,8 +12005,7 @@ _PUBLIC_ void ndr_print_srvsvc_NetTransportCtr1(struct ndr_print *ndr, const cha
ndr->depth++;
for (cntr_array_1=0;cntr_array_1<r->count;cntr_array_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_array_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_array_1) != -1) {
ndr_print_srvsvc_NetTransportInfo1(ndr, "array", &r->array[cntr_array_1]);
free(idx_1);
}
@@ -12282,8 +12256,7 @@ _PUBLIC_ void ndr_print_srvsvc_NetTransportCtr2(struct ndr_print *ndr, const cha
ndr->depth++;
for (cntr_array_1=0;cntr_array_1<r->count;cntr_array_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_array_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_array_1) != -1) {
ndr_print_srvsvc_NetTransportInfo2(ndr, "array", &r->array[cntr_array_1]);
free(idx_1);
}
@@ -12540,8 +12513,7 @@ _PUBLIC_ void ndr_print_srvsvc_NetTransportCtr3(struct ndr_print *ndr, const cha
ndr->depth++;
for (cntr_array_1=0;cntr_array_1<r->count;cntr_array_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_array_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_array_1) != -1) {
ndr_print_srvsvc_NetTransportInfo3(ndr, "array", &r->array[cntr_array_1]);
free(idx_1);
}
@@ -15684,8 +15656,11 @@ static enum ndr_err_code ndr_push_srvsvc_NetShareSetInfo(struct ndr_push *ndr, i
NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, ndr_charset_length(r->in.share_name, CH_UTF16)));
NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.share_name, ndr_charset_length(r->in.share_name, CH_UTF16), sizeof(uint16_t), CH_UTF16));
NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.level));
- NDR_CHECK(ndr_push_set_switch_value(ndr, &r->in.info, r->in.level));
- NDR_CHECK(ndr_push_srvsvc_NetShareInfo(ndr, NDR_SCALARS|NDR_BUFFERS, &r->in.info));
+ if (r->in.info == NULL) {
+ return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
+ }
+ NDR_CHECK(ndr_push_set_switch_value(ndr, r->in.info, r->in.level));
+ NDR_CHECK(ndr_push_srvsvc_NetShareInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info));
NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.parm_error));
if (r->in.parm_error) {
NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->in.parm_error));
@@ -15706,6 +15681,7 @@ static enum ndr_err_code ndr_pull_srvsvc_NetShareSetInfo(struct ndr_pull *ndr, i
uint32_t _ptr_server_unc;
uint32_t _ptr_parm_error;
TALLOC_CTX *_mem_save_server_unc_0;
+ TALLOC_CTX *_mem_save_info_0;
TALLOC_CTX *_mem_save_parm_error_0;
if (flags & NDR_IN) {
ZERO_STRUCT(r->out);
@@ -15736,8 +15712,14 @@ static enum ndr_err_code ndr_pull_srvsvc_NetShareSetInfo(struct ndr_pull *ndr, i
NDR_CHECK(ndr_check_string_terminator(ndr, ndr_get_array_length(ndr, &r->in.share_name), sizeof(uint16_t)));
NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.share_name, ndr_get_array_length(ndr, &r->in.share_name), sizeof(uint16_t), CH_UTF16));
NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.level));
- NDR_CHECK(ndr_pull_set_switch_value(ndr, &r->in.info, r->in.level));
- NDR_CHECK(ndr_pull_srvsvc_NetShareInfo(ndr, NDR_SCALARS|NDR_BUFFERS, &r->in.info));
+ if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
+ NDR_PULL_ALLOC(ndr, r->in.info);
+ }
+ _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, r->in.info, LIBNDR_FLAG_REF_ALLOC);
+ NDR_CHECK(ndr_pull_set_switch_value(ndr, r->in.info, r->in.level));
+ NDR_CHECK(ndr_pull_srvsvc_NetShareInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info));
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_parm_error));
if (_ptr_parm_error) {
NDR_PULL_ALLOC(ndr, r->in.parm_error);
@@ -15787,8 +15769,11 @@ _PUBLIC_ void ndr_print_srvsvc_NetShareSetInfo(struct ndr_print *ndr, const char
ndr->depth--;
ndr_print_string(ndr, "share_name", r->in.share_name);
ndr_print_uint32(ndr, "level", r->in.level);
- ndr_print_set_switch_value(ndr, &r->in.info, r->in.level);
- ndr_print_srvsvc_NetShareInfo(ndr, "info", &r->in.info);
+ ndr_print_ptr(ndr, "info", r->in.info);
+ ndr->depth++;
+ ndr_print_set_switch_value(ndr, r->in.info, r->in.level);
+ ndr_print_srvsvc_NetShareInfo(ndr, "info", r->in.info);
+ ndr->depth--;
ndr_print_ptr(ndr, "parm_error", r->in.parm_error);
ndr->depth++;
if (r->in.parm_error) {
@@ -16207,8 +16192,11 @@ static enum ndr_err_code ndr_push_srvsvc_NetSrvSetInfo(struct ndr_push *ndr, int
NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.server_unc, ndr_charset_length(r->in.server_unc, CH_UTF16), sizeof(uint16_t), CH_UTF16));
}
NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.level));
- NDR_CHECK(ndr_push_set_switch_value(ndr, &r->in.info, r->in.level));
- NDR_CHECK(ndr_push_srvsvc_NetSrvInfo(ndr, NDR_SCALARS|NDR_BUFFERS, &r->in.info));
+ if (r->in.info == NULL) {
+ return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
+ }
+ NDR_CHECK(ndr_push_set_switch_value(ndr, r->in.info, r->in.level));
+ NDR_CHECK(ndr_push_srvsvc_NetSrvInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info));
NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.parm_error));
if (r->in.parm_error) {
NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->in.parm_error));
@@ -16229,6 +16217,7 @@ static enum ndr_err_code ndr_pull_srvsvc_NetSrvSetInfo(struct ndr_pull *ndr, int
uint32_t _ptr_server_unc;
uint32_t _ptr_parm_error;
TALLOC_CTX *_mem_save_server_unc_0;
+ TALLOC_CTX *_mem_save_info_0;
TALLOC_CTX *_mem_save_parm_error_0;
if (flags & NDR_IN) {
ZERO_STRUCT(r->out);
@@ -16252,8 +16241,14 @@ static enum ndr_err_code ndr_pull_srvsvc_NetSrvSetInfo(struct ndr_pull *ndr, int
NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_unc_0, 0);
}
NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.level));
- NDR_CHECK(ndr_pull_set_switch_value(ndr, &r->in.info, r->in.level));
- NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo(ndr, NDR_SCALARS|NDR_BUFFERS, &r->in.info));
+ if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
+ NDR_PULL_ALLOC(ndr, r->in.info);
+ }
+ _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, r->in.info, LIBNDR_FLAG_REF_ALLOC);
+ NDR_CHECK(ndr_pull_set_switch_value(ndr, r->in.info, r->in.level));
+ NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info));
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_parm_error));
if (_ptr_parm_error) {
NDR_PULL_ALLOC(ndr, r->in.parm_error);
@@ -16302,8 +16297,11 @@ _PUBLIC_ void ndr_print_srvsvc_NetSrvSetInfo(struct ndr_print *ndr, const char *
}
ndr->depth--;
ndr_print_uint32(ndr, "level", r->in.level);
- ndr_print_set_switch_value(ndr, &r->in.info, r->in.level);
- ndr_print_srvsvc_NetSrvInfo(ndr, "info", &r->in.info);
+ ndr_print_ptr(ndr, "info", r->in.info);
+ ndr->depth++;
+ ndr_print_set_switch_value(ndr, r->in.info, r->in.level);
+ ndr_print_srvsvc_NetSrvInfo(ndr, "info", r->in.info);
+ ndr->depth--;
ndr_print_ptr(ndr, "parm_error", r->in.parm_error);
ndr->depth++;
if (r->in.parm_error) {
@@ -17029,9 +17027,12 @@ static enum ndr_err_code ndr_push_srvsvc_NetRemoteTOD(struct ndr_push *ndr, int
}
}
if (flags & NDR_OUT) {
- NDR_CHECK(ndr_push_unique_ptr(ndr, r->out.info));
- if (r->out.info) {
- NDR_CHECK(ndr_push_srvsvc_NetRemoteTODInfo(ndr, NDR_SCALARS, r->out.info));
+ if (r->out.info == NULL) {
+ return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
+ }
+ NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.info));
+ if (*r->out.info) {
+ NDR_CHECK(ndr_push_srvsvc_NetRemoteTODInfo(ndr, NDR_SCALARS, *r->out.info));
}
NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
}
@@ -17044,6 +17045,7 @@ static enum ndr_err_code ndr_pull_srvsvc_NetRemoteTOD(struct ndr_pull *ndr, int
uint32_t _ptr_info;
TALLOC_CTX *_mem_save_server_unc_0;
TALLOC_CTX *_mem_save_info_0;
+ TALLOC_CTX *_mem_save_info_1;
if (flags & NDR_IN) {
ZERO_STRUCT(r->out);
@@ -17065,20 +17067,28 @@ static enum ndr_err_code ndr_pull_srvsvc_NetRemoteTOD(struct ndr_pull *ndr, int
NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.server_unc, ndr_get_array_length(ndr, &r->in.server_unc), sizeof(uint16_t), CH_UTF16));
NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_unc_0, 0);
}
+ NDR_PULL_ALLOC(ndr, r->out.info);
+ ZERO_STRUCTP(r->out.info);
}
if (flags & NDR_OUT) {
+ if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
+ NDR_PULL_ALLOC(ndr, r->out.info);
+ }
+ _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, r->out.info, LIBNDR_FLAG_REF_ALLOC);
NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info));
if (_ptr_info) {
- NDR_PULL_ALLOC(ndr, r->out.info);
+ NDR_PULL_ALLOC(ndr, *r->out.info);
} else {
- r->out.info = NULL;
+ *r->out.info = NULL;
}
- if (r->out.info) {
- _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
- NDR_PULL_SET_MEM_CTX(ndr, r->out.info, 0);
- NDR_CHECK(ndr_pull_srvsvc_NetRemoteTODInfo(ndr, NDR_SCALARS, r->out.info));
- NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, 0);
+ if (*r->out.info) {
+ _mem_save_info_1 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, *r->out.info, 0);
+ NDR_CHECK(ndr_pull_srvsvc_NetRemoteTODInfo(ndr, NDR_SCALARS, *r->out.info));
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_1, 0);
}
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
}
return NDR_ERR_SUCCESS;
@@ -17107,10 +17117,13 @@ _PUBLIC_ void ndr_print_srvsvc_NetRemoteTOD(struct ndr_print *ndr, const char *n
ndr->depth++;
ndr_print_ptr(ndr, "info", r->out.info);
ndr->depth++;
- if (r->out.info) {
- ndr_print_srvsvc_NetRemoteTODInfo(ndr, "info", r->out.info);
+ ndr_print_ptr(ndr, "info", *r->out.info);
+ ndr->depth++;
+ if (*r->out.info) {
+ ndr_print_srvsvc_NetRemoteTODInfo(ndr, "info", *r->out.info);
}
ndr->depth--;
+ ndr->depth--;
ndr_print_WERROR(ndr, "result", r->out.result);
ndr->depth--;
}
diff --git a/source3/librpc/gen_ndr/ndr_svcctl.c b/source3/librpc/gen_ndr/ndr_svcctl.c
index b2dfd0eef4..16e0416288 100644
--- a/source3/librpc/gen_ndr/ndr_svcctl.c
+++ b/source3/librpc/gen_ndr/ndr_svcctl.c
@@ -588,8 +588,23 @@ _PUBLIC_ void ndr_print_svcctl_LockServiceDatabase(struct ndr_print *ndr, const
static enum ndr_err_code ndr_push_svcctl_QueryServiceObjectSecurity(struct ndr_push *ndr, int flags, const struct svcctl_QueryServiceObjectSecurity *r)
{
if (flags & NDR_IN) {
+ if (r->in.handle == NULL) {
+ return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
+ }
+ NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.handle));
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.security_flags));
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.buffer_size));
}
if (flags & NDR_OUT) {
+ if (r->out.buffer == NULL) {
+ return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
+ }
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.buffer_size));
+ NDR_CHECK(ndr_push_array_uint8(ndr, NDR_SCALARS, r->out.buffer, r->in.buffer_size));
+ if (r->out.needed == NULL) {
+ return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
+ }
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.needed));
NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
}
return NDR_ERR_SUCCESS;
@@ -597,10 +612,48 @@ static enum ndr_err_code ndr_push_svcctl_QueryServiceObjectSecurity(struct ndr_p
static enum ndr_err_code ndr_pull_svcctl_QueryServiceObjectSecurity(struct ndr_pull *ndr, int flags, struct svcctl_QueryServiceObjectSecurity *r)
{
+ TALLOC_CTX *_mem_save_handle_0;
+ TALLOC_CTX *_mem_save_needed_0;
if (flags & NDR_IN) {
+ ZERO_STRUCT(r->out);
+
+ if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
+ NDR_PULL_ALLOC(ndr, r->in.handle);
+ }
+ _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
+ NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.handle));
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
+ NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.security_flags));
+ NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.buffer_size));
+ if (r->in.buffer_size < 0 || r->in.buffer_size > 0x40000) {
+ return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
+ }
+ NDR_PULL_ALLOC_N(ndr, r->out.buffer, r->in.buffer_size);
+ memset(r->out.buffer, 0, (r->in.buffer_size) * sizeof(*r->out.buffer));
+ NDR_PULL_ALLOC(ndr, r->out.needed);
+ ZERO_STRUCTP(r->out.needed);
}
if (flags & NDR_OUT) {
+ NDR_CHECK(ndr_pull_array_size(ndr, &r->out.buffer));
+ if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
+ NDR_PULL_ALLOC_N(ndr, r->out.buffer, ndr_get_array_size(ndr, &r->out.buffer));
+ }
+ NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_SCALARS, r->out.buffer, ndr_get_array_size(ndr, &r->out.buffer)));
+ if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
+ NDR_PULL_ALLOC(ndr, r->out.needed);
+ }
+ _mem_save_needed_0 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, r->out.needed, LIBNDR_FLAG_REF_ALLOC);
+ NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.needed));
+ if (*r->out.needed < 0 || *r->out.needed > 0x40000) {
+ return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
+ }
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_needed_0, LIBNDR_FLAG_REF_ALLOC);
NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+ if (r->out.buffer) {
+ NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->out.buffer, r->in.buffer_size));
+ }
}
return NDR_ERR_SUCCESS;
}
@@ -615,11 +668,25 @@ _PUBLIC_ void ndr_print_svcctl_QueryServiceObjectSecurity(struct ndr_print *ndr,
if (flags & NDR_IN) {
ndr_print_struct(ndr, "in", "svcctl_QueryServiceObjectSecurity");
ndr->depth++;
+ ndr_print_ptr(ndr, "handle", r->in.handle);
+ ndr->depth++;
+ ndr_print_policy_handle(ndr, "handle", r->in.handle);
+ ndr->depth--;
+ ndr_print_uint32(ndr, "security_flags", r->in.security_flags);
+ ndr_print_uint32(ndr, "buffer_size", r->in.buffer_size);
ndr->depth--;
}
if (flags & NDR_OUT) {
ndr_print_struct(ndr, "out", "svcctl_QueryServiceObjectSecurity");
ndr->depth++;
+ ndr_print_ptr(ndr, "buffer", r->out.buffer);
+ ndr->depth++;
+ ndr_print_array_uint8(ndr, "buffer", r->out.buffer, r->in.buffer_size);
+ ndr->depth--;
+ ndr_print_ptr(ndr, "needed", r->out.needed);
+ ndr->depth++;
+ ndr_print_uint32(ndr, "needed", *r->out.needed);
+ ndr->depth--;
ndr_print_WERROR(ndr, "result", r->out.result);
ndr->depth--;
}
@@ -629,6 +696,17 @@ _PUBLIC_ void ndr_print_svcctl_QueryServiceObjectSecurity(struct ndr_print *ndr,
static enum ndr_err_code ndr_push_svcctl_SetServiceObjectSecurity(struct ndr_push *ndr, int flags, const struct svcctl_SetServiceObjectSecurity *r)
{
if (flags & NDR_IN) {
+ if (r->in.handle == NULL) {
+ return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
+ }
+ NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.handle));
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.security_flags));
+ if (r->in.buffer == NULL) {
+ return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
+ }
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.buffer_size));
+ NDR_CHECK(ndr_push_array_uint8(ndr, NDR_SCALARS, r->in.buffer, r->in.buffer_size));
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.buffer_size));
}
if (flags & NDR_OUT) {
NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
@@ -638,7 +716,25 @@ static enum ndr_err_code ndr_push_svcctl_SetServiceObjectSecurity(struct ndr_pus
static enum ndr_err_code ndr_pull_svcctl_SetServiceObjectSecurity(struct ndr_pull *ndr, int flags, struct svcctl_SetServiceObjectSecurity *r)
{
+ TALLOC_CTX *_mem_save_handle_0;
if (flags & NDR_IN) {
+ if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
+ NDR_PULL_ALLOC(ndr, r->in.handle);
+ }
+ _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
+ NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
+ NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.handle));
+ NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
+ NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.security_flags));
+ NDR_CHECK(ndr_pull_array_size(ndr, &r->in.buffer));
+ if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
+ NDR_PULL_ALLOC_N(ndr, r->in.buffer, ndr_get_array_size(ndr, &r->in.buffer));
+ }
+ NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_SCALARS, r->in.buffer, ndr_get_array_size(ndr, &r->in.buffer)));
+ NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.buffer_size));
+ if (r->in.buffer) {
+ NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->in.buffer, r->in.buffer_size));
+ }
}
if (flags & NDR_OUT) {
NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
@@ -656,6 +752,16 @@ _PUBLIC_ void ndr_print_svcctl_SetServiceObjectSecurity(struct ndr_print *ndr, c
if (flags & NDR_IN) {
ndr_print_struct(ndr, "in", "svcctl_SetServiceObjectSecurity");
ndr->depth++;
+ ndr_print_ptr(ndr, "handle", r->in.handle);
+ ndr->depth++;
+ ndr_print_policy_handle(ndr, "handle", r->in.handle);
+ ndr->depth--;
+ ndr_print_uint32(ndr, "security_flags", r->in.security_flags);
+ ndr_print_ptr(ndr, "buffer", r->in.buffer);
+ ndr->depth++;
+ ndr_print_array_uint8(ndr, "buffer", r->in.buffer, r->in.buffer_size);
+ ndr->depth--;
+ ndr_print_uint32(ndr, "buffer_size", r->in.buffer_size);
ndr->depth--;
}
if (flags & NDR_OUT) {
diff --git a/source3/librpc/gen_ndr/ndr_unixinfo.c b/source3/librpc/gen_ndr/ndr_unixinfo.c
deleted file mode 100644
index 03a8d30f03..0000000000
--- a/source3/librpc/gen_ndr/ndr_unixinfo.c
+++ /dev/null
@@ -1,538 +0,0 @@
-/* parser auto-generated by pidl */
-
-#include "includes.h"
-#include "librpc/gen_ndr/ndr_unixinfo.h"
-
-#include "librpc/gen_ndr/ndr_security.h"
-static enum ndr_err_code ndr_push_unixinfo_GetPWUidInfo(struct ndr_push *ndr, int ndr_flags, const struct unixinfo_GetPWUidInfo *r)
-{
- if (ndr_flags & NDR_SCALARS) {
- NDR_CHECK(ndr_push_align(ndr, 4));
- NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->status));
- {
- uint32_t _flags_save_string = ndr->flags;
- ndr_set_flags(&ndr->flags, LIBNDR_FLAG_STR_UTF8|LIBNDR_FLAG_STR_NULLTERM);
- NDR_CHECK(ndr_push_string(ndr, NDR_SCALARS, r->homedir));
- ndr->flags = _flags_save_string;
- }
- {
- uint32_t _flags_save_string = ndr->flags;
- ndr_set_flags(&ndr->flags, LIBNDR_FLAG_STR_UTF8|LIBNDR_FLAG_STR_NULLTERM);
- NDR_CHECK(ndr_push_string(ndr, NDR_SCALARS, r->shell));
- ndr->flags = _flags_save_string;
- }
- }
- if (ndr_flags & NDR_BUFFERS) {
- }
- return NDR_ERR_SUCCESS;
-}
-
-static enum ndr_err_code ndr_pull_unixinfo_GetPWUidInfo(struct ndr_pull *ndr, int ndr_flags, struct unixinfo_GetPWUidInfo *r)
-{
- if (ndr_flags & NDR_SCALARS) {
- NDR_CHECK(ndr_pull_align(ndr, 4));
- NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->status));
- {
- uint32_t _flags_save_string = ndr->flags;
- ndr_set_flags(&ndr->flags, LIBNDR_FLAG_STR_UTF8|LIBNDR_FLAG_STR_NULLTERM);
- NDR_CHECK(ndr_pull_string(ndr, NDR_SCALARS, &r->homedir));
- ndr->flags = _flags_save_string;
- }
- {
- uint32_t _flags_save_string = ndr->flags;
- ndr_set_flags(&ndr->flags, LIBNDR_FLAG_STR_UTF8|LIBNDR_FLAG_STR_NULLTERM);
- NDR_CHECK(ndr_pull_string(ndr, NDR_SCALARS, &r->shell));
- ndr->flags = _flags_save_string;
- }
- }
- if (ndr_flags & NDR_BUFFERS) {
- }
- return NDR_ERR_SUCCESS;
-}
-
-_PUBLIC_ void ndr_print_unixinfo_GetPWUidInfo(struct ndr_print *ndr, const char *name, const struct unixinfo_GetPWUidInfo *r)
-{
- ndr_print_struct(ndr, name, "unixinfo_GetPWUidInfo");
- ndr->depth++;
- ndr_print_NTSTATUS(ndr, "status", r->status);
- ndr_print_string(ndr, "homedir", r->homedir);
- ndr_print_string(ndr, "shell", r->shell);
- ndr->depth--;
-}
-
-static enum ndr_err_code ndr_push_unixinfo_SidToUid(struct ndr_push *ndr, int flags, const struct unixinfo_SidToUid *r)
-{
- if (flags & NDR_IN) {
- NDR_CHECK(ndr_push_dom_sid(ndr, NDR_SCALARS|NDR_BUFFERS, &r->in.sid));
- }
- if (flags & NDR_OUT) {
- if (r->out.uid == NULL) {
- return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
- }
- NDR_CHECK(ndr_push_hyper(ndr, NDR_SCALARS, *r->out.uid));
- NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
- }
- return NDR_ERR_SUCCESS;
-}
-
-static enum ndr_err_code ndr_pull_unixinfo_SidToUid(struct ndr_pull *ndr, int flags, struct unixinfo_SidToUid *r)
-{
- TALLOC_CTX *_mem_save_uid_0;
- if (flags & NDR_IN) {
- ZERO_STRUCT(r->out);
-
- NDR_CHECK(ndr_pull_dom_sid(ndr, NDR_SCALARS|NDR_BUFFERS, &r->in.sid));
- NDR_PULL_ALLOC(ndr, r->out.uid);
- ZERO_STRUCTP(r->out.uid);
- }
- if (flags & NDR_OUT) {
- if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
- NDR_PULL_ALLOC(ndr, r->out.uid);
- }
- _mem_save_uid_0 = NDR_PULL_GET_MEM_CTX(ndr);
- NDR_PULL_SET_MEM_CTX(ndr, r->out.uid, LIBNDR_FLAG_REF_ALLOC);
- NDR_CHECK(ndr_pull_hyper(ndr, NDR_SCALARS, r->out.uid));
- NDR_PULL_SET_MEM_CTX(ndr, _mem_save_uid_0, LIBNDR_FLAG_REF_ALLOC);
- NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
- }
- return NDR_ERR_SUCCESS;
-}
-
-_PUBLIC_ void ndr_print_unixinfo_SidToUid(struct ndr_print *ndr, const char *name, int flags, const struct unixinfo_SidToUid *r)
-{
- ndr_print_struct(ndr, name, "unixinfo_SidToUid");
- ndr->depth++;
- if (flags & NDR_SET_VALUES) {
- ndr->flags |= LIBNDR_PRINT_SET_VALUES;
- }
- if (flags & NDR_IN) {
- ndr_print_struct(ndr, "in", "unixinfo_SidToUid");
- ndr->depth++;
- ndr_print_dom_sid(ndr, "sid", &r->in.sid);
- ndr->depth--;
- }
- if (flags & NDR_OUT) {
- ndr_print_struct(ndr, "out", "unixinfo_SidToUid");
- ndr->depth++;
- ndr_print_ptr(ndr, "uid", r->out.uid);
- ndr->depth++;
- ndr_print_hyper(ndr, "uid", *r->out.uid);
- ndr->depth--;
- ndr_print_NTSTATUS(ndr, "result", r->out.result);
- ndr->depth--;
- }
- ndr->depth--;
-}
-
-static enum ndr_err_code ndr_push_unixinfo_UidToSid(struct ndr_push *ndr, int flags, const struct unixinfo_UidToSid *r)
-{
- if (flags & NDR_IN) {
- NDR_CHECK(ndr_push_hyper(ndr, NDR_SCALARS, r->in.uid));
- }
- if (flags & NDR_OUT) {
- if (r->out.sid == NULL) {
- return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
- }
- NDR_CHECK(ndr_push_dom_sid(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.sid));
- NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
- }
- return NDR_ERR_SUCCESS;
-}
-
-static enum ndr_err_code ndr_pull_unixinfo_UidToSid(struct ndr_pull *ndr, int flags, struct unixinfo_UidToSid *r)
-{
- TALLOC_CTX *_mem_save_sid_0;
- if (flags & NDR_IN) {
- ZERO_STRUCT(r->out);
-
- NDR_CHECK(ndr_pull_hyper(ndr, NDR_SCALARS, &r->in.uid));
- NDR_PULL_ALLOC(ndr, r->out.sid);
- ZERO_STRUCTP(r->out.sid);
- }
- if (flags & NDR_OUT) {
- if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
- NDR_PULL_ALLOC(ndr, r->out.sid);
- }
- _mem_save_sid_0 = NDR_PULL_GET_MEM_CTX(ndr);
- NDR_PULL_SET_MEM_CTX(ndr, r->out.sid, LIBNDR_FLAG_REF_ALLOC);
- NDR_CHECK(ndr_pull_dom_sid(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.sid));
- NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sid_0, LIBNDR_FLAG_REF_ALLOC);
- NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
- }
- return NDR_ERR_SUCCESS;
-}
-
-_PUBLIC_ void ndr_print_unixinfo_UidToSid(struct ndr_print *ndr, const char *name, int flags, const struct unixinfo_UidToSid *r)
-{
- ndr_print_struct(ndr, name, "unixinfo_UidToSid");
- ndr->depth++;
- if (flags & NDR_SET_VALUES) {
- ndr->flags |= LIBNDR_PRINT_SET_VALUES;
- }
- if (flags & NDR_IN) {
- ndr_print_struct(ndr, "in", "unixinfo_UidToSid");
- ndr->depth++;
- ndr_print_hyper(ndr, "uid", r->in.uid);
- ndr->depth--;
- }
- if (flags & NDR_OUT) {
- ndr_print_struct(ndr, "out", "unixinfo_UidToSid");
- ndr->depth++;
- ndr_print_ptr(ndr, "sid", r->out.sid);
- ndr->depth++;
- ndr_print_dom_sid(ndr, "sid", r->out.sid);
- ndr->depth--;
- ndr_print_NTSTATUS(ndr, "result", r->out.result);
- ndr->depth--;
- }
- ndr->depth--;
-}
-
-static enum ndr_err_code ndr_push_unixinfo_SidToGid(struct ndr_push *ndr, int flags, const struct unixinfo_SidToGid *r)
-{
- if (flags & NDR_IN) {
- NDR_CHECK(ndr_push_dom_sid(ndr, NDR_SCALARS|NDR_BUFFERS, &r->in.sid));
- }
- if (flags & NDR_OUT) {
- if (r->out.gid == NULL) {
- return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
- }
- NDR_CHECK(ndr_push_hyper(ndr, NDR_SCALARS, *r->out.gid));
- NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
- }
- return NDR_ERR_SUCCESS;
-}
-
-static enum ndr_err_code ndr_pull_unixinfo_SidToGid(struct ndr_pull *ndr, int flags, struct unixinfo_SidToGid *r)
-{
- TALLOC_CTX *_mem_save_gid_0;
- if (flags & NDR_IN) {
- ZERO_STRUCT(r->out);
-
- NDR_CHECK(ndr_pull_dom_sid(ndr, NDR_SCALARS|NDR_BUFFERS, &r->in.sid));
- NDR_PULL_ALLOC(ndr, r->out.gid);
- ZERO_STRUCTP(r->out.gid);
- }
- if (flags & NDR_OUT) {
- if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
- NDR_PULL_ALLOC(ndr, r->out.gid);
- }
- _mem_save_gid_0 = NDR_PULL_GET_MEM_CTX(ndr);
- NDR_PULL_SET_MEM_CTX(ndr, r->out.gid, LIBNDR_FLAG_REF_ALLOC);
- NDR_CHECK(ndr_pull_hyper(ndr, NDR_SCALARS, r->out.gid));
- NDR_PULL_SET_MEM_CTX(ndr, _mem_save_gid_0, LIBNDR_FLAG_REF_ALLOC);
- NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
- }
- return NDR_ERR_SUCCESS;
-}
-
-_PUBLIC_ void ndr_print_unixinfo_SidToGid(struct ndr_print *ndr, const char *name, int flags, const struct unixinfo_SidToGid *r)
-{
- ndr_print_struct(ndr, name, "unixinfo_SidToGid");
- ndr->depth++;
- if (flags & NDR_SET_VALUES) {
- ndr->flags |= LIBNDR_PRINT_SET_VALUES;
- }
- if (flags & NDR_IN) {
- ndr_print_struct(ndr, "in", "unixinfo_SidToGid");
- ndr->depth++;
- ndr_print_dom_sid(ndr, "sid", &r->in.sid);
- ndr->depth--;
- }
- if (flags & NDR_OUT) {
- ndr_print_struct(ndr, "out", "unixinfo_SidToGid");
- ndr->depth++;
- ndr_print_ptr(ndr, "gid", r->out.gid);
- ndr->depth++;
- ndr_print_hyper(ndr, "gid", *r->out.gid);
- ndr->depth--;
- ndr_print_NTSTATUS(ndr, "result", r->out.result);
- ndr->depth--;
- }
- ndr->depth--;
-}
-
-static enum ndr_err_code ndr_push_unixinfo_GidToSid(struct ndr_push *ndr, int flags, const struct unixinfo_GidToSid *r)
-{
- if (flags & NDR_IN) {
- NDR_CHECK(ndr_push_hyper(ndr, NDR_SCALARS, r->in.gid));
- }
- if (flags & NDR_OUT) {
- if (r->out.sid == NULL) {
- return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
- }
- NDR_CHECK(ndr_push_dom_sid(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.sid));
- NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
- }
- return NDR_ERR_SUCCESS;
-}
-
-static enum ndr_err_code ndr_pull_unixinfo_GidToSid(struct ndr_pull *ndr, int flags, struct unixinfo_GidToSid *r)
-{
- TALLOC_CTX *_mem_save_sid_0;
- if (flags & NDR_IN) {
- ZERO_STRUCT(r->out);
-
- NDR_CHECK(ndr_pull_hyper(ndr, NDR_SCALARS, &r->in.gid));
- NDR_PULL_ALLOC(ndr, r->out.sid);
- ZERO_STRUCTP(r->out.sid);
- }
- if (flags & NDR_OUT) {
- if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
- NDR_PULL_ALLOC(ndr, r->out.sid);
- }
- _mem_save_sid_0 = NDR_PULL_GET_MEM_CTX(ndr);
- NDR_PULL_SET_MEM_CTX(ndr, r->out.sid, LIBNDR_FLAG_REF_ALLOC);
- NDR_CHECK(ndr_pull_dom_sid(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.sid));
- NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sid_0, LIBNDR_FLAG_REF_ALLOC);
- NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
- }
- return NDR_ERR_SUCCESS;
-}
-
-_PUBLIC_ void ndr_print_unixinfo_GidToSid(struct ndr_print *ndr, const char *name, int flags, const struct unixinfo_GidToSid *r)
-{
- ndr_print_struct(ndr, name, "unixinfo_GidToSid");
- ndr->depth++;
- if (flags & NDR_SET_VALUES) {
- ndr->flags |= LIBNDR_PRINT_SET_VALUES;
- }
- if (flags & NDR_IN) {
- ndr_print_struct(ndr, "in", "unixinfo_GidToSid");
- ndr->depth++;
- ndr_print_hyper(ndr, "gid", r->in.gid);
- ndr->depth--;
- }
- if (flags & NDR_OUT) {
- ndr_print_struct(ndr, "out", "unixinfo_GidToSid");
- ndr->depth++;
- ndr_print_ptr(ndr, "sid", r->out.sid);
- ndr->depth++;
- ndr_print_dom_sid(ndr, "sid", r->out.sid);
- ndr->depth--;
- ndr_print_NTSTATUS(ndr, "result", r->out.result);
- ndr->depth--;
- }
- ndr->depth--;
-}
-
-static enum ndr_err_code ndr_push_unixinfo_GetPWUid(struct ndr_push *ndr, int flags, const struct unixinfo_GetPWUid *r)
-{
- uint32_t cntr_uids_0;
- uint32_t cntr_infos_0;
- if (flags & NDR_IN) {
- if (r->in.count == NULL) {
- return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
- }
- NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->in.count));
- NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->in.count));
- for (cntr_uids_0 = 0; cntr_uids_0 < *r->in.count; cntr_uids_0++) {
- NDR_CHECK(ndr_push_hyper(ndr, NDR_SCALARS, r->in.uids[cntr_uids_0]));
- }
- }
- if (flags & NDR_OUT) {
- if (r->out.count == NULL) {
- return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
- }
- NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.count));
- NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.count));
- for (cntr_infos_0 = 0; cntr_infos_0 < *r->out.count; cntr_infos_0++) {
- NDR_CHECK(ndr_push_unixinfo_GetPWUidInfo(ndr, NDR_SCALARS, &r->out.infos[cntr_infos_0]));
- }
- NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
- }
- return NDR_ERR_SUCCESS;
-}
-
-static enum ndr_err_code ndr_pull_unixinfo_GetPWUid(struct ndr_pull *ndr, int flags, struct unixinfo_GetPWUid *r)
-{
- uint32_t cntr_uids_0;
- uint32_t cntr_infos_0;
- TALLOC_CTX *_mem_save_count_0;
- TALLOC_CTX *_mem_save_uids_0;
- TALLOC_CTX *_mem_save_infos_0;
- if (flags & NDR_IN) {
- ZERO_STRUCT(r->out);
-
- if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
- NDR_PULL_ALLOC(ndr, r->in.count);
- }
- _mem_save_count_0 = NDR_PULL_GET_MEM_CTX(ndr);
- NDR_PULL_SET_MEM_CTX(ndr, r->in.count, LIBNDR_FLAG_REF_ALLOC);
- NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->in.count));
- if (*r->in.count < 0 || *r->in.count > 1023) {
- return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
- }
- NDR_PULL_SET_MEM_CTX(ndr, _mem_save_count_0, LIBNDR_FLAG_REF_ALLOC);
- NDR_CHECK(ndr_pull_array_size(ndr, &r->in.uids));
- NDR_PULL_ALLOC_N(ndr, r->in.uids, ndr_get_array_size(ndr, &r->in.uids));
- _mem_save_uids_0 = NDR_PULL_GET_MEM_CTX(ndr);
- NDR_PULL_SET_MEM_CTX(ndr, r->in.uids, 0);
- for (cntr_uids_0 = 0; cntr_uids_0 < *r->in.count; cntr_uids_0++) {
- NDR_CHECK(ndr_pull_hyper(ndr, NDR_SCALARS, &r->in.uids[cntr_uids_0]));
- }
- NDR_PULL_SET_MEM_CTX(ndr, _mem_save_uids_0, 0);
- NDR_PULL_ALLOC(ndr, r->out.count);
- *r->out.count = *r->in.count;
- if (r->in.uids) {
- NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->in.uids, *r->in.count));
- }
- }
- if (flags & NDR_OUT) {
- if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
- NDR_PULL_ALLOC(ndr, r->out.count);
- }
- _mem_save_count_0 = NDR_PULL_GET_MEM_CTX(ndr);
- NDR_PULL_SET_MEM_CTX(ndr, r->out.count, LIBNDR_FLAG_REF_ALLOC);
- NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.count));
- if (*r->out.count < 0 || *r->out.count > 1023) {
- return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
- }
- NDR_PULL_SET_MEM_CTX(ndr, _mem_save_count_0, LIBNDR_FLAG_REF_ALLOC);
- NDR_CHECK(ndr_pull_array_size(ndr, &r->out.infos));
- NDR_PULL_ALLOC_N(ndr, r->out.infos, ndr_get_array_size(ndr, &r->out.infos));
- _mem_save_infos_0 = NDR_PULL_GET_MEM_CTX(ndr);
- NDR_PULL_SET_MEM_CTX(ndr, r->out.infos, 0);
- for (cntr_infos_0 = 0; cntr_infos_0 < *r->out.count; cntr_infos_0++) {
- NDR_CHECK(ndr_pull_unixinfo_GetPWUidInfo(ndr, NDR_SCALARS, &r->out.infos[cntr_infos_0]));
- }
- NDR_PULL_SET_MEM_CTX(ndr, _mem_save_infos_0, 0);
- NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
- if (r->out.infos) {
- NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->out.infos, *r->out.count));
- }
- }
- return NDR_ERR_SUCCESS;
-}
-
-_PUBLIC_ void ndr_print_unixinfo_GetPWUid(struct ndr_print *ndr, const char *name, int flags, const struct unixinfo_GetPWUid *r)
-{
- uint32_t cntr_uids_0;
- uint32_t cntr_infos_0;
- ndr_print_struct(ndr, name, "unixinfo_GetPWUid");
- ndr->depth++;
- if (flags & NDR_SET_VALUES) {
- ndr->flags |= LIBNDR_PRINT_SET_VALUES;
- }
- if (flags & NDR_IN) {
- ndr_print_struct(ndr, "in", "unixinfo_GetPWUid");
- ndr->depth++;
- ndr_print_ptr(ndr, "count", r->in.count);
- ndr->depth++;
- ndr_print_uint32(ndr, "count", *r->in.count);
- ndr->depth--;
- ndr->print(ndr, "%s: ARRAY(%d)", "uids", *r->in.count);
- ndr->depth++;
- for (cntr_uids_0=0;cntr_uids_0<*r->in.count;cntr_uids_0++) {
- char *idx_0=NULL;
- asprintf(&idx_0, "[%d]", cntr_uids_0);
- if (idx_0) {
- ndr_print_hyper(ndr, "uids", r->in.uids[cntr_uids_0]);
- free(idx_0);
- }
- }
- ndr->depth--;
- ndr->depth--;
- }
- if (flags & NDR_OUT) {
- ndr_print_struct(ndr, "out", "unixinfo_GetPWUid");
- ndr->depth++;
- ndr_print_ptr(ndr, "count", r->out.count);
- ndr->depth++;
- ndr_print_uint32(ndr, "count", *r->out.count);
- ndr->depth--;
- ndr->print(ndr, "%s: ARRAY(%d)", "infos", *r->out.count);
- ndr->depth++;
- for (cntr_infos_0=0;cntr_infos_0<*r->out.count;cntr_infos_0++) {
- char *idx_0=NULL;
- asprintf(&idx_0, "[%d]", cntr_infos_0);
- if (idx_0) {
- ndr_print_unixinfo_GetPWUidInfo(ndr, "infos", &r->out.infos[cntr_infos_0]);
- free(idx_0);
- }
- }
- ndr->depth--;
- ndr_print_NTSTATUS(ndr, "result", r->out.result);
- ndr->depth--;
- }
- ndr->depth--;
-}
-
-static const struct ndr_interface_call unixinfo_calls[] = {
- {
- "unixinfo_SidToUid",
- sizeof(struct unixinfo_SidToUid),
- (ndr_push_flags_fn_t) ndr_push_unixinfo_SidToUid,
- (ndr_pull_flags_fn_t) ndr_pull_unixinfo_SidToUid,
- (ndr_print_function_t) ndr_print_unixinfo_SidToUid,
- false,
- },
- {
- "unixinfo_UidToSid",
- sizeof(struct unixinfo_UidToSid),
- (ndr_push_flags_fn_t) ndr_push_unixinfo_UidToSid,
- (ndr_pull_flags_fn_t) ndr_pull_unixinfo_UidToSid,
- (ndr_print_function_t) ndr_print_unixinfo_UidToSid,
- false,
- },
- {
- "unixinfo_SidToGid",
- sizeof(struct unixinfo_SidToGid),
- (ndr_push_flags_fn_t) ndr_push_unixinfo_SidToGid,
- (ndr_pull_flags_fn_t) ndr_pull_unixinfo_SidToGid,
- (ndr_print_function_t) ndr_print_unixinfo_SidToGid,
- false,
- },
- {
- "unixinfo_GidToSid",
- sizeof(struct unixinfo_GidToSid),
- (ndr_push_flags_fn_t) ndr_push_unixinfo_GidToSid,
- (ndr_pull_flags_fn_t) ndr_pull_unixinfo_GidToSid,
- (ndr_print_function_t) ndr_print_unixinfo_GidToSid,
- false,
- },
- {
- "unixinfo_GetPWUid",
- sizeof(struct unixinfo_GetPWUid),
- (ndr_push_flags_fn_t) ndr_push_unixinfo_GetPWUid,
- (ndr_pull_flags_fn_t) ndr_pull_unixinfo_GetPWUid,
- (ndr_print_function_t) ndr_print_unixinfo_GetPWUid,
- false,
- },
- { NULL, 0, NULL, NULL, NULL, false }
-};
-
-static const char * const unixinfo_endpoint_strings[] = {
- "ncacn_np:[\\pipe\\unixinfo]",
- "ncacn_ip_tcp:",
- "ncalrpc:",
-};
-
-static const struct ndr_interface_string_array unixinfo_endpoints = {
- .count = 3,
- .names = unixinfo_endpoint_strings
-};
-
-static const char * const unixinfo_authservice_strings[] = {
- "host",
-};
-
-static const struct ndr_interface_string_array unixinfo_authservices = {
- .count = 3,
- .names = unixinfo_authservice_strings
-};
-
-
-const struct ndr_interface_table ndr_table_unixinfo = {
- .name = "unixinfo",
- .syntax_id = {
- {0x9c54e310,0xa955,0x4885,{0xbd,0x31},{0x78,0x78,0x71,0x47,0xdf,0xa6}},
- NDR_UNIXINFO_VERSION
- },
- .helpstring = NDR_UNIXINFO_HELPSTRING,
- .num_calls = 5,
- .calls = unixinfo_calls,
- .endpoints = &unixinfo_endpoints,
- .authservices = &unixinfo_authservices
-};
-
diff --git a/source3/librpc/gen_ndr/ndr_unixinfo.h b/source3/librpc/gen_ndr/ndr_unixinfo.h
deleted file mode 100644
index 17f8b811db..0000000000
--- a/source3/librpc/gen_ndr/ndr_unixinfo.h
+++ /dev/null
@@ -1,31 +0,0 @@
-/* header auto-generated by pidl */
-
-#include "librpc/ndr/libndr.h"
-#include "librpc/gen_ndr/unixinfo.h"
-
-#ifndef _HEADER_NDR_unixinfo
-#define _HEADER_NDR_unixinfo
-
-#define NDR_UNIXINFO_UUID "9c54e310-a955-4885-bd31-78787147dfa6"
-#define NDR_UNIXINFO_VERSION 0.0
-#define NDR_UNIXINFO_NAME "unixinfo"
-#define NDR_UNIXINFO_HELPSTRING "Unixinfo specific stuff"
-extern const struct ndr_interface_table ndr_table_unixinfo;
-#define NDR_UNIXINFO_SIDTOUID (0x00)
-
-#define NDR_UNIXINFO_UIDTOSID (0x01)
-
-#define NDR_UNIXINFO_SIDTOGID (0x02)
-
-#define NDR_UNIXINFO_GIDTOSID (0x03)
-
-#define NDR_UNIXINFO_GETPWUID (0x04)
-
-#define NDR_UNIXINFO_CALL_COUNT (5)
-void ndr_print_unixinfo_GetPWUidInfo(struct ndr_print *ndr, const char *name, const struct unixinfo_GetPWUidInfo *r);
-void ndr_print_unixinfo_SidToUid(struct ndr_print *ndr, const char *name, int flags, const struct unixinfo_SidToUid *r);
-void ndr_print_unixinfo_UidToSid(struct ndr_print *ndr, const char *name, int flags, const struct unixinfo_UidToSid *r);
-void ndr_print_unixinfo_SidToGid(struct ndr_print *ndr, const char *name, int flags, const struct unixinfo_SidToGid *r);
-void ndr_print_unixinfo_GidToSid(struct ndr_print *ndr, const char *name, int flags, const struct unixinfo_GidToSid *r);
-void ndr_print_unixinfo_GetPWUid(struct ndr_print *ndr, const char *name, int flags, const struct unixinfo_GetPWUid *r);
-#endif /* _HEADER_NDR_unixinfo */
diff --git a/source3/librpc/gen_ndr/ndr_winreg.c b/source3/librpc/gen_ndr/ndr_winreg.c
index b63d410587..cd16a141b0 100644
--- a/source3/librpc/gen_ndr/ndr_winreg.c
+++ b/source3/librpc/gen_ndr/ndr_winreg.c
@@ -3700,7 +3700,7 @@ static enum ndr_err_code ndr_pull_winreg_QueryMultipleValues(struct ndr_pull *nd
NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->in.buffer_size));
NDR_PULL_SET_MEM_CTX(ndr, _mem_save_buffer_size_0, LIBNDR_FLAG_REF_ALLOC);
NDR_PULL_ALLOC_N(ndr, r->out.values, r->in.num_values);
- memcpy(r->out.values, r->in.values, r->in.num_values * sizeof(*r->in.values));
+ memcpy(r->out.values, r->in.values, (r->in.num_values) * sizeof(*r->in.values));
NDR_PULL_ALLOC(ndr, r->out.buffer_size);
*r->out.buffer_size = *r->in.buffer_size;
if (r->in.values) {
@@ -3798,8 +3798,7 @@ _PUBLIC_ void ndr_print_winreg_QueryMultipleValues(struct ndr_print *ndr, const
ndr->depth++;
for (cntr_values_1=0;cntr_values_1<r->in.num_values;cntr_values_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_values_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_values_1) != -1) {
ndr_print_QueryMultipleValue(ndr, "values", &r->in.values[cntr_values_1]);
free(idx_1);
}
@@ -3828,8 +3827,7 @@ _PUBLIC_ void ndr_print_winreg_QueryMultipleValues(struct ndr_print *ndr, const
ndr->depth++;
for (cntr_values_1=0;cntr_values_1<r->in.num_values;cntr_values_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_values_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_values_1) != -1) {
ndr_print_QueryMultipleValue(ndr, "values", &r->out.values[cntr_values_1]);
free(idx_1);
}
diff --git a/source3/librpc/gen_ndr/ndr_wkssvc.c b/source3/librpc/gen_ndr/ndr_wkssvc.c
index 096c0b2c72..80ea67526e 100644
--- a/source3/librpc/gen_ndr/ndr_wkssvc.c
+++ b/source3/librpc/gen_ndr/ndr_wkssvc.c
@@ -3071,8 +3071,7 @@ _PUBLIC_ void ndr_print_wkssvc_NetWkstaEnumUsersCtr0(struct ndr_print *ndr, cons
ndr->depth++;
for (cntr_user0_1=0;cntr_user0_1<r->entries_read;cntr_user0_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_user0_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_user0_1) != -1) {
ndr_print_wkssvc_NetrWkstaUserInfo0(ndr, "user0", &r->user0[cntr_user0_1]);
free(idx_1);
}
@@ -3317,8 +3316,7 @@ _PUBLIC_ void ndr_print_wkssvc_NetWkstaEnumUsersCtr1(struct ndr_print *ndr, cons
ndr->depth++;
for (cntr_user1_1=0;cntr_user1_1<r->entries_read;cntr_user1_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_user1_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_user1_1) != -1) {
ndr_print_wkssvc_NetrWkstaUserInfo1(ndr, "user1", &r->user1[cntr_user1_1]);
free(idx_1);
}
@@ -3909,8 +3907,7 @@ _PUBLIC_ void ndr_print_wkssvc_NetWkstaTransportCtr0(struct ndr_print *ndr, cons
ndr->depth++;
for (cntr_array_1=0;cntr_array_1<r->count;cntr_array_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_array_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_array_1) != -1) {
ndr_print_wkssvc_NetWkstaTransportInfo0(ndr, "array", &r->array[cntr_array_1]);
free(idx_1);
}
@@ -4867,8 +4864,7 @@ _PUBLIC_ void ndr_print_wkssvc_NetrUseEnumCtr2(struct ndr_print *ndr, const char
ndr->depth++;
for (cntr_array_1=0;cntr_array_1<r->count;cntr_array_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_array_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_array_1) != -1) {
ndr_print_wkssvc_NetrUseInfo2(ndr, "array", &r->array[cntr_array_1]);
free(idx_1);
}
@@ -4954,8 +4950,7 @@ _PUBLIC_ void ndr_print_wkssvc_NetrUseEnumCtr1(struct ndr_print *ndr, const char
ndr->depth++;
for (cntr_array_1=0;cntr_array_1<r->count;cntr_array_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_array_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_array_1) != -1) {
ndr_print_wkssvc_NetrUseInfo1(ndr, "array", &r->array[cntr_array_1]);
free(idx_1);
}
@@ -5041,8 +5036,7 @@ _PUBLIC_ void ndr_print_wkssvc_NetrUseEnumCtr0(struct ndr_print *ndr, const char
ndr->depth++;
for (cntr_array_1=0;cntr_array_1<r->count;cntr_array_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_array_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_array_1) != -1) {
ndr_print_wkssvc_NetrUseInfo0(ndr, "array", &r->array[cntr_array_1]);
free(idx_1);
}
@@ -5666,8 +5660,7 @@ _PUBLIC_ void ndr_print_wkssvc_ComputerNamesCtr(struct ndr_print *ndr, const cha
ndr->depth++;
for (cntr_computer_name_1=0;cntr_computer_name_1<r->count;cntr_computer_name_1++) {
char *idx_1=NULL;
- asprintf(&idx_1, "[%d]", cntr_computer_name_1);
- if (idx_1) {
+ if (asprintf(&idx_1, "[%d]", cntr_computer_name_1) != -1) {
ndr_print_lsa_String(ndr, "computer_name", &r->computer_name[cntr_computer_name_1]);
free(idx_1);
}
@@ -8836,8 +8829,7 @@ _PUBLIC_ void ndr_print_wkssvc_NetrGetJoinableOus(struct ndr_print *ndr, const c
ndr->depth++;
for (cntr_ous_2=0;cntr_ous_2<*r->out.num_ous;cntr_ous_2++) {
char *idx_2=NULL;
- asprintf(&idx_2, "[%d]", cntr_ous_2);
- if (idx_2) {
+ if (asprintf(&idx_2, "[%d]", cntr_ous_2) != -1) {
ndr_print_ptr(ndr, "ous", (*r->out.ous)[cntr_ous_2]);
ndr->depth++;
if ((*r->out.ous)[cntr_ous_2]) {
@@ -9757,8 +9749,7 @@ _PUBLIC_ void ndr_print_wkssvc_NetrGetJoinableOus2(struct ndr_print *ndr, const
ndr->depth++;
for (cntr_ous_2=0;cntr_ous_2<*r->out.num_ous;cntr_ous_2++) {
char *idx_2=NULL;
- asprintf(&idx_2, "[%d]", cntr_ous_2);
- if (idx_2) {
+ if (asprintf(&idx_2, "[%d]", cntr_ous_2) != -1) {
ndr_print_ptr(ndr, "ous", (*r->out.ous)[cntr_ous_2]);
ndr->depth++;
if ((*r->out.ous)[cntr_ous_2]) {
diff --git a/source3/librpc/gen_ndr/ndr_xattr.c b/source3/librpc/gen_ndr/ndr_xattr.c
index 425ad814bf..46c4249d21 100644
--- a/source3/librpc/gen_ndr/ndr_xattr.c
+++ b/source3/librpc/gen_ndr/ndr_xattr.c
@@ -91,8 +91,7 @@ _PUBLIC_ void ndr_print_tdb_xattrs(struct ndr_print *ndr, const char *name, cons
ndr->depth++;
for (cntr_xattrs_0=0;cntr_xattrs_0<r->num_xattrs;cntr_xattrs_0++) {
char *idx_0=NULL;
- asprintf(&idx_0, "[%d]", cntr_xattrs_0);
- if (idx_0) {
+ if (asprintf(&idx_0, "[%d]", cntr_xattrs_0) != -1) {
ndr_print_tdb_xattr(ndr, "xattrs", &r->xattrs[cntr_xattrs_0]);
free(idx_0);
}
diff --git a/source3/librpc/gen_ndr/netlogon.h b/source3/librpc/gen_ndr/netlogon.h
index ef2218c0f2..058e5e7fb0 100644
--- a/source3/librpc/gen_ndr/netlogon.h
+++ b/source3/librpc/gen_ndr/netlogon.h
@@ -603,6 +603,7 @@ union netr_CONTROL_QUERY_INFORMATION {
enum netr_LogonControlCode
#ifndef USE_UINT_ENUMS
{
+ NETLOGON_CONTROL_SYNC=2,
NETLOGON_CONTROL_REDISCOVER=5,
NETLOGON_CONTROL_TC_QUERY=6,
NETLOGON_CONTROL_TRANSPORT_NOTIFY=7,
@@ -610,6 +611,7 @@ enum netr_LogonControlCode
}
#else
{ __donnot_use_enum_netr_LogonControlCode=0x7FFFFFFF}
+#define NETLOGON_CONTROL_SYNC ( 2 )
#define NETLOGON_CONTROL_REDISCOVER ( 5 )
#define NETLOGON_CONTROL_TC_QUERY ( 6 )
#define NETLOGON_CONTROL_TRANSPORT_NOTIFY ( 7 )
@@ -849,7 +851,7 @@ struct netr_LogonSamLogon {
const char *computer_name;/* [unique,charset(UTF16)] */
struct netr_Authenticator *credential;/* [unique] */
uint16_t logon_level;
- union netr_LogonLevel logon;/* [switch_is(logon_level)] */
+ union netr_LogonLevel *logon;/* [ref,switch_is(logon_level)] */
uint16_t validation_level;
struct netr_Authenticator *return_authenticator;/* [unique] */
} in;
@@ -890,7 +892,7 @@ struct netr_ServerReqChallenge {
} in;
struct {
- struct netr_Credential *credentials;/* [ref] */
+ struct netr_Credential *return_credentials;/* [ref] */
NTSTATUS result;
} out;
@@ -907,7 +909,7 @@ struct netr_ServerAuthenticate {
} in;
struct {
- struct netr_Credential *credentials;/* [ref] */
+ struct netr_Credential *return_credentials;/* [ref] */
NTSTATUS result;
} out;
@@ -920,8 +922,8 @@ struct netr_ServerPasswordSet {
const char *account_name;/* [charset(UTF16)] */
enum netr_SchannelType secure_channel_type;
const char *computer_name;/* [charset(UTF16)] */
- struct netr_Authenticator credential;
- struct samr_Password new_password;
+ struct netr_Authenticator *credential;/* [ref] */
+ struct samr_Password *new_password;/* [ref] */
} in;
struct {
@@ -936,7 +938,7 @@ struct netr_DatabaseDeltas {
struct {
const char *logon_server;/* [charset(UTF16)] */
const char *computername;/* [charset(UTF16)] */
- struct netr_Authenticator credential;
+ struct netr_Authenticator *credential;/* [ref] */
enum netr_SamDatabaseID database_id;
uint32_t preferredmaximumlength;
struct netr_Authenticator *return_authenticator;/* [ref] */
@@ -944,7 +946,7 @@ struct netr_DatabaseDeltas {
} in;
struct {
- struct netr_DELTA_ENUM_ARRAY *delta_enum_array;/* [ref] */
+ struct netr_DELTA_ENUM_ARRAY **delta_enum_array;/* [ref] */
struct netr_Authenticator *return_authenticator;/* [ref] */
uint64_t *sequence_num;/* [ref] */
NTSTATUS result;
@@ -1071,7 +1073,7 @@ struct netr_LogonControl2 {
const char *logon_server;/* [unique,charset(UTF16)] */
uint32_t function_code;
uint32_t level;
- union netr_CONTROL_DATA_INFORMATION data;/* [switch_is(function_code)] */
+ union netr_CONTROL_DATA_INFORMATION *data;/* [ref,switch_is(function_code)] */
} in;
struct {
@@ -1093,7 +1095,7 @@ struct netr_ServerAuthenticate2 {
} in;
struct {
- struct netr_Credential *credentials;/* [ref] */
+ struct netr_Credential *return_credentials;/* [ref] */
uint32_t *negotiate_flags;/* [ref] */
NTSTATUS result;
} out;
@@ -1105,7 +1107,7 @@ struct netr_DatabaseSync2 {
struct {
const char *logon_server;/* [charset(UTF16)] */
const char *computername;/* [charset(UTF16)] */
- struct netr_Authenticator credential;
+ struct netr_Authenticator *credential;/* [ref] */
enum netr_SamDatabaseID database_id;
uint16_t restart_state;
uint32_t preferredmaximumlength;
@@ -1114,7 +1116,7 @@ struct netr_DatabaseSync2 {
} in;
struct {
- struct netr_DELTA_ENUM_ARRAY *delta_enum_array;/* [ref] */
+ struct netr_DELTA_ENUM_ARRAY **delta_enum_array;/* [ref] */
struct netr_Authenticator *return_authenticator;/* [ref] */
uint32_t *sync_context;/* [ref] */
NTSTATUS result;
@@ -1435,7 +1437,7 @@ struct netr_LogonSamLogonEx {
const char *server_name;/* [unique,charset(UTF16)] */
const char *computer_name;/* [unique,charset(UTF16)] */
uint16_t logon_level;
- union netr_LogonLevel logon;/* [switch_is(logon_level)] */
+ union netr_LogonLevel *logon;/* [ref,switch_is(logon_level)] */
uint16_t validation_level;
uint32_t *flags;/* [ref] */
} in;
diff --git a/source3/librpc/gen_ndr/ntsvcs.h b/source3/librpc/gen_ndr/ntsvcs.h
new file mode 100644
index 0000000000..9cdfa656b4
--- /dev/null
+++ b/source3/librpc/gen_ndr/ntsvcs.h
@@ -0,0 +1,568 @@
+/* header auto-generated by pidl */
+
+#include <stdint.h>
+
+#ifndef _HEADER_ntsvcs
+#define _HEADER_ntsvcs
+
+struct PNP_HwProfInfo {
+ uint32_t unknown1;
+ uint16_t unknown2[160];
+ uint32_t unknown3;
+};
+
+
+struct PNP_Disconnect {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_Connect {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_GetVersion {
+ struct {
+ uint16_t *version;/* [ref] */
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_GetGlobalState {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_InitDetection {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_ReportLogOn {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_ValidateDeviceInstance {
+ struct {
+ const char *devicepath;/* [ref,charset(UTF16)] */
+ uint32_t flags;
+ } in;
+
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_GetRootDeviceInstance {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_GetRelatedDeviceInstance {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_EnumerateSubKeys {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_GetDeviceList {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_GetDeviceListSize {
+ struct {
+ const char *devicename;/* [unique,charset(UTF16)] */
+ uint32_t flags;
+ } in;
+
+ struct {
+ uint32_t *size;/* [ref] */
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_GetDepth {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_GetDeviceRegProp {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_SetDeviceRegProp {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_GetClassInstance {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_CreateKey {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_DeleteRegistryKey {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_GetClassCount {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_GetClassName {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_DeleteClassKey {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_GetInterfaceDeviceAlias {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_GetInterfaceDeviceList {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_GetInterfaceDeviceListSize {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_RegisterDeviceClassAssociation {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_UnregisterDeviceClassAssociation {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_GetClassRegProp {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_SetClassRegProp {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_CreateDevInst {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_DeviceInstanceAction {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_GetDeviceStatus {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_SetDeviceProblem {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_DisableDevInst {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_UninstallDevInst {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_AddID {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_RegisterDriver {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_QueryRemove {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_RequestDeviceEject {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_IsDockStationPresent {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_RequestEjectPC {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_HwProfFlags {
+ struct {
+ uint32_t unknown1;
+ const char *devicepath;/* [ref,charset(UTF16)] */
+ uint32_t unknown2;
+ const char *unknown5;/* [unique,charset(UTF16)] */
+ uint32_t unknown6;
+ uint32_t unknown7;
+ uint32_t *unknown3;/* [ref] */
+ uint16_t *unknown4;/* [unique] */
+ } in;
+
+ struct {
+ const char **unknown5a;/* [unique,charset(UTF16)] */
+ uint32_t *unknown3;/* [ref] */
+ uint16_t *unknown4;/* [unique] */
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_GetHwProfInfo {
+ struct {
+ uint32_t idx;
+ uint32_t unknown1;
+ uint32_t unknown2;
+ struct PNP_HwProfInfo *info;/* [ref] */
+ } in;
+
+ struct {
+ struct PNP_HwProfInfo *info;/* [ref] */
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_AddEmptyLogConf {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_FreeLogConf {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_GetFirstLogConf {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_GetNextLogConf {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_GetLogConfPriority {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_AddResDes {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_FreeResDes {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_GetNextResDes {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_GetResDesData {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_GetResDesDataSize {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_ModifyResDes {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_DetectResourceLimit {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_QueryResConfList {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_SetHwProf {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_QueryArbitratorFreeData {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_QueryArbitratorFreeSize {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_RunDetection {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_RegisterNotification {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_UnregisterNotification {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_GetCustomDevProp {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_GetVersionInternal {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_GetBlockedDriverInfo {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+
+struct PNP_GetServerSideDeviceInstallFlags {
+ struct {
+ WERROR result;
+ } out;
+
+};
+
+#endif /* _HEADER_ntsvcs */
diff --git a/source3/librpc/gen_ndr/samr.h b/source3/librpc/gen_ndr/samr.h
index dff4bf80f0..c0e2d9d9a9 100644
--- a/source3/librpc/gen_ndr/samr.h
+++ b/source3/librpc/gen_ndr/samr.h
@@ -8,7 +8,11 @@
#ifndef _HEADER_samr
#define _HEADER_samr
+#define MAX_SAM_ENTRIES_W2K ( 0x400 )
+#define MAX_SAM_ENTRIES_W95 ( 50 )
#define SAMR_ENUM_USERS_MULTIPLIER ( 54 )
+#define PASS_MUST_CHANGE_AT_NEXT_LOGON ( 0x01 )
+#define PASS_DONT_CHANGE_AT_NEXT_LOGON ( 0x00 )
/* bitmap samr_AcctFlags */
#define ACB_DISABLED ( 0x00000001 )
#define ACB_HOMDIRREQ ( 0x00000002 )
@@ -590,7 +594,7 @@ struct samr_DispInfoFullGroups {
struct samr_DispEntryAscii {
uint32_t idx;
- struct lsa_AsciiString account_name;
+ struct lsa_AsciiStringLarge account_name;
};
struct samr_DispInfoAscii {
diff --git a/source3/librpc/gen_ndr/srv_lsa.c b/source3/librpc/gen_ndr/srv_lsa.c
index b4600017bc..1ce0448469 100644
--- a/source3/librpc/gen_ndr/srv_lsa.c
+++ b/source3/librpc/gen_ndr/srv_lsa.c
@@ -1128,7 +1128,7 @@ static bool api_lsa_LookupNames(pipes_struct *p)
}
ZERO_STRUCT(r->out);
- r->out.domains = talloc_zero(r, struct lsa_RefDomainList);
+ r->out.domains = talloc_zero(r, struct lsa_RefDomainList *);
if (r->out.domains == NULL) {
talloc_free(r);
return false;
@@ -1210,7 +1210,7 @@ static bool api_lsa_LookupSids(pipes_struct *p)
}
ZERO_STRUCT(r->out);
- r->out.domains = talloc_zero(r, struct lsa_RefDomainList);
+ r->out.domains = talloc_zero(r, struct lsa_RefDomainList *);
if (r->out.domains == NULL) {
talloc_free(r);
return false;
@@ -1452,7 +1452,7 @@ static bool api_lsa_EnumPrivsAccount(pipes_struct *p)
}
ZERO_STRUCT(r->out);
- r->out.privs = talloc_zero(r, struct lsa_PrivilegeSet);
+ r->out.privs = talloc_zero(r, struct lsa_PrivilegeSet *);
if (r->out.privs == NULL) {
talloc_free(r);
return false;
@@ -4437,7 +4437,7 @@ static bool api_lsa_LookupSids2(pipes_struct *p)
}
ZERO_STRUCT(r->out);
- r->out.domains = talloc_zero(r, struct lsa_RefDomainList);
+ r->out.domains = talloc_zero(r, struct lsa_RefDomainList *);
if (r->out.domains == NULL) {
talloc_free(r);
return false;
@@ -4519,7 +4519,7 @@ static bool api_lsa_LookupNames2(pipes_struct *p)
}
ZERO_STRUCT(r->out);
- r->out.domains = talloc_zero(r, struct lsa_RefDomainList);
+ r->out.domains = talloc_zero(r, struct lsa_RefDomainList *);
if (r->out.domains == NULL) {
talloc_free(r);
return false;
@@ -5258,7 +5258,7 @@ static bool api_lsa_LookupNames3(pipes_struct *p)
}
ZERO_STRUCT(r->out);
- r->out.domains = talloc_zero(r, struct lsa_RefDomainList);
+ r->out.domains = talloc_zero(r, struct lsa_RefDomainList *);
if (r->out.domains == NULL) {
talloc_free(r);
return false;
@@ -5858,7 +5858,7 @@ static bool api_lsa_LookupSids3(pipes_struct *p)
}
ZERO_STRUCT(r->out);
- r->out.domains = talloc_zero(r, struct lsa_RefDomainList);
+ r->out.domains = talloc_zero(r, struct lsa_RefDomainList *);
if (r->out.domains == NULL) {
talloc_free(r);
return false;
@@ -5940,7 +5940,7 @@ static bool api_lsa_LookupNames4(pipes_struct *p)
}
ZERO_STRUCT(r->out);
- r->out.domains = talloc_zero(r, struct lsa_RefDomainList);
+ r->out.domains = talloc_zero(r, struct lsa_RefDomainList *);
if (r->out.domains == NULL) {
talloc_free(r);
return false;
diff --git a/source3/librpc/gen_ndr/srv_netlogon.c b/source3/librpc/gen_ndr/srv_netlogon.c
index 808493463a..67876f11ef 100644
--- a/source3/librpc/gen_ndr/srv_netlogon.c
+++ b/source3/librpc/gen_ndr/srv_netlogon.c
@@ -367,7 +367,12 @@ static bool api_netr_ServerReqChallenge(pipes_struct *p)
}
ZERO_STRUCT(r->out);
- r->out.credentials = r->in.credentials;
+ r->out.return_credentials = talloc_zero(r, struct netr_Credential);
+ if (r->out.return_credentials == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
r->out.result = _netr_ServerReqChallenge(p, r);
if (p->rng_fault_state) {
@@ -442,7 +447,12 @@ static bool api_netr_ServerAuthenticate(pipes_struct *p)
}
ZERO_STRUCT(r->out);
- r->out.credentials = r->in.credentials;
+ r->out.return_credentials = talloc_zero(r, struct netr_Credential);
+ if (r->out.return_credentials == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
r->out.result = _netr_ServerAuthenticate(p, r);
if (p->rng_fault_state) {
@@ -599,7 +609,7 @@ static bool api_netr_DatabaseDeltas(pipes_struct *p)
ZERO_STRUCT(r->out);
r->out.return_authenticator = r->in.return_authenticator;
r->out.sequence_num = r->in.sequence_num;
- r->out.delta_enum_array = talloc_zero(r, struct netr_DELTA_ENUM_ARRAY);
+ r->out.delta_enum_array = talloc_zero(r, struct netr_DELTA_ENUM_ARRAY *);
if (r->out.delta_enum_array == NULL) {
talloc_free(r);
return false;
@@ -1280,7 +1290,12 @@ static bool api_netr_ServerAuthenticate2(pipes_struct *p)
}
ZERO_STRUCT(r->out);
- r->out.credentials = r->in.credentials;
+ r->out.return_credentials = talloc_zero(r, struct netr_Credential);
+ if (r->out.return_credentials == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
r->out.negotiate_flags = r->in.negotiate_flags;
r->out.result = _netr_ServerAuthenticate2(p, r);
@@ -1358,7 +1373,7 @@ static bool api_netr_DatabaseSync2(pipes_struct *p)
ZERO_STRUCT(r->out);
r->out.return_authenticator = r->in.return_authenticator;
r->out.sync_context = r->in.sync_context;
- r->out.delta_enum_array = talloc_zero(r, struct netr_DELTA_ENUM_ARRAY);
+ r->out.delta_enum_array = talloc_zero(r, struct netr_DELTA_ENUM_ARRAY *);
if (r->out.delta_enum_array == NULL) {
talloc_free(r);
return false;
diff --git a/source3/librpc/gen_ndr/srv_ntsvcs.c b/source3/librpc/gen_ndr/srv_ntsvcs.c
new file mode 100644
index 0000000000..339de6c747
--- /dev/null
+++ b/source3/librpc/gen_ndr/srv_ntsvcs.c
@@ -0,0 +1,4859 @@
+/*
+ * Unix SMB/CIFS implementation.
+ * server auto-generated by pidl. DO NOT MODIFY!
+ */
+
+#include "includes.h"
+#include "librpc/gen_ndr/srv_ntsvcs.h"
+
+static bool api_PNP_Disconnect(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_Disconnect *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_DISCONNECT];
+
+ r = talloc(talloc_tos(), struct PNP_Disconnect);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_Disconnect, r);
+ }
+
+ r->out.result = _PNP_Disconnect(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_Disconnect, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_Connect(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_Connect *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_CONNECT];
+
+ r = talloc(talloc_tos(), struct PNP_Connect);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_Connect, r);
+ }
+
+ r->out.result = _PNP_Connect(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_Connect, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_GetVersion(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_GetVersion *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_GETVERSION];
+
+ r = talloc(talloc_tos(), struct PNP_GetVersion);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetVersion, r);
+ }
+
+ ZERO_STRUCT(r->out);
+ r->out.version = talloc_zero(r, uint16_t);
+ if (r->out.version == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ r->out.result = _PNP_GetVersion(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetVersion, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_GetGlobalState(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_GetGlobalState *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_GETGLOBALSTATE];
+
+ r = talloc(talloc_tos(), struct PNP_GetGlobalState);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetGlobalState, r);
+ }
+
+ r->out.result = _PNP_GetGlobalState(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetGlobalState, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_InitDetection(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_InitDetection *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_INITDETECTION];
+
+ r = talloc(talloc_tos(), struct PNP_InitDetection);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_InitDetection, r);
+ }
+
+ r->out.result = _PNP_InitDetection(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_InitDetection, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_ReportLogOn(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_ReportLogOn *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_REPORTLOGON];
+
+ r = talloc(talloc_tos(), struct PNP_ReportLogOn);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_ReportLogOn, r);
+ }
+
+ r->out.result = _PNP_ReportLogOn(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_ReportLogOn, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_ValidateDeviceInstance(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_ValidateDeviceInstance *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_VALIDATEDEVICEINSTANCE];
+
+ r = talloc(talloc_tos(), struct PNP_ValidateDeviceInstance);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_ValidateDeviceInstance, r);
+ }
+
+ r->out.result = _PNP_ValidateDeviceInstance(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_ValidateDeviceInstance, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_GetRootDeviceInstance(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_GetRootDeviceInstance *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_GETROOTDEVICEINSTANCE];
+
+ r = talloc(talloc_tos(), struct PNP_GetRootDeviceInstance);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetRootDeviceInstance, r);
+ }
+
+ r->out.result = _PNP_GetRootDeviceInstance(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetRootDeviceInstance, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_GetRelatedDeviceInstance(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_GetRelatedDeviceInstance *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_GETRELATEDDEVICEINSTANCE];
+
+ r = talloc(talloc_tos(), struct PNP_GetRelatedDeviceInstance);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetRelatedDeviceInstance, r);
+ }
+
+ r->out.result = _PNP_GetRelatedDeviceInstance(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetRelatedDeviceInstance, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_EnumerateSubKeys(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_EnumerateSubKeys *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_ENUMERATESUBKEYS];
+
+ r = talloc(talloc_tos(), struct PNP_EnumerateSubKeys);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_EnumerateSubKeys, r);
+ }
+
+ r->out.result = _PNP_EnumerateSubKeys(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_EnumerateSubKeys, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_GetDeviceList(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_GetDeviceList *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_GETDEVICELIST];
+
+ r = talloc(talloc_tos(), struct PNP_GetDeviceList);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetDeviceList, r);
+ }
+
+ r->out.result = _PNP_GetDeviceList(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetDeviceList, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_GetDeviceListSize(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_GetDeviceListSize *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_GETDEVICELISTSIZE];
+
+ r = talloc(talloc_tos(), struct PNP_GetDeviceListSize);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetDeviceListSize, r);
+ }
+
+ ZERO_STRUCT(r->out);
+ r->out.size = talloc_zero(r, uint32_t);
+ if (r->out.size == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ r->out.result = _PNP_GetDeviceListSize(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetDeviceListSize, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_GetDepth(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_GetDepth *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_GETDEPTH];
+
+ r = talloc(talloc_tos(), struct PNP_GetDepth);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetDepth, r);
+ }
+
+ r->out.result = _PNP_GetDepth(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetDepth, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_GetDeviceRegProp(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_GetDeviceRegProp *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_GETDEVICEREGPROP];
+
+ r = talloc(talloc_tos(), struct PNP_GetDeviceRegProp);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetDeviceRegProp, r);
+ }
+
+ r->out.result = _PNP_GetDeviceRegProp(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetDeviceRegProp, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_SetDeviceRegProp(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_SetDeviceRegProp *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_SETDEVICEREGPROP];
+
+ r = talloc(talloc_tos(), struct PNP_SetDeviceRegProp);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_SetDeviceRegProp, r);
+ }
+
+ r->out.result = _PNP_SetDeviceRegProp(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_SetDeviceRegProp, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_GetClassInstance(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_GetClassInstance *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_GETCLASSINSTANCE];
+
+ r = talloc(talloc_tos(), struct PNP_GetClassInstance);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetClassInstance, r);
+ }
+
+ r->out.result = _PNP_GetClassInstance(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetClassInstance, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_CreateKey(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_CreateKey *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_CREATEKEY];
+
+ r = talloc(talloc_tos(), struct PNP_CreateKey);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_CreateKey, r);
+ }
+
+ r->out.result = _PNP_CreateKey(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_CreateKey, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_DeleteRegistryKey(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_DeleteRegistryKey *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_DELETEREGISTRYKEY];
+
+ r = talloc(talloc_tos(), struct PNP_DeleteRegistryKey);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_DeleteRegistryKey, r);
+ }
+
+ r->out.result = _PNP_DeleteRegistryKey(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_DeleteRegistryKey, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_GetClassCount(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_GetClassCount *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_GETCLASSCOUNT];
+
+ r = talloc(talloc_tos(), struct PNP_GetClassCount);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetClassCount, r);
+ }
+
+ r->out.result = _PNP_GetClassCount(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetClassCount, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_GetClassName(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_GetClassName *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_GETCLASSNAME];
+
+ r = talloc(talloc_tos(), struct PNP_GetClassName);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetClassName, r);
+ }
+
+ r->out.result = _PNP_GetClassName(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetClassName, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_DeleteClassKey(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_DeleteClassKey *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_DELETECLASSKEY];
+
+ r = talloc(talloc_tos(), struct PNP_DeleteClassKey);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_DeleteClassKey, r);
+ }
+
+ r->out.result = _PNP_DeleteClassKey(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_DeleteClassKey, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_GetInterfaceDeviceAlias(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_GetInterfaceDeviceAlias *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_GETINTERFACEDEVICEALIAS];
+
+ r = talloc(talloc_tos(), struct PNP_GetInterfaceDeviceAlias);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetInterfaceDeviceAlias, r);
+ }
+
+ r->out.result = _PNP_GetInterfaceDeviceAlias(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetInterfaceDeviceAlias, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_GetInterfaceDeviceList(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_GetInterfaceDeviceList *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_GETINTERFACEDEVICELIST];
+
+ r = talloc(talloc_tos(), struct PNP_GetInterfaceDeviceList);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetInterfaceDeviceList, r);
+ }
+
+ r->out.result = _PNP_GetInterfaceDeviceList(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetInterfaceDeviceList, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_GetInterfaceDeviceListSize(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_GetInterfaceDeviceListSize *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_GETINTERFACEDEVICELISTSIZE];
+
+ r = talloc(talloc_tos(), struct PNP_GetInterfaceDeviceListSize);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetInterfaceDeviceListSize, r);
+ }
+
+ r->out.result = _PNP_GetInterfaceDeviceListSize(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetInterfaceDeviceListSize, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_RegisterDeviceClassAssociation(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_RegisterDeviceClassAssociation *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_REGISTERDEVICECLASSASSOCIATION];
+
+ r = talloc(talloc_tos(), struct PNP_RegisterDeviceClassAssociation);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_RegisterDeviceClassAssociation, r);
+ }
+
+ r->out.result = _PNP_RegisterDeviceClassAssociation(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_RegisterDeviceClassAssociation, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_UnregisterDeviceClassAssociation(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_UnregisterDeviceClassAssociation *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_UNREGISTERDEVICECLASSASSOCIATION];
+
+ r = talloc(talloc_tos(), struct PNP_UnregisterDeviceClassAssociation);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_UnregisterDeviceClassAssociation, r);
+ }
+
+ r->out.result = _PNP_UnregisterDeviceClassAssociation(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_UnregisterDeviceClassAssociation, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_GetClassRegProp(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_GetClassRegProp *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_GETCLASSREGPROP];
+
+ r = talloc(talloc_tos(), struct PNP_GetClassRegProp);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetClassRegProp, r);
+ }
+
+ r->out.result = _PNP_GetClassRegProp(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetClassRegProp, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_SetClassRegProp(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_SetClassRegProp *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_SETCLASSREGPROP];
+
+ r = talloc(talloc_tos(), struct PNP_SetClassRegProp);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_SetClassRegProp, r);
+ }
+
+ r->out.result = _PNP_SetClassRegProp(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_SetClassRegProp, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_CreateDevInst(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_CreateDevInst *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_CREATEDEVINST];
+
+ r = talloc(talloc_tos(), struct PNP_CreateDevInst);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_CreateDevInst, r);
+ }
+
+ r->out.result = _PNP_CreateDevInst(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_CreateDevInst, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_DeviceInstanceAction(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_DeviceInstanceAction *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_DEVICEINSTANCEACTION];
+
+ r = talloc(talloc_tos(), struct PNP_DeviceInstanceAction);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_DeviceInstanceAction, r);
+ }
+
+ r->out.result = _PNP_DeviceInstanceAction(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_DeviceInstanceAction, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_GetDeviceStatus(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_GetDeviceStatus *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_GETDEVICESTATUS];
+
+ r = talloc(talloc_tos(), struct PNP_GetDeviceStatus);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetDeviceStatus, r);
+ }
+
+ r->out.result = _PNP_GetDeviceStatus(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetDeviceStatus, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_SetDeviceProblem(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_SetDeviceProblem *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_SETDEVICEPROBLEM];
+
+ r = talloc(talloc_tos(), struct PNP_SetDeviceProblem);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_SetDeviceProblem, r);
+ }
+
+ r->out.result = _PNP_SetDeviceProblem(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_SetDeviceProblem, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_DisableDevInst(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_DisableDevInst *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_DISABLEDEVINST];
+
+ r = talloc(talloc_tos(), struct PNP_DisableDevInst);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_DisableDevInst, r);
+ }
+
+ r->out.result = _PNP_DisableDevInst(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_DisableDevInst, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_UninstallDevInst(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_UninstallDevInst *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_UNINSTALLDEVINST];
+
+ r = talloc(talloc_tos(), struct PNP_UninstallDevInst);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_UninstallDevInst, r);
+ }
+
+ r->out.result = _PNP_UninstallDevInst(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_UninstallDevInst, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_AddID(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_AddID *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_ADDID];
+
+ r = talloc(talloc_tos(), struct PNP_AddID);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_AddID, r);
+ }
+
+ r->out.result = _PNP_AddID(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_AddID, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_RegisterDriver(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_RegisterDriver *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_REGISTERDRIVER];
+
+ r = talloc(talloc_tos(), struct PNP_RegisterDriver);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_RegisterDriver, r);
+ }
+
+ r->out.result = _PNP_RegisterDriver(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_RegisterDriver, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_QueryRemove(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_QueryRemove *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_QUERYREMOVE];
+
+ r = talloc(talloc_tos(), struct PNP_QueryRemove);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_QueryRemove, r);
+ }
+
+ r->out.result = _PNP_QueryRemove(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_QueryRemove, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_RequestDeviceEject(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_RequestDeviceEject *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_REQUESTDEVICEEJECT];
+
+ r = talloc(talloc_tos(), struct PNP_RequestDeviceEject);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_RequestDeviceEject, r);
+ }
+
+ r->out.result = _PNP_RequestDeviceEject(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_RequestDeviceEject, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_IsDockStationPresent(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_IsDockStationPresent *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_ISDOCKSTATIONPRESENT];
+
+ r = talloc(talloc_tos(), struct PNP_IsDockStationPresent);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_IsDockStationPresent, r);
+ }
+
+ r->out.result = _PNP_IsDockStationPresent(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_IsDockStationPresent, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_RequestEjectPC(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_RequestEjectPC *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_REQUESTEJECTPC];
+
+ r = talloc(talloc_tos(), struct PNP_RequestEjectPC);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_RequestEjectPC, r);
+ }
+
+ r->out.result = _PNP_RequestEjectPC(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_RequestEjectPC, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_HwProfFlags(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_HwProfFlags *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_HWPROFFLAGS];
+
+ r = talloc(talloc_tos(), struct PNP_HwProfFlags);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_HwProfFlags, r);
+ }
+
+ ZERO_STRUCT(r->out);
+ r->out.unknown3 = r->in.unknown3;
+ r->out.unknown4 = r->in.unknown4;
+ r->out.unknown5a = talloc_zero(r, const char *);
+ if (r->out.unknown5a == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ r->out.result = _PNP_HwProfFlags(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_HwProfFlags, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_GetHwProfInfo(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_GetHwProfInfo *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_GETHWPROFINFO];
+
+ r = talloc(talloc_tos(), struct PNP_GetHwProfInfo);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetHwProfInfo, r);
+ }
+
+ ZERO_STRUCT(r->out);
+ r->out.info = r->in.info;
+ r->out.result = _PNP_GetHwProfInfo(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetHwProfInfo, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_AddEmptyLogConf(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_AddEmptyLogConf *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_ADDEMPTYLOGCONF];
+
+ r = talloc(talloc_tos(), struct PNP_AddEmptyLogConf);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_AddEmptyLogConf, r);
+ }
+
+ r->out.result = _PNP_AddEmptyLogConf(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_AddEmptyLogConf, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_FreeLogConf(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_FreeLogConf *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_FREELOGCONF];
+
+ r = talloc(talloc_tos(), struct PNP_FreeLogConf);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_FreeLogConf, r);
+ }
+
+ r->out.result = _PNP_FreeLogConf(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_FreeLogConf, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_GetFirstLogConf(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_GetFirstLogConf *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_GETFIRSTLOGCONF];
+
+ r = talloc(talloc_tos(), struct PNP_GetFirstLogConf);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetFirstLogConf, r);
+ }
+
+ r->out.result = _PNP_GetFirstLogConf(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetFirstLogConf, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_GetNextLogConf(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_GetNextLogConf *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_GETNEXTLOGCONF];
+
+ r = talloc(talloc_tos(), struct PNP_GetNextLogConf);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetNextLogConf, r);
+ }
+
+ r->out.result = _PNP_GetNextLogConf(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetNextLogConf, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_GetLogConfPriority(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_GetLogConfPriority *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_GETLOGCONFPRIORITY];
+
+ r = talloc(talloc_tos(), struct PNP_GetLogConfPriority);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetLogConfPriority, r);
+ }
+
+ r->out.result = _PNP_GetLogConfPriority(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetLogConfPriority, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_AddResDes(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_AddResDes *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_ADDRESDES];
+
+ r = talloc(talloc_tos(), struct PNP_AddResDes);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_AddResDes, r);
+ }
+
+ r->out.result = _PNP_AddResDes(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_AddResDes, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_FreeResDes(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_FreeResDes *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_FREERESDES];
+
+ r = talloc(talloc_tos(), struct PNP_FreeResDes);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_FreeResDes, r);
+ }
+
+ r->out.result = _PNP_FreeResDes(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_FreeResDes, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_GetNextResDes(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_GetNextResDes *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_GETNEXTRESDES];
+
+ r = talloc(talloc_tos(), struct PNP_GetNextResDes);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetNextResDes, r);
+ }
+
+ r->out.result = _PNP_GetNextResDes(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetNextResDes, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_GetResDesData(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_GetResDesData *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_GETRESDESDATA];
+
+ r = talloc(talloc_tos(), struct PNP_GetResDesData);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetResDesData, r);
+ }
+
+ r->out.result = _PNP_GetResDesData(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetResDesData, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_GetResDesDataSize(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_GetResDesDataSize *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_GETRESDESDATASIZE];
+
+ r = talloc(talloc_tos(), struct PNP_GetResDesDataSize);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetResDesDataSize, r);
+ }
+
+ r->out.result = _PNP_GetResDesDataSize(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetResDesDataSize, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_ModifyResDes(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_ModifyResDes *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_MODIFYRESDES];
+
+ r = talloc(talloc_tos(), struct PNP_ModifyResDes);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_ModifyResDes, r);
+ }
+
+ r->out.result = _PNP_ModifyResDes(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_ModifyResDes, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_DetectResourceLimit(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_DetectResourceLimit *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_DETECTRESOURCELIMIT];
+
+ r = talloc(talloc_tos(), struct PNP_DetectResourceLimit);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_DetectResourceLimit, r);
+ }
+
+ r->out.result = _PNP_DetectResourceLimit(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_DetectResourceLimit, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_QueryResConfList(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_QueryResConfList *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_QUERYRESCONFLIST];
+
+ r = talloc(talloc_tos(), struct PNP_QueryResConfList);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_QueryResConfList, r);
+ }
+
+ r->out.result = _PNP_QueryResConfList(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_QueryResConfList, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_SetHwProf(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_SetHwProf *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_SETHWPROF];
+
+ r = talloc(talloc_tos(), struct PNP_SetHwProf);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_SetHwProf, r);
+ }
+
+ r->out.result = _PNP_SetHwProf(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_SetHwProf, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_QueryArbitratorFreeData(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_QueryArbitratorFreeData *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_QUERYARBITRATORFREEDATA];
+
+ r = talloc(talloc_tos(), struct PNP_QueryArbitratorFreeData);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_QueryArbitratorFreeData, r);
+ }
+
+ r->out.result = _PNP_QueryArbitratorFreeData(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_QueryArbitratorFreeData, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_QueryArbitratorFreeSize(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_QueryArbitratorFreeSize *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_QUERYARBITRATORFREESIZE];
+
+ r = talloc(talloc_tos(), struct PNP_QueryArbitratorFreeSize);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_QueryArbitratorFreeSize, r);
+ }
+
+ r->out.result = _PNP_QueryArbitratorFreeSize(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_QueryArbitratorFreeSize, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_RunDetection(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_RunDetection *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_RUNDETECTION];
+
+ r = talloc(talloc_tos(), struct PNP_RunDetection);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_RunDetection, r);
+ }
+
+ r->out.result = _PNP_RunDetection(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_RunDetection, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_RegisterNotification(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_RegisterNotification *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_REGISTERNOTIFICATION];
+
+ r = talloc(talloc_tos(), struct PNP_RegisterNotification);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_RegisterNotification, r);
+ }
+
+ r->out.result = _PNP_RegisterNotification(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_RegisterNotification, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_UnregisterNotification(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_UnregisterNotification *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_UNREGISTERNOTIFICATION];
+
+ r = talloc(talloc_tos(), struct PNP_UnregisterNotification);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_UnregisterNotification, r);
+ }
+
+ r->out.result = _PNP_UnregisterNotification(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_UnregisterNotification, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_GetCustomDevProp(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_GetCustomDevProp *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_GETCUSTOMDEVPROP];
+
+ r = talloc(talloc_tos(), struct PNP_GetCustomDevProp);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetCustomDevProp, r);
+ }
+
+ r->out.result = _PNP_GetCustomDevProp(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetCustomDevProp, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_GetVersionInternal(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_GetVersionInternal *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_GETVERSIONINTERNAL];
+
+ r = talloc(talloc_tos(), struct PNP_GetVersionInternal);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetVersionInternal, r);
+ }
+
+ r->out.result = _PNP_GetVersionInternal(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetVersionInternal, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_GetBlockedDriverInfo(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_GetBlockedDriverInfo *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_GETBLOCKEDDRIVERINFO];
+
+ r = talloc(talloc_tos(), struct PNP_GetBlockedDriverInfo);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetBlockedDriverInfo, r);
+ }
+
+ r->out.result = _PNP_GetBlockedDriverInfo(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetBlockedDriverInfo, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+static bool api_PNP_GetServerSideDeviceInstallFlags(pipes_struct *p)
+{
+ const struct ndr_interface_call *call;
+ struct ndr_pull *pull;
+ struct ndr_push *push;
+ enum ndr_err_code ndr_err;
+ DATA_BLOB blob;
+ struct PNP_GetServerSideDeviceInstallFlags *r;
+
+ call = &ndr_table_ntsvcs.calls[NDR_PNP_GETSERVERSIDEDEVICEINSTALLFLAGS];
+
+ r = talloc(talloc_tos(), struct PNP_GetServerSideDeviceInstallFlags);
+ if (r == NULL) {
+ return false;
+ }
+
+ if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull = ndr_pull_init_blob(&blob, r);
+ if (pull == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+ ndr_err = call->ndr_pull(pull, NDR_IN, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_IN_DEBUG(PNP_GetServerSideDeviceInstallFlags, r);
+ }
+
+ r->out.result = _PNP_GetServerSideDeviceInstallFlags(p, r);
+
+ if (p->rng_fault_state) {
+ talloc_free(r);
+ /* Return true here, srv_pipe_hnd.c will take care */
+ return true;
+ }
+
+ if (DEBUGLEVEL >= 10) {
+ NDR_PRINT_OUT_DEBUG(PNP_GetServerSideDeviceInstallFlags, r);
+ }
+
+ push = ndr_push_init_ctx(r);
+ if (push == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ ndr_err = call->ndr_push(push, NDR_OUT, r);
+ if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+ talloc_free(r);
+ return false;
+ }
+
+ blob = ndr_push_blob(push);
+ if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+ talloc_free(r);
+ return false;
+ }
+
+ talloc_free(r);
+
+ return true;
+}
+
+
+/* Tables */
+static struct api_struct api_ntsvcs_cmds[] =
+{
+ {"PNP_DISCONNECT", NDR_PNP_DISCONNECT, api_PNP_Disconnect},
+ {"PNP_CONNECT", NDR_PNP_CONNECT, api_PNP_Connect},
+ {"PNP_GETVERSION", NDR_PNP_GETVERSION, api_PNP_GetVersion},
+ {"PNP_GETGLOBALSTATE", NDR_PNP_GETGLOBALSTATE, api_PNP_GetGlobalState},
+ {"PNP_INITDETECTION", NDR_PNP_INITDETECTION, api_PNP_InitDetection},
+ {"PNP_REPORTLOGON", NDR_PNP_REPORTLOGON, api_PNP_ReportLogOn},
+ {"PNP_VALIDATEDEVICEINSTANCE", NDR_PNP_VALIDATEDEVICEINSTANCE, api_PNP_ValidateDeviceInstance},
+ {"PNP_GETROOTDEVICEINSTANCE", NDR_PNP_GETROOTDEVICEINSTANCE, api_PNP_GetRootDeviceInstance},
+ {"PNP_GETRELATEDDEVICEINSTANCE", NDR_PNP_GETRELATEDDEVICEINSTANCE, api_PNP_GetRelatedDeviceInstance},
+ {"PNP_ENUMERATESUBKEYS", NDR_PNP_ENUMERATESUBKEYS, api_PNP_EnumerateSubKeys},
+ {"PNP_GETDEVICELIST", NDR_PNP_GETDEVICELIST, api_PNP_GetDeviceList},
+ {"PNP_GETDEVICELISTSIZE", NDR_PNP_GETDEVICELISTSIZE, api_PNP_GetDeviceListSize},
+ {"PNP_GETDEPTH", NDR_PNP_GETDEPTH, api_PNP_GetDepth},
+ {"PNP_GETDEVICEREGPROP", NDR_PNP_GETDEVICEREGPROP, api_PNP_GetDeviceRegProp},
+ {"PNP_SETDEVICEREGPROP", NDR_PNP_SETDEVICEREGPROP, api_PNP_SetDeviceRegProp},
+ {"PNP_GETCLASSINSTANCE", NDR_PNP_GETCLASSINSTANCE, api_PNP_GetClassInstance},
+ {"PNP_CREATEKEY", NDR_PNP_CREATEKEY, api_PNP_CreateKey},
+ {"PNP_DELETEREGISTRYKEY", NDR_PNP_DELETEREGISTRYKEY, api_PNP_DeleteRegistryKey},
+ {"PNP_GETCLASSCOUNT", NDR_PNP_GETCLASSCOUNT, api_PNP_GetClassCount},
+ {"PNP_GETCLASSNAME", NDR_PNP_GETCLASSNAME, api_PNP_GetClassName},
+ {"PNP_DELETECLASSKEY", NDR_PNP_DELETECLASSKEY, api_PNP_DeleteClassKey},
+ {"PNP_GETINTERFACEDEVICEALIAS", NDR_PNP_GETINTERFACEDEVICEALIAS, api_PNP_GetInterfaceDeviceAlias},
+ {"PNP_GETINTERFACEDEVICELIST", NDR_PNP_GETINTERFACEDEVICELIST, api_PNP_GetInterfaceDeviceList},
+ {"PNP_GETINTERFACEDEVICELISTSIZE", NDR_PNP_GETINTERFACEDEVICELISTSIZE, api_PNP_GetInterfaceDeviceListSize},
+ {"PNP_REGISTERDEVICECLASSASSOCIATION", NDR_PNP_REGISTERDEVICECLASSASSOCIATION, api_PNP_RegisterDeviceClassAssociation},
+ {"PNP_UNREGISTERDEVICECLASSASSOCIATION", NDR_PNP_UNREGISTERDEVICECLASSASSOCIATION, api_PNP_UnregisterDeviceClassAssociation},
+ {"PNP_GETCLASSREGPROP", NDR_PNP_GETCLASSREGPROP, api_PNP_GetClassRegProp},
+ {"PNP_SETCLASSREGPROP", NDR_PNP_SETCLASSREGPROP, api_PNP_SetClassRegProp},
+ {"PNP_CREATEDEVINST", NDR_PNP_CREATEDEVINST, api_PNP_CreateDevInst},
+ {"PNP_DEVICEINSTANCEACTION", NDR_PNP_DEVICEINSTANCEACTION, api_PNP_DeviceInstanceAction},
+ {"PNP_GETDEVICESTATUS", NDR_PNP_GETDEVICESTATUS, api_PNP_GetDeviceStatus},
+ {"PNP_SETDEVICEPROBLEM", NDR_PNP_SETDEVICEPROBLEM, api_PNP_SetDeviceProblem},
+ {"PNP_DISABLEDEVINST", NDR_PNP_DISABLEDEVINST, api_PNP_DisableDevInst},
+ {"PNP_UNINSTALLDEVINST", NDR_PNP_UNINSTALLDEVINST, api_PNP_UninstallDevInst},
+ {"PNP_ADDID", NDR_PNP_ADDID, api_PNP_AddID},
+ {"PNP_REGISTERDRIVER", NDR_PNP_REGISTERDRIVER, api_PNP_RegisterDriver},
+ {"PNP_QUERYREMOVE", NDR_PNP_QUERYREMOVE, api_PNP_QueryRemove},
+ {"PNP_REQUESTDEVICEEJECT", NDR_PNP_REQUESTDEVICEEJECT, api_PNP_RequestDeviceEject},
+ {"PNP_ISDOCKSTATIONPRESENT", NDR_PNP_ISDOCKSTATIONPRESENT, api_PNP_IsDockStationPresent},
+ {"PNP_REQUESTEJECTPC", NDR_PNP_REQUESTEJECTPC, api_PNP_RequestEjectPC},
+ {"PNP_HWPROFFLAGS", NDR_PNP_HWPROFFLAGS, api_PNP_HwProfFlags},
+ {"PNP_GETHWPROFINFO", NDR_PNP_GETHWPROFINFO, api_PNP_GetHwProfInfo},
+ {"PNP_ADDEMPTYLOGCONF", NDR_PNP_ADDEMPTYLOGCONF, api_PNP_AddEmptyLogConf},
+ {"PNP_FREELOGCONF", NDR_PNP_FREELOGCONF, api_PNP_FreeLogConf},
+ {"PNP_GETFIRSTLOGCONF", NDR_PNP_GETFIRSTLOGCONF, api_PNP_GetFirstLogConf},
+ {"PNP_GETNEXTLOGCONF", NDR_PNP_GETNEXTLOGCONF, api_PNP_GetNextLogConf},
+ {"PNP_GETLOGCONFPRIORITY", NDR_PNP_GETLOGCONFPRIORITY, api_PNP_GetLogConfPriority},
+ {"PNP_ADDRESDES", NDR_PNP_ADDRESDES, api_PNP_AddResDes},
+ {"PNP_FREERESDES", NDR_PNP_FREERESDES, api_PNP_FreeResDes},
+ {"PNP_GETNEXTRESDES", NDR_PNP_GETNEXTRESDES, api_PNP_GetNextResDes},
+ {"PNP_GETRESDESDATA", NDR_PNP_GETRESDESDATA, api_PNP_GetResDesData},
+ {"PNP_GETRESDESDATASIZE", NDR_PNP_GETRESDESDATASIZE, api_PNP_GetResDesDataSize},
+ {"PNP_MODIFYRESDES", NDR_PNP_MODIFYRESDES, api_PNP_ModifyResDes},
+ {"PNP_DETECTRESOURCELIMIT", NDR_PNP_DETECTRESOURCELIMIT, api_PNP_DetectResourceLimit},
+ {"PNP_QUERYRESCONFLIST", NDR_PNP_QUERYRESCONFLIST, api_PNP_QueryResConfList},
+ {"PNP_SETHWPROF", NDR_PNP_SETHWPROF, api_PNP_SetHwProf},
+ {"PNP_QUERYARBITRATORFREEDATA", NDR_PNP_QUERYARBITRATORFREEDATA, api_PNP_QueryArbitratorFreeData},
+ {"PNP_QUERYARBITRATORFREESIZE", NDR_PNP_QUERYARBITRATORFREESIZE, api_PNP_QueryArbitratorFreeSize},
+ {"PNP_RUNDETECTION", NDR_PNP_RUNDETECTION, api_PNP_RunDetection},
+ {"PNP_REGISTERNOTIFICATION", NDR_PNP_REGISTERNOTIFICATION, api_PNP_RegisterNotification},
+ {"PNP_UNREGISTERNOTIFICATION", NDR_PNP_UNREGISTERNOTIFICATION, api_PNP_UnregisterNotification},
+ {"PNP_GETCUSTOMDEVPROP", NDR_PNP_GETCUSTOMDEVPROP, api_PNP_GetCustomDevProp},
+ {"PNP_GETVERSIONINTERNAL", NDR_PNP_GETVERSIONINTERNAL, api_PNP_GetVersionInternal},
+ {"PNP_GETBLOCKEDDRIVERINFO", NDR_PNP_GETBLOCKEDDRIVERINFO, api_PNP_GetBlockedDriverInfo},
+ {"PNP_GETSERVERSIDEDEVICEINSTALLFLAGS", NDR_PNP_GETSERVERSIDEDEVICEINSTALLFLAGS, api_PNP_GetServerSideDeviceInstallFlags},
+};
+
+void ntsvcs_get_pipe_fns(struct api_struct **fns, int *n_fns)
+{
+ *fns = api_ntsvcs_cmds;
+ *n_fns = sizeof(api_ntsvcs_cmds) / sizeof(struct api_struct);
+}
+
+NTSTATUS rpc_ntsvcs_init(void)
+{
+ return rpc_pipe_register_commands(SMB_RPC_INTERFACE_VERSION, "ntsvcs", "ntsvcs", api_ntsvcs_cmds, sizeof(api_ntsvcs_cmds) / sizeof(struct api_struct));
+}
diff --git a/source3/librpc/gen_ndr/srv_ntsvcs.h b/source3/librpc/gen_ndr/srv_ntsvcs.h
new file mode 100644
index 0000000000..c3969b11da
--- /dev/null
+++ b/source3/librpc/gen_ndr/srv_ntsvcs.h
@@ -0,0 +1,71 @@
+#include "librpc/gen_ndr/ndr_ntsvcs.h"
+#ifndef __SRV_NTSVCS__
+#define __SRV_NTSVCS__
+WERROR _PNP_Disconnect(pipes_struct *p, struct PNP_Disconnect *r);
+WERROR _PNP_Connect(pipes_struct *p, struct PNP_Connect *r);
+WERROR _PNP_GetVersion(pipes_struct *p, struct PNP_GetVersion *r);
+WERROR _PNP_GetGlobalState(pipes_struct *p, struct PNP_GetGlobalState *r);
+WERROR _PNP_InitDetection(pipes_struct *p, struct PNP_InitDetection *r);
+WERROR _PNP_ReportLogOn(pipes_struct *p, struct PNP_ReportLogOn *r);
+WERROR _PNP_ValidateDeviceInstance(pipes_struct *p, struct PNP_ValidateDeviceInstance *r);
+WERROR _PNP_GetRootDeviceInstance(pipes_struct *p, struct PNP_GetRootDeviceInstance *r);
+WERROR _PNP_GetRelatedDeviceInstance(pipes_struct *p, struct PNP_GetRelatedDeviceInstance *r);
+WERROR _PNP_EnumerateSubKeys(pipes_struct *p, struct PNP_EnumerateSubKeys *r);
+WERROR _PNP_GetDeviceList(pipes_struct *p, struct PNP_GetDeviceList *r);
+WERROR _PNP_GetDeviceListSize(pipes_struct *p, struct PNP_GetDeviceListSize *r);
+WERROR _PNP_GetDepth(pipes_struct *p, struct PNP_GetDepth *r);
+WERROR _PNP_GetDeviceRegProp(pipes_struct *p, struct PNP_GetDeviceRegProp *r);
+WERROR _PNP_SetDeviceRegProp(pipes_struct *p, struct PNP_SetDeviceRegProp *r);
+WERROR _PNP_GetClassInstance(pipes_struct *p, struct PNP_GetClassInstance *r);
+WERROR _PNP_CreateKey(pipes_struct *p, struct PNP_CreateKey *r);
+WERROR _PNP_DeleteRegistryKey(pipes_struct *p, struct PNP_DeleteRegistryKey *r);
+WERROR _PNP_GetClassCount(pipes_struct *p, struct PNP_GetClassCount *r);
+WERROR _PNP_GetClassName(pipes_struct *p, struct PNP_GetClassName *r);
+WERROR _PNP_DeleteClassKey(pipes_struct *p, struct PNP_DeleteClassKey *r);
+WERROR _PNP_GetInterfaceDeviceAlias(pipes_struct *p, struct PNP_GetInterfaceDeviceAlias *r);
+WERROR _PNP_GetInterfaceDeviceList(pipes_struct *p, struct PNP_GetInterfaceDeviceList *r);
+WERROR _PNP_GetInterfaceDeviceListSize(pipes_struct *p, struct PNP_GetInterfaceDeviceListSize *r);
+WERROR _PNP_RegisterDeviceClassAssociation(pipes_struct *p, struct PNP_RegisterDeviceClassAssociation *r);
+WERROR _PNP_UnregisterDeviceClassAssociation(pipes_struct *p, struct PNP_UnregisterDeviceClassAssociation *r);
+WERROR _PNP_GetClassRegProp(pipes_struct *p, struct PNP_GetClassRegProp *r);
+WERROR _PNP_SetClassRegProp(pipes_struct *p, struct PNP_SetClassRegProp *r);
+WERROR _PNP_CreateDevInst(pipes_struct *p, struct PNP_CreateDevInst *r);
+WERROR _PNP_DeviceInstanceAction(pipes_struct *p, struct PNP_DeviceInstanceAction *r);
+WERROR _PNP_GetDeviceStatus(pipes_struct *p, struct PNP_GetDeviceStatus *r);
+WERROR _PNP_SetDeviceProblem(pipes_struct *p, struct PNP_SetDeviceProblem *r);
+WERROR _PNP_DisableDevInst(pipes_struct *p, struct PNP_DisableDevInst *r);
+WERROR _PNP_UninstallDevInst(pipes_struct *p, struct PNP_UninstallDevInst *r);
+WERROR _PNP_AddID(pipes_struct *p, struct PNP_AddID *r);
+WERROR _PNP_RegisterDriver(pipes_struct *p, struct PNP_RegisterDriver *r);
+WERROR _PNP_QueryRemove(pipes_struct *p, struct PNP_QueryRemove *r);
+WERROR _PNP_RequestDeviceEject(pipes_struct *p, struct PNP_RequestDeviceEject *r);
+WERROR _PNP_IsDockStationPresent(pipes_struct *p, struct PNP_IsDockStationPresent *r);
+WERROR _PNP_RequestEjectPC(pipes_struct *p, struct PNP_RequestEjectPC *r);
+WERROR _PNP_HwProfFlags(pipes_struct *p, struct PNP_HwProfFlags *r);
+WERROR _PNP_GetHwProfInfo(pipes_struct *p, struct PNP_GetHwProfInfo *r);
+WERROR _PNP_AddEmptyLogConf(pipes_struct *p, struct PNP_AddEmptyLogConf *r);
+WERROR _PNP_FreeLogConf(pipes_struct *p, struct PNP_FreeLogConf *r);
+WERROR _PNP_GetFirstLogConf(pipes_struct *p, struct PNP_GetFirstLogConf *r);
+WERROR _PNP_GetNextLogConf(pipes_struct *p, struct PNP_GetNextLogConf *r);
+WERROR _PNP_GetLogConfPriority(pipes_struct *p, struct PNP_GetLogConfPriority *r);
+WERROR _PNP_AddResDes(pipes_struct *p, struct PNP_AddResDes *r);
+WERROR _PNP_FreeResDes(pipes_struct *p, struct PNP_FreeResDes *r);
+WERROR _PNP_GetNextResDes(pipes_struct *p, struct PNP_GetNextResDes *r);
+WERROR _PNP_GetResDesData(pipes_struct *p, struct PNP_GetResDesData *r);
+WERROR _PNP_GetResDesDataSize(pipes_struct *p, struct PNP_GetResDesDataSize *r);
+WERROR _PNP_ModifyResDes(pipes_struct *p, struct PNP_ModifyResDes *r);
+WERROR _PNP_DetectResourceLimit(pipes_struct *p, struct PNP_DetectResourceLimit *r);
+WERROR _PNP_QueryResConfList(pipes_struct *p, struct PNP_QueryResConfList *r);
+WERROR _PNP_SetHwProf(pipes_struct *p, struct PNP_SetHwProf *r);
+WERROR _PNP_QueryArbitratorFreeData(pipes_struct *p, struct PNP_QueryArbitratorFreeData *r);
+WERROR _PNP_QueryArbitratorFreeSize(pipes_struct *p, struct PNP_QueryArbitratorFreeSize *r);
+WERROR _PNP_RunDetection(pipes_struct *p, struct PNP_RunDetection *r);
+WERROR _PNP_RegisterNotification(pipes_struct *p, struct PNP_RegisterNotification *r);
+WERROR _PNP_UnregisterNotification(pipes_struct *p, struct PNP_UnregisterNotification *r);
+WERROR _PNP_GetCustomDevProp(pipes_struct *p, struct PNP_GetCustomDevProp *r);
+WERROR _PNP_GetVersionInternal(pipes_struct *p, struct PNP_GetVersionInternal *r);
+WERROR _PNP_GetBlockedDriverInfo(pipes_struct *p, struct PNP_GetBlockedDriverInfo *r);
+WERROR _PNP_GetServerSideDeviceInstallFlags(pipes_struct *p, struct PNP_GetServerSideDeviceInstallFlags *r);
+void ntsvcs_get_pipe_fns(struct api_struct **fns, int *n_fns);
+NTSTATUS rpc_ntsvcs_init(void);
+#endif /* __SRV_NTSVCS__ */
diff --git a/source3/librpc/gen_ndr/srv_srvsvc.c b/source3/librpc/gen_ndr/srv_srvsvc.c
index afd458765e..75e586c716 100644
--- a/source3/librpc/gen_ndr/srv_srvsvc.c
+++ b/source3/librpc/gen_ndr/srv_srvsvc.c
@@ -2225,7 +2225,7 @@ static bool api_srvsvc_NetRemoteTOD(pipes_struct *p)
}
ZERO_STRUCT(r->out);
- r->out.info = talloc_zero(r, struct srvsvc_NetRemoteTODInfo);
+ r->out.info = talloc_zero(r, struct srvsvc_NetRemoteTODInfo *);
if (r->out.info == NULL) {
talloc_free(r);
return false;
diff --git a/source3/librpc/gen_ndr/srv_svcctl.c b/source3/librpc/gen_ndr/srv_svcctl.c
index a7163917bd..10db320452 100644
--- a/source3/librpc/gen_ndr/srv_svcctl.c
+++ b/source3/librpc/gen_ndr/srv_svcctl.c
@@ -352,6 +352,19 @@ static bool api_svcctl_QueryServiceObjectSecurity(pipes_struct *p)
NDR_PRINT_IN_DEBUG(svcctl_QueryServiceObjectSecurity, r);
}
+ ZERO_STRUCT(r->out);
+ r->out.buffer = talloc_zero_array(r, uint8_t, r->in.buffer_size);
+ if (r->out.buffer == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
+ r->out.needed = talloc_zero(r, uint32_t);
+ if (r->out.needed == NULL) {
+ talloc_free(r);
+ return false;
+ }
+
r->out.result = _svcctl_QueryServiceObjectSecurity(p, r);
if (p->rng_fault_state) {
diff --git a/source3/librpc/gen_ndr/srv_unixinfo.c b/source3/librpc/gen_ndr/srv_unixinfo.c
deleted file mode 100644
index 6142bb113f..0000000000
--- a/source3/librpc/gen_ndr/srv_unixinfo.c
+++ /dev/null
@@ -1,430 +0,0 @@
-/*
- * Unix SMB/CIFS implementation.
- * server auto-generated by pidl. DO NOT MODIFY!
- */
-
-#include "includes.h"
-#include "librpc/gen_ndr/srv_unixinfo.h"
-
-static bool api_unixinfo_SidToUid(pipes_struct *p)
-{
- const struct ndr_interface_call *call;
- struct ndr_pull *pull;
- struct ndr_push *push;
- enum ndr_err_code ndr_err;
- DATA_BLOB blob;
- struct unixinfo_SidToUid *r;
-
- call = &ndr_table_unixinfo.calls[NDR_UNIXINFO_SIDTOUID];
-
- r = talloc(talloc_tos(), struct unixinfo_SidToUid);
- if (r == NULL) {
- return false;
- }
-
- if (!prs_data_blob(&p->in_data.data, &blob, r)) {
- talloc_free(r);
- return false;
- }
-
- pull = ndr_pull_init_blob(&blob, r);
- if (pull == NULL) {
- talloc_free(r);
- return false;
- }
-
- pull->flags |= LIBNDR_FLAG_REF_ALLOC;
- ndr_err = call->ndr_pull(pull, NDR_IN, r);
- if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
- talloc_free(r);
- return false;
- }
-
- if (DEBUGLEVEL >= 10) {
- NDR_PRINT_IN_DEBUG(unixinfo_SidToUid, r);
- }
-
- ZERO_STRUCT(r->out);
- r->out.uid = talloc_zero(r, uint64_t);
- if (r->out.uid == NULL) {
- talloc_free(r);
- return false;
- }
-
- r->out.result = _unixinfo_SidToUid(p, r);
-
- if (p->rng_fault_state) {
- talloc_free(r);
- /* Return true here, srv_pipe_hnd.c will take care */
- return true;
- }
-
- if (DEBUGLEVEL >= 10) {
- NDR_PRINT_OUT_DEBUG(unixinfo_SidToUid, r);
- }
-
- push = ndr_push_init_ctx(r);
- if (push == NULL) {
- talloc_free(r);
- return false;
- }
-
- ndr_err = call->ndr_push(push, NDR_OUT, r);
- if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
- talloc_free(r);
- return false;
- }
-
- blob = ndr_push_blob(push);
- if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
- talloc_free(r);
- return false;
- }
-
- talloc_free(r);
-
- return true;
-}
-
-static bool api_unixinfo_UidToSid(pipes_struct *p)
-{
- const struct ndr_interface_call *call;
- struct ndr_pull *pull;
- struct ndr_push *push;
- enum ndr_err_code ndr_err;
- DATA_BLOB blob;
- struct unixinfo_UidToSid *r;
-
- call = &ndr_table_unixinfo.calls[NDR_UNIXINFO_UIDTOSID];
-
- r = talloc(talloc_tos(), struct unixinfo_UidToSid);
- if (r == NULL) {
- return false;
- }
-
- if (!prs_data_blob(&p->in_data.data, &blob, r)) {
- talloc_free(r);
- return false;
- }
-
- pull = ndr_pull_init_blob(&blob, r);
- if (pull == NULL) {
- talloc_free(r);
- return false;
- }
-
- pull->flags |= LIBNDR_FLAG_REF_ALLOC;
- ndr_err = call->ndr_pull(pull, NDR_IN, r);
- if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
- talloc_free(r);
- return false;
- }
-
- if (DEBUGLEVEL >= 10) {
- NDR_PRINT_IN_DEBUG(unixinfo_UidToSid, r);
- }
-
- ZERO_STRUCT(r->out);
- r->out.sid = talloc_zero(r, struct dom_sid);
- if (r->out.sid == NULL) {
- talloc_free(r);
- return false;
- }
-
- r->out.result = _unixinfo_UidToSid(p, r);
-
- if (p->rng_fault_state) {
- talloc_free(r);
- /* Return true here, srv_pipe_hnd.c will take care */
- return true;
- }
-
- if (DEBUGLEVEL >= 10) {
- NDR_PRINT_OUT_DEBUG(unixinfo_UidToSid, r);
- }
-
- push = ndr_push_init_ctx(r);
- if (push == NULL) {
- talloc_free(r);
- return false;
- }
-
- ndr_err = call->ndr_push(push, NDR_OUT, r);
- if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
- talloc_free(r);
- return false;
- }
-
- blob = ndr_push_blob(push);
- if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
- talloc_free(r);
- return false;
- }
-
- talloc_free(r);
-
- return true;
-}
-
-static bool api_unixinfo_SidToGid(pipes_struct *p)
-{
- const struct ndr_interface_call *call;
- struct ndr_pull *pull;
- struct ndr_push *push;
- enum ndr_err_code ndr_err;
- DATA_BLOB blob;
- struct unixinfo_SidToGid *r;
-
- call = &ndr_table_unixinfo.calls[NDR_UNIXINFO_SIDTOGID];
-
- r = talloc(talloc_tos(), struct unixinfo_SidToGid);
- if (r == NULL) {
- return false;
- }
-
- if (!prs_data_blob(&p->in_data.data, &blob, r)) {
- talloc_free(r);
- return false;
- }
-
- pull = ndr_pull_init_blob(&blob, r);
- if (pull == NULL) {
- talloc_free(r);
- return false;
- }
-
- pull->flags |= LIBNDR_FLAG_REF_ALLOC;
- ndr_err = call->ndr_pull(pull, NDR_IN, r);
- if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
- talloc_free(r);
- return false;
- }
-
- if (DEBUGLEVEL >= 10) {
- NDR_PRINT_IN_DEBUG(unixinfo_SidToGid, r);
- }
-
- ZERO_STRUCT(r->out);
- r->out.gid = talloc_zero(r, uint64_t);
- if (r->out.gid == NULL) {
- talloc_free(r);
- return false;
- }
-
- r->out.result = _unixinfo_SidToGid(p, r);
-
- if (p->rng_fault_state) {
- talloc_free(r);
- /* Return true here, srv_pipe_hnd.c will take care */
- return true;
- }
-
- if (DEBUGLEVEL >= 10) {
- NDR_PRINT_OUT_DEBUG(unixinfo_SidToGid, r);
- }
-
- push = ndr_push_init_ctx(r);
- if (push == NULL) {
- talloc_free(r);
- return false;
- }
-
- ndr_err = call->ndr_push(push, NDR_OUT, r);
- if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
- talloc_free(r);
- return false;
- }
-
- blob = ndr_push_blob(push);
- if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
- talloc_free(r);
- return false;
- }
-
- talloc_free(r);
-
- return true;
-}
-
-static bool api_unixinfo_GidToSid(pipes_struct *p)
-{
- const struct ndr_interface_call *call;
- struct ndr_pull *pull;
- struct ndr_push *push;
- enum ndr_err_code ndr_err;
- DATA_BLOB blob;
- struct unixinfo_GidToSid *r;
-
- call = &ndr_table_unixinfo.calls[NDR_UNIXINFO_GIDTOSID];
-
- r = talloc(talloc_tos(), struct unixinfo_GidToSid);
- if (r == NULL) {
- return false;
- }
-
- if (!prs_data_blob(&p->in_data.data, &blob, r)) {
- talloc_free(r);
- return false;
- }
-
- pull = ndr_pull_init_blob(&blob, r);
- if (pull == NULL) {
- talloc_free(r);
- return false;
- }
-
- pull->flags |= LIBNDR_FLAG_REF_ALLOC;
- ndr_err = call->ndr_pull(pull, NDR_IN, r);
- if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
- talloc_free(r);
- return false;
- }
-
- if (DEBUGLEVEL >= 10) {
- NDR_PRINT_IN_DEBUG(unixinfo_GidToSid, r);
- }
-
- ZERO_STRUCT(r->out);
- r->out.sid = talloc_zero(r, struct dom_sid);
- if (r->out.sid == NULL) {
- talloc_free(r);
- return false;
- }
-
- r->out.result = _unixinfo_GidToSid(p, r);
-
- if (p->rng_fault_state) {
- talloc_free(r);
- /* Return true here, srv_pipe_hnd.c will take care */
- return true;
- }
-
- if (DEBUGLEVEL >= 10) {
- NDR_PRINT_OUT_DEBUG(unixinfo_GidToSid, r);
- }
-
- push = ndr_push_init_ctx(r);
- if (push == NULL) {
- talloc_free(r);
- return false;
- }
-
- ndr_err = call->ndr_push(push, NDR_OUT, r);
- if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
- talloc_free(r);
- return false;
- }
-
- blob = ndr_push_blob(push);
- if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
- talloc_free(r);
- return false;
- }
-
- talloc_free(r);
-
- return true;
-}
-
-static bool api_unixinfo_GetPWUid(pipes_struct *p)
-{
- const struct ndr_interface_call *call;
- struct ndr_pull *pull;
- struct ndr_push *push;
- enum ndr_err_code ndr_err;
- DATA_BLOB blob;
- struct unixinfo_GetPWUid *r;
-
- call = &ndr_table_unixinfo.calls[NDR_UNIXINFO_GETPWUID];
-
- r = talloc(talloc_tos(), struct unixinfo_GetPWUid);
- if (r == NULL) {
- return false;
- }
-
- if (!prs_data_blob(&p->in_data.data, &blob, r)) {
- talloc_free(r);
- return false;
- }
-
- pull = ndr_pull_init_blob(&blob, r);
- if (pull == NULL) {
- talloc_free(r);
- return false;
- }
-
- pull->flags |= LIBNDR_FLAG_REF_ALLOC;
- ndr_err = call->ndr_pull(pull, NDR_IN, r);
- if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
- talloc_free(r);
- return false;
- }
-
- if (DEBUGLEVEL >= 10) {
- NDR_PRINT_IN_DEBUG(unixinfo_GetPWUid, r);
- }
-
- ZERO_STRUCT(r->out);
- r->out.count = r->in.count;
- r->out.infos = talloc_zero_array(r, struct unixinfo_GetPWUidInfo, *r->out.count);
- if (r->out.infos == NULL) {
- talloc_free(r);
- return false;
- }
-
- r->out.result = _unixinfo_GetPWUid(p, r);
-
- if (p->rng_fault_state) {
- talloc_free(r);
- /* Return true here, srv_pipe_hnd.c will take care */
- return true;
- }
-
- if (DEBUGLEVEL >= 10) {
- NDR_PRINT_OUT_DEBUG(unixinfo_GetPWUid, r);
- }
-
- push = ndr_push_init_ctx(r);
- if (push == NULL) {
- talloc_free(r);
- return false;
- }
-
- ndr_err = call->ndr_push(push, NDR_OUT, r);
- if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
- talloc_free(r);
- return false;
- }
-
- blob = ndr_push_blob(push);
- if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
- talloc_free(r);
- return false;
- }
-
- talloc_free(r);
-
- return true;
-}
-
-
-/* Tables */
-static struct api_struct api_unixinfo_cmds[] =
-{
- {"UNIXINFO_SIDTOUID", NDR_UNIXINFO_SIDTOUID, api_unixinfo_SidToUid},
- {"UNIXINFO_UIDTOSID", NDR_UNIXINFO_UIDTOSID, api_unixinfo_UidToSid},
- {"UNIXINFO_SIDTOGID", NDR_UNIXINFO_SIDTOGID, api_unixinfo_SidToGid},
- {"UNIXINFO_GIDTOSID", NDR_UNIXINFO_GIDTOSID, api_unixinfo_GidToSid},
- {"UNIXINFO_GETPWUID", NDR_UNIXINFO_GETPWUID, api_unixinfo_GetPWUid},
-};
-
-void unixinfo_get_pipe_fns(struct api_struct **fns, int *n_fns)
-{
- *fns = api_unixinfo_cmds;
- *n_fns = sizeof(api_unixinfo_cmds) / sizeof(struct api_struct);
-}
-
-NTSTATUS rpc_unixinfo_init(void)
-{
- return rpc_pipe_register_commands(SMB_RPC_INTERFACE_VERSION, "unixinfo", "unixinfo", api_unixinfo_cmds, sizeof(api_unixinfo_cmds) / sizeof(struct api_struct));
-}
diff --git a/source3/librpc/gen_ndr/srv_unixinfo.h b/source3/librpc/gen_ndr/srv_unixinfo.h
deleted file mode 100644
index 6e5c033b61..0000000000
--- a/source3/librpc/gen_ndr/srv_unixinfo.h
+++ /dev/null
@@ -1,11 +0,0 @@
-#include "librpc/gen_ndr/ndr_unixinfo.h"
-#ifndef __SRV_UNIXINFO__
-#define __SRV_UNIXINFO__
-NTSTATUS _unixinfo_SidToUid(pipes_struct *p, struct unixinfo_SidToUid *r);
-NTSTATUS _unixinfo_UidToSid(pipes_struct *p, struct unixinfo_UidToSid *r);
-NTSTATUS _unixinfo_SidToGid(pipes_struct *p, struct unixinfo_SidToGid *r);
-NTSTATUS _unixinfo_GidToSid(pipes_struct *p, struct unixinfo_GidToSid *r);
-NTSTATUS _unixinfo_GetPWUid(pipes_struct *p, struct unixinfo_GetPWUid *r);
-void unixinfo_get_pipe_fns(struct api_struct **fns, int *n_fns);
-NTSTATUS rpc_unixinfo_init(void);
-#endif /* __SRV_UNIXINFO__ */
diff --git a/source3/librpc/gen_ndr/srvsvc.h b/source3/librpc/gen_ndr/srvsvc.h
index 6e6c7829a0..cede81e837 100644
--- a/source3/librpc/gen_ndr/srvsvc.h
+++ b/source3/librpc/gen_ndr/srvsvc.h
@@ -1299,7 +1299,7 @@ struct srvsvc_NetShareSetInfo {
const char *server_unc;/* [unique,charset(UTF16)] */
const char *share_name;/* [charset(UTF16)] */
uint32_t level;
- union srvsvc_NetShareInfo info;/* [switch_is(level)] */
+ union srvsvc_NetShareInfo *info;/* [ref,switch_is(level)] */
uint32_t *parm_error;/* [unique] */
} in;
@@ -1371,7 +1371,7 @@ struct srvsvc_NetSrvSetInfo {
struct {
const char *server_unc;/* [unique,charset(UTF16)] */
uint32_t level;
- union srvsvc_NetSrvInfo info;/* [switch_is(level)] */
+ union srvsvc_NetSrvInfo *info;/* [ref,switch_is(level)] */
uint32_t *parm_error;/* [unique] */
} in;
@@ -1472,7 +1472,7 @@ struct srvsvc_NetRemoteTOD {
} in;
struct {
- struct srvsvc_NetRemoteTODInfo *info;/* [unique] */
+ struct srvsvc_NetRemoteTODInfo **info;/* [ref] */
WERROR result;
} out;
diff --git a/source3/librpc/gen_ndr/svcctl.h b/source3/librpc/gen_ndr/svcctl.h
index 7314be0a33..c13e96b2a0 100644
--- a/source3/librpc/gen_ndr/svcctl.h
+++ b/source3/librpc/gen_ndr/svcctl.h
@@ -134,6 +134,14 @@ struct svcctl_LockServiceDatabase {
struct svcctl_QueryServiceObjectSecurity {
struct {
+ struct policy_handle *handle;/* [ref] */
+ uint32_t security_flags;
+ uint32_t buffer_size;/* [range(0,0x40000)] */
+ } in;
+
+ struct {
+ uint8_t *buffer;/* [ref,size_is(buffer_size)] */
+ uint32_t *needed;/* [ref,range(0,0x40000)] */
WERROR result;
} out;
@@ -142,6 +150,13 @@ struct svcctl_QueryServiceObjectSecurity {
struct svcctl_SetServiceObjectSecurity {
struct {
+ struct policy_handle *handle;/* [ref] */
+ uint32_t security_flags;
+ uint8_t *buffer;/* [ref,size_is(buffer_size)] */
+ uint32_t buffer_size;
+ } in;
+
+ struct {
WERROR result;
} out;
diff --git a/source3/librpc/gen_ndr/unixinfo.h b/source3/librpc/gen_ndr/unixinfo.h
deleted file mode 100644
index bfe0934ccd..0000000000
--- a/source3/librpc/gen_ndr/unixinfo.h
+++ /dev/null
@@ -1,82 +0,0 @@
-/* header auto-generated by pidl */
-
-#include <stdint.h>
-
-#include "librpc/gen_ndr/security.h"
-#ifndef _HEADER_unixinfo
-#define _HEADER_unixinfo
-
-struct unixinfo_GetPWUidInfo {
- NTSTATUS status;
- const char * homedir;/* [flag(LIBNDR_FLAG_STR_UTF8|LIBNDR_FLAG_STR_NULLTERM)] */
- const char * shell;/* [flag(LIBNDR_FLAG_STR_UTF8|LIBNDR_FLAG_STR_NULLTERM)] */
-};
-
-
-struct unixinfo_SidToUid {
- struct {
- struct dom_sid sid;
- } in;
-
- struct {
- uint64_t *uid;/* [ref] */
- NTSTATUS result;
- } out;
-
-};
-
-
-struct unixinfo_UidToSid {
- struct {
- uint64_t uid;
- } in;
-
- struct {
- struct dom_sid *sid;/* [ref] */
- NTSTATUS result;
- } out;
-
-};
-
-
-struct unixinfo_SidToGid {
- struct {
- struct dom_sid sid;
- } in;
-
- struct {
- uint64_t *gid;/* [ref] */
- NTSTATUS result;
- } out;
-
-};
-
-
-struct unixinfo_GidToSid {
- struct {
- uint64_t gid;
- } in;
-
- struct {
- struct dom_sid *sid;/* [ref] */
- NTSTATUS result;
- } out;
-
-};
-
-
-struct unixinfo_GetPWUid {
- struct {
- uint64_t *uids;/* [size_is(*count)] */
- uint32_t *count;/* [ref,range(0,1023)] */
- } in;
-
- struct {
- struct unixinfo_GetPWUidInfo *infos;/* [size_is(*count)] */
- uint32_t *count;/* [ref,range(0,1023)] */
- NTSTATUS result;
- } out;
-
-};
-
-#endif /* _HEADER_unixinfo */