diff options
author | Matthias Dieter Wallnöfer <mdw@samba.org> | 2010-06-27 23:13:14 +0200 |
---|---|---|
committer | Matthias Dieter Wallnöfer <mdw@samba.org> | 2010-06-28 14:51:05 +0200 |
commit | 3c1a9fb87fe165485abaa694e9d9616e46c8cf6e (patch) | |
tree | cca8f846166ccd4b28108d0207a7cc995b33028a /source4/rpc_server/samr | |
parent | ea83d21341306dfab1f14c9491856a9414a29669 (diff) | |
download | samba-3c1a9fb87fe165485abaa694e9d9616e46c8cf6e.tar.gz samba-3c1a9fb87fe165485abaa694e9d9616e46c8cf6e.tar.bz2 samba-3c1a9fb87fe165485abaa694e9d9616e46c8cf6e.zip |
s4:dcesrv_samr_SetUserInfo - deny operations when "fields_present" is 0
Taken from s3
Diffstat (limited to 'source4/rpc_server/samr')
-rw-r--r-- | source4/rpc_server/samr/dcesrv_samr.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/source4/rpc_server/samr/dcesrv_samr.c b/source4/rpc_server/samr/dcesrv_samr.c index 0b4e8e25ec..9556c86783 100644 --- a/source4/rpc_server/samr/dcesrv_samr.c +++ b/source4/rpc_server/samr/dcesrv_samr.c @@ -3183,6 +3183,9 @@ static NTSTATUS dcesrv_samr_SetUserInfo(struct dcesrv_call_state *dce_call, TALL break; case 21: + if (r->in.info->info21.fields_present == 0) + return NT_STATUS_INVALID_PARAMETER; + #define IFSET(bit) if (bit & r->in.info->info21.fields_present) IFSET(SAMR_FIELD_ACCT_EXPIRY) SET_UINT64(msg, info21.acct_expiry, "accountExpires"); @@ -3253,6 +3256,9 @@ static NTSTATUS dcesrv_samr_SetUserInfo(struct dcesrv_call_state *dce_call, TALL break; case 23: + if (r->in.info->info23.info.fields_present == 0) + return NT_STATUS_INVALID_PARAMETER; + #define IFSET(bit) if (bit & r->in.info->info23.info.fields_present) IFSET(SAMR_FIELD_ACCT_EXPIRY) SET_UINT64(msg, info23.info.acct_expiry, "accountExpires"); @@ -3320,6 +3326,9 @@ static NTSTATUS dcesrv_samr_SetUserInfo(struct dcesrv_call_state *dce_call, TALL break; case 25: + if (r->in.info->info25.info.fields_present == 0) + return NT_STATUS_INVALID_PARAMETER; + #define IFSET(bit) if (bit & r->in.info->info25.info.fields_present) IFSET(SAMR_FIELD_ACCT_EXPIRY) SET_UINT64(msg, info25.info.acct_expiry, "accountExpires"); |