Cisco Ethernet switch User Manual

Browse online or download User Manual for Networking Cisco Ethernet switch. Hacking Layer 2: Fun with Ethernet Switches

  • Download
  • Add to my manuals
  • Print
  • Page
    / 84
  • Table of contents
  • BOOKMARKS
  • Rated. / 5. Based on customer reviews
Page view 0
1
© 2002, Cisco Systems, Inc. All rights reserved.
l2-security-bh.ppt
Hacking Layer 2: Fun with
Ethernet Switches
Sean Convery, Cisco Systems
Page view 0
1 2 ... 84

Summary of Contents

Page 1 - Ethernet Switches

1© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptHacking Layer 2: Fun withEthernet SwitchesSean Convery, Cisco [email protected]

Page 2 - ¥ Summary and Case Study

101010© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptNormal CAM Behaviour 1/3MAC AMAC BMAC CPort 1Port 2Port 3A->BA->BB Unkno

Page 3

111111© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptNormal CAM Behaviour 2/3B->AA Is on Port 1Learn: B Is on Port 2B->AMAC A

Page 4

121212© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptNormal CAM Behaviour 3/3A->BA->BB Is on Port 2I Do Not SeeTraffic to B !

Page 5 - The Domino Effect

131313© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptCAM Overflow 1/3¥ Theoretical attack until May 1999¥ macof tool since May 1999

Page 6

141414© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptCAM Overflow 2/3X->?X Is on Port 3Y Is on Port 3Y->?MAC AMAC BMAC CPort

Page 7 - The Numbers from CSI/FBI

151515© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptCAM Overflow 3/3MAC AMAC BMAC CPort 1Port 2Port 3A->BA->BB UnknownÉFlood

Page 8 - MAC Attacks

161616© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptCatalyst CAM Tables¥ Catalyst switches use hash to place MAC in CAM table123..

Page 9 - MAC Address/CAM Table Review

171717© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptMAC Flooding Switches with Macof¥ [root@attack-lnx dsniff-2.3]# ./macof¥ b5:cf

Page 10 - Normal CAM Behaviour 1/3

181818© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptCAM Table Full!¥ Dsniff (macof) can generate 155,000 MAC entries on aswitch pe

Page 11 - Normal CAM Behaviour 2/3

191919© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptMAC Flooding Attack Mitigation¥ Port SecurityCapabilities are dependant on the

Page 12 - Normal CAM Behaviour 3/3

222© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptAgenda¥ Layer 2 Attack Landscape¥ Specific Attacks and Countermeasures (Ciscoand

Page 13 - CAM Overflow 1/3

202020© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.ppt¥ Beware management burden and performance hit¥ Lots of platform specific opti

Page 14 - CAM Overflow 2/3

21© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptVLAN ÒHoppingÓ Attacks

Page 15 - CAM Overflow 3/3

222222© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptTrunk Port Refresher¥ Trunk ports have access to all VLANs by default¥ Used to

Page 16 - Catalyst CAM Tables

232323© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptCisco Switching Control Protocols¥ Used to negotiate trunk status, exchange VL

Page 17

242424© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptFor the Detail Oriented: 802.3 w/802.2 SNAPIf you like this sort of thing: htt

Page 18 - CAM Table Full!

252525© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptDynamic Trunk Protocol (DTP)¥ What is DTP?Automates ISL/802.1Q trunkconfigurat

Page 19 - ¥ Port Security

262626© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptBasic VLAN Hopping Attack¥ A station can spoof as a switch with ISL or 802.1Q

Page 20 - Port Security Details

272727© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptDouble Encapsulated 802.1q VLANHopping Attack¥ Send double encapsulated 802.1Q

Page 21 - VLAN ÒHoppingÓ Attacks

282828© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptDouble Encap 802.1Q Ethereal CaptureOuter Tag, Attacker VLANInner Tag, Victim

Page 22 - Trunk Port Refresher

292929© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptDisabling Auto-Trunking¥ Defaults change depending on switch;always check:From

Page 23

333© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptCaveats¥ All attacks and mitigation techniques assumea switched Ethernet network

Page 24 - 0100.0ccc.cccc

303030© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptSecurity Best Practicesfor VLANs and Trunking¥ Always use a dedicated VLAN ID

Page 25 - Dynamic Trunk Protocol (DTP)

31© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptARP Attacks

Page 26 - Basic VLAN Hopping Attack

323232© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptARP Refresher¥ An ARP request messageshould be placed in a frameand broadcast

Page 27 - Hopping Attack

333333© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptGratuitous ARP¥ Gratuitous ARP is used by hosts to ÒannounceÓ theirIP address

Page 28 - Inner Tag, Victim VLAN

343434© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptMisuse of Gratuitous ARP¥ ARP has no security or ownership of IP or MACaddress

Page 29 - Disabling Auto-Trunking

353535© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptA Test in the Lab¥ Host X and Y will likely ignore the message unless theycurr

Page 30 - Security Best Practices

363636© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptDug Song, Author of dsniffDsniffÑA Collection of Tools to Do:¥ ARP spoofing¥ M

Page 31 - ARP Attacks

373737© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptC:\>testC:\>arp -d 10.1.1.1C:\>ping -n 1 10.1.1.1Pinging 10.1.1.1 wit

Page 32 - ARP Refresher

383838© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptMore on Arpspoof¥ All traffic now flows through machine runningdsniff in a hal

Page 33 - Gratuitous ARP

393939© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptSelective Sniffing¥ Once the dsniff box has started the arpspoofprocess, the m

Page 34 - Misuse of Gratuitous ARP

444© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptHost BWhy Worry about Layer 2 Security?Host APhysical LinksPhysical LinksMAC Addr

Page 35 - A Test in the Lab

404040© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptSSL/SSH Interception¥ Using dnsspoof all web sites can resolveto the dsniff ho

Page 36 - ¥ SSH/SSL interception

414141© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptSSL/SSH Interception¥ Using dsniff (webmitm) most SSL sessions canbe intercept

Page 37 - Arpspoof in Action

424242© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptSSL/SSH Interception¥ Upon inspectionthey will lookinvalid but theywould likel

Page 38 - More on Arpspoof

434343© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptDsniff evolves: Ettercap¥ Similar to dsniff though not as many protocolssuppor

Page 39 - Selective Sniffing

444444© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptCan It Get Much Easier?

Page 40 - SSL/SSH Interception

454545© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptPromiscuousPortPromiscuousPortCommunityÔAÕCommunityÔBÕIsolatedPortsPrimary VLA

Page 41

464646© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptAll PVLANs Are Not Created Equal¥ On CAT 4K, 6K they are called Private VLANs¥

Page 42

474747© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptPrivate VLAN Configuration¥ Available on: Cat 6K with CatOS 5.4(1); Cat 4K wit

Page 43 - Dsniff evolves: Ettercap

484848© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptCatOS PVLAN Configuration Examplebh-2002 (enable) set vlan 41 pvlan primaryVTP

Page 44 - Can It Get Much Easier?

494949© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptMore ARP Spoof Mitigation¥ Some IDS systems will watch for an unusuallyhigh am

Page 45

555© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptThe Domino Effect¥ Unfortunately this means if one layer is hacked, communication

Page 46 - Community Ports

50© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptSpanning Tree Attacks

Page 47 - Private VLAN Configuration

515151© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptSpanning Tree BasicsSTP is very simple. Messages are sent using Bridge Protoco

Page 48

525252© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptSpanning Tree Attacks and Methods¥ Standard 802.1d STP takes 30-45seconds to d

Page 49 - More ARP Spoof Mitigation

535353© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptSpanning Tree Attack Example 1/2¥ Send BPDU messages to becomeroot bridgeAttac

Page 50 - Spanning Tree Attacks

545454© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptBBFFSpanning Tree Attack Example 2/2¥ Send BPDU messages to becomeroot bridgeA

Page 51 - Spanning Tree Basics

555555© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptApplied Knowledge: Summary Attack¥ Goal: see traffic on the backbone butintere

Page 52

565656© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptSTP Attack Mitigation¥ DonÕt disable STP, introducing a loop would become anot

Page 53

575757© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptVLAN Trunking Protocol (VTP)¥ Used to distribute VLAN configuration among swit

Page 54

585858© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptPotential VTP Attacks¥ After becoming a trunkport, an attacker couldsend VTP m

Page 55

59© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptLayer 2 Port Authentication

Page 56 - STP Attack Mitigation

666© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptNetOPS/SecOPS, WhoÕs Problem Is It?¥ I handle securityissues at L3 andabove¥ I ha

Page 57 - VLAN Trunking Protocol (VTP)

606060© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptDynamic VLAN Access Ports¥ VLAN assignment based on MAC address or HTTP Auth (

Page 58 - Potential VTP Attacks

616161© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptVMPS ArchitectureVMPSDatabaseVMPSServerVMPSClientTFTPQueryReplyAll VMPS traffi

Page 59 - Layer 2 Port Authentication

626262© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptVMPS/VQP Attacks¥ No public domain tools today (Ethereal doesnÕt even decode)¥

Page 60 - Dynamic VLAN Access Ports

636363© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptVMPS/VQP Attack Mitigation¥ Consider sending VQP messages Out-of-Band (OOB)¥ I

Page 61 - VMPS Architecture

646464© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.ppt802.1x/EAP Switch Authentication¥ 802.1x and EAP (Extensible Authentication Pr

Page 62 - VMPS/VQP Attacks

656565© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.ppt802.1X Port AuthenticationRequest IDActual Authentication Conversation Is Betw

Page 63 - VMPS/VQP Attack Mitigation

66© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptOther Attacks

Page 64 - (TLS, MD5, OTP)

676767© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptCisco Discovery Protocol (CDP)¥ Runs at Layer 2 and allows Cisco devicesto cha

Page 65 - 802.1X Port Authentication

686868© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptCDP Attacks¥ Besides the information gathering benefit CDP offers anattacker,

Page 66 - Other Attacks

696969© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptDHCP Starvation Attacks¥ Anyplace where macof works, you can DoS anetwork by r

Page 67 - 0100.0ccc.cccc

777© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptThe Numbers from CSI/FBI

Page 68 - CDP Attacks

707070© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptDHCP Starvation Attack Mitigation¥ Same techniques that mitigate CAM flooding,

Page 69 - DHCP Starvation Attacks

717171© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptPrivate VLAN Attacks 1/2PVLANs WorkDrop PacketAttackerMac:A IP:1S:A1 D:B2Victi

Page 70

727272© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptAttackerMac:A IP:1VictimMac:B IP:2Promiscuous PortIsolated PortPrivate VLAN At

Page 71 - Private VLAN Attacks 1/2

737373© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptPVLAN Attack Mitigation¥ Setup ACL on ingress router port:IOS(config)#access-l

Page 72 - Private VLAN Attacks 2/2

747474© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptMulticast Brute-Force Failover Analysis¥ Send random Ethernet multicast frames

Page 73 - PVLAN Attack Mitigation

757575© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptRandom Frame Stress Attack¥ Send random frames to a switch interfaceattempting

Page 74 - Nice Try

767676© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptIP Telephony Considerations¥ Most IP Telephony deployments use a distinct VLAN

Page 75 - Random Frame Stress Attack

777777© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptSwitch Management¥ Management can be your weakest linkAll the great mitigation

Page 76 - IP Telephony Considerations

78© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptSummary and Case Study

Page 77 - Switch Management

797979© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptLayer 2 Security Best Practices 1/2¥ Manage switches in as secure a manner as

Page 78 - Summary and Case Study

8© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptMAC Attacks

Page 79

808080© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptLayer 2 Security Best Practices 2/2¥ Enable STP attack mitigation (BPDU Guard,

Page 80 - Your Own Security Policy

818181© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptA Relevant Case Study¥ Do you have a part of your network that looks like this

Page 81 - A Relevant Case Study

828282© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptA More Secure AlternativeOutsideInsideInternetInternalNew Security PerimeterNe

Page 82 - A More Secure Alternative

838383© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptLessons Learned¥ Carefully consider any time you mustcount on VLANs to operate

Page 83 - Lessons Learned

848484© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptFurther Reading¥ SAFE Blueprintshttp://www.cisco.com/go/safe¥ Improving Securi

Page 84 - Further Reading

999© 2002, Cisco Systems, Inc. All rights reserved.l2-security-bh.pptMAC Address/CAM Table Review1234.5678.9ABC1234.5678.9ABC0000.0cXX.XXXX0000.0cXX.X

Comments to this Manuals

No comments