SNMP
Configuring source address checking
iMG/RG Software Reference Manual (System Configuration)
1-104
FIGURE 1-21
snmpTargetAddrTMask (continued)
This indicates that none of the bits of the source address will be compared to the value of
snmpTargetAd-
drTAddress
, and consequently, an incoming SNMP request will not be reject based on its source address.
1.6.5.3 Matching a source address in a subnet
If the high-order bits of
snmpTargetAddrTMask
are set to ‘1’ and the low-order bits are set to ‘0’, the
mask can be used to reject an SNMP request that does not come from a particular subnet. For example, if
snmpTargetAddrTMask
is
255.255.255.128:0
, then only the most significant 25 bits of the source
address must match the most significant 25 bits of the value of
snmpTargetAddrTAddress
.
FIGURE 1-22
snmpTargetAddrTMask (continued)
Consider the case where the value of
snmpTargetAddrTAddress
is
192.147.142.35
:
FIGURE 1-23
snmpTargetAddrTMask (continued)
in order not to be rejected, the source address of an incoming SNMP request must begin with
192.147.142
In the fourth byte, only the first bit will be compared to the same bit of the value of
snmpTargetAddrTAd-
dress
. The remaining bits are “don’t care” cases (shown in
Figure 1-24
).
0
byte 1
0 0 0 0
0 0 0 0
0
byte 2
0 0 0 0
0 0 0 0
0
byte 3
0 0 0 0
0 0 0 0
0
byte 4
0 0 0 0
0 0 0 0
binary
decimal
255
byte 1
1 1 1 1
1 1 1 1
255
byte 2
1 1 1 1
1 1 1 1
255
byte 3
1 1 1 1
1 1 1 1
128
byte 4
1 0 0 0
0 0 0 0
binary
decimal
192
byte 1
1 1 0 0
0 0 0 0
147
byte 2
1 0 0 1
0 0 1 1
142
byte 3
1 0 0 0
1 1 1 0
35
byte 4
0 0 1 0
0 0 1 1
binary
decimal