Escolar Documentos
Profissional Documentos
Cultura Documentos
Apresentao Alessandro Coneglian Bianchini exerce a funo de engenheiro na NEC Brasil, atuando na elaborao de projetos e implantao de VoIP, Wireless, Redes e Segurana da informao; formado em engenharia eltrica com nfase em telecomunicaes pela Escola de Engenharia Mau-SP, ps-graduado em segurana da informao pelo IBTA-SP e tambm ps-graduado em engenharia de rede e sistema de telecomunicaes pelo INATEL-MG; Possui certificaes de fabricantes como Cisco,Allied Telesyn, Fortinet e Vmware.
Certificaes
VCP 4 Vmware Certified Professional 4.0 VCP 3 Vmware Certified Professional 3.0 ITIL v3 Foundation CCNP - Cisco Certified Network Professional CCDP - Cisco Certified Design Professional CCVP - Cisco Certified Voice Professional CCSP - Cisco Certified Security Professional CCNA - Cisco Certified Network Associate CCDA - Cisco Certified Design Associate CAWDS Cisco Advanced Wireless Design Specialist CAWFS Cisco Advanced Wireless Field Specialist CISS - Cisco Information Security Specialist CIOSSS - Cisco IOS Security Specialist CFWS - Cisco Firewall Specialist CIPSS - Cisco IPS Specialist FCNSA- Fortinet Certified Network Security Administrator CAIR Certified Allied installation Router CAIS Certified Allied installation switch CASE Certified Allied system engineer 4011 Recognition - CNSS (Committee on National Security Systems) 4013 Recognition CNSS (Committee on National Security Systems)
3
AGENDA
Design Modelo Hierrquico Cisco Exemplos Configurao bsica do Switch Cisco VLANs VTP SPANNING TREE Etherchannel Segurana em Redes Ethernet Gerenciamento QoS
DESIGN REDE
Alta Disponibilidade (5-9s) Escalabilidade
PROTOCOLO ROTEAMENTO
Core Core Core Distribuio Por que usar: - Rpida convergncia - Contingncia: construo de caminhos redundantes - Eliminao de spanning-tree nestas camadas da rede
10
PROTOCOLO ROTEAMENTO
11
LAYER 2 ou 3 Distribution Catalyst 3560G-24T Catalyst 3560G-24T Catalyst 3560G-24T Catalyst 3560G-24T
1Gbps FO multimodo
Server Farm
12
REDUNDNCIA PREVISTA Switches Core Redundncia da placa supervisora e Fonte de Alimentao 2 pares de fibra em link agregation entre switches Core e Distribution 2 pares de fibra para Interligao entre Swiches Core em placas supervisoras distintas Tempo previsto de indisponibilidade da rede ser igual ao tempo para que a placa supervisora back-up assuma o controle, que de aproximadamente 3 segundos. Interligao entre switches Core e Distribution: HSRP ou protocolo roteamento Funcionamento da rede mesmo em caso de falha em um dos switches Core sem que haja interveno manual.
13
14
INTERFACE DE CONFIGURAO
15
16
17
18
19
20
HOSTNAME - EXEMPLO
21
Banner Login
banner login & *************************************************************************************** * * AVISO * * ACESSO PERMITIDO SOMENTE A PESSOAS AUTORIZADAS. * TODAS AS CONEXOES ESTAO SENDO MONITORADAS. * A UTILIZACAO INAPROPRIADA E/OU NAO AUTORIZADA PODE * RESULTAR EM PENALIDADES PREVISTAS EM LEI. * *************************************************************************************** * Warning * * ACCESS PERMITTED ONLY TO AUTHORIZED PEOPLE. * ALL ACTIVITIES AND CONNECTIONS ARE BEEN MONITORED. * INAPPROPRIATE OR NOT AUTHORIZED ACCESS MAY RESULT IN * LAW PENALTIES. **************************************************************************************** &
22
Variaveis
motd $(hostname) $(domain) $(line) $(line-desc) YES YES YES YES login YES YES YES YES exec YES YES YES YES
23
24
25
26
27
28
AUTENTICAO CENTRALIZADA
29
EXEMPLO DE CONFIGURAO
username ADMIN password senha1234 radius-server host 192.168.1.2 auth-port 1812 key <senha> radius-server host 192.168.1.3 auth-port 1812 key <senha> Ou tacacs-server host 192.168.1.4 single-connection key <senha> tacacs-server host <acs2> single-connection key <senha> aaa new-model aaa authentication login default group tacacs+ local aaa authorization exec default group tacacs+ local aaa accounting exec default group tacacs+ local line con 0 exec-timeout 0 0 login authentication default line vty 0 15 exec-timeout 3 0 login authentication default
30
31
32
33
34
35
36
VLANs - BENEFCIOS
Simplifica gerenciamento da rede Prov um maior nvel de segurana em relalao rede flat Flexibilidade e Escalabilidade Reduz dominio de Broadcast
37
38
39
VERIFICANDO VLANs
show interfaces show vlan
Nota: se a porta no esta associado a nenhuma VLAN por que est Em TRUNK
40
41
ISL: Proprietrio Cisco, encapsulamento de frame 802.1Q: No-proprietrio (Padro IEEE), adiciona campo (tag) no cabealho do frame (exceto para vlan nativa)
42
VLAN: RANGE
44
CONFIGURAO DE TRUNK
Trunk pode ser configurado manualmente ou via DTP (Dynamic Trunk Protocol) DTP negocia trunk na porta
45
Negociao do trunk via DTP ocorre quando habilitado nas duas pontas da conexo show dtp interface Para verificar negociao do trunk
46
47
48
49
50
51
TROUBLESHOOTING - TRUNK
- Configurao DTP inconsistente - Encapsulamento do trunk (ISL, 802.1Q) diferentes - Domnio de VTP diferentes - Capacidade de hardware das portas
52
53
Grupo de switches que trocam informaes de VLAN VLANs administrados centralmente por um determinado switch
54
PROTOCOLO VTP
Anncio com informao de configurao de VLAN Mantm consistncia de configurao de VLAN no domnio VTP Envia anncios somente em portas trunk
55
SERVER (default)
-Cria, modifica, apaga VLANs -Envia e encaminha anncios VTP -Sincroniza configurao de VLANs -Salva configurao na NVRAM
CLIENT
- No pode criar, modificar ou apagar VLANs - Encaminha anncios VTP - Sincroniza configurao de VLANs - No salva configurao na NVRAM
TRANSPARENT
- Cria, modifica, apaga VLANs - Encaminha anncios VTP - No sincroniza configurao de VLANs - Salva configurao na NVRAM
56
VTP PRUNING
VTP Pruning utiliza banda com maior eficincia Flooding de broadcast encaminhado somente para portas associadas quela vlan.
57
OPERAO DO VTP
Anncio VTP enviado em multicast VTP Server e Client so atualizados para o ltimo revision number Anncios VTP enviados a cada 5 minutos ou quando tiver alguma alterao
58
CONFIGURAO DE VTP
Configurando VTP:
vtp mode vtp domain vtp password
Verificando VTP:
show vtp status show vtp counters
59
CONFIGURANDO VTP
S1(config)#vtp mode server S1(config)#vtp domain cisco S1(config)#vtp password cisco S2(config)#vtp mode client S2(config)#vtp domain cisco S2(config)#vtp password cisco S3(config)#vtp mode transparent S3(config)#vtp domain cisco S3(config)#vtp password cisco
60
VERIFICANDO VTP
61
62
TROUBLESHOOTING VTP
Problemas comuns:
Updates no recebidos
- domnio de VTP e senha devem ser iguais - verso VTP deve ser compatvel com outros switches do domnio - deve haver pelo menos um VTP Server - checar se h conexo trunk com VTP Server
64
65
ip routing !Habilita roteamento no switch interface vlan10 ip address 10.1.1.1 255.255.255.0 interface vlan20 ip address 10.2.2.1 255.255.255.0 interface fa0/1 !Routed Port no switchport ip address 10.3.3.1 255.255.255.0 ip route 0.0.0.0 0.0.0.0 200.200.200.1
EXEMPLO DE ENDEREAMENTO
10 . X . Y. Z
Octeto que representa a filial Octeto que representa o VLAN ID Octeto que representa o Host
67
EXEMPLO DE ENDEREAMENTO
Filial Rede
10.1.10.0/24 10.1.11.0/24 10.1.12.0/24 10.1.13.0/24 10.1.14.0/24 10.1.15.0/24 10.1.16.0/24 10.1.17.0/24 10.2.10.0/24 10.2.11.0/24 10.2.12.0/24 10.2.13.0/24 10.2.14.0/24 10.2.15.0/24 10.2.16.0/24 10.2.17.0/24
Vlan
SERVIDOR GERENCIA RECEPCAO TECNICO ADMINISTRATIVO VOIP VIDEO VISITANTE SERVIDOR GERENCIA TECNICO SELECAO ADMINISTRATIVO VOIP VIDEO VISITANTE
68
RIO DEJANEIRO
FORTALEZA
DHCP
69
DHCP SERVER
Switch(config)#ip dhcp excluded-address 10.254.253.1 10.254.253.9 Switch(config)# ip dhcp pool DHCP-APS Switch(dhcp-config)# network 10.254.253.0 255.255.255.0 Switch(dhcp-config)# domain-name nec.com.br Switch(dhcp-config)# default-router 10.254.253.1 Switch(dhcp-config)# option 60 ascii "Cisco AP c1130" Switch(dhcp-config)# option 43 hex f108.0afe.fd04.0afe.fd06 Switch(dhcp-config)# lease 1
DHCP RELAY
Switch(config)#interface vlan 10 Switch(config-if)# ip address 192.168.1.0 255.255.255.0 Switch(config-if)# ip helper-address 10.10.10.1
70
IP HELPER-ADDRESS
Servio Time TACACS DNS BOOTP/DHCP Server BOOTP/DHCP Client TFTP NetBIOS name service NetBIOS datagram service Porta 37 49 53 67 68 69 137 138
Exemplo RTA(config-if)#ip helper-address 192.168.1.254 RTA(config-if)#exit RTA(config)#ip forward-protocol udp 517 RTA(config)#no ip forward-protocol udp 37 RTA(config)#no ip forward-protocol udp 49 RTA(config)#no ip forward-protocol udp 137 RTA(config)#no ip forward-protocol udp 138
71
ETHERCHANNEL
72
ETHERCHANNEL
Agregao lgica links Balanceamento Redundncia
73
ETHERCHANNEL
Apenas portas com caractersticas idnticas podem ser agregadas. Configurao: Automtica: PAgP: Port Aggregation Protocol (Cisco) LACP: Link Aggregation Control Protocol (IEEE 802.3) Manual: On: sem protocolo de negociao Usado apenas para compatibilidade entre switches que no suportam os protocolos de negociao.
74
ETHERCHANNEL
PAgP Port Aggregation Protocol
Protocolo proprietrio da cisco Agrupa automaticamente portas com as mesmas caractersiticas: Velocidade, modo duplex, native VLAN, VLAN range, trunking status. Porta Access devem pertencer a mesma VLAN Portas Trunk devem pertencer a mesma native VLAN O grupo de portas passado ao protocolo Spanning-Tree como sendo uma porta nica. Permite agregar at 8 portas.
75
ETHERCHANNEL
LACP - Link Aggregation Protocol
Padro IEEE 802.3ad Modos de operao: Passivo Similar ao modo auto PAgP Ativo Similar ao modo desirable PAgP Permite agregar at 16 portas, mas apenas 8 esto ativas num dado instante.
76
ETHERCHANNEL - CONFIGURAO
interface port-channel [channel-group-number] channel-protocol [pagp | lacp] channel-group 2 mode [active|auto|desirable|on|passive]
active auto desirable on passive Enable Enable Enable Enable Enable LACP unconditionally PAgP only if a PAgP device is detected PAgP unconditionally Etherchannel only LACP only if a LACP device is detected
Verificando Etherchannel:
show interfaces fastethernet 0/1 Show etherchannel 2 port-channel Show etherchannel 2 summary
77
interface Port-channel2 switchport access vlan 10 switchport mode access interface GigabitEthernet1/0 switchport access vlan 10 switchport mode access channel-group 2 mode active interface GigabitEthernet1/1 switchport access vlan 10 switchport mode access channel-group 2 mode active
78
interface Port-channel2 switchport mode trunk interface GigabitEthernet1/0 switchport mode trunk channel-group 2 mode active interface GigabitEthernet1/1 switchport mode trunk channel-group 2 mode active
79
interface port-channel 5 no switchport ip address 172.16.2.1 255.255.255.0 interface range gigabitethernet1/0 no ip address no switchport channel-group 5 mode active interface range gigabitethernet1/0 no ip address no switchport channel-group 5 mode active
80
SPANNING TREE
81
Escolha de um switch como Root e Construo de uma rvore como o menor caminho at o Root.
82
83
84
85
86
87
88
SPANNING-TREE
89
Core2 spanning-tree mode mst spanning-tree extend system-id spanning-tree mst configuration name Exemplo revision 1 instance 1 vlan 2, 10, 14 instance 2 vlan 12, 16,20 instance 3 vlan 13,15,17 instance 4 vlan 19,21,23 spanning-tree mst 0-2 root primary spanning-tree mst 3-4 root secondary
90
91
92
S2
SEGURANA NA LAN
Ataque MAC Address Flooding
Ferramentas de Hackers: macof (parte do dsniff)
Gera uma srie de endereos MAC falsos Quando a tabela CAM lota (32K entradas), o trfego enviado para todas as portas
DHCP Starvation
Ferramentas de Hackers : gobbler
Utiliza todo range de endereos do servidor DHCP
ARP Spoofing
Ferramentas de Hackers : ettercap, dsniff, arpspoof
Possibilita ataques tipo Man in the middle em Layer 2
93
S2
94
S2
95
S2
96
S2
97
Funcionamento do DHCP
DHCP Client DHCP Server
DHCP Discover (Broadcast) DHCP Offer (Unicast) DHCP Request (Broadcast) DHCP Ack (Unicast)
98
DHCP Client
DHCP Server
Gobbler
DHCP Discover (Broadcast) x (Tamanho do pool DHCP) DHCP Offer (Unicast) x (Tamanho do pool DHCP) DHCP Request (Broadcast) x (Tamanho do pool DHCP) DHCP Ack (Unicast) x (Tamanho do pool DHCP)
99
Servidor Falso
DHCP Discover (Broadcast) DHCP Offer (Unicast) Do servidor falso DHCP Request (Broadcast) DHCP Ack (Unicast) Do servidor falso, com Def GW alterado
100
DHCP SNOOPING
DHCP Snooping: Trust e Untrusted ports Untrusted Ports: No respondem s Requisies do DHCP Configurar DHCP snooping nos Uplinks com Servidor DHCP No configurar DHCP snooping em portas de usurios
101
102
103
104
ARP INSPECTION
105
ARP INSPECTION Switch(config)# ip arp inspection vlan 1 Switch(config)# interface Gigabitethernet1/0/1 Switch(config-if)# ip arp inspection trust
106
107
108
109
110
111
112
113
114
115
HSRP -
116
EXEMPLO DE CONFIGURAO
Core-1 interface vlan 10 description ADMINISTRACAO ip address 10.10.10.3 255.255.255.0 standby 1 ip 10.10.10.1 standby 1 priority 150 standby 1 preempt no shutdown interface vlan 11 description TECNICO ip address 10.10.11.3 255.255.255.0 standby 1 ip 10.10.11.1 standby 1 priority 140 standby 1 preempt no shutdown
Core-2 interface vlan 10 description ADMINISTRACAO ip address 10.10.10.2 255.255.255.0 standby 1 ip 10.10.10.1 standby 1 priority 140 standby 1 preempt no shutdown interface vlan 11 description TECNICO ip address 10.10.11.2 255.255.255.0 standby 1 ip 10.10.11.1 standby 1 priority 150 standby 1 preempt no shutdown
117
Servios de Identificao
RADIUS
User ok. Assign VLAN3 and ACL14 to port5.
802.1x
User ok?
Protege o acesso rede atravs Wiring Closet da autenticao do usurio via servidor de RADIUS, habilitando ou impedindo o acesso rede
118
Rede Cabeada
802.1x
120
802.1x (Cont.) Suplicante: a entidade que quer ter acesso Autenticador: a entidade que controla o acesso Servidor de autenticao: a entidade que autoriza ou nega o acesso
121
122
123
802.1x CONFIGURAO
124
3- Configurar atributos no servidor RADIUS. Servidor RADIUS dever retornar os seguintes atributos para o switch: [64] Tunnel-Type=VLAN [65] Tunnel-Medium-Type=IEEE 802 [81] Tunnel-Private-Group-ID= VLAN name ou VLAN ID
125
126
127
128
SSH
Switch(config)# ip domain-name nec.com.br Switch(config)# access-list 10 permit host 10.254.254.254 Switch(config)# crypto key generate rsa NEC_BRASIL 1024 Switch(config)# ip ssh version 2 Switch(config)# ip ssh time-out 60 Switch(config)# ip ssh authentication-retries 2 Switch(config)# line vty 0 15 Switch(config-line)# transport input ssh Switch(config-line)# access-class 10 in
129
Gerenciamento
130
SNMP V1 e V2c Switch(config)#access-list 90 permit 10.254.254.254 Switch(config)# access-list 90 remark CISCO-WORKS Switch(config)# snmp-server community snmpRW RW 90 Switch(config)# snmp-server community snmpRO RO 90 Switch(config)# snmp-server ifindex persist Switch(config)# snmp-server contact ramal Switch(config)# snmp-server location Cispro Switch(config)# snmp-server trap link ietf Switch(config)# snmp-server trap-source Vlan600 SNMP V3 autenticado Switch(config)# snmp-server group admsw v3 auth Switch(config)# snmp-server user admin admsw v3 auth md5 admpass SNMP V3 autenticado e criptografado Switch(config)# snmp-server group admsw v3 auth Switch(config)# snmp-server user admin admsw v3 auth md5 admpass priv des56 admpass
131
SNMP
SINCRONISMO DE DATA/HORA
132
NTP
Switch(config)#clock timezone GMT-3 Switch(config)# clock summer-time GMT-2 date Oct 19 2009 0:00 Feb 27 2010 0:00 ntp server 10.254.254.254 Com autenticao Switch(config)# ntp server 10.254.254.254 key 5 Switch(config)# ntp authenticate Switch(config)# ntp authentication-key 5 md5 1000
133
134
SYSLOG
switch(config)# logging 10.254.254.254
135
136
137
138
Bits de prioridade dos TAGs IEEE 802.1Q Campo CoS: Class of Service (IEEE 802.1p)
139
140
MECANISMO DE QoS
141
142
145
146
147
149
150
47 31 55 63 23 39
dscp
151
Controla a taxa no qual os quadros so retirados das filas SRR pode ser configurado como: SHAPED MODE: Cada fila de sada possui uma quantidade de banda limitada Mesmo que a banda de outras filas no esteja sendo utilizada, a banda de uma fila nunca excedida. Suportado somente na fila de sada. SHARED MODE: Garante um mnimo de banda para cada fila (em porcentagem) mas permite uma maior utilizao caso as outras filas estejam ociosas. Suportado nas filas de entrada e sada
152
Filas 1 e 2 Shaped Mode - Fila 1 pode usar no mximo 1/8 da banda (12,5%) - Fila 2 pode usar no mximo 1/4 da banda (25%) Filas 3 e 4 Shared Mode
153
Filas 1, 2, 3, 4 Shared Mode - Fila 1 pode usar no mnimo 10% da banda - Fila 2 pode usar no mnimo 20% da banda - Fila 3 pode usar no mnimo 30% da banda - Fila 4 pode usar no mnimo 40% da banda OBS: Shape tem precedncia sobre Share srr-queue bandwidth share 20 10 60 10 srr-queue bandwidth shape 20 0 0 10
154
155
156
WTD: as filas utilizam um algoritmo de descarte ponderado, baseado na classificao dos quadros:
Novos quadros com Cos 4-5 so descartados quando a fila atinge 60% da taxa de ocupao
157
158
159
160
161
162
163
164
165