Merge branch 'audit.b3' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/audit...
[linux-2.6.git] / security / dummy.c
index 0a553d3..fd99429 100644 (file)
@@ -773,8 +773,14 @@ static int dummy_socket_sock_rcv_skb (struct sock *sk, struct sk_buff *skb)
        return 0;
 }
 
-static int dummy_socket_getpeersec(struct socket *sock, char __user *optval,
-                                  int __user *optlen, unsigned len)
+static int dummy_socket_getpeersec_stream(struct socket *sock, char __user *optval,
+                                         int __user *optlen, unsigned len)
+{
+       return -ENOPROTOOPT;
+}
+
+static int dummy_socket_getpeersec_dgram(struct sk_buff *skb, char **secdata,
+                                        u32 *seclen)
 {
        return -ENOPROTOOPT;
 }
@@ -1014,7 +1020,8 @@ void security_fixup_ops (struct security_operations *ops)
        set_to_dummy_if_null(ops, socket_getsockopt);
        set_to_dummy_if_null(ops, socket_shutdown);
        set_to_dummy_if_null(ops, socket_sock_rcv_skb);
-       set_to_dummy_if_null(ops, socket_getpeersec);
+       set_to_dummy_if_null(ops, socket_getpeersec_stream);
+       set_to_dummy_if_null(ops, socket_getpeersec_dgram);
        set_to_dummy_if_null(ops, sk_alloc_security);
        set_to_dummy_if_null(ops, sk_free_security);
        set_to_dummy_if_null(ops, sk_getsid);