Welcome to Linux Forums! With a comprehensive Linux Forum, information on various types of Linux software and many Linux Reviews articles, we have all the knowledge you need a click away, or accessible via our knowledgeable members.
Find the answer to your Linux question:
New to Linux Forums? Register here for free!
    Linux Forums > GNU Linux Zone > Linux Security > 2.6.31 iptables ignores reply pkt at interface SNAT+VLAN

Forgot Password?
 Linux Security   Discussion about keeping your machines secure, and the crackers out.

Site Navigation
Linux Articles
Linux Forums
Linux Downloads
Linux Hosting
Free Magazines
Job Board
IRC Chat
RSS Feeds


Linux Forum Topics
Linux Forums
Your Distro
Linux Resources
GNU Linux Zone
The Community
Reply
 
Thread Tools Display Modes
Old 1 Week Ago   #1 (permalink)
Just Joined!
 
Join Date: Nov 2009
Posts: 1
2.6.31 iptables ignores reply pkt at interface SNAT+VLAN

Hi, I have a bit complex iptables+nat+mangle+vlan's setup within my box working perfectly with 2.6.30 and previous kernel versions. However, If I boot 2.6.31 then one of the capabilities stops working.

Replay packet's are silently ignored "only" at the interface doing SNAT+vlan. Rest of actions: iptables, nat, mangle's, policy based routing and NAT (no vlan) are working perfectly. To simplify the problem, here is the relevant setup and config:

Code:
 
["uid 1500" wget from 99.0.0.9]
     |
LOCALHOST(10.0.0.1)vlan400  ==== (10.0.0.2)ROUTER ==== "MyPrivate" host(99.0.0.9)
Code:
# echo "100 MyPrivate" >> /etc/iproute2/rt_tables
# ip route add 10.0.0.1/24 dev vlan400 table MyPrivate
# ip route add 99.0.0.0/8 via 10.0.0.2 table MyPrivate
# iptables -A OUTPUT -t mangle -m owner --uid-owner 1500 -j MARK --set-mark 1500
# ip rule add fwmark 1500 table MyPrivate
# iptables -t nat -A POSTROUTING -o vlan400 -j SNAT --to-source 10.0.0.1
# echo 0 > /proc/sys/net/ipv4/conf/all/rp_filter
With this setup, all network traffic originated by user id 1500 should check first the "MyPrivate" table and if destination is 99.0.0.9 then send it out through vlan400 interface and perform source NAT.

Starts ok, traffic goes out on "vlan400" and remote host reply is correct, but then it stops. My localhost is not sending the last ACK, looks like it never sees the reply (SYN, ACK)

Code:
$ (running uid 1500)
$ wget from 99.0.0.9
:
10.0.0.1 SYN -->
                   <-- SYN, ACK 99.0.0.9
Just booting back with 2.6.30 starts working perfect again.

I've made lots of tests, googled, etc. but couldn't find anything, only some references to some issues corrected on 2.6.31 regarding NAT and connection tracking, but none similar to mine. Iptables version is not the problem, used 1.4.2, 1.4.3, 1.4.5 and allways works with kernel < 2.6.31.

Anybody knows if something important has been changed with 2.6.31? any idea?

Thanks in advance,
Luis
luispa is offline  


Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off

Free Magazines
Run Your Own Web Server Using Linux & Apache - Free 191 Page Preview
Learn about everything you'll need to build and maintain your Linux servers, and to deploy Web applications to them.
subscribe
Open Source Security Myths Dispelled
Dispel the five major myths surrounding Open Source Security and gain the tools necessary to make a truly informed decision for your IT organization
subscribe
InformationWeek
InformationWeek is the only newsweekly you'll need to stay on top of the latest developments in information technology.
subscribe



All times are GMT. The time now is 06:44 PM.






© 2000 - 2009 - All Rights Reserved - Property of  MAS Media

Content Relevant URLs by vBSEO 3.3.0 RC2