Basics Switching Concepts and Configuration Chapter-2
Basics Switching Concepts and Configuration Chapter-2
Objectives
Upon completion of this chapter, you will be able to answer the following questions:
■ How do you configure the initial settings on ■ How do you describe basic security attacks
a Cisco switch? in a switched environment?
■ How do you configure switch ports to meet ■ How do you describe security best practices
network requirements? in a switched environment?
■ How do you configure the management ■ How do you configure the port security fea-
VLAN switch virtual interface? ture to restrict network access?
Key Terms
This chapter uses the following key terms. You can find the definitions in the Glossary.
Introduction (2.0.1.1)
Switches are used to connect multiple devices together on the same network. In a
properly designed network, LAN switches are responsible for directing and control-
ling the data flow at the access layer to networked resources.
Cisco switches are self-configuring, and no additional configurations are necessary
for them to function out of the box. However, Cisco switches run Cisco IOS and
can be manually configured to better meet the needs of the network. This includes
adjusting port speed, bandwidth, and security requirements.
Additionally, Cisco switches can be managed both locally and remotely. To remotely
manage a switch, it needs to have an IP address and default gateway configured.
These are just two of the configurations discussed in this chapter.
Access layer switches operate at the access layer, where client network devices con-
nect directly to the network and IT departments want uncomplicated network access
for the users. It is one of the most vulnerable areas of the network because it is so
exposed to the user. Switches need to be configured to be resilient to attacks of all
types while they are protecting user data and allowing high-speed connections. Port
security is one of the security features that Cisco-managed switches provide.
This chapter examines some of the basic switch configuration settings required to
maintain a secure, available, switched LAN environment.
5. The boot loader locates and loads a default IOS operating system software image
into memory and hands control of the switch over to the IOS.
The boot loader finds the Cisco IOS image and attempts to automatically boot by
using information in the BOOT environment variable. If this variable is not set, the
switch attempts to load and execute the first executable file it can by performing a
recursive, depth-first search throughout the flash file system. In a depth-first search
of the file system, the search begins at the first top-level directory. The search pro-
ceeds through the directory from the lowest level subdirectory, up the tree. If the
search is unsuccessful, the next top-level directory is located and the bottom-up
search pattern is repeated. On Catalyst 2960 Series switches, the image file is nor-
mally contained in a directory that has the same name as the image file (excluding the
.bin file extension).
The IOS operating system then initializes the interfaces using the Cisco IOS com-
mands found in the configuration file, startup-config, which is stored in NVRAM.
In Figure 2-1, the BOOT environment variable is set using the boot system global
configuration mode command. Notice that the IOS is located in a distinct folder and
the folder path is specified. Use the show bootvar command (show boot in older IOS
versions) to see to what the current IOS boot file is set.
1 2 3 4
1
2
3
4
How To Step 1. Connect a PC by a console cable to the switch console port. Configure ter-
minal emulation software to connect to the switch.
Step 2. Unplug the switch power cord, because many Cisco switches do not have
an on/off switch.
Step 3. Reconnect the power cord to the switch and, within 15 seconds, press and
hold down the Mode button while the System LED is still flashing green.
Step 4. Continue pressing the Mode button until the System LED turns briefly
amber and then solid green; then release the Mode button.
Step 5. The boot loader switch: prompt appears in the terminal emulation software
on the PC.
The boot loader command line supports commands to format the flash file system,
reinstall the operating system software, and recover from a lost or forgotten pass-
word. For example, the dir command can be used to view a list of files within a spec-
ified directory, as shown in Figure 2-2.
Note
In this example, the IOS is located in the root of the flash folder.
blocked to ensure that a loop does not exist in the forwarding domain and is not
forwarding data (typically, ports will remain in this state for the first 30 seconds
after being activated). If the LED is blinking amber, the port is blocked to prevent
a possible loop in the forwarding domain.
■ Port Duplex LED: Indicates that the port duplex mode is selected when the LED
is green. When selected, port LEDs that are off are in half-duplex mode. If the
port LED is green, the port is in full-duplex mode.
■ Port Speed LED: Indicates that the port speed mode is selected. When selected,
the port LEDs will display colors with different meanings. If the LED is off, the
port is operating at 10 Mb/s. If the LED is green, the port is operating at 100
Mb/s. If the LED is blinking green, the port is operating at 1000 Mb/s.
■ Power over Ethernet (PoE) Mode LED: If PoE is supported, a PoE mode LED
will be present. If the LED is off, it indicates that the PoE mode is not selected
and that none of the ports have been denied power or placed in a fault condition.
If the LED is blinking amber, the PoE mode is not selected but at least one of the
ports has been denied power, or has a PoE fault. If the LED is green, it indicates
that the PoE mode is selected and that the port LEDs will display colors with dif-
ferent meanings. If the port LED is off, the PoE is off. If the port LED is green,
the PoE is on. If the port LED is alternating green-amber, PoE is denied because
providing power to the powered device will exceed the switch power capacity.
If the LED is blinking amber, PoE is off because of a fault. If the LED is amber,
PoE for the port has been disabled.
The SVI for VLAN 99 will not appear as “up/up” until VLAN 99 is created and there
is a device connected to a switch port associated with VLAN 99. To create a VLAN
with the vlan_id of 99 and associate it to interface FastEthernet 0/1, use the following
commands:
S1(config)# vlan 99
S1(config-vlan)# name Mgmt
S1(config)# interface f0/1
S1(config-if)# switchport access vlan 99
Configure the default gateway for the switch. S1(config)# ip default-gateway 172.17.99.1
Save the running configuration file to the S1# copy running-config startup-config
startup configuration file.
The default setting for both duplex and speed for switch ports on Cisco Catalyst
2960 and 3560 switches is auto. The 10/100/1000 ports operate in either half- or full-
duplex mode when they are set to 10 or 100 Mb/s, but when they are set to 1000
Mb/s (1 Gb/s), they operate only in full-duplex mode. Autonegotiation is useful when
the speed and duplex settings of the device connecting to the port are unknown or
can change. When connecting to known devices, such as servers, dedicated worksta-
tions, or network devices, best practice is to manually set the speed and duplex
settings.
When troubleshooting switch port issues, the duplex and speed settings should be
checked.
Note
Mismatched settings for the duplex mode and speed of switch ports can cause connectivity
issues. Autonegotiation failure creates mismatched settings.
All fiber-optic ports, such as 100BASE-FX ports, operate only at one preset speed
and are always full-duplex.
Interactive
Activity 2.1.2.2: Configuring Duplex and Speed
Graphic Go to the online course to use the Syntax Checker in the second graphic to config-
ure port F0/1 of switch S1.
Auto-MDIX (2.1.2.3)
Until recently, certain cable types (straight-through or crossover) were required when
connecting devices. Switch-to-switch or switch-to-router connections required using
different Ethernet cables. Using the automatic medium-dependent interface cross-
over (auto-MDIX) feature on an interface eliminates this problem. When auto-MDIX
is enabled, the interface automatically detects the required cable connection type
(straight-through or crossover) and configures the connection appropriately. When
connecting to switches without the auto-MDIX feature, straight-through cables must
be used to connect to devices such as servers, workstations, or routers, and crossover
cables must be used to connect to other switches or repeaters.
With auto-MDIX enabled, either type of cable can be used to connect to other
devices, and the interface automatically adjusts to communicate successfully. On
newer Cisco routers and switches, the mdix auto interface configuration mode com-
mand enables the feature. When using auto-MDIX on an interface, the interface
speed and duplex must be set to auto so that the feature operates correctly.
The commands to enable auto-MDIX are shown in Figure 2-9.
Note
The auto-MDIX feature is enabled by default on Catalyst 2960 and Catalyst 3560 switches,
but it is not available on the older Catalyst 2950 and Catalyst 3550 switches.
To examine the auto-MDIX setting for a specific interface, use the show controllers
ethernet-controller command with the phy keyword. To limit the output to lines
referencing auto-MDIX, use the include Auto-MDIX filter. As shown in Figure 2-10,
the output indicates On or Off for the feature.
Interactive
Activity 2.1.2.3: Enable Auto-MDIX
Graphic Go to the online course to use the Syntax Checker in the third graphic to configure
port F0/1 on S2 for auto-MDIX.
Figure 2-11 shows sample abbreviated output from the show running-config com-
mand. Use this command to verify that the switch has been correctly configured. As
seen in the output for S1, some key information is shown:
■ Fast Ethernet 0/18 interface is configured with the management VLAN 99.
■ VLAN 99 is configured with an IP address of 172.17.99.11 255.255.255.0.
■ Default gateway is set to 172.17.99.1.
The show interfaces command is another commonly used command that displays
status and statistics information on the network interfaces of the switch. The show
interfaces command is frequently used when configuring and monitoring network
devices.
Figure 2-12 shows the output from the show interfaces fastEthernet 0/18 command.
The first line in the figure indicates that the FastEthernet 0/18 interface is up/up,
meaning that it is operational. Farther down, the output shows that the duplex is full
and the speed is 100 Mb/s.
Up Up Operational
The first parameter (FastEthernet0/1 is up) refers to the hardware layer and essen-
tially reflects whether the interface is receiving the carrier detect signal from the
other end. The second parameter (line protocol is up) refers to the data link layer and
reflects whether the data link layer protocol keepalives are being received.
Based on the output of the show interfaces command, possible problems can be
fixed as follows:
■ If the interface is up and the line protocol is down, a problem exists. There could
be an encapsulation type mismatch, the interface on the other end could be
error-disabled, or there could be a hardware problem.
■ If the line protocol and the interface are both down, a cable is not attached or
some other interface problem exists. For example, in a back-to-back connection,
the other end of the connection might be administratively down.
■ If the interface is administratively down, it has been manually disabled (the shut-
down command has been issued) in the active configuration.
Example 2-2 shows an example of the show interfaces command output. The exam-
ple shows counters and statistics for the FastEthernet 0/1 interface.
Some media errors are not severe enough to cause the circuit to fail, but do cause
network performance issues. Table 2-5 explains some of these common errors, which
can be detected by using the show interfaces command.
Input errors Total number of errors. It includes runts, giants, no buffer, CRC, frame,
overrun, and ignored counts.
Runts Packets that are discarded because they are smaller than the minimum
packet size for the medium. For example, any Ethernet packet that is less
than 64 bytes is considered a runt.
Giants Packets that are discarded because they exceed the maximum packet size
for the medium. For example, any Ethernet packet that is greater than 1518
bytes is considered a giant.
CRC CRC errors are generated when the calculated checksum is not the same as
the checksum received.
Output errors Sum of all errors that prevented the final transmission of datagrams out of
the interface that is being examined.
“Input errors” is the sum of all errors in datagrams that were received on the inter-
face being examined. This includes runts, giants, CRC, no buffer, frame, overrun,
and ignored counts. The reported input errors from the show interfaces command
include the following:
■ Runt frames: Ethernet frames that are shorter than the 64-byte minimum allowed
length are called runts. Malfunctioning NICs are the usual cause of excessive
runt frames, but they can be caused by the same issues as excessive collisions.
■ Giants: Ethernet frames that are longer than the maximum allowed length are
called giants. Giants are caused by the same issues as those that cause runts.
■ CRC errors: On Ethernet and serial interfaces, CRC errors usually indicate a
media or cable error. Common causes include electrical interference, loose or
damaged connections, or using the incorrect cabling type. If you see many CRC
errors, there is too much noise on the link and you should inspect the cable for
damage and length. You should also search for and eliminate noise sources, if
possible.
“Output errors” is the sum of all errors that prevented the final transmission of data-
grams out of the interface that is being examined. The reported output errors from
the show interfaces command include the following:
■ Collisions: Collisions in half-duplex operations are completely normal and you
should not worry about them, as long as you are pleased with half-duplex opera-
tions. However, you should never see collisions in a properly designed and con-
figured network that uses full-duplex communication. It is highly recommended
that you use full-duplex unless you have older or legacy equipment that requires
half-duplex.
■ Late collisions: A late collision refers to a collision that occurs after 512 bits of
the frame (the preamble) have been transmitted. Excessive cable lengths are the
most common cause of late collisions. Another common cause is duplex miscon-
figuration. For example, you could have one end of a connection configured for
full-duplex and the other for half-duplex. You would see late collisions on the
interface that is configured for half-duplex. In that case, you must configure the
same duplex setting on both ends. A properly designed and configured network
should never have late collisions.
If the interface is up, but issues with connectivity are still present:
■ Using the show interfaces command, check for indications of excessive noise.
Indications can include an increase in the counters for runts, giants, and CRC
errors. If there is excessive noise, first find and remove the source of the noise, if
possible. Also, verify that the cable does not exceed the maximum cable length
and check the type of cable that is used. For copper cable, it is recommended
that you use at least Category 5.
■ If noise is not an issue, check for excessive collisions. If there are collisions or
late collisions, verify the duplex settings on both ends of the connection. Much
like the speed setting, the duplex setting is usually autonegotiated. If there does
appear to be a duplex mismatch, manually set the duplex on both connection
ends. It is recommended to use full-duplex if both sides support it.
In Figure 2-15, the attacker can capture the username and password of the adminis-
trator from the plaintext Telnet session.
Figure 2-16 shows the Wireshark view of an SSH session. The attacker can track the
session using the IP address of the administrator device.
However, in Figure 2-17, the username and password are encrypted.
To enable SSH on a Catalyst 2960 switch, the switch must be using a version of
the IOS software including cryptographic (encrypted) features and capabilities. In
Example 2-3, use the show version command on the switch to see which IOS the
switch is currently running, and verify that the IOS filename includes the combina-
tion “k9”, which indicates that it supports cryptographic (encrypted) features and
capabilities.
Note
To delete the RSA key pair, use the crypto key zeroize rsa global configuration mode com-
mand. After the RSA key pair is deleted, the SSH server is automatically disabled.
Interactive
Activity 2.2.1.2: Configure SSH
Graphic Go to the online course to use the Syntax Checker in the second graphic to config-
ure SSH on S1.
In Figure 2-19, the PC initiates an SSH connection to the SVI VLAN IP address of S1.
In Example 2-4 (and the related graphic in Figure 2-20), the user has been prompted
for a username and password. Using the configuration from the previous example,
the username admin and password ccna are entered. After entering the correct com-
bination, the user is connected through SSH to the CLI on the Catalyst 2960 switch.
Example 2-4 PuTTY Window Text for Remote Management SSH Connection
S1> enable
Password:
S1#
To display the version and configuration data for SSH on the device that you config-
ured as an SSH server, use the show ip ssh command. In the example, SSH version 2
is enabled. To check the SSH connections to the device, use the show ssh command
(see Figure 2-21).
In Figure 2-23, host B receives the frame and sends a reply to host A. The switch then
learns that the MAC address for host B is located on port 2 and records that informa-
tion into the MAC address table.
Host C also receives the frame from host A to host B, but because the destination
MAC address of that frame is host B, host C drops that frame.
As shown in Figure 2-24, any frame sent by host A (or any other host) to host B is
forwarded to port 2 of the switch and not broadcast out every port.
MAC address tables are limited in size. MAC flooding attacks make use of this limi-
tation to overwhelm the switch with fake source MAC addresses until the switch
MAC address table is full.
As shown in Figure 2-25, an attacker at host C can send frames with fake, randomly
generated source and destination MAC addresses to the switch. The switch updates
the MAC address table with the information in the fake frames. When the MAC
address table is full of fake MAC addresses, the switch enters into what is known as
fail-open mode. In this mode, the switch broadcasts all frames to all machines on the
network. As a result, the attacker can see all the frames.
Some network attack tools can generate up to 155,000 MAC entries on a switch per
minute. Depending on the switch, the maximum MAC address table size varies.
As shown in Figure 2-26, as long as the MAC address table on the switch remains
full, the switch broadcasts all received frames out of every port. In this example,
frames sent from host A to host B are also broadcast out of port 3 on the switch and
seen by the attacker at host C.
One way to mitigate MAC address table overflow attacks is to configure port
security.
DHCP starvation is often used before a DHCP spoofing attack to deny service to the
legitimate DHCP server, making it easier to introduce a fake DHCP server into the
network.
To mitigate DHCP attacks, use the DHCP snooping and port security features on the
Cisco Catalyst switches. These features are covered in a later topic.
It is recommended that you disable the use of CDP on devices or ports that do not
need to use it by using the no cdp run global configuration mode command. CDP
can be disabled on a per-port basis.
Telnet Attacks
The Telnet protocol is insecure and can be used by an attacker to gain remote access
to a Cisco network device. There are tools available that allow an attacker to launch a
brute force password-cracking attack against the vty lines on the switch.
accessing switch management functions. This can be combined with other direct
attacks on the network as part of a coordinated attempt to prevent the network
administrator from accessing core devices during the breach.
Vulnerabilities in the Telnet service that permit DoS attacks to occur are usually
addressed in security patches that are included in newer Cisco IOS revisions.
Note
It is a best practice to use SSH rather than Telnet for remote management connections.
These methods, illustrated in Figure 2-29, are only a starting point for security man-
agement. Organizations must remain vigilant at all times to defend against continu-
ally evolving threats. Use network security tools to measure the vulnerability of the
current network.
Catalyst 2960 switch has 24 ports and there are three Fast Ethernet connections in
use, it is good practice to disable the 21 unused ports. Navigate to each unused port
and issue the Cisco IOS shutdown command. If a port later needs to be reactivated,
it can be enabled with the no shutdown command. Figure 2-30 shows partial output
for this configuration.
The process of enabling and disabling ports can be time-consuming, but it enhances
security on the network and is well worth the effort.
DHCP traffic. From a DHCP snooping perspective, untrusted access ports should not
send any DHCP server messages.
How To Step 1. Enable DHCP snooping using the ip dhcp snooping global configuration
mode command.
Step 2. Enable DHCP snooping for specific VLANs using the ip dhcp snooping
vlan number command.
Step 3. Define ports as trusted at the interface level by defining the trusted ports
using the ip dhcp snooping trust command.
Step 4. (Optional) Limit the rate at which an attacker can continually send bogus
DHCP requests through untrusted ports to the DHCP server using the ip
dhcp snooping limit rate rate command.
■ Dynamic secure MAC addresses: MAC addresses that are dynamically learned
and stored only in the address table. MAC addresses configured in this way are
removed when the switch restarts.
■ Sticky secure MAC addresses: MAC addresses that can be dynamically learned
or manually configured, and then stored in the address table and added to the
running configuration.
An interface can be configured for one of three violation modes, specifying the
action to be taken if a violation occurs:
■ Protect: When the number of secure MAC addresses reaches the limit allowed
on the port, packets with unknown source addresses are dropped until a suffi-
cient number of secure MAC addresses are removed, or the number of maximum
allowable addresses is increased. There is no notification that a security violation
has occurred.
■ Restrict: When the number of secure MAC addresses reaches the limit allowed
on the port, packets with unknown source addresses are dropped until a suffi-
cient number of secure MAC addresses are removed, or the number of maximum
allowable addresses is increased. In this mode, there is a notification that a secu-
rity violation has occurred.
■ Shutdown: In this (default) violation mode, a port security violation causes the
interface to immediately become error-disabled and turns off the port LED. It
increments the violation counter. When a secure port is in the error-disabled
state, it can be brought out of this state by entering the shutdown and no shut-
down interface configuration mode commands.
Table 2-6 presents which kinds of data traffic are forwarded when one of the security
violation modes is configured on a port.
Protect No No No No
To change the violation mode on a switch port, use the switchport port-security
violation {protect | restrict | shutdown} interface configuration mode command.
Maximum number of 1
secure MAC addresses
Restrict Shutdown. The port shuts down when the maximum number of
secure MAC addresses is exceeded.
Figure 2-33 shows the Cisco IOS CLI commands needed to configure port security
on the Fast Ethernet F0/18 port on the S1 switch. Notice that the example does
not specify a violation mode. In this example, the violation mode is shutdown (the
default mode).
Figure 2-34 shows how to enable sticky secure MAC addresses for port security
on Fast Ethernet port 0/19 of switch S1. As stated earlier, the maximum number of
secure MAC addresses can be manually configured. In this example, the Cisco IOS
command syntax is used to set the maximum number of MAC addresses to 10 for
port 0/19. The violation mode is set to shutdown, by default.
The output shown in Example 2-6 shows the values for the sticky port security set-
tings. The maximum number of addresses is set to 10, as configured.
Note
The MAC address is identified as a sticky MAC address in Example 2-6.
Sticky MAC addresses are added to the MAC address table and to the running con-
figuration. Port security with sticky MAC addresses retains dynamically learned
MAC addresses during a link-down condition. If you enter the copy running-config
startup-config command, port security with sticky MAC addresses saves dynami-
cally learned MAC addresses in the startup config file and the port does not have to
learn addresses from ingress traffic after bootup or a restart. As shown in Example
2-7, the sticky MAC for PC2 has been added to the running configuration for S1.
Note
The port protocol and link status is changed to down.
The port LED will change to orange. The show interfaces command identifies the
port status as err-disabled (see Example 2-10). The output of the show port-security
interface command now shows the port status as secure-shutdown. Because the port
security violation mode is set to shutdown, the port with the security violation goes
to the error-disabled state.
The administrator should determine what caused the security violation before reen-
abling the port. If an unauthorized device is connected to a secure port, the port
should not be reenabled until the security threat is eliminated. To reenable the port,
use the shutdown interface configuration mode command (see Example 2-11). Then,
use the no shutdown interface configuration command to make the port operational.
To configure a device as having an NTP master clock to which peers can synchronize
themselves, use the ntp master [stratum] command in global configuration mode.
The stratum value is a number from 1 to 15 and indicates the NTP stratum number
that the system will claim. If the system is configured as an NTP master and no stra-
tum number is specified, it will default to stratum 8. If the NTP master cannot reach
any clock with a lower stratum number, the system will claim to be synchronized at
the configured stratum number, and other systems will be willing to synchronize to it
using NTP.
To display the status of NTP associations, use the show ntp associations command
in privileged EXEC mode. This command will indicate the IP address of any peer
devices that are synchronized to this peer, statically configured peers, and stratum
number. The show ntp status user EXEC command can be used to display such
information as the NTP synchronization status, the peer that the device is synchro-
nized to, and in which NTP strata the device is functioning. Example 2-12 displays
the verification of NTP on Router R2.
Summary (2.3)
Class Activity 2.3.1.1: Switch Trio
You are the network administrator for a small- to medium-sized business. Corporate
headquarters for your business has mandated that security must be implemented on
all switches in all offices. The memorandum delivered to you this morning states the
following:
“By Monday, April 18, 20xx, the first three ports of all configurable switches
located in all offices must be secured with MAC addresses—one address will be
reserved for the printer, one address will be reserved for the laptop in the office,
and one address will be reserved for the office server.
If a port’s security is breached, we ask that you shut it down until the reason for
the breach can be certified.
Please implement this policy no later than the date stated in this memorandum.
For questions, call 1.800.555.1212. Thank you. The Network Management Team.”
Work with a partner in the class and create a Packet Tracer example to test this new
security policy. After you have created your file, test it with at least one device to
ensure that it is operational or validated.
Save your work and be prepared to share it with the entire class.
When a Cisco LAN switch is first powered on, it goes through the following boot
sequence:
1. The switch loads a power-on self-test (POST) program stored in ROM. POST
checks the CPU subsystem. It tests the CPU, DRAM, and the portion of the flash
device that makes up the flash file system.
2. The switch loads the boot loader software. The boot loader is a small program
stored in ROM and is run immediately after POST successfully completes.
3. The boot loader performs low-level CPU initialization. It initializes the CPU reg-
isters, which control where physical memory is mapped, the quantity of memory,
and its speed.
4. The boot loader initializes the flash file system on the system board.
5. The boot loader locates and loads a default IOS operating system software image
into memory and hands control of the switch over to the IOS.
The specific Cisco IOS file that is loaded is specified by the BOOT environmental
variable. After the Cisco IOS is loaded, it uses the commands found in the startup
config file to initialize and configure the interfaces. If the Cisco IOS files are miss-
ing or damaged, the boot loader program can be used to reload or recover from the
problem.
The operational status of the switch is displayed by a series of LEDs on the front
panel. These LEDs display such things as port status, duplex, and speed.
An IP address is configured on the SVI of the management VLAN to allow for
remote configuration of the device. A default gateway belonging to the management
VLAN must be configured on the switch using the ip default-gateway command. If
the default gateway is not properly configured, remote management is not possible.
It is recommended that Secure Shell (SSH) be used to provide a secure (encrypted)
management connection to a remote device to prevent the sniffing of unencrypted
usernames and passwords, which is possible when using protocols such as Telnet.
One of the advantages of a switch is that it allows full-duplex communication
between devices, effectively doubling the communication rate. Although it is possi-
ble to specify the speed and duplex settings of a switch interface, it is recommended
that the switch be allowed to set these parameters automatically to avoid errors.
Switch port security is a requirement to prevent such attacks as MAC address flood-
ing and DHCP spoofing. Switch ports should be configured to allow only frames
with specific source MAC addresses to enter. Frames from unknown source MAC
addresses should be denied and cause the port to shut down to prevent further
attacks.
Port security is only one defense against network compromise. There are ten best
practices that represent the best insurance for a network:
■ Develop a written security policy for the organization.
■ Shut down unused services and ports.
■ Use strong passwords and change them often.
■ Control physical access to devices.
■ Avoid using standard insecure HTTP websites, especially for login screens.
Instead use the more secure HTTPS.
■ Perform backups and test the backed-up files on a regular basis.
■ Educate employees about social engineering attacks, and develop policies to vali-
date identities over the phone, through email, and in person.
■ Encrypt sensitive data and protect it with a strong password.
■ Implement security hardware and software, such as firewalls.
■ Keep IOS software up to date by installing security patches weekly or daily, if
possible.
These methods are only a starting point for security management. Organizations
must remain vigilant at all times to defend against continually evolving threats.
Practice
The following activities provide practice with the topics introduced in this chapter.
The Labs and Class Activities are available in the companion Switched Networks Lab
Manual (ISBN 978-1-58713-327-5). The Packet Tracer Activities PKA files are found
in the online course.
Class Activities
■ Class Activity 2.0.1.2: Stand by Me
■ Class Activity 2.3.1.1: Switch Trio
Labs
■ Lab 2.1.1.6: Configuring Basic Switch Settings
■ Lab 2.2.4.11: Configuring Switch Security Features
2. What advantage does SSH offer over Telnet when remotely connecting to a
device?
A. Encryption
B. More connection lines
C. Connection-oriented services
D. Username and password authentication
3. Which option correctly associates the Layer 2 security attack with the
description?
A. MAC address flooding: broadcast requests for IP addresses with spoofed
MAC addresses
B. DHCP starvation: using Cisco-proprietary protocols to gain information
about a switch
C. CDP attack: the attacker fills the switch MAC address table with invalid
MAC addresses
D. Telnet attack: using brute force password attacks to gain access to a switch
A. So that there can be remote connectivity to the switch through such pro-
grams as Telnet and ping
B. So that frames can be sent through the switch to the router
C. So that frames generated from workstations and destined for remote net-
works can pass to a higher level
D. So that other networks can be accessed from the command prompt of the
switch
9. What are the default settings for duplex and speed on Cisco Catalyst 2960 and
3560 switches?
10. What feature on Cisco Catalyst 2960 enables switch ports to work with either
crossover or straight-through cables?
11. A giant Ethernet frame is one that is greater than how many bytes?
13. Assume that a Cisco Catalyst switch has an image that supports SSH. Assume
that a host name and domain name are configured, that local authentication is
properly configured, and that the vty lines support all protocols. Which com-
mand is required to have a functional SSH configuration?
A. ip ssh version 2 in global configuration mode
B. crypto key generate rsa in global configuration mode
C. transport input ssh in line VTY configuration mode
D. login local in line vty configuration mode
E. ip domain-name <domain-name> in global configuration mode
15. A network administrator plugs a PC into a switch port. The LED for that port
changes to solid green. What statement best describes the current status of the
port?
A. There is a duplex mismatch error.
B. There is a link fault error. This port is unable to forward frames.
C. The port is operational and ready to transmit packets.
D. This port has been disabled by management and is unable to forward frames.
E. The flash memory is busy.
17. List three best practices for securing a network. (Several answers are possible.)
20. An attacker has bypassed physical security and was able to connect a laptop to
an Ethernet interface on a switch. If all the switch ports are configured with port
security and the violation mode is set to factory default, which action is taken
against the attacker?
A. Packets with unknown source addresses are dropped, and there is no notifica-
tion that a security violation has occurred.
B. Packets with unknown source addresses are dropped, and there is a notifica-
tion that a security violation has occurred.
C. Packets with unknown source addresses are dropped, and the interface
becomes error-disabled and turns off the port LED.
D. Packets with unknown source addresses are forwarded, and there is a notifi-
cation to the syslog server.