Re: [despammed] port translation

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



am  Sun, dem 11.01.2004, um 11:21:17 +0100 mailte Romain Moyne folgendes:
> Hello,
> 
> I'm French and my english is bad ;)

I'm German and my english is bad, too ;-)

> I have a http server (debian 3.0) behind a router (debian 3.0). I have a 
> problem when I want to log the visitor's IP of my website with PHP or 
> Perl or all language. I have always the IP of my router ! Somebody tell 
> me that I must do port translation but I have searched and I haven't 
> fand anything.
> Can you help me ?
> This is the rules of my router :
> 
> iptables -t nat -A PREROUTING -d MyIP -p tcp --dport 80 -j DNAT 
> --to-destination 192.168.0.3:80

With this rule you make a 'DNAT', the WebServer can only see the
Source-IP from your router.

You can install a WebServer or an Proxy for your Webserver on the
router, than you can see the visitor's IP and you can log this.

A other way is to analyse the logged packets on the router.


Andreas
-- 
Diese Message wurde erstellt mit freundlicher Unterstützung eines freilau-
fenden Pinguins aus artgerechter Freilandhaltung.   Er ist garantiert frei
von Micro$oft'schen Viren. (#97922 http://counter.li.org)     GPG 7F4584DA
Was, Sie wissen nicht, wo Kaufbach ist? Hier: N 51.05082°, E 13.56889° ;-)


[Index of Archives]     [Linux Netfilter Development]     [Linux Kernel Networking Development]     [Netem]     [Berkeley Packet Filter]     [Linux Kernel Development]     [Advanced Routing & Traffice Control]     [Bugtraq]

  Powered by Linux