PDA

Archiv verlassen und diese Seite im Standarddesign anzeigen : VPN Server einrichten



urmell
11.11.03, 16:43
Hallo Community!

Ich habe heute mittels poptop einen VPN Server auf meinem Linux Rechner eingerichtet. Man kann auch ohne weiteres von außen(aus dem Internet) auf diesen connecten. Die Clients bekommen dann ihre Ip zugewiesen, koennen sich aber nicht untereinander anpingen. Der VPN-Server selbst hingegen(192.168.2.19) kann von jedem Client per Ping erreicht werden.
Die Frage ist also warum sich die Clients nicht untereinander anpingen koennen.

Ich benutze SuSE 8.1 ausserdem ist die yast Firewall deaktiviert, so kann diese also als Ursache ausgeschlossen werden. Auch auf den Clients laufen keine Firewalls. Wo also liegt das Problem?

Hier noch meine pptpd.conf aus dem /etc Verzeichniss


################################################## ##############################
#
# Sample PoPToP configuration file
#
# for PoPToP version 0.9.12
#
################################################## ##############################

# TAG: speed
#
# Specifies the speed for the PPP daemon to talk at.
#
speed 115200

# TAG: debug
#
# Turns on (more) debugging to syslog
#
#debug

# TAG: localip
# TAG: remoteip
#
# Specifies the local and remote IP address ranges.
#
# You can specify single IP addresses seperated by commas or you can
# specify ranges, or both. For example:
#
# 192.168.0.234,192.168.0.245-249,192.168.0.254
#
# IMPORTANT RESTRICTIONS:
#
# 1. No spaces are permitted between commas or within addresses.
#
# 2. If you give more IP addresses than MAX_CONNECTIONS, it will
# start at the beginning of the list and go until it gets
# MAX_CONNECTIONS IPs. Others will be ignored.
#
# 3. No shortcuts in ranges! ie. 234-8 does not mean 234 to 238,
# you must type 234-238 if you mean this.
#
# 4. If you give a single localIP, that's ok - all local IPs will
# be set to the given one. You MUST still give at least one remote
# IP for each simultaneous client.
#
#localip 192.168.0.234-238,192.168.0.245
#remoteip 192.168.1.234-238,192.168.1.245
#localip 10.0.1.1
#remoteip 10.0.1.2-100
max_connections 6
localip 192.168.2.19 "<---- hier bin ich mir nicht sicher...muss dort die ip des servers eingetragen werden, sprich die lokale????"
remoteip 192.168.2.25-30

Vielen Dank schon im Vorraus

urmel

LKH
11.11.03, 16:52
Hi,

das schon mal gelesen: http://poptop.sourceforge.net/dox/qna.html#2 ?

urmell
11.11.03, 17:52
Das Tutorial sieht ja wirklich gut aus, das Problem ist ich benutze iptables und keine ipchains. Folglich kann ich mit den Commands nicht viel anfangen, da ich nicht weiß wie ich sie auf iptables uebertragen soll. Falls das jemand kann wäre ich ihm sehr dankbar!!

Hier die Befehle:

ipchains -P input DENY
ipchains -P forward DENY
ipchains -A input 192.168.56.0/24 -j ACCEPT /* allow connections from inside */
ipchains -A input -p tcp -d 192.168.56.11 1723 -j ACCEPT
ipchains -A input -p 47 -d 192.168.56.11 -j ACCEPT
ipchains -A forward -p tcp -d 192.168.56.11 1723 -j ACCEPT
ipchains -A forward -p tcp -s 192.168.56.11 1723 -j ACCEPT
ipchains -A forward -p 47 -d 192.168.56.11 -j ACCEPT
ipchains -A forward -p 47 -s 192.168.56.11 -j ACCEPT
ipchains -A forward -i ppp+ -d 192.168.56.0/24 -j ACCEPT /* allow from clients to inside */
ipchains -A forward -i ppp+ -s 192.168.56.0/24 -j ACCEPT /* allow from inside to clients */

Vielen Dank

urmel

cane
12.11.03, 09:01
Das sollte hinhauen: Ansonsten empfehle ich Dir das Buch Linux Firewalls (http://www.oreilly.de/german/freebooks/linuxfireger/index.html) kostenlos runterzuladen und zu lesen...

ipchains -P input DENY
iptables -A INPUT -j DROP

ipchains -P forward DENY
iptables -A FORWARD -j DROP

ipchains -A input 192.168.56.0/24 -j ACCEPT /* allow connections from inside */
iptables -A INPUT -s 192.168.56.0/24 -j ACCEPT

ipchains -A input -p tcp -d 192.168.56.11 1723 -j ACCEPT
iptables -A INPUT -p tcp -d 192.168.56.11 -dport 1723 -j ACCEPT

ipchains -A input -p 47 -d 192.168.56.11 -j ACCEPT
iptables -A INPUT -p 47 -d 192.168.56.11 -j ACCEPT

ipchains -A forward -p tcp -d 192.168.56.11 1723 -j ACCEPT
iptables -A FORWARD -p tcp -d 192.168.56.11 -dport 1723 -j ACCEPT

ipchains -A forward -p tcp -s 192.168.56.11 1723 -j ACCEPT
iptables -A FORWARD -p tcp -s 192.168.56.11 -sport 1723 -j ACCEPT

ipchains -A forward -p 47 -d 192.168.56.11 -j ACCEPT
iptables -A FORWARD -p 47 -d 192.168.56.11 -j ACCEPT

ipchains -A forward -p 47 -s 192.168.56.11 -j ACCEPT
iptables -A FORWARD -p 47 -s 192.168.56.11 -j ACCEPT

ipchains -A forward -i ppp+ -d 192.168.56.0/24 -j ACCEPT /* allow from clients to
inside */
iptables -A FORWARD -i ppp+ -d 192.168.56.0/24 -j ACCEPT

ipchains -A forward -i ppp+ -s 192.168.56.0/24 -j ACCEPT /* allow from inside to clients */
iptables -A FORWARD -i ppp+ -s 192.168.56.0/24 -j ACCEPT

Bei Deinem Interface ppp+ bin ich mir unsicher ob das so richtig ist. Ich denke es gibt nur ppp0, ppp1... Oder es ist eine Ipchains Formulierung...

Naja mußt Du ausprobieren.

mfg
cane

maniac1810
12.11.03, 10:44
@urmel

hast du mal ein Tut parat, nach dem du das VPN eingerichtet hast? wäre echt klasse!

Micha

€dit: sorry, vergesst die frage! war wohl zu voreilig :ugly:

urmell
12.11.03, 13:33
ich hab einfach debian 3.0 drauf gemacht und benutze ipchains...das geht jetzt wunderbar.
trotzdem vielen dank fuer eure Hilfe

@ maniacEin Tut hab ich net, aber du kannst dich gerne an mich wenden. Ist wirklich einfach!!!Nur mit der Firewall kann es kompliziert werden...

urmel

klemens
12.11.03, 13:47
Wie wärs damit:
http://lug-kr.sourceforge.net/cgi-bin/lugwiki.pl?VPNmitPPTP