You are on page 1of 47

Network+ Guide to Networks

Eighth Edition

Subnets and VLANs

© 2019 Cengage. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part, except for use as
permitted in a license distributed with a certain product or service or otherwise on a password-protected website for
classroom use. 1
Objectives

• Differentiate between IPV4 and IPV6


• Explain how VLANs work and how they’re used

© 2019 Cengage. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part, except for use as permitted in a license
distributed with a certain product or service or otherwise on a password-protected website for classroom use.
Subnets in IPv6 (1 of 3)

• Subnetting in IPv6 is simpler than IPv4


• Classes not used
• Subnet masks not used
• Single IPv6 subnet is capable of supplying 18,446,744,073,709,551,616 I Pv6 addresses
• Subnetting helps administrators manage the enormous volume of IPv6
addresses
• IPv6 address commonly written as eight blocks of four hexadecimal characters:
• Last four blocks identify the interface
• First four blocks identify the network and serve as the network prefix (also called the
site prefix or global routing prefix)
• Fourth hexadecimal block in the site prefix can be altered to create subnets

© 2019 Cengage. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part, except for use as permitted in a license
distributed with a certain product or service or otherwise on a password-protected website for classroom use. 3
Subnets in IPv6 (2 of 3)

© 2019 Cengage. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part, except for use as permitted in a license
distributed with a certain product or service or otherwise on a password-protected website for classroom use. 4
Subnets in IPv6 (3 of 3)

© 2019 Cengage. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part, except for use as permitted in a license
distributed with a certain product or service or otherwise on a password-protected website for classroom use. 5
IPv4 and IPv6 Coexistence

The migration techniques can be divided into three categories:


Dual-stack, Tunnelling, and Translation.
Dual-stack

Dual-stack: Allows IPv4 and IPv6 to coexist on the same network.


Devices run both IPv4 and IPv6 protocol stacks simultaneously.
6
IPv4 and IPv6 Coexistence (cont.)

Tunnelling

Tunnelling: A method of transporting an IPv6 packet over an IPv4


network. The IPv6 packet is encapsulated inside an IPv4 packet.

7
IPv4 and IPv6 Coexistence (cont.)

Translation

Translation: The Network Address Translation 64 (NAT64) allows


IPv6-enabled devices to communicate with IPv4-enabled devices
using a translation technique similar to NAT for IPv4. An IPv6 packet
is translated to an IPv4 packet, and vice versa.

8
Hexadecimal Number System

• Hexadecimal is a base
sixteen system.
• Base 16 numbering system
uses the numbers 0 to 9 and
the letters A to F.
• Four bits (half of a byte) can
be represented with a single
hexadecimal value.

9
Hexadecimal Number System (cont.)

Look at the binary bit patterns


that match the decimal and
hexadecimal values

10
IPv6 Address Representation

• 128 bits in length and written as a string of hexadecimal values


• In IPv6, 4 bits represents a single hexadecimal digit, 32 hexadecimal value = IPv6
address

•2001:0DB8:0000:1111:0000:0000:0000:0200
•FE80:0000:0000:0000:0123:4567:89AB:CDEF

• Hextet used to refer to a segment of 16 bits or four hexadecimals


• Can be written in either lowercase or uppercase

11
IPv6 Address Representation (cont.)

12
Subnetting Using the Subnet ID

An IPv6 Network Space is subnetted to support hierarchical, logical design of


the network

13
IPV6 Subnet Allocation

14
Rule 1- Omitting Leading 0s

• The first rule to help reduce the notation of IPv6 addresses is any leading 0s
(zeros) in any 16-bit section or hextet can be omitted.
• 01AB can be represented as 1AB.
• 09F0 can be represented as 9F0.
• 0A00 can be represented as A00.
• 00AB can be represented as AB.

15
Rule 2 - Omitting All 0 Segments

• A double colon (::) can replace any single, contiguous string of one or more 16-
bit segments (hextets) consisting of all 0’s.
• Double colon (::) can only be used once within an address otherwise the
address will be ambiguous.
• Known as the compressed format.
• Incorrect address - 2001:0DB8::ABCD::1234.

16
Rule 2 - Omitting All 0 Segments (cont.)

Example #1

Example #2

17
IPv6 Prefix Length

• IPv6 does not use the dotted-decimal subnet mask notation


• Prefix length indicates the network portion of an IPv6 address using the
following format:
 IPv6 address/prefix length
 Prefix length can range from 0 to 128
 Typical prefix length is /64

18
IPv6 Address Types

There are three types of IPv6 addresses:


 Unicast
 Multicast
 Anycast.

Note: IPv6 does not have broadcast addresses.

19
IPv6 Unicast Addresses

Unicast
 Uniquely identifies an
interface on an IPv6-
enabled device.
 A packet sent to a unicast
address is received by the
interface that is assigned
that address.

20
IPv6 Unicast Addresses (cont.)

21
IPv6 Unicast Addresses (cont.)

Global Unicast
 Similar to a public IPv4 address
 Globally unique
 Internet routable addresses
 Can be configured statically or assigned dynamically
Link-local
 Used to communicate with other devices on the same local link
 Confined to a single link; not routable beyond the link

22
IPv6 Unicast Addresses (cont.)

Loopback
 Used by a host to send a packet to itself and cannot be assigned to a physical
interface.
 Ping an IPv6 loopback address to test the configuration of TCP/IP on the local host.
 All-0s except for the last bit, represented as ::1/128 or just ::1.
Unspecified Address
 All-0’s address represented as ::/128 or just ::
 Cannot be assigned to an interface and is only used as a source address.
 An unspecified address is used as a source address when the device does not yet have
a permanent IPv6 address or when the source of the packet is irrelevant to the
destination.

23
IPv6 Unicast Addresses (cont.)

Unique Local
 Similar to private addresses for IPv4.
 Used for local addressing within a site or between a limited number of sites.
 In the range of FC00::/7 to FDFF::/7.
IPv4 Embedded (not covered in this course)
 Used to help transition from IPv4 to IPv6.

24
IPv6 Link-Local Unicast Addresses

• Every IPv6-enabled network interface is REQUIRED to have a link-local


address
• Enables a device to communicate with other IPv6-enabled devices on the
same link and only on that link (subnet)
• FE80::/10 range, first 10 bits are 1111 1110 10xx xxxx
• 1111 1110 1000 0000 (FE80) - 1111 1110 1011 1111 (FEBF)

25
IPv6 Link-Local Unicast Addresses (cont.)

Packets with a
source or
destination link-local
address cannot be
routed beyond the
link from where the
packet originated.

26
Structure of an IPv6 Global Unicast Address

• IPv6 global unicast addresses are globally unique and routable on the IPv6
Internet
• Equivalent to public IPv4 addresses
• ICANN allocates IPv6 address blocks to the five RIRs(Regional Internet Registry)

27
Structure of an IPv6 Global Unicast Address (cont.)

Currently, only global unicast addresses with the first three bits of 001 or
2000::/3 are being assigned

28
Structure of an IPv6 Global Unicast Address (cont.)

A global unicast address has three parts: Global Routing Prefix, Subnet ID, and
Interface ID.

 Global Routing Prefix is the prefix or network portion of the address


assigned by the provider, such as an ISP, to a customer or site,
currently, RIR’s assign a /48 global routing prefix to customers.
 2001:0DB8:ACAD::/48 has a prefix that indicates that the first 48 bits
(2001:0DB8:ACAD) is the prefix or network portion.

29
VLANs (Virtual Local Area Networks) (1 of 2)

• VLAN (virtual local area network):


• Groups ports on a switch so that some of the local traffic on the switch is forced to go
through a router
• Limiting traffic to a smaller broadcast domain

© 2019 Cengage. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part, except for use as permitted in a license
distributed with a certain product or service or otherwise on a password-protected website for classroom use. 30
VLANs (Virtual Local Area Networks) (2 of 2)

• Reasons for using VLANs:


• Isolating connections with heavy or unpredictable traffic patterns
• Identifying groups of devices whose data should be given priority handling
• Containing groups of devices that rely on legacy protocols incompatible with the
majority of the network’s traffic
• Separating groups of users who need special security or network functions
• Configuring temporary networks
• Reducing the cost of networking equipment

© 2019 Cengage. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part, except for use as permitted in a license
distributed with a certain product or service or otherwise on a password-protected website for classroom use. 31
Managed Switches (1 of 8)

• Unmanaged switch
• Provides plug-and-play simplicity with minimal configuration
- Has no IP address assigned to it
• Managed switch:
• Can be configured via a command-line interface or a web-based management G UI
• Are usually assigned an IP address
• VLANS can only be implemented through managed switches
• Ports can be partitioned into groups

© 2019 Cengage. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part, except for use as permitted in a license
distributed with a certain product or service or otherwise on a password-protected website for classroom use. 32
Managed Switches (2 of 8)

© 2019 Cengage. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part, except for use as permitted in a license
distributed with a certain product or service or otherwise on a password-protected website for classroom use. 33
Managed Switches (3 of 8)

• Figure 8-18 shows how a normal Layer 2 switch operates

© 2019 Cengage. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part, except for use as permitted in a license
distributed with a certain product or service or otherwise on a password-protected website for classroom use. 34
Managed Switches (4 of 8)

• Figure 8-19 shows what happens when ports on a managed switch are
partitioned into two VLANs

© 2019 Cengage. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part, except for use as permitted in a license
distributed with a certain product or service or otherwise on a password-protected website for classroom use. 35
Managed Switches (5 of 8)

• VLAN ports do not have to be next to each other


• See Figure 8-20

© 2019 Cengage. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part, except for use as permitted in a license
distributed with a certain product or service or otherwise on a password-protected website for classroom use. 36
Managed Switches (8 of 8)

© 2019 Cengage. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part, except for use as permitted in a license
distributed with a certain product or service or otherwise on a password-protected website for classroom use. 37
Switch Ports and Trunks (1 of 3)

• A port on a switch is configured as either an access port or a trunk port:


• Access port—Used for connecting a single node
• Trunk port—Capable of managing traffic among multiple V LANs
• Trunk
• A single physical connection between switches through which many logical V LANs can
transmit and receive data
• Trunking protocols assign and interpret VLAN tags in Ethernet frames
• Cisco’s VTP (VLAN trunking protocol):
• The most popular protocol for exchanging VLAN information over trunks
• VTP allows changes to VLAN database on one switch, called the stack master, to be
communicated to all other switches in the network

© 2019 Cengage. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part, except for use as permitted in a license
distributed with a certain product or service or otherwise on a password-protected website for classroom use. 38
Switch Ports and Trunks (2 of 3)

© 2019 Cengage. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part, except for use as permitted in a license
distributed with a certain product or service or otherwise on a password-protected website for classroom use. 39
Switch Ports and Trunks (3 of 3)

© 2019 Cengage. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part, except for use as permitted in a license
distributed with a certain product or service or otherwise on a password-protected website for classroom use. 40
VLANs and Subnets

• Each VLAN is assigned its own subnet of IP addresses


• Sample network in Figure 8-22 (See on slide 36) is divided into three subnets
• Router sees three logical, virtual LANs connected to a single router port

© 2019 Cengage. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part, except for use as permitted in a license
distributed with a certain product or service or otherwise on a password-protected website for classroom use. 41
Types of VLANs

• VLAN types:
• Default VLAN—Typically preconfigured on a switch and initially includes all switch
ports
• Native VLAN—Receives all untagged frames from untagged ports
• Data VLAN—Carries user-generated traffic, such as email, web browsing, or database
updates
• Management VLAN—Can be used to provide administrative access to a switch
• Voice VLAN—Supports VoIP traffic

© 2019 Cengage. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part, except for use as permitted in a license
distributed with a certain product or service or otherwise on a password-protected website for classroom use. 42
View Configured VLANs (1 of 2)

• Once created maintain VLANs via switch software


• Figure 8-27 (See next slide) illustrates the result of a show vlan command on a
Cisco switch
• This command is used to list the current V LAN recognized by a switch

© 2019 Cengage. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part, except for use as permitted in a license
distributed with a certain product or service or otherwise on a password-protected website for classroom use. 43
View Configured VLANs (2 of 2)

© 2019 Cengage. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part, except for use as permitted in a license
distributed with a certain product or service or otherwise on a password-protected website for classroom use. 44
Troubleshoot and Secure VLANs (1 of 3)

• Common configuration errors:


• Incorrect port mode—Switch ports connected to endpoints should nearly always use
access mode
• Incorrect VLAN assignment—Can happen due to a variety of situations
• VLAN isolation—You can potentially cut off an entire group from the rest of the
network
• VLAN hopping:
- Occurs when an attacker generates transmissions that appear to belong to a protected
VLAN
- Crosses VLANs to access sensitive data or inject harmful software

© 2019 Cengage. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part, except for use as permitted in a license
distributed with a certain product or service or otherwise on a password-protected website for classroom use. 45
Troubleshoot and Secure VLANs (2 of 3)

• Two approaches to VLAN hopping:


• Double tagging—Hacker stacks VLAN tags in Ethernet frames
- First, legitimate tag is removed by switch
- Second, illegitimate tag is revealed, tricking switch into forwarding transmission on to a
restricted VLAN
• Switch spoofing—Attacker connects to a switch and makes the connection look to the
switch as if it’s a trunk line
- Hacker can feed his own VLAN traffic into that port and access VLANs throughout the network

© 2019 Cengage. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part, except for use as permitted in a license
distributed with a certain product or service or otherwise on a password-protected website for classroom use. 46
Troubleshoot and Secure VLANs (3 of 3)

• Mitigation efforts to reduce the risk of VLAN hopping:


• Don’t use the default VLAN
• Change the native VLAN to an unused VLAN ID
• Disable auto-trunking on switches that don’t need to support traffic from multiple V
LANs
• On switches that carry traffic from multiple VLANs, configure all ports as access
ports unless they are used as trunk ports
• Specify which VLANs are supported on each trunk instead of accepting a range of
all VLANs
• Use physical security methods such as door locks to restrict access to network
equipment

© 2019 Cengage. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part, except for use as permitted in a license
distributed with a certain product or service or otherwise on a password-protected website for classroom use. 47

You might also like