1
0
mirror of https://github.com/samba-team/samba.git synced 2025-01-12 09:18:10 +03:00

r8633: check for valid input to ejs_userAuth()

This commit is contained in:
Andrew Tridgell 2005-07-20 05:41:29 +00:00 committed by Gerald (Jerry) Carter
parent 001917cc9d
commit 8e788ae309

View File

@ -102,6 +102,11 @@ static int ejs_userAuth(MprVarHandle eid, int argc, struct MprVar **argv)
domain = mprToString(mprGetProperty(argv[0], "domain", NULL));
remote_host = mprToString(mprGetProperty(argv[0], "rhost", NULL));
if (username == NULL || password == NULL || domain == NULL) {
mpr_Return(eid, mprCreateUndefinedVar());
return 0;
}
tmp_ctx = talloc_new(mprMemCtx());
auth = mprObject("auth");