]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
AUDIT: Fix user pointer deref thinko in sys_socketcall().
authorDavid Woodhouse <dwmw2@shinybook.infradead.org>
Thu, 2 Jun 2005 11:13:21 +0000 (12:13 +0100)
committerDavid Woodhouse <dwmw2@shinybook.infradead.org>
Thu, 2 Jun 2005 11:13:21 +0000 (12:13 +0100)
I cunningly put the audit call immediately after the
copy_from_user().... but used the _userspace_ copy of the args still.
Let's not do that.

Signed-off-by: David Woodhouse <dwmw2@infradead.org>
net/socket.c

index 6b7c3b51a7c12ab6ecc160cc08cda83dbb2a9a9c..38729af09461f0be4db5aa89e88d53dab314d9ad 100644 (file)
@@ -1908,7 +1908,7 @@ asmlinkage long sys_socketcall(int call, unsigned long __user *args)
        if (copy_from_user(a, args, nargs[call]))
                return -EFAULT;
 
-       err = audit_socketcall(nargs[call]/sizeof(unsigned long), args);
+       err = audit_socketcall(nargs[call]/sizeof(unsigned long), a);
        if (err)
                return err;