• 22.08.2025, 21:48
  • Registrieren
  • Anmelden
  • Du bist nicht angemeldet.

 

kampfsau

God

Linux ipautofw? wer kennt sich aus?

Donnerstag, 22. Mai 2003, 11:14

hoi

mir gehts um folgenden befehl:

ipautofw -A -r <port1> <port2> -h <IP vom zielrechner>

kann ich da auch eine portrange einstellen, oder muß ich jeden einzeln? ???

sprich is port1 der eingangsport und port2 der port bei dems dann am zielrechner ankommt?
oder is port1-2 die range?

irgendwie kommt das in der helpfile ned so gut raus :P
8) there is no gravity - the world sucks 8)

LiquidAcid

unregistriert

Re: Linux ipautofw? wer kennt sich aus?

Donnerstag, 22. Mai 2003, 15:20

Hi, ich hab hier mal was kopiert. Ist aus der /etc/portfw.sh meines fli4l Routers.

Quellcode

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
#!/bin/sh
#------------------------------------------------------------------------------
# /etc/portfw.sh - ip port forwarding
#------------------------------------------------------------------------------
# ATTENTION ATTENTION ATTENTION ATTENTION ATTENTION ATTENTION ATTENTION
#                  NEW ARGUMENTS, SEE BELOW !!!
# ATTENTION ATTENTION ATTENTION ATTENTION ATTENTION ATTENTION ATTENTION
#------------------------------------------------------------------------------
# Called by /etc/ppp/ip-up everytime a new connection will be established
#
# Either ipportfw or ipautofw can be used
#------------------------------------------------------------------------------
# Usage of portfw (NEW):
#
# add entry:
#   ipmasqadm portfw -a -P PROTO -L LADDR LPORT -R HIDDENHOST RPORT [-p PREF]
# delete entry:
#   ipmasqadm portfw -d -P PROTO -L LADDR LPORT [-R HIDDENHOST RPORT]
# clear table:
#   ipmasqadm portfw -f
# list table:
#   ipmasqadm portfw -l
# no names:
#   ipmasqadm portfw <args> -n
#
#   PROTO       protocol, can be "tcp" or "udp"
#   LADDR       local interface receiving packets to be forwarded
#   LPORT       port being redirected
#   HIDDENHOST  ip address of your lan computer using the application
#   RPORT       the port being redirected to
#   PREF        preference level (load balancing, default=10)
#------------------------------------------------------------------------------
# Usage of autofw (NEW):
#
# add entry:
#   ipmasqadm autofw -A -r PROTO LOW HIGH [-h HIDDENHOST] [-c ctltype ctlport]
# clear table (flush):
#   ipmasqadm autofw -F
#
#   PROTO       protocol, can be "tcp" or "udp"
#   LOW         lowest port of range
#   HIGH        highest port of range
#   HIDDENHOST  ip address of your lan computer using the application
#------------------------------------------------------------------------------
# Here you will find hints to get your application run:
#
#                      [url]http://www.tsmservices.com/masq/[/url]
#------------------------------------------------------------------------------
# Creation:     08.09.2000  fm
# Last Update:  07.09.2001  tg
#------------------------------------------------------------------------------
# You can access the IP of the ppp device with $ip
#------------------------------------------------------------------------------
# Define your PCs to forward ports to:
#------------------------------------------------------------------------------
hiddenhost1=192.168.0.2                         # ip of PC 'voodoomaster' in LAN
hiddenhost2=192.168.1.2                         # ip of PC 'terminator' in LAN
#hiddenhost3=192.168.0.4                         # ip of PC in LAN: change here!
#hiddenhost4=192.168.0.5                         # ip of PC in LAN: change here!

#------------------------------------------------------------------------------
# example for ftp (internal ftp server, access from outside):
#
# Don't forget to correct the firewall ports in base.txt, see FW_N_PORTS
# and FW_PORT_x
#
# and to enable the ftp-Masquerading module in config.txt:
#   MASQ_MODULE_1='ftp'                         # masquerading module: ftp
#------------------------------------------------------------------------------
#/usr/sbin/ipmasqadm autofw -A -v -r tcp 21 21 -h $hiddenhost1

#------------------------------------------------------------------------------
# example for Battlecom (using ipautofw):
#------------------------------------------------------------------------------
#/usr/sbin/ipmasqadm autofw -A -v -r udp  2300  2400 -h $hiddenhost1
#/usr/sbin/ipmasqadm autofw -A -v -r tcp  2300  2400 -h $hiddenhost1
#/usr/sbin/ipmasqadm autofw -A -v -r tcp 47624 47624 -h $hiddenhost1
#/usr/sbin/ipmasqadm autofw -A -v -r udp 47624 47624 -h $hiddenhost1
#/usr/sbin/ipmasqadm autofw -A -v -r udp 28800 28900 -h $hiddenhost1

# --- added from config.txt ---


Im oberen Teil steht, wie man ipautofw benutzt, ist eigentlich recht einfach. ;)

cya
liquid

kampfsau

God

Re: Linux ipautofw? wer kennt sich aus?

Donnerstag, 22. Mai 2003, 19:31

mah kannst ned einfach sagen, daß das was ich als "port1" und "port2" bezeichnet hab, tatsächlich die range is?
eieiei... ::)

aber danke... sollte klappen :D
8) there is no gravity - the world sucks 8)