3Com corebuilder 3500 Implementation Manual page 234

Hide thumbs Also See for corebuilder 3500:
Table of Contents

Advertisement

234
C
10: P
HAPTER
ACKET
Name
pushField.w
pushTop
pushLiteral
eq
reject
pushLiteral.w
lt
accept
pushField.a
pushLiteral.a
ne
F
ILTERING
Figure 37 Accept and Reject Instructions
Accept
(Use for OR-ing tests)
First test
Nonzero
Yes
result?
No
Next test
The following example shows the use of both accept and reject in a
packet filter. This packet filter was created for a network that is running
both Phase I and Phase II AppleTalk software. The goal of the filter is to
eliminate the AppleTalk traffic.
"Filter AppleTalk datagrams"
12
0x809b
0x5dc
16
0x03080007809b
First test
Nonzero
Accept packet
result?
and terminate
test sequence
Next test
# Get the type field.
# Make a copy.
# EtherTalk Phase I type.
# Test if the packet type is
# equal to the AppleTalk type,
# reject the packet and end.
# Otherwise,
# Largest 802.3 packet size
# If this value is less than the
# value in the packet's
# type/length field, then this
# is an Ethernet frame, so
# accept the packet if it is not
# 802.3, otherwise...
# get the SNAP OUI and Ethertype
# value to compare.
# If not equal, then forward the
# packet, otherwise drop it.
Reject
(Use for AND-ing tests)
Reject packet
Yes
and terminate
test sequence
No

Advertisement

Table of Contents
loading

Table of Contents