summaryrefslogtreecommitdiff
path: root/source3/rpc_server
diff options
context:
space:
mode:
authorGünther Deschner <gd@samba.org>2009-05-29 13:15:27 +0200
committerGünther Deschner <gd@samba.org>2009-05-29 13:17:52 +0200
commit90b38906541de554e3964d96ed83a7c71b5ea05c (patch)
treed99b94aa836565a07777d94ac94000697a6a61ff /source3/rpc_server
parent65f86a644a8171a99c63b6cb32e01e22897174f6 (diff)
downloadsamba-90b38906541de554e3964d96ed83a7c71b5ea05c.tar.gz
samba-90b38906541de554e3964d96ed83a7c71b5ea05c.tar.bz2
samba-90b38906541de554e3964d96ed83a7c71b5ea05c.zip
s3-netlogon: Fix _netr_LogonSamLogon{Ex} with validation level != 3.
Guenther
Diffstat (limited to 'source3/rpc_server')
-rw-r--r--source3/rpc_server/srv_netlog_nt.c13
1 files changed, 7 insertions, 6 deletions
diff --git a/source3/rpc_server/srv_netlog_nt.c b/source3/rpc_server/srv_netlog_nt.c
index 73d1f4b1a5..7f45a4809c 100644
--- a/source3/rpc_server/srv_netlog_nt.c
+++ b/source3/rpc_server/srv_netlog_nt.c
@@ -882,6 +882,13 @@ NTSTATUS _netr_LogonSamLogon(pipes_struct *p,
return NT_STATUS_ACCESS_DENIED;
}
+ *r->out.authoritative = true; /* authoritative response */
+ if (r->in.validation_level != 2 && r->in.validation_level != 3) {
+ DEBUG(0,("%s: bad validation_level value %d.\n",
+ fn, (int)r->in.validation_level));
+ return NT_STATUS_INVALID_INFO_CLASS;
+ }
+
sam3 = TALLOC_ZERO_P(p->mem_ctx, struct netr_SamInfo3);
if (!sam3) {
return NT_STATUS_NO_MEMORY;
@@ -889,12 +896,6 @@ NTSTATUS _netr_LogonSamLogon(pipes_struct *p,
/* store the user information, if there is any. */
r->out.validation->sam3 = sam3;
- *r->out.authoritative = true; /* authoritative response */
- if (r->in.validation_level != 2 && r->in.validation_level != 3) {
- DEBUG(0,("%s: bad validation_level value %d.\n",
- fn, (int)r->in.validation_level));
- return NT_STATUS_INVALID_INFO_CLASS;
- }
if (process_creds) {