mirror of
git://git.code.sf.net/p/xtables-addons/xtables-addons
synced 2025-09-21 12:04:56 +02:00
Compare commits
6 Commits
Author | SHA1 | Date | |
---|---|---|---|
![]() |
20e1b669fc | ||
![]() |
e4784832ed | ||
![]() |
48e30a0990 | ||
![]() |
ea588d0b9c | ||
![]() |
96460646e9 | ||
![]() |
2cb4b2bec6 |
@@ -1,7 +1,7 @@
|
|||||||
# -*- Makefile -*-
|
# -*- Makefile -*-
|
||||||
|
|
||||||
ACLOCAL_AMFLAGS = -I m4
|
ACLOCAL_AMFLAGS = -I m4
|
||||||
SUBDIRS = extensions geoip
|
SUBDIRS = extensions extensions/ACCOUNT extensions/pknock geoip
|
||||||
|
|
||||||
man_MANS := xtables-addons.8
|
man_MANS := xtables-addons.8
|
||||||
|
|
||||||
|
@@ -40,4 +40,4 @@ targets.man: .manpages.lst ${wcman_targets}
|
|||||||
$(call man_run,${wlist_targets})
|
$(call man_run,${wlist_targets})
|
||||||
|
|
||||||
clean:
|
clean:
|
||||||
rm -f xtables-addons.8 matches.man targets.man
|
rm -f xtables-addons.8 matches.man targets.man .manpages.lst
|
||||||
|
@@ -1,4 +1,4 @@
|
|||||||
AC_INIT([xtables-addons], [3.10])
|
AC_INIT([xtables-addons], [3.11])
|
||||||
AC_CONFIG_AUX_DIR([build-aux])
|
AC_CONFIG_AUX_DIR([build-aux])
|
||||||
AC_CONFIG_HEADERS([config.h])
|
AC_CONFIG_HEADERS([config.h])
|
||||||
AC_CONFIG_MACRO_DIR([m4])
|
AC_CONFIG_MACRO_DIR([m4])
|
||||||
@@ -27,7 +27,7 @@ fi
|
|||||||
AC_CHECK_HEADERS([linux/netfilter/x_tables.h], [],
|
AC_CHECK_HEADERS([linux/netfilter/x_tables.h], [],
|
||||||
[AC_MSG_ERROR([You need to have linux/netfilter/x_tables.h, see INSTALL file for details])])
|
[AC_MSG_ERROR([You need to have linux/netfilter/x_tables.h, see INSTALL file for details])])
|
||||||
PKG_CHECK_MODULES([libxtables], [xtables >= 1.6.0])
|
PKG_CHECK_MODULES([libxtables], [xtables >= 1.6.0])
|
||||||
xtlibdir="$(pkg-config --variable=xtlibdir xtables)"
|
xtlibdir="$($PKG_CONFIG --variable=xtlibdir xtables)"
|
||||||
|
|
||||||
AC_ARG_WITH([xtlibdir],
|
AC_ARG_WITH([xtlibdir],
|
||||||
AS_HELP_STRING([--with-xtlibdir=PATH],
|
AS_HELP_STRING([--with-xtlibdir=PATH],
|
||||||
@@ -57,7 +57,7 @@ if test -n "$kbuilddir"; then
|
|||||||
echo "WARNING: Version detection did not succeed. Continue at own luck.";
|
echo "WARNING: Version detection did not succeed. Continue at own luck.";
|
||||||
else
|
else
|
||||||
echo "$kmajor.$kminor.$kmicro.$kstable in $kbuilddir";
|
echo "$kmajor.$kminor.$kmicro.$kstable in $kbuilddir";
|
||||||
if test "$kmajor" -gt 5 -o "$kmajor" -eq 5 -a "$kminor" -gt 8; then
|
if test "$kmajor" -gt 5 -o "$kmajor" -eq 5 -a "$kminor" -gt 9; then
|
||||||
echo "WARNING: That kernel version is not officially supported yet. Continue at own luck.";
|
echo "WARNING: That kernel version is not officially supported yet. Continue at own luck.";
|
||||||
elif test "$kmajor" -eq 5 -a "$kminor" -ge 0; then
|
elif test "$kmajor" -eq 5 -a "$kminor" -ge 0; then
|
||||||
:
|
:
|
||||||
|
@@ -1,3 +1,8 @@
|
|||||||
|
v3.11 (2020-09-06)
|
||||||
|
==================
|
||||||
|
- Support for up to Linux 5.9
|
||||||
|
|
||||||
|
|
||||||
v3.10 (2020-07-28)
|
v3.10 (2020-07-28)
|
||||||
==================
|
==================
|
||||||
- Support for up to Linux 5.8
|
- Support for up to Linux 5.8
|
||||||
|
@@ -28,6 +28,9 @@
|
|||||||
#include <linux/kernel.h>
|
#include <linux/kernel.h>
|
||||||
#include <linux/mm.h>
|
#include <linux/mm.h>
|
||||||
#include <linux/string.h>
|
#include <linux/string.h>
|
||||||
|
#if LINUX_VERSION_CODE >= KERNEL_VERSION(5, 9, 0)
|
||||||
|
#include <linux/sockptr.h>
|
||||||
|
#endif
|
||||||
#include <linux/spinlock.h>
|
#include <linux/spinlock.h>
|
||||||
#include <asm/uaccess.h>
|
#include <asm/uaccess.h>
|
||||||
#include <net/netns/generic.h>
|
#include <net/netns/generic.h>
|
||||||
@@ -879,7 +882,12 @@ static int ipt_acc_handle_get_data(struct ipt_acc_net *ian,
|
|||||||
}
|
}
|
||||||
|
|
||||||
static int ipt_acc_set_ctl(struct sock *sk, int cmd,
|
static int ipt_acc_set_ctl(struct sock *sk, int cmd,
|
||||||
void *user, unsigned int len)
|
#if LINUX_VERSION_CODE < KERNEL_VERSION(5, 9, 0)
|
||||||
|
void *user,
|
||||||
|
#else
|
||||||
|
sockptr_t arg,
|
||||||
|
#endif
|
||||||
|
unsigned int len)
|
||||||
{
|
{
|
||||||
struct net *net = sock_net(sk);
|
struct net *net = sock_net(sk);
|
||||||
struct ipt_acc_net *ian = net_generic(net, ipt_acc_net_id);
|
struct ipt_acc_net *ian = net_generic(net, ipt_acc_net_id);
|
||||||
@@ -898,7 +906,12 @@ static int ipt_acc_set_ctl(struct sock *sk, int cmd,
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (copy_from_user(&handle, user, len)) {
|
#if LINUX_VERSION_CODE < KERNEL_VERSION(5, 9, 0)
|
||||||
|
if (copy_from_user(&handle, user, len))
|
||||||
|
#else
|
||||||
|
if (copy_from_sockptr(&handle, arg, len))
|
||||||
|
#endif
|
||||||
|
{
|
||||||
printk("ACCOUNT: ipt_acc_set_ctl: copy_from_user failed for "
|
printk("ACCOUNT: ipt_acc_set_ctl: copy_from_user failed for "
|
||||||
"IPT_SO_SET_HANDLE_FREE\n");
|
"IPT_SO_SET_HANDLE_FREE\n");
|
||||||
break;
|
break;
|
||||||
|
@@ -5,4 +5,4 @@ AM_CFLAGS = ${regular_CFLAGS} ${libxtables_CFLAGS}
|
|||||||
|
|
||||||
include ../../Makefile.extra
|
include ../../Makefile.extra
|
||||||
|
|
||||||
noinst_PROGRAMS = pknlusr
|
sbin_PROGRAMS = pknlusr
|
||||||
|
@@ -1,4 +1,4 @@
|
|||||||
.TH xtables-addons 8 "" "" "v3.9 (2020-02-25)"
|
.TH xtables-addons 8 "" "" "v3.11 (2020-09-06)"
|
||||||
.SH Name
|
.SH Name
|
||||||
Xtables-addons \(em additional extensions for iptables, ip6tables, etc.
|
Xtables-addons \(em additional extensions for iptables, ip6tables, etc.
|
||||||
.SH Targets
|
.SH Targets
|
||||||
|
Reference in New Issue
Block a user