Mandrake 10 + shorewall +pptp adsl probleem

Pagina: 1
Acties:

  • jlokerse
  • Registratie: Juni 2001
  • Laatst online: 11-08-2021
Heren geleerden,

ik hoop hier toch hulp te kunen vinden voor het volgende probleem:

Ik wil een pc als router/firewall gaan gebruiken.
Ik heb Mandrake 10 (community) erop geinstalleerd.
De machine heeft 2 netwerkkaarten, met aan 1 kaart ADSL van xs4all met een alcatel modem.
Aan de andere netwerkkaart hangt via een switch mijn lan pc's.

Op mandrake draait shorewall om de firewall in te stellen.
Ik heb de wijzigingen die op de shorewall staan in geval van een pptp verbinding met een adsl modem gemaakt.

Nu kan ik wel surfen op de firewall met lynx maar niet op de machines op m'n lan.

Ik kan wel pingen naar een lan machine van de firewall pc.

Nu staat er in shorewall policies wel logging aan op de reject en drop regels maar als ik probeer te surfenn vanaf een lan pc zie ik niets in de logs verschijnen wat er op duidt dat er iets geblocked wordt door de firewall.

Als ik shorewall stop en de policies van input/output/forward op accept zet en een iptables rule invoer voor masquerading werkt het surfen wel vanaf een lan pc.

sidenote: wegens een fout bij het installeren van mandrake 10 (kreeg een foutmelding bij het installeren van pptp, deze dus met de hand met de rpm van cd1 geinstalleerd) krijg ik wel de melding bij het opstarten van de pptp tunnel dat een pass-filter niet in de kernel zit, en dat daarom de gateway niet standaard ingesteld wordt.

Dit doe ik dus met de hand (gecontroleerd met route), en als ik dan zoals hierboven shorewall stop en handmatig iptables instel werkt alles wel dus dat sluit ik uit als oorzaak.

Ik heb hiervoor ook al met mandrake multinetwork firewall lopen stoeien op het zelfde probleem en daar om dus uitgeweken naar mandrake 10 om beter te kunnen uitzoeken waar het probleem nu ligt, wat helaas dus niet lukt.
Als het werkt wil ik graag weer terug naar mnf wegens de webinterface.

Ik heb al uitvoerig gezocht op de diverse sites maar kan geen nuttige informatie vinden.

de diverse configuratie files:

code:
1
2
3
4
5
6
7
8
9
#
# Shorewall 1.4 -- Interfaces File
#
# /etc/shorewall/interfaces
#ZONE    INTERFACE  BROADCAST   OPTIONS
net ppp0    detect
loc eth1    detect
modem   eth0    detect
#LAST LINE -- ADD YOUR ENTRIES BEFORE THIS ONE -- DO NOT REMOVE


code:
1
2
3
4
5
6
7
#
# Shorewall 1.4 /etc/shorewall/zones
#ZONE   DISPLAY     COMMENTS
net Net Internet zone
loc Local   Local
modem   Modem   ADSL modem
#LAST LINE - ADD YOUR ENTRIES ABOVE THIS ONE - DO NOT REMOVE



code:
1
2
3
4
5
6
# Shorewall 1.4 - /etc/shorewall/tunnels
#
# TYPE          ZONE    GATEWAY     GATEWAY
#                       ZONE
pptpclient  modem   10.0.0.10
#LAST LINE -- ADD YOUR ENTRIES BEFORE THIS ONE -- DO NOT REMOVE



code:
1
2
3
4
5
6
7
#
# Shorewall 1.4 - Masquerade file
#
# /etc/shorewall/masq
#INTERFACE          SUBNET      ADDRESS
ppp0    192.168.1.0/24
#LAST LINE -- ADD YOUR ENTRIES ABOVE THIS LINE -- DO NOT REMOVE



code:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
#
# Shorewall 1.4 -- Policy File
# /etc/shorewall/policy
#SOURCE     DEST        POLICY      LOG     LIMIT:BURST
#                       LEVEL
#
# THE FOLLOWING POLICY MUST BE LAST
#   
loc net ACCEPT
fw  net ACCEPT
fw  modem   ACCEPT
net all DROP    info
all all REJECT  info
#LAST LINE -- DO NOT REMOVE


[code]

Een overzicht van iptables -L als shorewall alles geconfigureerd heeft volgens bovenstaande configuratie files:

code:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
Chain INPUT (policy DROP)
target     prot opt source               destination         
ACCEPT     all  --  anywhere             anywhere            
DROP      !icmp --  anywhere             anywhere            state INVALID 
ppp0_in    all  --  anywhere             anywhere            
eth1_in    all  --  anywhere             anywhere            
eth0_in    all  --  anywhere             anywhere            
common     all  --  anywhere             anywhere            
LOG        all  --  anywhere             anywhere            LOG level info prefix `Shorewall:INPUT:REJECT:' 
reject     all  --  anywhere             anywhere            

Chain FORWARD (policy DROP)
target     prot opt source               destination         
DROP      !icmp --  anywhere             anywhere            state INVALID 
ppp0_fwd   all  --  anywhere             anywhere            
eth1_fwd   all  --  anywhere             anywhere            
eth0_fwd   all  --  anywhere             anywhere            
common     all  --  anywhere             anywhere            
LOG        all  --  anywhere             anywhere            LOG level info prefix `Shorewall:FORWARD:REJECT:' 
reject     all  --  anywhere             anywhere            

Chain OUTPUT (policy DROP)
target     prot opt source               destination         
ACCEPT     all  --  anywhere             anywhere            
DROP      !icmp --  anywhere             anywhere            state INVALID 
fw2net     all  --  anywhere             anywhere            
all2all    all  --  anywhere             anywhere            
fw2modem   all  --  anywhere             anywhere            
common     all  --  anywhere             anywhere            
LOG        all  --  anywhere             anywhere            LOG level info prefix `Shorewall:OUTPUT:REJECT:' 
reject     all  --  anywhere             anywhere            

Chain all2all (6 references)
target     prot opt source               destination         
ACCEPT     all  --  anywhere             anywhere            state RELATED,ESTABLISHED 
newnotsyn  tcp  --  anywhere             anywhere            state NEW tcp flags:!SYN,RST,ACK/SYN 
common     all  --  anywhere             anywhere            
LOG        all  --  anywhere             anywhere            LOG level info prefix `Shorewall:all2all:REJECT:' 
reject     all  --  anywhere             anywhere            

Chain common (5 references)
target     prot opt source               destination         
icmpdef    icmp --  anywhere             anywhere            
reject     udp  --  anywhere             anywhere            udp dpt:135 
reject     udp  --  anywhere             anywhere            udp dpts:netbios-ns:netbios-ssn 
reject     udp  --  anywhere             anywhere            udp dpt:microsoft-ds 
reject     tcp  --  anywhere             anywhere            tcp dpt:netbios-ssn 
reject     tcp  --  anywhere             anywhere            tcp dpt:microsoft-ds 
reject     tcp  --  anywhere             anywhere            tcp dpt:135 
DROP       udp  --  anywhere             anywhere            udp dpt:1900 
DROP       all  --  anywhere             255.255.255.255     
DROP       all  --  anywhere             BASE-ADDRESS.MCAST.NET/4 
reject     tcp  --  anywhere             anywhere            tcp dpt:auth 
DROP       udp  --  anywhere             anywhere            udp spt:domain state NEW 

Chain dynamic (6 references)
target     prot opt source               destination         

Chain eth0_fwd (1 references)
target     prot opt source               destination         
dynamic    all  --  anywhere             anywhere            state NEW 
all2all    all  --  anywhere             anywhere            
all2all    all  --  anywhere             anywhere            

Chain eth0_in (1 references)
target     prot opt source               destination         
dynamic    all  --  anywhere             anywhere            state NEW 
modem2fw   all  --  anywhere             anywhere            

Chain eth1_fwd (1 references)
target     prot opt source               destination         
dynamic    all  --  anywhere             anywhere            state NEW 
loc2net    all  --  anywhere             anywhere            
all2all    all  --  anywhere             anywhere            

Chain eth1_in (1 references)
target     prot opt source               destination         
dynamic    all  --  anywhere             anywhere            state NEW 
loc2fw     all  --  anywhere             anywhere            

Chain fw2modem (1 references)
target     prot opt source               destination         
ACCEPT     all  --  anywhere             anywhere            state RELATED,ESTABLISHED 
newnotsyn  tcp  --  anywhere             anywhere            state NEW tcp flags:!SYN,RST,ACK/SYN 
ACCEPT     gre  --  anywhere             10.0.0.10           
ACCEPT     tcp  --  anywhere             10.0.0.10           tcp dpt:1723 
ACCEPT     all  --  anywhere             anywhere            

Chain fw2net (1 references)
target     prot opt source               destination         
ACCEPT     all  --  anywhere             anywhere            state RELATED,ESTABLISHED 
newnotsyn  tcp  --  anywhere             anywhere            state NEW tcp flags:!SYN,RST,ACK/SYN 
ACCEPT     all  --  anywhere             anywhere            

Chain icmpdef (1 references)
target     prot opt source               destination         

Chain loc2fw (1 references)
target     prot opt source               destination         
ACCEPT     all  --  anywhere             anywhere            state RELATED,ESTABLISHED 
newnotsyn  tcp  --  anywhere             anywhere            state NEW tcp flags:!SYN,RST,ACK/SYN 
ACCEPT     tcp  --  anywhere             anywhere            multiport dports http,https,ssh state NEW 
ACCEPT     icmp --  anywhere             anywhere            icmp echo-request 
all2all    all  --  anywhere             anywhere            

Chain loc2net (1 references)
target     prot opt source               destination         
ACCEPT     all  --  anywhere             anywhere            state RELATED,ESTABLISHED 
newnotsyn  tcp  --  anywhere             anywhere            state NEW tcp flags:!SYN,RST,ACK/SYN 
ACCEPT     all  --  anywhere             anywhere            

Chain modem2fw (1 references)
target     prot opt source               destination         
ACCEPT     all  --  anywhere             anywhere            state RELATED,ESTABLISHED 
newnotsyn  tcp  --  anywhere             anywhere            state NEW tcp flags:!SYN,RST,ACK/SYN 
ACCEPT     gre  --  anywhere             anywhere            
all2all    all  --  anywhere             anywhere            

Chain net2all (3 references)
target     prot opt source               destination         
ACCEPT     all  --  anywhere             anywhere            state RELATED,ESTABLISHED 
newnotsyn  tcp  --  anywhere             anywhere            state NEW tcp flags:!SYN,RST,ACK/SYN 
common     all  --  anywhere             anywhere            
LOG        all  --  anywhere             anywhere            LOG level info prefix `Shorewall:net2all:DROP:' 
DROP       all  --  anywhere             anywhere            

Chain net2fw (1 references)
target     prot opt source               destination         
ACCEPT     all  --  anywhere             anywhere            state RELATED,ESTABLISHED 
newnotsyn  tcp  --  anywhere             anywhere            state NEW tcp flags:!SYN,RST,ACK/SYN 
ACCEPT     tcp  --  anywhere             anywhere            multiport dports http,https,ssh state NEW 
ACCEPT     icmp --  anywhere             anywhere            icmp echo-request 
net2all    all  --  anywhere             anywhere            

Chain newnotsyn (8 references)
target     prot opt source               destination         
LOG        all  --  anywhere             anywhere            LOG level info prefix `Shorewall:newnotsyn:DROP:' 
DROP       all  --  anywhere             anywhere            

Chain ppp0_fwd (1 references)
target     prot opt source               destination         
dynamic    all  --  anywhere             anywhere            state NEW 
net2all    all  --  anywhere             anywhere            
net2all    all  --  anywhere             anywhere            

Chain ppp0_in (1 references)
target     prot opt source               destination         
dynamic    all  --  anywhere             anywhere            state NEW 
net2fw     all  --  anywhere             anywhere            

Chain reject (11 references)
target     prot opt source               destination         
REJECT     tcp  --  anywhere             anywhere            reject-with tcp-reset 
REJECT     udp  --  anywhere             anywhere            reject-with icmp-port-unreachable 
REJECT     icmp --  anywhere             anywhere            reject-with icmp-host-unreachable 
REJECT     all  --  anywhere             anywhere            reject-with icmp-host-prohibited 

Chain shorewall (0 references)
target     prot opt source               destination


Sorry voor de lap tekst maar wil graag volledig zijn.

[ Voor 62% gewijzigd door jlokerse op 23-06-2004 17:00 ]