<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">
<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta name=Generator content="Microsoft Word 11 (filtered medium)">
<!--[if !mso]>
<style>
v\:* {behavior:url(#default#VML);}
o\:* {behavior:url(#default#VML);}
w\:* {behavior:url(#default#VML);}
.shape {behavior:url(#default#VML);}
</style>
<![endif]-->
<style>
<!--
/* Font Definitions */
@font-face
        {font-family:Tahoma;
        panose-1:2 11 6 4 3 5 4 4 2 4;}
@font-face
        {font-family:"MS Shell Dlg";
        panose-1:2 11 6 4 2 2 2 2 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0cm;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:"Times New Roman";}
a:link, span.MsoHyperlink
        {color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {color:purple;
        text-decoration:underline;}
p
        {mso-margin-top-alt:auto;
        margin-right:0cm;
        mso-margin-bottom-alt:auto;
        margin-left:0cm;
        font-size:12.0pt;
        font-family:"Times New Roman";}
span.StileMessaggioDiPostaElettronica18
        {mso-style-type:personal;
        font-family:Arial;
        color:windowtext;}
span.StileMessaggioDiPostaElettronica19
        {mso-style-type:personal;
        font-family:Arial;
        color:navy;}
span.StileMessaggioDiPostaElettronica20
        {mso-style-type:personal;
        font-family:Arial;
        color:navy;}
span.StileMessaggioDiPostaElettronica21
        {mso-style-type:personal-reply;
        font-family:Arial;
        color:navy;}
@page Section1
        {size:595.3pt 841.9pt;
        margin:70.85pt 2.0cm 2.0cm 2.0cm;}
div.Section1
        {page:Section1;}
-->
</style>
</head>
<body lang=IT link=blue vlink=purple>
<div class=Section1>
<p class=MsoNormal><font size=2 color=navy face=Arial><span style='font-size:
10.0pt;font-family:Arial;color:navy'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=2 color=navy face=Arial><span lang=EN-GB
style='font-size:10.0pt;font-family:Arial;color:navy'>OK I have another
question… please help me!!<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 color=navy face=Arial><span lang=EN-GB
style='font-size:10.0pt;font-family:Arial;color:navy'>My VPN/Firewall have this
IP : public: 217.xxx.xxx.xxx ip on Dmz:10.0.0.200 Ip on Private Lan
172.16.1.200<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 color=navy face=Arial><span lang=EN-GB
style='font-size:10.0pt;font-family:Arial;color:navy'>I have a client in the
Private lan with IP 172.16.1.10/11 ecc<o:p></o:p></span></font></p>
<p class=MsoNormal style='margin-right:.9pt;text-autospace:none'><font size=2
color=navy face=Arial><span lang=EN-GB style='font-size:10.0pt;font-family:
Arial;color:navy'>From the vpn client if I ping 172.16.1.10/11 </span></font><font
size=2 color=black face="MS Shell Dlg"><span lang=EN-GB style='font-size:10.0pt;
font-family:"MS Shell Dlg";color:black'>everything operates but if I ping
172.16.1.200 (is the ip on the firewall/vpn of the private lan) my firewall
ACCEPT ESP packets and DROP the icmp packets!!!<o:p></o:p></span></font></p>
<p class=MsoNormal style='margin-right:.9pt;text-autospace:none'><font size=2
color=black face="MS Shell Dlg"><span lang=EN-GB style='font-size:10.0pt;
font-family:"MS Shell Dlg";color:black'>Why???<o:p></o:p></span></font></p>
<p class=MsoNormal style='margin-right:.9pt;text-autospace:none'><font size=2
color=black face="MS Shell Dlg"><span lang=EN-GB style='font-size:10.0pt;
font-family:"MS Shell Dlg";color:black'>Thanks<o:p></o:p></span></font></p>
<p class=MsoNormal style='margin-right:.9pt;text-autospace:none'><font size=2
color=black face="MS Shell Dlg"><span lang=EN-GB style='font-size:10.0pt;
font-family:"MS Shell Dlg";color:black'>Giovanni</span></font><font size=2
face="MS Shell Dlg"><span lang=EN-GB style='font-size:10.0pt;font-family:"MS Shell Dlg"'><o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 color=navy face=Arial><span lang=EN-GB
style='font-size:10.0pt;font-family:Arial;color:navy'><o:p> </o:p></span></font></p>
<div>
<div class=MsoNormal align=center style='text-align:center'><font size=3
face="Times New Roman"><span style='font-size:12.0pt'>
<hr size=2 width="100%" align=center tabindex=-1>
</span></font></div>
<p class=MsoNormal><b><font size=2 face=Tahoma><span style='font-size:10.0pt;
font-family:Tahoma;font-weight:bold'>Da:</span></font></b><font size=2
face=Tahoma><span style='font-size:10.0pt;font-family:Tahoma'> Giovanni
[mailto:gio_ton@tiscali.it] <br>
<b><span style='font-weight:bold'>Inviato:</span></b> mercoledì 27
ottobre 2004 1.31<br>
<b><span style='font-weight:bold'>A:</span></b> 'users@openswan.org'<br>
<b><span style='font-weight:bold'>Oggetto:</span></b> R: [Openswan Users]
OpensWan and Iptables</span></font><o:p></o:p></p>
</div>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=3 color=navy face="Times New Roman"><span
style='font-size:12.0pt;color:navy'>Now works very well!!!</span></font><o:p></o:p></p>
<p class=MsoNormal><font size=2 color=navy face=Arial><span style='font-size:
10.0pt;font-family:Arial;color:navy'>Thanks again<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 color=navy face=Arial><span style='font-size:
10.0pt;font-family:Arial;color:navy'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=2 color=navy face=Arial><span style='font-size:
10.0pt;font-family:Arial;color:navy'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=2 color=navy face=Arial><span style='font-size:
10.0pt;font-family:Arial;color:navy'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=2 color=blue face=Arial><span style='font-size:
10.0pt;font-family:Arial;color:blue'>Hi </span></font><o:p></o:p></p>
<p class=MsoNormal><font size=2 color=blue face=Arial><span style='font-size:
10.0pt;font-family:Arial;color:blue'>This should give you an idea:</span></font><o:p></o:p></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'><!--StartFragment --> [ #Allow IKE ]<br>
<br>
# Allow ESP Traffic from/to Gateway<br>
iptables -A INPUT -i $EXTERNAL_INTERFACE -p esp -j ACCEPT<br>
iptables -A OUTPUT -o $EXTERNAL_INTERFACE -p esp -j ACCEPT<br>
<br>
# Tag Incoming IPSec Traffic. 'mark' sticks after processing.<br>
iptables -t mangle -A PREROUTING -i $EXTERNAL_INTERFACE -p esp -j MARK
--set-mark 1<br>
<br>
# Forward Authenticated Traffic to LAN.<br>
iptables -A FORWARD -i $EXTERNAL_INTERFACE -m mark --mark 1 -d $LAN_ADDRESSES
-j ACCEPT <o:p></o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'> <o:p></o:p></span></font></p>
<p class=MsoNormal><font size=3 color=black face="Times New Roman"><span
style='font-size:12.0pt;color:black'><!--StartFragment --># Allow established
connections to communicate back.</span></font><o:p></o:p></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>iptables -A FORWARD -i $LAN_INTERFACE -o $EXTERNAL_INTERFACE -m state
--state NEW,ESTABLISHED,RELATED -j ACCEPT<br>
iptables -A FORWARD -i $EXTERNAL_INTERFACE -o $LAN_INTERFACE -m state --state
ESTABLISHED,RELATED -j ACCEPT<o:p></o:p></span></font></p>
<div>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'> <o:p></o:p></span></font></p>
</div>
<div>
<p class=MsoNormal><font size=3 color=black face="Times New Roman"><span
style='font-size:12.0pt;color:black'># SRC nat everything apart from esp
traffic.</span></font><o:p></o:p></p>
</div>
<div>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'><!--StartFragment -->iptables -t nat -A POSTROUTING -o
$EXTERNAL_INTERFACE -p ! esp -j SNAT --to-source $EXTERNAL_IPADDR <o:p></o:p></span></font></p>
</div>
<div>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'> <o:p></o:p></span></font></p>
</div>
<div>
<p class=MsoNormal><font size=2 color=blue face=Arial><span style='font-size:
10.0pt;font-family:Arial;color:blue'>I hope this helps.</span></font><o:p></o:p></p>
</div>
<div>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'> <o:p></o:p></span></font></p>
</div>
<div>
<p class=MsoNormal><font size=2 color=blue face=Arial><span style='font-size:
10.0pt;font-family:Arial;color:blue'>Cheers,</span></font><o:p></o:p></p>
</div>
<div>
<p class=MsoNormal><font size=2 color=blue face=Arial><span style='font-size:
10.0pt;font-family:Arial;color:blue'>Daniel.</span></font><o:p></o:p></p>
</div>
<div>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'> <o:p></o:p></span></font></p>
</div>
</div>
</body>
</html>