summaryrefslogtreecommitdiff
path: root/source4/librpc/ndr
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2003-11-20 10:29:54 +0000
committerAndrew Tridgell <tridge@samba.org>2003-11-20 10:29:54 +0000
commitd4dfcda78eeca4206965667a45f4f00f4e10457a (patch)
tree952f96c7eef52ad28609d65eef4cb37b1002e191 /source4/librpc/ndr
parent5d77cda1dccf79356aa8ab3ef3516aa69325e2be (diff)
downloadsamba-d4dfcda78eeca4206965667a45f4f00f4e10457a.tar.gz
samba-d4dfcda78eeca4206965667a45f4f00f4e10457a.tar.bz2
samba-d4dfcda78eeca4206965667a45f4f00f4e10457a.zip
* fixed level2 of QueryUserInfo
* added per-field testing of SetUserInfo * fixed strlen_m() (This used to be commit 26238b0f8a5752bb0f611c4aa492b964e419209a)
Diffstat (limited to 'source4/librpc/ndr')
-rw-r--r--source4/librpc/ndr/ndr_atsvc.c2
-rw-r--r--source4/librpc/ndr/ndr_dfs.c16
-rw-r--r--source4/librpc/ndr/ndr_echo.c4
-rw-r--r--source4/librpc/ndr/ndr_lsa.c18
-rw-r--r--source4/librpc/ndr/ndr_misc.c12
-rw-r--r--source4/librpc/ndr/ndr_samr.c31
-rw-r--r--source4/librpc/ndr/ndr_samr.h3
-rw-r--r--source4/librpc/ndr/ndr_spoolss.c4
-rw-r--r--source4/librpc/ndr/ndr_srvsvc.c40
-rw-r--r--source4/librpc/ndr/ndr_wkssvc.c2
10 files changed, 124 insertions, 8 deletions
diff --git a/source4/librpc/ndr/ndr_atsvc.c b/source4/librpc/ndr/ndr_atsvc.c
index 76255b44d7..d502add2b0 100644
--- a/source4/librpc/ndr/ndr_atsvc.c
+++ b/source4/librpc/ndr/ndr_atsvc.c
@@ -204,8 +204,10 @@ buffers:
}
}
NDR_ALLOC_N_SIZE(ndr, r->first_entry, r->entries_read, sizeof(r->first_entry[0]));
+ {
NDR_CHECK(ndr_pull_array(ndr, NDR_SCALARS|NDR_BUFFERS, (void **)r->first_entry, sizeof(r->first_entry[0]), r->entries_read, (ndr_pull_flags_fn_t)ndr_pull_atsvc_JobEnumInfo));
}
+ }
done:
return NT_STATUS_OK;
}
diff --git a/source4/librpc/ndr/ndr_dfs.c b/source4/librpc/ndr/ndr_dfs.c
index 626cfc5789..d6a6679700 100644
--- a/source4/librpc/ndr/ndr_dfs.c
+++ b/source4/librpc/ndr/ndr_dfs.c
@@ -598,8 +598,10 @@ buffers:
}
}
NDR_ALLOC_N_SIZE(ndr, r->stores, r->num_stores, sizeof(r->stores[0]));
+ {
NDR_CHECK(ndr_pull_array(ndr, NDR_SCALARS|NDR_BUFFERS, (void **)r->stores, sizeof(r->stores[0]), r->num_stores, (ndr_pull_flags_fn_t)ndr_pull_dfs_StorageInfo));
}
+ }
done:
return NT_STATUS_OK;
}
@@ -653,8 +655,10 @@ buffers:
}
}
NDR_ALLOC_N_SIZE(ndr, r->stores, r->num_stores, sizeof(r->stores[0]));
+ {
NDR_CHECK(ndr_pull_array(ndr, NDR_SCALARS|NDR_BUFFERS, (void **)r->stores, sizeof(r->stores[0]), r->num_stores, (ndr_pull_flags_fn_t)ndr_pull_dfs_StorageInfo));
}
+ }
done:
return NT_STATUS_OK;
}
@@ -953,8 +957,10 @@ buffers:
}
}
NDR_ALLOC_N_SIZE(ndr, r->s, r->count, sizeof(r->s[0]));
+ {
NDR_CHECK(ndr_pull_array(ndr, NDR_SCALARS|NDR_BUFFERS, (void **)r->s, sizeof(r->s[0]), r->count, (ndr_pull_flags_fn_t)ndr_pull_dfs_Info1));
}
+ }
done:
return NT_STATUS_OK;
}
@@ -984,8 +990,10 @@ buffers:
}
}
NDR_ALLOC_N_SIZE(ndr, r->s, r->count, sizeof(r->s[0]));
+ {
NDR_CHECK(ndr_pull_array(ndr, NDR_SCALARS|NDR_BUFFERS, (void **)r->s, sizeof(r->s[0]), r->count, (ndr_pull_flags_fn_t)ndr_pull_dfs_Info2));
}
+ }
done:
return NT_STATUS_OK;
}
@@ -1015,8 +1023,10 @@ buffers:
}
}
NDR_ALLOC_N_SIZE(ndr, r->s, r->count, sizeof(r->s[0]));
+ {
NDR_CHECK(ndr_pull_array(ndr, NDR_SCALARS|NDR_BUFFERS, (void **)r->s, sizeof(r->s[0]), r->count, (ndr_pull_flags_fn_t)ndr_pull_dfs_Info3));
}
+ }
done:
return NT_STATUS_OK;
}
@@ -1046,8 +1056,10 @@ buffers:
}
}
NDR_ALLOC_N_SIZE(ndr, r->s, r->count, sizeof(r->s[0]));
+ {
NDR_CHECK(ndr_pull_array(ndr, NDR_SCALARS|NDR_BUFFERS, (void **)r->s, sizeof(r->s[0]), r->count, (ndr_pull_flags_fn_t)ndr_pull_dfs_Info4));
}
+ }
done:
return NT_STATUS_OK;
}
@@ -1077,8 +1089,10 @@ buffers:
}
}
NDR_ALLOC_N_SIZE(ndr, r->s, r->count, sizeof(r->s[0]));
+ {
NDR_CHECK(ndr_pull_array(ndr, NDR_SCALARS|NDR_BUFFERS, (void **)r->s, sizeof(r->s[0]), r->count, (ndr_pull_flags_fn_t)ndr_pull_dfs_Info200));
}
+ }
done:
return NT_STATUS_OK;
}
@@ -1108,8 +1122,10 @@ buffers:
}
}
NDR_ALLOC_N_SIZE(ndr, r->s, r->count, sizeof(r->s[0]));
+ {
NDR_CHECK(ndr_pull_array(ndr, NDR_SCALARS|NDR_BUFFERS, (void **)r->s, sizeof(r->s[0]), r->count, (ndr_pull_flags_fn_t)ndr_pull_dfs_Info300));
}
+ }
done:
return NT_STATUS_OK;
}
diff --git a/source4/librpc/ndr/ndr_echo.c b/source4/librpc/ndr/ndr_echo.c
index b3ec408b2d..9ddc64354a 100644
--- a/source4/librpc/ndr/ndr_echo.c
+++ b/source4/librpc/ndr/ndr_echo.c
@@ -73,8 +73,10 @@ NTSTATUS ndr_pull_echo_EchoData(struct ndr_pull *ndr, struct echo_EchoData *r)
}
}
NDR_ALLOC_N_SIZE(ndr, r->out.out_data, r->in.len, sizeof(r->out.out_data[0]));
+ {
NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.out_data, r->in.len));
}
+ }
return NT_STATUS_OK;
}
@@ -95,8 +97,10 @@ NTSTATUS ndr_pull_echo_SourceData(struct ndr_pull *ndr, struct echo_SourceData *
return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should be %u", _array_size, r->in.len);
}
}
+ {
NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.data, r->in.len));
}
+ }
return NT_STATUS_OK;
}
diff --git a/source4/librpc/ndr/ndr_lsa.c b/source4/librpc/ndr/ndr_lsa.c
index 2ed6b89e7b..b246fbc170 100644
--- a/source4/librpc/ndr/ndr_lsa.c
+++ b/source4/librpc/ndr/ndr_lsa.c
@@ -592,8 +592,10 @@ buffers:
}
}
NDR_ALLOC_N_SIZE(ndr, r->privs, r->count, sizeof(r->privs[0]));
+ {
NDR_CHECK(ndr_pull_array(ndr, NDR_SCALARS|NDR_BUFFERS, (void **)r->privs, sizeof(r->privs[0]), r->count, (ndr_pull_flags_fn_t)ndr_pull_lsa_PrivEntry));
}
+ }
done:
return NT_STATUS_OK;
}
@@ -714,8 +716,10 @@ buffers:
}
}
NDR_ALLOC_N_SIZE(ndr, r->settings, r->count, sizeof(r->settings[0]));
+ {
NDR_CHECK(ndr_pull_array_uint32(ndr, NDR_SCALARS|NDR_BUFFERS, r->settings, r->count));
}
+ }
done:
return NT_STATUS_OK;
}
@@ -1083,8 +1087,10 @@ buffers:
}
}
NDR_ALLOC_N_SIZE(ndr, r->sids, r->num_sids, sizeof(r->sids[0]));
+ {
NDR_CHECK(ndr_pull_array(ndr, NDR_SCALARS|NDR_BUFFERS, (void **)r->sids, sizeof(r->sids[0]), r->num_sids, (ndr_pull_flags_fn_t)ndr_pull_lsa_SidPtr));
}
+ }
done:
return NT_STATUS_OK;
}
@@ -1154,8 +1160,10 @@ buffers:
}
}
NDR_ALLOC_N_SIZE(ndr, r->domains, r->count, sizeof(r->domains[0]));
+ {
NDR_CHECK(ndr_pull_array(ndr, NDR_SCALARS|NDR_BUFFERS, (void **)r->domains, sizeof(r->domains[0]), r->count, (ndr_pull_flags_fn_t)ndr_pull_lsa_DomainInformation));
}
+ }
done:
return NT_STATUS_OK;
}
@@ -1209,8 +1217,10 @@ buffers:
}
}
NDR_ALLOC_N_SIZE(ndr, r->sids, r->count, sizeof(r->sids[0]));
+ {
NDR_CHECK(ndr_pull_array(ndr, NDR_SCALARS|NDR_BUFFERS, (void **)r->sids, sizeof(r->sids[0]), r->count, (ndr_pull_flags_fn_t)ndr_pull_lsa_TranslatedSid));
}
+ }
done:
return NT_STATUS_OK;
}
@@ -1265,8 +1275,10 @@ buffers:
}
}
NDR_ALLOC_N_SIZE(ndr, r->domains, r->count, sizeof(r->domains[0]));
+ {
NDR_CHECK(ndr_pull_array(ndr, NDR_SCALARS|NDR_BUFFERS, (void **)r->domains, sizeof(r->domains[0]), r->count, (ndr_pull_flags_fn_t)ndr_pull_lsa_TrustInformation));
}
+ }
done:
return NT_STATUS_OK;
}
@@ -1331,8 +1343,10 @@ buffers:
}
}
NDR_ALLOC_N_SIZE(ndr, r->names, r->count, sizeof(r->names[0]));
+ {
NDR_CHECK(ndr_pull_array(ndr, NDR_SCALARS|NDR_BUFFERS, (void **)r->names, sizeof(r->names[0]), r->count, (ndr_pull_flags_fn_t)ndr_pull_lsa_TranslatedName));
}
+ }
done:
return NT_STATUS_OK;
}
@@ -1416,7 +1430,9 @@ buffers:
return ndr_pull_error(ndr, NDR_ERR_CONFORMANT_SIZE, "Bad conformant size %u should be %u", _conformant_size, r->count);
}
NDR_ALLOC_N_SIZE(ndr, r->set, _conformant_size, sizeof(r->set[0]));
+ {
NDR_CHECK(ndr_pull_array(ndr, NDR_SCALARS|NDR_BUFFERS, (void **)r->set, sizeof(r->set[0]), r->count, (ndr_pull_flags_fn_t)ndr_pull_lsa_LUIDAttribute));
+ }
done:
return NT_STATUS_OK;
}
@@ -1592,8 +1608,10 @@ buffers:
}
}
NDR_ALLOC_N_SIZE(ndr, r->names, r->count, sizeof(r->names[0]));
+ {
NDR_CHECK(ndr_pull_array(ndr, NDR_SCALARS|NDR_BUFFERS, (void **)r->names, sizeof(r->names[0]), r->count, (ndr_pull_flags_fn_t)ndr_pull_lsa_Name));
}
+ }
done:
return NT_STATUS_OK;
}
diff --git a/source4/librpc/ndr/ndr_misc.c b/source4/librpc/ndr/ndr_misc.c
index 31f501e614..575f0d3a4d 100644
--- a/source4/librpc/ndr/ndr_misc.c
+++ b/source4/librpc/ndr/ndr_misc.c
@@ -90,14 +90,22 @@ NTSTATUS ndr_pull_dom_sid(struct ndr_pull *ndr, int ndr_flags, struct dom_sid *r
NDR_CHECK(ndr_pull_align(ndr, 4));
NDR_CHECK(ndr_pull_uint8(ndr, &r->sid_rev_num));
NDR_CHECK(ndr_pull_uint8(ndr, &r->num_auths));
+ {
NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_SCALARS, r->id_auth, 6));
+ }
NDR_ALLOC_N_SIZE(ndr, r->sub_auths, r->num_auths, sizeof(r->sub_auths[0]));
+ {
NDR_CHECK(ndr_pull_array_uint32(ndr, NDR_SCALARS, r->sub_auths, r->num_auths));
+ }
ndr_pull_struct_end(ndr);
buffers:
if (!(ndr_flags & NDR_BUFFERS)) goto done;
+ {
NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_BUFFERS, r->id_auth, 6));
+ }
+ {
NDR_CHECK(ndr_pull_array_uint32(ndr, NDR_BUFFERS, r->sub_auths, r->num_auths));
+ }
done:
return NT_STATUS_OK;
}
@@ -127,11 +135,15 @@ NTSTATUS ndr_pull_security_acl(struct ndr_pull *ndr, int ndr_flags, struct secur
NDR_CHECK(ndr_pull_uint16(ndr, &r->revision));
NDR_CHECK(ndr_pull_uint32(ndr, &r->num_aces));
NDR_ALLOC_N_SIZE(ndr, r->aces, r->num_aces, sizeof(r->aces[0]));
+ {
NDR_CHECK(ndr_pull_array(ndr, NDR_SCALARS, (void **)r->aces, sizeof(r->aces[0]), r->num_aces, (ndr_pull_flags_fn_t)ndr_pull_security_ace));
+ }
ndr_pull_struct_end(ndr);
buffers:
if (!(ndr_flags & NDR_BUFFERS)) goto done;
+ {
NDR_CHECK(ndr_pull_array(ndr, NDR_BUFFERS, (void **)r->aces, sizeof(r->aces[0]), r->num_aces, (ndr_pull_flags_fn_t)ndr_pull_security_ace));
+ }
done:
return NT_STATUS_OK;
}
diff --git a/source4/librpc/ndr/ndr_samr.c b/source4/librpc/ndr/ndr_samr.c
index 42ce47f8db..f2dcfb9124 100644
--- a/source4/librpc/ndr/ndr_samr.c
+++ b/source4/librpc/ndr/ndr_samr.c
@@ -347,14 +347,14 @@ NTSTATUS ndr_push_samr_UserInfo2(struct ndr_push *ndr, int ndr_flags, struct sam
NDR_CHECK(ndr_push_struct_start(ndr));
NDR_CHECK(ndr_push_align(ndr, 4));
NDR_CHECK(ndr_push_samr_Name(ndr, NDR_SCALARS, &r->comment));
- NDR_CHECK(ndr_push_uint32(ndr, r->unknown1));
- NDR_CHECK(ndr_push_uint32(ndr, r->unknown2));
+ NDR_CHECK(ndr_push_samr_Name(ndr, NDR_SCALARS, &r->unknown));
NDR_CHECK(ndr_push_uint16(ndr, r->country_code));
NDR_CHECK(ndr_push_uint16(ndr, r->code_page));
ndr_push_struct_end(ndr);
buffers:
if (!(ndr_flags & NDR_BUFFERS)) goto done;
NDR_CHECK(ndr_push_samr_Name(ndr, NDR_BUFFERS, &r->comment));
+ NDR_CHECK(ndr_push_samr_Name(ndr, NDR_BUFFERS, &r->unknown));
done:
return NT_STATUS_OK;
}
@@ -1225,8 +1225,10 @@ buffers:
}
}
NDR_ALLOC_N_SIZE(ndr, r->entries, r->count, sizeof(r->entries[0]));
+ {
NDR_CHECK(ndr_pull_array(ndr, NDR_SCALARS|NDR_BUFFERS, (void **)r->entries, sizeof(r->entries[0]), r->count, (ndr_pull_flags_fn_t)ndr_pull_samr_SamEntry));
}
+ }
done:
return NT_STATUS_OK;
}
@@ -1705,8 +1707,10 @@ buffers:
}
}
NDR_ALLOC_N_SIZE(ndr, r->ids, r->count, sizeof(r->ids[0]));
+ {
NDR_CHECK(ndr_pull_array_uint32(ndr, NDR_SCALARS|NDR_BUFFERS, r->ids, r->count));
}
+ }
done:
return NT_STATUS_OK;
}
@@ -1762,8 +1766,10 @@ buffers:
}
}
NDR_ALLOC_N_SIZE(ndr, r->names, r->count, sizeof(r->names[0]));
+ {
NDR_CHECK(ndr_pull_array(ndr, NDR_SCALARS|NDR_BUFFERS, (void **)r->names, sizeof(r->names[0]), r->count, (ndr_pull_flags_fn_t)ndr_pull_samr_Name));
}
+ }
done:
return NT_STATUS_OK;
}
@@ -2155,14 +2161,14 @@ NTSTATUS ndr_pull_samr_UserInfo2(struct ndr_pull *ndr, int ndr_flags, struct sam
if (!(ndr_flags & NDR_SCALARS)) goto buffers;
NDR_CHECK(ndr_pull_align(ndr, 4));
NDR_CHECK(ndr_pull_samr_Name(ndr, NDR_SCALARS, &r->comment));
- NDR_CHECK(ndr_pull_uint32(ndr, &r->unknown1));
- NDR_CHECK(ndr_pull_uint32(ndr, &r->unknown2));
+ NDR_CHECK(ndr_pull_samr_Name(ndr, NDR_SCALARS, &r->unknown));
NDR_CHECK(ndr_pull_uint16(ndr, &r->country_code));
NDR_CHECK(ndr_pull_uint16(ndr, &r->code_page));
ndr_pull_struct_end(ndr);
buffers:
if (!(ndr_flags & NDR_BUFFERS)) goto done;
NDR_CHECK(ndr_pull_samr_Name(ndr, NDR_BUFFERS, &r->comment));
+ NDR_CHECK(ndr_pull_samr_Name(ndr, NDR_BUFFERS, &r->unknown));
done:
return NT_STATUS_OK;
}
@@ -2216,13 +2222,16 @@ buffers:
}
}
NDR_ALLOC_N_SIZE(ndr, r->logon_hours, 1260, sizeof(r->logon_hours[0]));
+ {
uint32 _offset, _length;
NDR_CHECK(ndr_pull_uint32(ndr, &_offset));
NDR_CHECK(ndr_pull_uint32(ndr, &_length));
if (_offset != 0) return ndr_pull_error(ndr, NDR_ERR_OFFSET, "Bad array offset 0x%08x", _offset);
if (_length > 1260 || _length != r->units_per_week/8) return ndr_pull_error(ndr, NDR_ERR_LENGTH, "Bad array length 0x%08x > size 0x%08x", _offset, 1260);
+
NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_SCALARS|NDR_BUFFERS, r->logon_hours, _length));
}
+ }
done:
return NT_STATUS_OK;
}
@@ -2252,13 +2261,16 @@ buffers:
}
}
NDR_ALLOC_N_SIZE(ndr, r->logon_hours, 1260, sizeof(r->logon_hours[0]));
+ {
uint32 _offset, _length;
NDR_CHECK(ndr_pull_uint32(ndr, &_offset));
NDR_CHECK(ndr_pull_uint32(ndr, &_length));
if (_offset != 0) return ndr_pull_error(ndr, NDR_ERR_OFFSET, "Bad array offset 0x%08x", _offset);
if (_length > 1260 || _length != r->units_per_week/8) return ndr_pull_error(ndr, NDR_ERR_LENGTH, "Bad array length 0x%08x > size 0x%08x", _offset, 1260);
+
NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_SCALARS|NDR_BUFFERS, r->logon_hours, _length));
}
+ }
done:
return NT_STATUS_OK;
}
@@ -2313,13 +2325,16 @@ buffers:
}
}
NDR_ALLOC_N_SIZE(ndr, r->logon_hours, 1260, sizeof(r->logon_hours[0]));
+ {
uint32 _offset, _length;
NDR_CHECK(ndr_pull_uint32(ndr, &_offset));
NDR_CHECK(ndr_pull_uint32(ndr, &_length));
if (_offset != 0) return ndr_pull_error(ndr, NDR_ERR_OFFSET, "Bad array offset 0x%08x", _offset);
if (_length > 1260 || _length != r->units_per_week/8) return ndr_pull_error(ndr, NDR_ERR_LENGTH, "Bad array length 0x%08x > size 0x%08x", _offset, 1260);
+
NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_SCALARS|NDR_BUFFERS, r->logon_hours, _length));
}
+ }
done:
return NT_STATUS_OK;
}
@@ -2570,8 +2585,10 @@ buffers:
}
}
NDR_ALLOC_N_SIZE(ndr, r->buffer, r->buf_count, sizeof(r->buffer[0]));
+ {
NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_SCALARS|NDR_BUFFERS, r->buffer, r->buf_count));
}
+ }
if (r->logon_hours) {
{
uint32 _array_size;
@@ -2581,13 +2598,16 @@ buffers:
}
}
NDR_ALLOC_N_SIZE(ndr, r->logon_hours, 1260, sizeof(r->logon_hours[0]));
+ {
uint32 _offset, _length;
NDR_CHECK(ndr_pull_uint32(ndr, &_offset));
NDR_CHECK(ndr_pull_uint32(ndr, &_length));
if (_offset != 0) return ndr_pull_error(ndr, NDR_ERR_OFFSET, "Bad array offset 0x%08x", _offset);
if (_length > 1260 || _length != r->units_per_week/8) return ndr_pull_error(ndr, NDR_ERR_LENGTH, "Bad array length 0x%08x > size 0x%08x", _offset, 1260);
+
NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_SCALARS|NDR_BUFFERS, r->logon_hours, _length));
}
+ }
done:
return NT_STATUS_OK;
}
@@ -4314,8 +4334,7 @@ void ndr_print_samr_UserInfo2(struct ndr_print *ndr, const char *name, struct sa
ndr_print_struct(ndr, name, "samr_UserInfo2");
ndr->depth++;
ndr_print_samr_Name(ndr, "comment", &r->comment);
- ndr_print_uint32(ndr, "unknown1", r->unknown1);
- ndr_print_uint32(ndr, "unknown2", r->unknown2);
+ ndr_print_samr_Name(ndr, "unknown", &r->unknown);
ndr_print_uint16(ndr, "country_code", r->country_code);
ndr_print_uint16(ndr, "code_page", r->code_page);
ndr->depth--;
diff --git a/source4/librpc/ndr/ndr_samr.h b/source4/librpc/ndr/ndr_samr.h
index 6b6f92d0d8..e148c9b90d 100644
--- a/source4/librpc/ndr/ndr_samr.h
+++ b/source4/librpc/ndr/ndr_samr.h
@@ -703,8 +703,7 @@ struct samr_UserInfo1 {
struct samr_UserInfo2 {
struct samr_Name comment;
- uint32 unknown1;
- uint32 unknown2;
+ struct samr_Name unknown;
uint16 country_code;
uint16 code_page;
};
diff --git a/source4/librpc/ndr/ndr_spoolss.c b/source4/librpc/ndr/ndr_spoolss.c
index b102a9292c..14ec78e8a1 100644
--- a/source4/librpc/ndr/ndr_spoolss.c
+++ b/source4/librpc/ndr/ndr_spoolss.c
@@ -1035,13 +1035,17 @@ NTSTATUS ndr_pull_spoolss_DeviceMode(struct ndr_pull *ndr, int ndr_flags, struct
NDR_CHECK(ndr_pull_uint32(ndr, &r->panningwidth));
NDR_CHECK(ndr_pull_uint32(ndr, &r->panningheight));
NDR_ALLOC_N_SIZE(ndr, r->private, r->driverextra, sizeof(r->private[0]));
+ {
NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_SCALARS, r->private, r->driverextra));
+ }
ndr_pull_struct_end(ndr);
buffers:
if (!(ndr_flags & NDR_BUFFERS)) goto done;
NDR_CHECK(ndr_pull_nstring(ndr, NDR_BUFFERS, &r->devicename));
NDR_CHECK(ndr_pull_nstring(ndr, NDR_BUFFERS, &r->formname));
+ {
NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_BUFFERS, r->private, r->driverextra));
+ }
done:
return NT_STATUS_OK;
}
diff --git a/source4/librpc/ndr/ndr_srvsvc.c b/source4/librpc/ndr/ndr_srvsvc.c
index 4937e7e914..877ffea51d 100644
--- a/source4/librpc/ndr/ndr_srvsvc.c
+++ b/source4/librpc/ndr/ndr_srvsvc.c
@@ -1436,8 +1436,10 @@ buffers:
}
}
NDR_ALLOC_N_SIZE(ndr, r->array, r->count, sizeof(r->array[0]));
+ {
NDR_CHECK(ndr_pull_array(ndr, NDR_SCALARS|NDR_BUFFERS, (void **)r->array, sizeof(r->array[0]), r->count, (ndr_pull_flags_fn_t)ndr_pull_srvsvc_NetConn0));
}
+ }
done:
return NT_STATUS_OK;
}
@@ -1504,8 +1506,10 @@ buffers:
}
}
NDR_ALLOC_N_SIZE(ndr, r->array, r->count, sizeof(r->array[0]));
+ {
NDR_CHECK(ndr_pull_array(ndr, NDR_SCALARS|NDR_BUFFERS, (void **)r->array, sizeof(r->array[0]), r->count, (ndr_pull_flags_fn_t)ndr_pull_srvsvc_NetConn1));
}
+ }
done:
return NT_STATUS_OK;
}
@@ -1626,8 +1630,10 @@ buffers:
}
}
NDR_ALLOC_N_SIZE(ndr, r->array, r->count, sizeof(r->array[0]));
+ {
NDR_CHECK(ndr_pull_array(ndr, NDR_SCALARS|NDR_BUFFERS, (void **)r->array, sizeof(r->array[0]), r->count, (ndr_pull_flags_fn_t)ndr_pull_srvsvc_NetFile2));
}
+ }
done:
return NT_STATUS_OK;
}
@@ -1692,8 +1698,10 @@ buffers:
}
}
NDR_ALLOC_N_SIZE(ndr, r->array, r->count, sizeof(r->array[0]));
+ {
NDR_CHECK(ndr_pull_array(ndr, NDR_SCALARS|NDR_BUFFERS, (void **)r->array, sizeof(r->array[0]), r->count, (ndr_pull_flags_fn_t)ndr_pull_srvsvc_NetFile3));
}
+ }
done:
return NT_STATUS_OK;
}
@@ -1837,8 +1845,10 @@ buffers:
}
}
NDR_ALLOC_N_SIZE(ndr, r->array, r->count, sizeof(r->array[0]));
+ {
NDR_CHECK(ndr_pull_array(ndr, NDR_SCALARS|NDR_BUFFERS, (void **)r->array, sizeof(r->array[0]), r->count, (ndr_pull_flags_fn_t)ndr_pull_srvsvc_NetSess0));
}
+ }
done:
return NT_STATUS_OK;
}
@@ -1904,8 +1914,10 @@ buffers:
}
}
NDR_ALLOC_N_SIZE(ndr, r->array, r->count, sizeof(r->array[0]));
+ {
NDR_CHECK(ndr_pull_array(ndr, NDR_SCALARS|NDR_BUFFERS, (void **)r->array, sizeof(r->array[0]), r->count, (ndr_pull_flags_fn_t)ndr_pull_srvsvc_NetSess1));
}
+ }
done:
return NT_STATUS_OK;
}
@@ -1981,8 +1993,10 @@ buffers:
}
}
NDR_ALLOC_N_SIZE(ndr, r->array, r->count, sizeof(r->array[0]));
+ {
NDR_CHECK(ndr_pull_array(ndr, NDR_SCALARS|NDR_BUFFERS, (void **)r->array, sizeof(r->array[0]), r->count, (ndr_pull_flags_fn_t)ndr_pull_srvsvc_NetSess2));
}
+ }
done:
return NT_STATUS_OK;
}
@@ -2046,8 +2060,10 @@ buffers:
}
}
NDR_ALLOC_N_SIZE(ndr, r->array, r->count, sizeof(r->array[0]));
+ {
NDR_CHECK(ndr_pull_array(ndr, NDR_SCALARS|NDR_BUFFERS, (void **)r->array, sizeof(r->array[0]), r->count, (ndr_pull_flags_fn_t)ndr_pull_srvsvc_NetSess10));
}
+ }
done:
return NT_STATUS_OK;
}
@@ -2133,8 +2149,10 @@ buffers:
}
}
NDR_ALLOC_N_SIZE(ndr, r->array, r->count, sizeof(r->array[0]));
+ {
NDR_CHECK(ndr_pull_array(ndr, NDR_SCALARS|NDR_BUFFERS, (void **)r->array, sizeof(r->array[0]), r->count, (ndr_pull_flags_fn_t)ndr_pull_srvsvc_NetSess502));
}
+ }
done:
return NT_STATUS_OK;
}
@@ -2326,8 +2344,10 @@ buffers:
}
}
NDR_ALLOC_N_SIZE(ndr, r->array, r->count, sizeof(r->array[0]));
+ {
NDR_CHECK(ndr_pull_array(ndr, NDR_SCALARS|NDR_BUFFERS, (void **)r->array, sizeof(r->array[0]), r->count, (ndr_pull_flags_fn_t)ndr_pull_srvsvc_NetShare0));
}
+ }
done:
return NT_STATUS_OK;
}
@@ -2390,8 +2410,10 @@ buffers:
}
}
NDR_ALLOC_N_SIZE(ndr, r->array, r->count, sizeof(r->array[0]));
+ {
NDR_CHECK(ndr_pull_array(ndr, NDR_SCALARS|NDR_BUFFERS, (void **)r->array, sizeof(r->array[0]), r->count, (ndr_pull_flags_fn_t)ndr_pull_srvsvc_NetShare1));
}
+ }
done:
return NT_STATUS_OK;
}
@@ -2477,8 +2499,10 @@ buffers:
}
}
NDR_ALLOC_N_SIZE(ndr, r->array, r->count, sizeof(r->array[0]));
+ {
NDR_CHECK(ndr_pull_array(ndr, NDR_SCALARS|NDR_BUFFERS, (void **)r->array, sizeof(r->array[0]), r->count, (ndr_pull_flags_fn_t)ndr_pull_srvsvc_NetShare2));
}
+ }
done:
return NT_STATUS_OK;
}
@@ -2542,8 +2566,10 @@ buffers:
}
}
NDR_ALLOC_N_SIZE(ndr, r->array, r->count, sizeof(r->array[0]));
+ {
NDR_CHECK(ndr_pull_array(ndr, NDR_SCALARS|NDR_BUFFERS, (void **)r->array, sizeof(r->array[0]), r->count, (ndr_pull_flags_fn_t)ndr_pull_srvsvc_NetShare501));
}
+ }
done:
return NT_STATUS_OK;
}
@@ -2640,8 +2666,10 @@ buffers:
}
}
NDR_ALLOC_N_SIZE(ndr, r->array, r->count, sizeof(r->array[0]));
+ {
NDR_CHECK(ndr_pull_array(ndr, NDR_SCALARS|NDR_BUFFERS, (void **)r->array, sizeof(r->array[0]), r->count, (ndr_pull_flags_fn_t)ndr_pull_srvsvc_NetShare502));
}
+ }
done:
return NT_STATUS_OK;
}
@@ -2847,8 +2875,10 @@ buffers:
}
}
NDR_ALLOC_N_SIZE(ndr, r->disk, r->size, sizeof(r->disk[0]));
+ {
NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_SCALARS|NDR_BUFFERS, r->disk, r->size));
}
+ }
done:
return NT_STATUS_OK;
}
@@ -2880,8 +2910,10 @@ buffers:
}
}
NDR_ALLOC_N_SIZE(ndr, r->array, r->count, sizeof(r->array[0]));
+ {
NDR_CHECK(ndr_pull_array(ndr, NDR_SCALARS|NDR_BUFFERS, (void **)r->array, sizeof(r->array[0]), r->count, (ndr_pull_flags_fn_t)ndr_pull_srvsvc_NetDisk0));
}
+ }
done:
return NT_STATUS_OK;
}
@@ -2967,8 +2999,10 @@ buffers:
}
}
NDR_ALLOC_N_SIZE(ndr, r->addr, r->count, sizeof(r->addr[0]));
+ {
NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_SCALARS|NDR_BUFFERS, r->addr, r->count));
}
+ }
done:
return NT_STATUS_OK;
}
@@ -3042,8 +3076,10 @@ buffers:
}
}
NDR_ALLOC_N_SIZE(ndr, r->array, r->count, sizeof(r->array[0]));
+ {
NDR_CHECK(ndr_pull_array(ndr, NDR_SCALARS|NDR_BUFFERS, (void **)r->array, sizeof(r->array[0]), r->count, (ndr_pull_flags_fn_t)ndr_pull_srvsvc_NetTransport0));
}
+ }
done:
return NT_STATUS_OK;
}
@@ -3127,8 +3163,10 @@ buffers:
}
}
NDR_ALLOC_N_SIZE(ndr, r->array, r->count, sizeof(r->array[0]));
+ {
NDR_CHECK(ndr_pull_array(ndr, NDR_SCALARS|NDR_BUFFERS, (void **)r->array, sizeof(r->array[0]), r->count, (ndr_pull_flags_fn_t)ndr_pull_srvsvc_NetTransport1));
}
+ }
done:
return NT_STATUS_OK;
}
@@ -3171,8 +3209,10 @@ buffers:
}
}
NDR_ALLOC_N_SIZE(ndr, r->array, r->count, sizeof(r->array[0]));
+ {
NDR_CHECK(ndr_pull_array(ndr, NDR_SCALARS|NDR_BUFFERS, (void **)r->array, sizeof(r->array[0]), r->count, (ndr_pull_flags_fn_t)ndr_pull_srvsvc_NetTransport2));
}
+ }
done:
return NT_STATUS_OK;
}
diff --git a/source4/librpc/ndr/ndr_wkssvc.c b/source4/librpc/ndr/ndr_wkssvc.c
index d6b1558d4c..d5f2fa4fda 100644
--- a/source4/librpc/ndr/ndr_wkssvc.c
+++ b/source4/librpc/ndr/ndr_wkssvc.c
@@ -634,8 +634,10 @@ buffers:
}
}
NDR_ALLOC_N_SIZE(ndr, r->transports, r->count, sizeof(r->transports[0]));
+ {
NDR_CHECK(ndr_pull_array(ndr, NDR_SCALARS|NDR_BUFFERS, (void **)r->transports, sizeof(r->transports[0]), r->count, (ndr_pull_flags_fn_t)ndr_pull_wkssvc_TransportInfo0));
}
+ }
done:
return NT_STATUS_OK;
}