route.c (dfc47ef8639facd77210e74be831943c2fdd9c74) route.c (af31f412c7c7a3c0fda4bf4beaf0c85af1f263c8)
1/*
2 * Linux INET6 implementation
3 * FIB front-end.
4 *
5 * Authors:
6 * Pedro Roque <roque@di.fc.ul.pt>
7 *
8 * This program is free software; you can redistribute it and/or

--- 2022 unchanged lines hidden (view full) ---

2031{
2032 struct fib6_config cfg;
2033 struct in6_rtmsg rtmsg;
2034 int err;
2035
2036 switch(cmd) {
2037 case SIOCADDRT: /* Add a route */
2038 case SIOCDELRT: /* Delete a route */
1/*
2 * Linux INET6 implementation
3 * FIB front-end.
4 *
5 * Authors:
6 * Pedro Roque <roque@di.fc.ul.pt>
7 *
8 * This program is free software; you can redistribute it and/or

--- 2022 unchanged lines hidden (view full) ---

2031{
2032 struct fib6_config cfg;
2033 struct in6_rtmsg rtmsg;
2034 int err;
2035
2036 switch(cmd) {
2037 case SIOCADDRT: /* Add a route */
2038 case SIOCDELRT: /* Delete a route */
2039 if (!capable(CAP_NET_ADMIN))
2039 if (!ns_capable(net->user_ns, CAP_NET_ADMIN))
2040 return -EPERM;
2041 err = copy_from_user(&rtmsg, arg,
2042 sizeof(struct in6_rtmsg));
2043 if (err)
2044 return -EFAULT;
2045
2046 rtmsg_to_fib6_config(net, &rtmsg, &cfg);
2047

--- 1195 unchanged lines hidden ---
2040 return -EPERM;
2041 err = copy_from_user(&rtmsg, arg,
2042 sizeof(struct in6_rtmsg));
2043 if (err)
2044 return -EFAULT;
2045
2046 rtmsg_to_fib6_config(net, &rtmsg, &cfg);
2047

--- 1195 unchanged lines hidden ---