New Site – Reverse Engineering Blog
As I learn more I will create content about Reverse engineering and vulnerability hunting. If this interests you please visit: https://0xa.day
Thanks
Network Engineering
As I learn more I will create content about Reverse engineering and vulnerability hunting. If this interests you please visit: https://0xa.day
Thanks
Powershell is a shell enviroment built using the .NET framework. Powershell scripts will have the suffix .ps1. Powershell
Windows 10 includes a feature that allows you to create a detailed report of the Wi-Fi connection history that can help to ease the process. The report provides information about each adapter, error events, as well as information about networks you have connected and session durations, which you can use to diagnose and solve connectivity related problems.
Start -> cmd -> right click and choose to run as admin
Commands
Go to the file path in windows file explorer and you can then view the report for the computers wireless interface.
monitor session <session number> source [interface/remote/vlan]
monitor session 1 source int fa 0/1
show monitor
monitor session 1 destination int fa 0/3
NTP is a layer 3 protocol. NTP is used for proper time, which is critical in networks. Making sure the network devices are all synchronized with the same time can help with management. Networking devices utilize time for several reasons:
clock set hour:minute:seconds day month year conf t ntp master [1 - 15]
conf t ntp server x.x.x.x
ntp authentication-key 1 md5 something ntp trusted-key 1
ntp authentication-key 1 md5 something ntp trusted-key 1 ntp authenticate ntp server x.x.x.x key 1
show ntp status show ntp associations show ntp stat | i in sync
**look for asterisk , clock is synced or synchronized references.**
**show ntp association detail will show authenticated**
hostname C-1-1 ! interface Loopback0 ip address 11.11.11.11 255.255.255.255 ! interface GigabitEthernet0/0 ip address 192.168.1.2 255.255.255.0 ip ospf 1 area 0 duplex auto speed auto media-type rj45 ! router ospf 1 router-id 11.11.11.11
hostname C-1-2 ! interface Loopback0 ip address 12.12.12.12 255.255.255.255 ! interface GigabitEthernet0/0 ip address 192.168.2.2 255.255.255.0 ip ospf 1 area 0 duplex auto speed auto media-type rj45 ! router ospf 1 router-id 12.12.12.12 !
hostname C-2-1 ! interface Loopback0 ip address 21.21.21.21 255.255.255.255 ! interface GigabitEthernet0/1 ip address 172.16.1.2 255.255.255.0 ip ospf 1 area 0 duplex auto speed auto media-type rj45 ! router ospf 1 router-id 21.21.21.21 !
hostname C-2-2 ! interface Loopback0 ip address 22.22.22.22 255.255.255.255 ! interface GigabitEthernet0/1 ip address 172.16.2.2 255.255.255.0 ip ospf 2 area 0 duplex auto speed auto media-type rj45 ! router ospf 2 router-id 22.22.22.22 !
hostname PE1 ! ip vrf Client1 rd 65000:1 route-target export 65000:1 route-target import 65000:1 ! ip vrf Client2 rd 65000:2 route-target export 65000:1 route-target import 65000:1 ! interface Loopback0 ip address 1.1.1.1 255.255.255.255 ! interface GigabitEthernet0/0 ip vrf forwarding Client1 ip address 192.168.1.1 255.255.255.0 ip ospf 1 area 0 duplex auto speed auto media-type rj45 ! interface GigabitEthernet0/1 ip vrf forwarding Client2 ip address 172.16.1.1 255.255.255.0 ip ospf 2 area 0 duplex auto speed auto media-type rj45 ! interface GigabitEthernet0/2 ip address 10.0.0.1 255.255.255.0 duplex auto speed auto media-type rj45 mpls ip ! router ospf 1 vrf Client1 router-id 192.168.1.1 redistribute bgp 65000 subnets ! router ospf 2 vrf Client2 router-id 172.16.1.1 redistribute bgp 65000 subnets ! router bgp 65000 bgp router-id 1.1.1.1 bgp log-neighbor-changes neighbor 2.2.2.2 remote-as 65000 neighbor 2.2.2.2 update-source Loopback0 ! address-family ipv4 neighbor 2.2.2.2 activate exit-address-family ! address-family vpnv4 neighbor 2.2.2.2 activate neighbor 2.2.2.2 send-community extended exit-address-family ! address-family ipv4 vrf Client1 redistribute ospf 1 exit-address-family ! address-family ipv4 vrf Client2 redistribute ospf 2 exit-address-family ! ip route 2.2.2.2 255.255.255.255 10.0.0.2
hostname PE2 ! ip vrf Client1 rd 65000:1 route-target export 65000:1 route-target import 65000:1 ! ip vrf Client2 rd 65000:2 route-target export 65000:2 route-target import 65000:2 ! interface Loopback0 ip address 2.2.2.2 255.255.255.255 ! interface GigabitEthernet0/0 ip vrf forwarding Client1 ip address 192.168.2.1 255.255.255.0 ip ospf 1 area 0 duplex auto speed auto media-type rj45 ! interface GigabitEthernet0/1 ip vrf forwarding Client2 ip address 172.16.2.1 255.255.255.0 ip ospf 2 area 0 duplex auto speed auto media-type rj45 ! interface GigabitEthernet0/2 ip address 10.0.0.2 255.255.255.0 duplex auto speed auto media-type rj45 mpls ip ! router ospf 1 vrf Client1 router-id 192.168.2.1 redistribute bgp 65000 subnets ! router ospf 2 vrf Client2 router-id 172.16.2.1 redistribute bgp 65000 subnets ! router bgp 65000 bgp router-id 2.2.2.2 bgp log-neighbor-changes neighbor 1.1.1.1 remote-as 65000 neighbor 1.1.1.1 update-source Loopback0 ! address-family ipv4 neighbor 1.1.1.1 activate exit-address-family ! address-family vpnv4 neighbor 1.1.1.1 activate neighbor 1.1.1.1 send-community extended exit-address-family ! address-family ipv4 vrf Client1 redistribute ospf 1 exit-address-family ! address-family ipv4 vrf Client2 redistribute ospf 2 exit-address-family ! ip route 1.1.1.1 255.255.255.255 10.0.0.1
NOTE: THIS LAB IS NOT COMPLETE IT IS SETUP SO BGP GOES DOWN DUE TO AN ISSUE WITH KEEP ALIVES. EVERY 3 MINUTES BGP WILL GO DOWN AND THEN THE DYNAMIC ROUTING PROTOCOL WILL TAKE PLACE. AFTER THIS BGP WILL COME UP AGAIN FOR ANOTHER 3 MINUTES AND KEEP REPEATING. THIS IS AN EXAMPLE OF WHY YOU USE STATIC ROUTING ACROSS EXTERNAL PEERS. THERE ARE OTHER SOLUTIONS..FIND THEM!
vIOS1#sh runn Building configuration… Current configuration : 3589 bytes ! ! Last configuration change at 15:13:59 UTC Sat Mar 13 2021 ! version 15.6 service timestamps debug datetime msec service timestamps log datetime msec no service password-encryption ! hostname vIOS1 ! boot-start-marker boot-end-marker ! ! ! no aaa new-model ethernet lmi ce ! ! ! mmi polling-interval 60 no mmi auto-configure no mmi pvc mmi snmp-timeout 180 ! ! ! ! ! ! ! ! ! ! ! ip cef no ipv6 cef ! multilink bundle-name authenticated ! ! ! ! ! redundancy ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! interface Loopback0 ip address 192.168.0.1 255.255.255.255 ip ospf 1 area 0 ! interface GigabitEthernet0/0 ip address 192.168.69.1 255.255.255.0 duplex auto speed auto media-type rj45 ! interface GigabitEthernet0/1 no ip address shutdown duplex auto speed auto media-type rj45 ! interface GigabitEthernet0/2 ip address 192.168.26.1 255.255.255.0 ip ospf 1 area 0 duplex auto speed auto media-type rj45 ! interface GigabitEthernet0/3 no ip address shutdown duplex auto speed auto media-type rj45 ! ! router eigrp 69 network 192.168.0.0 network 192.168.69.0 ! router ospf 1 ! router bgp 600 bgp log-neighbor-changes neighbor 192.168.0.2 remote-as 900 neighbor 192.168.0.2 ebgp-multihop 255 neighbor 192.168.0.2 update-source Loopback0 neighbor 192.168.0.4 remote-as 600 neighbor 192.168.0.4 update-source Loopback0 ! address-family ipv4 neighbor 192.168.0.2 activate neighbor 192.168.0.2 send-community neighbor 192.168.0.4 activate neighbor 192.168.0.4 send-community exit-address-family ! ip forward-protocol nd ! ip bgp-community new-format ! no ip http server no ip http secure-server !
vIOS2#sh runn Building configuration… Current configuration : 3368 bytes ! ! Last configuration change at 15:19:15 UTC Sat Mar 13 2021 ! version 15.6 service timestamps debug datetime msec service timestamps log datetime msec no service password-encryption ! hostname vIOS2 ! boot-start-marker boot-end-marker ! ! ! no aaa new-model ethernet lmi ce ! ! ! mmi polling-interval 60 no mmi auto-configure no mmi pvc mmi snmp-timeout 180 ! ! ! ! ! ! ! ! ! ! ! ip cef no ipv6 cef ! multilink bundle-name authenticated ! ! ! ! ! redundancy ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! interface Loopback0 ip address 192.168.0.2 255.255.255.255 ! interface GigabitEthernet0/0 ip address 192.168.69.2 255.255.255.0 duplex auto speed auto media-type rj45 ! interface GigabitEthernet0/1 no ip address shutdown duplex auto speed auto media-type rj45 ! interface GigabitEthernet0/2 no ip address shutdown duplex auto speed auto media-type rj45 ! interface GigabitEthernet0/3 no ip address shutdown duplex auto speed auto media-type rj45 ! ! router eigrp 69 network 192.168.0.0 network 192.168.69.0 ! router bgp 900 bgp log-neighbor-changes neighbor 192.168.0.1 remote-as 600 neighbor 192.168.0.1 ebgp-multihop 255 ! address-family ipv4 network 192.168.0.2 mask 255.255.255.255 neighbor 192.168.0.1 activate neighbor 192.168.0.1 send-community exit-address-family ! ip forward-protocol nd ! ip bgp-community new-format ! no ip http server no ip http secure-server
vIOS4#sh runn Building configuration… Current configuration : 3363 bytes ! ! Last configuration change at 15:18:58 UTC Sat Mar 13 2021 ! version 15.6 service timestamps debug datetime msec service timestamps log datetime msec no service password-encryption ! hostname vIOS4 ! boot-start-marker boot-end-marker ! ! ! no aaa new-model ethernet lmi ce ! ! ! mmi polling-interval 60 no mmi auto-configure no mmi pvc mmi snmp-timeout 180 ! ! ! ! ! ! ! ! ! ! ! ip cef no ipv6 cef ! multilink bundle-name authenticated ! ! ! ! ! redundancy ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! interface Loopback0 ip address 192.168.0.4 255.255.255.255 ip ospf 1 area 0 ! interface GigabitEthernet0/0 no ip address shutdown duplex auto speed auto media-type rj45 ! interface GigabitEthernet0/1 no ip address shutdown duplex auto speed auto media-type rj45 ! interface GigabitEthernet0/2 ip address 192.168.26.2 255.255.255.0 ip ospf 1 area 0 duplex auto speed auto media-type rj45 ! interface GigabitEthernet0/3 no ip address shutdown duplex auto speed auto media-type rj45 ! router ospf 1 ! router bgp 600 bgp log-neighbor-changes neighbor 192.168.0.1 remote-as 600 neighbor 192.168.0.1 update-source Loopback0 ! address-family ipv4 network 192.168.0.4 mask 255.255.255.255 neighbor 192.168.0.1 activate neighbor 192.168.0.1 send-community exit-address-family ! ip forward-protocol nd ! ip bgp-community new-format ! no ip http server no ip http secure-server
Root bridge: The root bridge is the most important switch in the Layer 2 topology.
Bridge protocol data unit (BPDU): This network packet is used for network switches to identify a hierarchy and notify of changes in the topology.
Two Types of BPDUs:
Max age: This is the maximum length of time that passes before a bridge port saves its BPDU information.
Hello time: time that a BPDU is advertised out of a port.
Forward delay: time that a port stays in a listening and learning state.
SW-01#sh runn Building configuration… Current configuration : 3810 bytes ! ! Last configuration change at 19:53:21 UTC Sat Mar 13 2021 ! version 15.2 service timestamps debug datetime msec service timestamps log datetime msec no service password-encryption service compress-config ! hostname SW-01 ! boot-start-marker boot-end-marker ! ! ! no aaa new-model ! ! ! ! ! ! ! ! ip cef no ipv6 cef ! ! errdisable recovery cause bpduguard errdisable recovery interval 30 ! spanning-tree mode rapid-pvst spanning-tree extend system-id ! vlan internal allocation policy ascending ! ! ! ! ! ! ! ! ! ! ! ! ! ! interface GigabitEthernet0/0 switchport trunk encapsulation dot1q switchport trunk native vlan 666 switchport mode trunk media-type rj45 negotiation auto ! interface GigabitEthernet0/1 switchport trunk encapsulation dot1q switchport trunk native vlan 666 switchport mode trunk media-type rj45 negotiation auto ! interface GigabitEthernet0/2 switchport trunk encapsulation dot1q switchport trunk native vlan 666 switchport mode trunk media-type rj45 negotiation auto ! interface GigabitEthernet0/3 description SHUTDOWN-NO-USERS switchport access vlan 999 switchport mode access shutdown media-type rj45 negotiation auto ! interface GigabitEthernet1/0 description SHUTDOWN-NO-USERS switchport access vlan 999 switchport mode access shutdown media-type rj45 negotiation auto ! interface GigabitEthernet1/1 description SHUTDOWN-NO-USERS switchport access vlan 999 switchport mode access shutdown media-type rj45 negotiation auto ! interface GigabitEthernet1/2 description SHUTDOWN-NO-USERS switchport access vlan 999 switchport mode access shutdown media-type rj45 negotiation auto ! interface GigabitEthernet1/3 description ACCESS-WIRED switchport access vlan 10 switchport mode access media-type rj45 negotiation auto spanning-tree portfast edge spanning-tree bpduguard enable ! ip forward-protocol nd ! no ip http server no ip http secure-server ! ! ! ! ! ! control-plane ! line con 0 line aux 0 line vty 0 4 ! ! end
SW-02#sh runn Building configuration… Current configuration : 3810 bytes ! ! Last configuration change at 19:53:22 UTC Sat Mar 13 2021 ! version 15.2 service timestamps debug datetime msec service timestamps log datetime msec no service password-encryption service compress-config ! hostname SW-02 ! boot-start-marker boot-end-marker ! ! ! no aaa new-model ! ! ! ! ! ! ! ! ip cef no ipv6 cef ! ! errdisable recovery cause bpduguard errdisable recovery interval 30 ! spanning-tree mode rapid-pvst spanning-tree extend system-id ! vlan internal allocation policy ascending ! ! ! ! ! ! ! ! ! ! ! ! ! ! interface GigabitEthernet0/0 switchport trunk encapsulation dot1q switchport trunk native vlan 666 switchport mode trunk media-type rj45 negotiation auto ! interface GigabitEthernet0/1 switchport trunk encapsulation dot1q switchport trunk native vlan 666 switchport mode trunk media-type rj45 negotiation auto ! interface GigabitEthernet0/2 switchport trunk encapsulation dot1q switchport trunk native vlan 666 switchport mode trunk media-type rj45 negotiation auto ! interface GigabitEthernet0/3 description SHUTDOWN-NO-USERS switchport access vlan 999 switchport mode access shutdown media-type rj45 negotiation auto ! interface GigabitEthernet1/0 description SHUTDOWN-NO-USERS switchport access vlan 999 switchport mode access shutdown media-type rj45 negotiation auto ! interface GigabitEthernet1/1 description SHUTDOWN-NO-USERS switchport access vlan 999 switchport mode access shutdown media-type rj45 negotiation auto ! interface GigabitEthernet1/2 description SHUTDOWN-NO-USERS switchport access vlan 999 switchport mode access shutdown media-type rj45 negotiation auto ! interface GigabitEthernet1/3 description ACCESS-WIRED switchport access vlan 10 switchport mode access media-type rj45 negotiation auto spanning-tree portfast edge spanning-tree bpduguard enable ! ip forward-protocol nd ! no ip http server no ip http secure-server ! ! ! ! ! ! control-plane ! line con 0 line aux 0 line vty 0 4 ! ! end SW-02#
SW-03#sh runn Building configuration… Current configuration : 3443 bytes ! ! Last configuration change at 19:53:38 UTC Sat Mar 13 2021 ! version 15.2 service timestamps debug datetime msec service timestamps log datetime msec no service password-encryption service compress-config ! hostname SW-03 ! boot-start-marker boot-end-marker ! ! ! no aaa new-model ! ! ! ! ! ! ! ! ip cef no ipv6 cef ! ! ! spanning-tree mode rapid-pvst spanning-tree extend system-id spanning-tree vlan 1-4094 priority 0 ! vlan internal allocation policy ascending ! ! ! ! ! ! ! ! ! ! ! ! ! ! interface GigabitEthernet0/0 switchport trunk encapsulation dot1q switchport trunk native vlan 666 switchport mode trunk media-type rj45 negotiation auto ! interface GigabitEthernet0/1 switchport trunk encapsulation dot1q switchport trunk native vlan 666 switchport mode trunk media-type rj45 negotiation auto spanning-tree guard root ! interface GigabitEthernet0/2 switchport trunk encapsulation dot1q switchport trunk native vlan 666 switchport mode trunk media-type rj45 negotiation auto spanning-tree guard root ! interface GigabitEthernet0/3 switchport trunk encapsulation dot1q switchport trunk native vlan 666 switchport mode trunk media-type rj45 negotiation auto ! interface GigabitEthernet1/0 media-type rj45 negotiation auto ! interface GigabitEthernet1/1 media-type rj45 negotiation auto ! interface GigabitEthernet1/2 media-type rj45 negotiation auto ! interface GigabitEthernet1/3 media-type rj45 negotiation auto ! ip forward-protocol nd ! no ip http server no ip http secure-server ! ! ! ! ! ! control-plane ! line con 0 line aux 0 line vty 0 4 ! ! end SW-03#
SW-04#sh runn Building configuration… Current configuration : 3446 bytes ! ! Last configuration change at 19:53:44 UTC Sat Mar 13 2021 ! version 15.2 service timestamps debug datetime msec service timestamps log datetime msec no service password-encryption service compress-config ! hostname SW-04 ! boot-start-marker boot-end-marker ! ! ! no aaa new-model ! ! ! ! ! ! ! ! ip cef no ipv6 cef ! ! ! spanning-tree mode rapid-pvst spanning-tree extend system-id spanning-tree vlan 1-4094 priority 4096 ! vlan internal allocation policy ascending ! ! ! ! ! ! ! ! ! ! ! ! ! ! interface GigabitEthernet0/0 switchport trunk encapsulation dot1q switchport trunk native vlan 666 switchport mode trunk media-type rj45 negotiation auto ! interface GigabitEthernet0/1 switchport trunk encapsulation dot1q switchport trunk native vlan 666 switchport mode trunk media-type rj45 negotiation auto spanning-tree guard root ! interface GigabitEthernet0/2 switchport trunk encapsulation dot1q switchport trunk native vlan 666 switchport mode trunk media-type rj45 negotiation auto spanning-tree guard root ! interface GigabitEthernet0/3 switchport trunk encapsulation dot1q switchport trunk native vlan 666 switchport mode trunk media-type rj45 negotiation auto ! interface GigabitEthernet1/0 media-type rj45 negotiation auto ! interface GigabitEthernet1/1 media-type rj45 negotiation auto ! interface GigabitEthernet1/2 media-type rj45 negotiation auto ! interface GigabitEthernet1/3 media-type rj45 negotiation auto ! ip forward-protocol nd ! no ip http server no ip http secure-server ! ! ! ! ! ! control-plane ! line con 0 line aux 0 line vty 0 4 ! ! end
In order to understand Virtual Port Channels we must know what a Port-Channel is. A port channel provides a way to aggregate (bond) multiple interfaces together. Traffic is then load balanced across each of the connections.
Though Port-Channels are great, the problem is that all links within the “bundle” must be connected to the same switch.