Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 553630 - net-firewall/xtables-addons-2.6 fails build against 4.1 kernel: extensions/xt_TARPIT.c:397:2: error: too few arguments to function ‘ NF_HOOK’
Summary: net-firewall/xtables-addons-2.6 fails build against 4.1 kernel: extensions/xt...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Unspecified (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Anthony Basile
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-06-30 10:47 UTC by Ettore Di Giacinto (RETIRED)
Modified: 2015-10-22 08:25 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
xtables-addons emerge build fail log (xtables-addons.log,22.60 KB, text/x-log)
2015-06-30 10:47 UTC, Ettore Di Giacinto (RETIRED)
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Ettore Di Giacinto (RETIRED) gentoo-dev 2015-06-30 10:47:29 UTC
Created attachment 405986 [details]
xtables-addons emerge build fail log

* Package:    net-firewall/xtables-addons-2.6

@sabayon we bumped into this while compiling xtables-addons against the 4.1 kernel sources. Fixed it with a revision bump containing a patch taken from netfilter-devel, it is applied only if >=4.1 kernel

https://github.com/Sabayon/for-gentoo/commit/c840be5b1389965d33051c86ab2b47902e9b5172

Cheers
Comment 1 Thomas Deutschmann (RETIRED) gentoo-dev 2015-07-03 20:25:46 UTC
Are you sure this patch is working?

See http://thread.gmane.org/gmane.comp.security.firewalls.netfilter.devel/58216/focus=58219
Comment 2 Thomas Deutschmann (RETIRED) gentoo-dev 2015-07-03 21:06:42 UTC
`XTABLES_ADDONS="echo" emerge xtables-addons` fails with

 * Installing compat_xtables module
 * Installing xt_ECHO module
install: cannot stat ‘xt_ECHO.ko’: No such file or directory
!!! doins: xt_ECHO.ko does not exist
 * ERROR: net-firewall/xtables-addons-2.6::gentoo failed (install phase):
 *   doins failed

,too.
Comment 3 Anthony Basile gentoo-dev 2015-07-03 22:31:13 UTC
We have to have a fix that will work with all versions of the kernel. 2.6 works for < 4.1 so we'll wait till upstream sorts this out for >= 4.1.
Comment 4 Anthony Basile gentoo-dev 2015-07-06 13:21:12 UTC
okay:

1) There are two issues here.  tarpit fails on linux-4.1 and above while echo fails on 4.0 and above.

2) I added xtables-addons-2.7 the tree.  Same issues.

3) I added a function to the ebuild to warn and die if modules known to fail on particular kernel versions are chosen.  (I actually need to generalize that function to work between kernel version rather than set a upper limit.)

4) I stabilized xtables-addons-2.6.

5) I'm checking to see if these issues are known upstream xtables-addons.

6) I'm not including patches that have not cleared upstream and don't have the appropriate intelligence to check kernel version and adjust for the changed kernel api.
Comment 5 Anthony Basile gentoo-dev 2015-07-06 13:27:03 UTC
(In reply to Anthony Basile from comment #4)
>
> 5) I'm checking to see if these issues are known upstream xtables-addons.
> 

tarpit is fixed in 2.7:

http://sourceforge.net/p/xtables-addons/xtables-addons/ci/96ce5ec48828d88da703ba00ef734d0c73ca6bc9/
Comment 6 Kevin Parent 2015-07-06 21:30:08 UTC
Ran into the same issue on funtoo.  xt_delude.c also needs to be patched.  I posted a bug report and working ebuild with patches at bugs.funtoo.org.

https://bugs.funtoo.org/browse/FL-2579?filter=-2

Found the patches in a netfilter-devel post

http://www.spinics.net/lists/netfilter-devel/msg37228.html
Comment 7 Thomas Deutschmann (RETIRED) gentoo-dev 2015-07-06 21:55:28 UTC
Everyone seems to read the message with the patch. But nobody seems to read the follow up from the same person posting the patch saying that it killed his network when he finally used tarpit.

Can somebody actual using tarpit or delude module say if these modules are *really* working with these patches or not?
Comment 8 Anthony Basile gentoo-dev 2015-10-22 08:25:41 UTC
(In reply to Thomas D. from comment #7)
> Everyone seems to read the message with the patch. But nobody seems to read
> the follow up from the same person posting the patch saying that it killed
> his network when he finally used tarpit.
> 
> Can somebody actual using tarpit or delude module say if these modules are
> *really* working with these patches or not?

I just pushed 2.9 to the tree.  Can someone check if tarpit works?

I'm also going to start stabilization against 2.8.  I know tarpit might be an issue but I don't have enough to say definitively.  If it turns out it is, I'll add a pkg_postinst() message pointing to the list email warning.

Open another bug if tarpit is broken because the build issue is addressed.