The problem is that the GW tries to send packet through the tunnel from its public address, which does not match the encryption domain.  You can remedy this by hide natting (source natting) all traffic destined to an encryption domain from the GW to its internal ip address.  
i.e.<br><br>iptables - t nat POSTROUTING -s &lt;PUBLIC IP OF GW&gt; -d &lt;ENCRYPTION DOMAIN&gt; -j SNAT --to-source &lt;INTERNAL IP OF GW&gt;<br><br>of course this is the Linux solution. Other OS&#39;s I couldn&#39;t really tell you how to use the NAT.
<br><br><div><span class="gmail_quote">On 05/03/07, <b class="gmail_sendername">Fernando Blankleder</b> &lt;<a href="mailto:fernandoblankleder@gmail.com">fernandoblankleder@gmail.com</a>&gt; wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">






<div bgcolor="#ffffff">
<div><font face="Arial" size="2">Hi, i&#39;m having problems pinging from my ipsec 
gateway to remote network, everything else works great, any clues ? i used to do 
it with routing but i lost my script :(</font></div>
<div><font face="Arial" size="2"></font>&nbsp;</div>
<div><font face="Arial" size="2">Thanks</font></div>
<div><font face="Arial" size="2">Fernando Blankleder</font></div>
<div>&nbsp;</div></div>
<br>_______________________________________________<br><a onclick="return top.js.OpenExtLink(window,event,this)" href="mailto:Users@openswan.org">Users@openswan.org</a><br><a onclick="return top.js.OpenExtLink(window,event,this)" href="http://lists.openswan.org/mailman/listinfo/users" target="_blank">
http://lists.openswan.org/mailman/listinfo/users</a><br>Building and Integrating Virtual Private Networks with Openswan:<br><a onclick="return top.js.OpenExtLink(window,event,this)" href="http://www.amazon.com/gp/product/1904811256/104-3099591-2946327?n=283155" target="_blank">
http://www.amazon.com/gp/product/1904811256/104-3099591-2946327?n=283155</a><br><br></blockquote></div><br><br clear="all"><br>-- <br>Computers are incredibly fast, accurate, and stupid; humans are incredibly slow, inaccurate and brilliant; together they are powerful beyond imagination.
<br>&nbsp;&nbsp;&nbsp;&nbsp; -- Albert Einstein