Paul Nieuwkamp schreef op maandag 02 mei 2005 @ 14:05:
Je kunt naar een 510 telnetten en dan commando's geven
Eentje die hier in de Speedtouch staat:
code:
1
2
| firewall rule create chain=forward index=0 src=!ip.ad.dr.es prot=tcp dstport=22 action=reject
nat create protocol=tcp inside_addr=10.0.0.252:22 outside_addr=0.0.0.0:22 |
waardoor je alleen vanaf een bepaald IP van buiten naar binnen mag via SSH.
Andere firewall rules zijn ook wel te verzinnen. Ik heb de CLI manual (of telnet manual, staat iig op de speedtouch-site) niet bij de hand dus ik gok even dat de volgende regel ook wel werkt:
code:
1
| firewall rule create chain=forward index=0 prot=tcp dstport=22 action=reject |
zodat er geen enkel SSH-verkeer door de router nodig is.
Hoe je nu zorgt dat je bijvoorbeeld wel naar binnen maar niet naar buiten kunt SSH-en zal vast wel in die manual staan
Edit: via de link in de post hierboven:
http://www.speedtouch.nl/docs/CLIguide_510_427.pdf voor firmware R4.2
Edit2: om de richting te bepalen moet je srcinfgrp in je firewall rule gebruiken zie ik in die manual

Hallo ik ben nu al een paar dagen aan het testen met die manual ik snap er echt niks van.
Ik krijg er die rule echt niet voorelkaar, zou je me even kunnen helpen?
Ik heb hier het betreffende stukje uit de handleiding geknipt, je moet zoveel variabelen invullen die ik niet snap? ook al staan ze beschreven.
Create a rule.
Note If a value is preceded by a “!”, it means "NOT".
E.g. "dstintfgrp=!wan" means "if dstintfgrp is different from WAN".
where:
firewall rule create chain = forward
[index = 0
[srcintf [!]= lan
[srcintfgrp [!]= lan
[src [!]= 0.0.0.0.
[dstintf [!]= wan
[dstintfgrp [!]= wan
[dst [!]= 0.0.0.0
[tos [!]= <number{1-255}>]
[precedence [!]= <number{0-7}>]
[dscp [!]= <number{0-63}>]
[prot [!]= <{<supported IP protocol name>|<number>}>]
[syn = <yes|no>]
[urg = <yes|no>]
[ack = <yes|no>]
[srcport [!]= <{<supported TCP/UDP port name>|<number>}>]
[srcportend = <{<supported TCP/UDP port name>|<number>}>]
[dstport [!]= <{<supported TCP/UDP port name>|<number>}>]
[dstportend = <{<supported TCP/UDP port name>|<number>}>]
[icmptype [!]= <{<supported ICMP type name>|<number>}>]
[icmpcode [!]= <number{0-15}>]
[icmpcodeend = <number{0-15}>]
[clink = <string>]
[log = <{no|yes}>]
action = <{accept|deny|drop|count}>
chain The name of the chain in which the rule must be inserted. REQUIRED
index The number of the rule before which the new rule must be added. OPTIONAL
srcintf The name of the interface the packet should [or should NOT] arrive on to make this rule apply.
srcintfgrp The interface group the packet should [or should NOT] arrive on.
Choose between:
• wan
• local
• lan.
Note NOT applicable if used in a chain assigned to the output hook.
src The source IP address (range) the packet should [or should NOT]
come from. (Supports cidr notation).
dstintf The name of the interface the packet should [or should NOT] be
going to.
Note NOT applicable if used in a chain assigned to the output hook.
dstintfgrp The interface group the packet should [or should NOT] be going to.
Choose between:
• wan
• local
• lan.
Note NOT applicable if used in a chain assigned to the output hook.
dst The destination IP address (range) the packet should [or should
NOT] be going to (supports cidr notation).
precedence A number between 0 and 7.
Represents the precedence in the IP packet (part of tos).
dscp A number between 0 and 63.
Represents the DSCP in the IP packet (part of tos).
tos A number between 0 and 255.
Represents the Type Of Service specification which should be
expected [or NOT expected] in the IP packet. The Type of Service
numbering specification is in accordance to the latest version of
RFC1700: Assigned numbers.
prot The protocol (name or number) expected [or NOT expected] in
the IP packet.
Choose between:
• icmp
• igmp
• ipinip
• tcp
• udp
• ah
• esp
• ipcomp
or, alternatively, specify the protocol number.
syn Expect TCP SYN flag set (yes) or not (no).
In combination with TCP ACK, this allows selection of incoming
versus outgoing TCP connections.
OPTIONAL
urg Expect TCP URG flag set (yes) or not (no). OPTIONAL
ack Expect TCP ACK flag set (yes) or not (no). OPTIONAL
srcport The TCP/UDP port (or beginning of range) the packet should [or should NOT] be from.
Select one of the supported TCP/UDP port names (See
“ Supported TCP/UDP Port Names” on page 412 for a listing of
TCP/UDP port names supported by the SpeedTouch™).
Alternatively, specify the protocol number.
srcportend The source TCP/UDP port range end (inclusive)(Only applicable for
ranges).
Select one of the supported TCP/UDP port names (See
“ Supported TCP/UDP Port Names” on page 412 for a listing of
TCP/UDP port names supported by the SpeedTouch™).
Alternatively, specify the protocol number.
dstport The TCP/UDP port (or beginning of range) the packet should [or
should NOT] be going to.
Select one of the supported TCP/UDP port names (See
“ Supported TCP/UDP Port Names” on page 412 for a listing of
TCP/UDP port names supported by the SpeedTouch™).
Alternatively, specify the protocol number.
dstportend The destination TCP/UDP port range end (inclusive) (Only
applicable for ranges).
Select one of the supported TCP/UDP port names (See
“ Supported TCP/UDP Port Names” on page 412 for a listing of
TCP/UDP port names supported by the SpeedTouch™).
Alternatively, specify the protocol number.
icmptype The expected [or NOT expected] ICMP type (name or number) of
the packet.
Select one of the supported ICMP type names (See “ Supported
ICMP Type Names” on page 415 for a listing of ICMP type names
supported by the SpeedTouch™).
Alternatively, specify the protocol number.
icmpcode A number between 0 and 15.
Represents the expected [or NOT expected] ICMP code (or
beginning of range) of the packet as specified in the latest version of
RFC1700: Assigned numbers.
icmpcodeend A number between 0 and 15.
Represents the ICMP code range end.
Only applicable for ranges.
clink The name of the chain to be parsed when this rule applies (action is ignored).
log Logging is done when this rule applies.
action Action to be taken when this rule applies.
Choose between:
• accept: the packet may pass.
• deny: ICMP error destination unreachable. An error message is sent
back to the sender.
• drop: packet disappears. It is silently dropped, i.e. without sending an
error message to the sender.
• count: update of statistics. Has no influence on the packet.
firewall rule clear Clear statistics for a given rule.
firewall rule delete Delete a specified rule in a chain.
firewall rule flush Delete all rules in a chain.
firewall rule list Show a list of all (or a specified) chains' rules.
firewall rule stats Show statistics for all (or a specified) chains' rules.