Sunday, July 23, 2023

PowerShell 010 - Powershell Functions and Logic

Powershell Functions and Logic

Making your own functions are a great way to invoke your own scripts in a simple, easy to use way.




You can use logic to build out functions with more complex capabilities. A few examples are:

foreach ($var in $vars) { $script }
Runs $script for each object on a list.

if ($true) { $script }
elseif ($var -eq $false) { $script }
else { $script }
If and elseif check if the given criteria is met and run the script if it is, otherwise will move on. Else will run the script when none of the previous criteria was met.

for ($i = 0; $i -eq 3; $i += 1) { $script }
Run $script for a set amount of loops.

try { $script }
catch { $script }
finally { $script }
Try $script, if it has an error it will run catch $script, then it will run finally $script no matter what.

return $var
Ends a script or function and returns $var

Network+ 015 - 3.2 Organizational Documents and Policies

3.0 Networking Operations

3.2 Organizational Documents and Policies


Plans and Procedures
Change Management
- Details how often changes can be made, for how long, the process to implement change, and fall back procedures if things don’t go well.

Incident Response Plan - Documented procedures and responses to different incidents. Should include disaster recovery plans for many different types of disasters.

Business Continuity Plan - A plan to continue business functions during disaster/during transition to recovery. May require non-technical solutions, and should be tested to ensure reliability.

System Life Cycle - Resource procurement and decommissioning process. Data destruction/preservation plan. Disposal process.

Standard Operating Procedures (SOP) - Process for when a device fails or goes down. Contact info for facilities issues. Keep online and offline; manual for what to do and who to contact for normal issues.


Hardening and Security Policies
Password Policy
- Password requirements to ensure password strength

Acceptable Use Policy - Documentation for acceptable uses and what is a misuse of an organization’s technology.

Bring Your Own Device (BYOD) Policy - Requirements for using personal devices on an org’s network often including MDM (mobile devices mgmt) policy to track and control data/data loss.

Remote Access Policy - Security requirements that should be followed before accessing an org’s network remotely. Can be applied to remote employees or 3rd party vendors.

On-boarding and Off-boarding Policy - Process details for bringing a new person on to a team, to ensure they get all required resources, and to ensure resource removal when they leave the team.

Security Policy - Documented details of process and procedures related to IT security.

Data Loss Policy (DLP)
- Designed to look for sensitive data and block it from transferring across the network.


Common Documentation
Physical Network Diagram
- Physical map of how data travels the network through various devices.

    Floor Plan - Physical layout over a map of the location, includes wiring, access points, port labels, wireless coverage.

    Rack Diagram - Documentation for where network devices are in a rack and how their wires are connected.

    Intermediate/Main Distribution Frame (IDF/MDF) Documentation
- Termination of wiring for internal and external connections, good testing location, mdf will be with the data center and idf will be a middle point between mdf and endpoints.

Logical Network Diagram - Logical abstraction of a network map, high-level overview for data flows.

Wiring Diagram - ANSI/TIA 606 wire labeling standard, best practices, port labeling, and documentation of cabling.

Site Survey Report - Determine existing wireless setup, identify APs, existing external frequencies, plan for recurring site surveys to document changes over time, heat maps to show wireless coverage.

Audit and Assessment Report - Validate existing policies are being followed, can be internal or external, sometimes a legal requirement.

Baseline Configurations
- Track and record past performance to compare against current performance to see changes and trends.


Common Agreements
Non-Disclosure Agreement (NDA)
- A signed agreement between parties to keep information confidential; usually comes with penalties for breaking the agreement. Used to protect business activities, trade secrets, etc. Sometimes unilateral (only one party must keep the secret).

Service-Level Agreement (SLA)
- Documents the minimum requirements agreed to for services such as uptime and response time. Documents expectations between multiple parties; usually formal and signed.

Memorandum of Understanding (MOU) - Letter of intent for services, might include confidential info not to be shared, but not usually a formally signed document.

Network+ 014 - 3.1 Network Monitoring, Statistics, and Sensors

3.0 Networking Operations

3.1 Network Monitoring, Statistics, and Sensors


Performance metrics/sensors
Device/chassis
    Temperature - Monitor trend vs baseline
    CPU usage - Monitor performance
     Memory - Monitor usage

Network metrics
    Bandwidth - Monitor utilization of the network
    Latency - Monitor network speed
    Jitter - Monitor network consistency


SNMP - Simple Network Message Protocol, used to collect data on network changes/status. V1/2 sends data unencrypted, v3 sends data encrypted and has other security features

    Traps - Sends a notification alert if a specified metric threshold is met
    Object Identifiers (OIDs) - Queryable data within a MIB
    Management Information Bases (MIBs) - Database that stores device network data


Network Device Logs
Log Reviews
    Traffic Logs
- Data traffic flows, summaries, very detailed for each device on the network
    Audit Logs - Event details, what and when things happened
    Syslog - Protocol to send data to a centralized, consolidated log receiver, integrates into the SIEM

Logging levels/Severity levels - Can be used for alert prioritization or as a filter for queries.


Interface statistics/status
    Link State (up/down)
- If an interface is active or not
    Speed/Duplex - Check for speed match, errors could
    Send/Receive Traffic - Errors could indicate a bandwidth issue
    Cyclic Redundancy Checks (CRCs) - Error checking for unintended changes/data corruption
    Protocol Packet and Byte Counts - Data/Packets sent/received


Interface Errors or Alerts
    CRC Errors
- Data corruption errors
    Giants - Frames that are more than 1518 bytes, indicative of interface errors/collisions
    Runts - Frames that are less than 64 bytes, indicative of a collision
    Encapsulation Errors - Expected frame mismatch for two switches (802.1Q is standard, ISL is legacy)


Environmental Factors and Sensors
    Temperature
- Devices need constant cooling
    Humidity - High humidity could create condensation, low humidity can create static discharges
    Electrical - Circuit load, monitor electrical system, voltage, etc.
    Flooding - Water/flood monitoring to alert about potential hardware damage


Baselines - Normal trends over time used to compare against live data

NetFlow Data - Collects all network traffic flows/statistics, uses probes and collectors

Uptime/Downtime - Summary of availability, check vendor/3rd party status pages

Monday, May 8, 2023

Network+ 013 - 2.4 Wireless Standards and Technologies

2.0 Networking Implementations

2.4 Wireless Standards and Technologies


802.11 Standards

    a - 5 GHz, 54 mbps, 20 MHz bandwidth

    b - 2.4 GHz, 11 mbps, 22 MHz bandwidth

    g - 2.4 GHz, 54 mbps, 20 MHz bandwidth

    n (WiFi 4) - 2.4 or 5 GHz, 150 mbps/channel, MIMO (Multi-In, Multi-Out), 4 streams
            20, 40, 80 MHz bandwidth

    ac (WiFi 5) - 5 GHz, 867 mbps/channel, channel bonding, Multi-user MIMO, 8 streams
            20, 40, 80, 80+80, 160 MHz bandwidth

    ax (WiFi 6) - 4 and 5 GHz, 1.2 gbps/channel, channel bonding, MU-MIMO, 8 streams
            20, 40, 80, 80+80, 160 MHz bandwidth


Frequencies and range
    2.4 GHz - 20 MHz channels: 1, 6, 11, between 2,412 - 2482 MHz bandwidth

    5 GHz - 20, 40, 80, 160 MHz, many channels


Channels - Designated frequencies assigned by the IEEE

    Regulatory Impacts - Legal restrictions on specific channels/frequencies


Channel Bonding - Combining channels together to create a wider frequency range.


Service Set Identifier (SSID) - Wireless broadcast connection name

    Basic Service Set (BSSID) - Wireless Access Point (WAP) physical address (similar to MAC).

    Extended Service Set (ESSID) - Multiple WAPs setup to extend the coverage of a wireless signal.

    Independent Basic Service Set (Ad-hoc, IBSS)
- Direct communication between devices without using a WAP, often used as an unplanned, temporary setup.

    Roaming - Auto switching between WAPs to maintain network connectivity.


Antenna Types
    Omni - Signal distributed evenly in each direction.

    Directional - Signal focused towards a single direction.


Encryption Standards

    WiFi Protected Access (WPA) - Legacy, transitional from WEP, RC4 cipher to be compatible with old hardware, introduced in 2002.

    WPA2 Personal - Uses block mode of encryption known as CCMP (Counter Mode with Cipher Block Chaining Message Authentication Code Protocol), introduced in 2004.

    Advanced Encryption Standard (AES) - Uses GMAC (Galois Message Authentication Code), introduced with WPA3 in 2018

    Temporal Key Integrity Protocol (TKIP) - RC4 cipher, larger Initialization Vector (IV), encrypted hash communications being sent over network.


Cellular Technologies
     Code-Division Multiple Access (CDMA) - Original 2G standard, Used a code to send and filter multiple streams of data at once (Verizon and Sprint).

    Global System for Mobile Communications (GSM) - Original 2G standard, used multiplexing to send/receive multiple streams of data at once (EU, AT&T, T-Mobile).

    Long-Term Evolution (LTE) - Merge standard used to converge previous standards into a single shared standard.

    3G, 4G, 5G - Mobile network generations, continuously improved speeds, bandwidths, and connectivity.


Multiple Input, Multiple Output (MIMO) - Multiple wireless channels used together to support higher data transfer rates.

Multi-User MIMO (MU-MIMO) - MIMO available to multiple users at the same time.

Monday, March 13, 2023

PowerShell 009 - GitHub and New Automation Script

GitHub and New Automation Script

I have made a GitHub account and uploaded a recent PowerShell script I made to automate an inventory process. This is my first upload and it is a script that outputs a .CSV file with system data (serial numbers, monitor info, AV software, etc.) It should save a considerable amount of time for my team and will be used in all regions we support.  As a side note, learning Python has been going well, but nothing new to post on that front. I am learning about various lists, slicing/searching them, and about tuples as well.

https://github.com/AOK-Tech/PowerShell-Scritps/blob/6a166b3b7549d920f5a3d7cde9216eee8d7600e2/Get-DueDiligence.ps1

Sunday, February 12, 2023

Python 000 - Intro

I have started learning Python.

Resource:
http://introtopython.org/

Basic Definitions
String
- Line of characters treated as text

Integer - Whole number

Float - Number that contains a decimal point

print() - A way to the display the contents of what is in the parentheses

Variables - An object you can designate to represent something else

List - An array of data

Looping - Repeating code in a designated way

Saturday, February 11, 2023

Network+ 012 - 2.3 Ethernet Switching Features

2.0 Networking Implementations

2.3 Ethernet Switching Features


vLAN - Logically separated LANs operating through a single switch

Data vLAN - Baseline data flow from a device to a designated vLAN

Voice vLAN - Data tagged with an 802.1Q header separated into a prioritized vLAN

Port Configurations
Port Tagging/IEEE 802.1Q
-Trunking, single connection for vLANs within a switch or connecting switches together

    Link Aggregation Control Protocol (LACP)
- Multiple interfaces acting as a single big link

Duplex - Data can be sent and received at the same time.

Speed - 10 / 100 / 1000 Mb / 10 Gb ,needs to match on both sides of connection

Flow Control - Non-deterministic, if a switch gets overloaded you need to tell other devices to slow down.

    IEEE 802.3x - Pause frame, method to regulate traffic flow

Port Mirroring - Copies traffic from an interface, used for packet capture, IDS

    Switched Port Analyzer (SPAN) - Mirroring all traffic on a switch to another system.

Port Security - Prevents unauthorized users from connecting to a switch interface, based on source MAC, each port can have a unique configuration. Can be configured with a limit on how many many unique MACs can connect and also can require MAC to be whitelisted, once port security activates it disables the interface.

Jumbo Frames - Increased byte size allowed for frame payloads, increases efficiency, everything must support jumbo frames, not all devices are compatible

Auto-Medium-Dependent Interface Crossover (MDI-X) - Automated capability to use a cable as either a straight-through or crossover cable.

Media Access Control (MAC) Address Tables - A list of MAC addresses and the interfaces they are connected to. Updates regularly

Power over Ethernet (PoE)/(PoE+) - Power provided by Ethernet cable

    IEEE 802.3af-2003 - The original PoE specifications, 15.4 watts DC power

    PoE+, IEEE 802.3at-2009 - Updated PoE specs, 25.5 watts DC power

Spanning Tree Protocol IEEE 802.1D - Switch network protocol with built-in loop protection and fault tolerance.

    STP port states - Initially Blocks forwarding to prevent a loop, Listens and clears the MAC table, Learns a new MAC table while still not forwarding. Once a new MAC table has been established it will start Forwarding data and is fully operational. STP ports can be administratively Disabled, but this will have an impact on how it operates.

        Root Port - Port path from Root.

        Designated Port - Port path back to Root

        Blocked Port - Ports blocked to prevent loops


    Rapid Spanning Tree Protocol (RSTP) 802.1w - Faster convergence than STP, from 30+ to 6 seconds.

Carrier Sense Multiple Access with collision detection (CSMA/CD) - Listens to the network to see if there is availability to send data over the network. If it detects a collision it sends a jam signal which clears everything then tries again.

Address Resolution Protocol (ARP) - Determine a MAC based on an IP address

Neighbor Discovery Protocol - Uses multicast with ICMPv6, replaces ARP. Used in conjunction with SLAAC (Stateless Address Autoconfiguration) and DAD (Duplicate Address Detection).

     Neighbor Solicitation (NS) - Request for MAC based on IPv6 address

    Neighbor Advertisement (NA) - Response to NS request

Friday, February 10, 2023

Network+ 011 - 2.2 Routing Technologies and Bandwidth Management

2.0 Networking Implementations

2.2 Routing Technologies and Bandwidth Management


Routing
Dynamic Routing
- Automated routing, listens/sends subnet info with other routers, determines the best path based on the gathered info, fault tolerance built-in to reestablish paths when needed, convergence process is different for every protocol.

Protocols
        Routing Internet Protocol (RIP)
- Distance-vector, good for small scale

        Open Shortest Path First (OSPF) - Link-state, good for large scale

        Enhanced Interior Gateway Routing Protocol (EIGRP) - Cisco, Distance-vector

        Border Gateway Protocol (BGP) - Hybrid routing protocol, determines routes based on paths, network policies, or configured rule-sets

Link state vs distance vector vs hybrid
        Distance-vector - Looks for path of fewest hops, little config required/mostly automatic, good for small networks, but doesn’t scale well to large networks.

        Link-state - Info passed between routers is related to current connectivity, considers speed of the connection, large/scalable.

        Hybrid - Uses a combination of link-state and distance-vector protocols, along with configurable rules/policies

Static routing - Pre-designated routes

Default route - When no other routes matches, the traffic goes this way

Administrative distance - Used by router to determine which routing protocol has priority.

Exterior vs Interior - Outside the network vs within a domain

Time to Live
- Amount of hops a packet can make before it is dropped.

Bandwidth management
Traffic shaping - Controlling the bandwidth usage/data rates by various applications.

Quality of Service (QoS) - Management of traffic shaping

Sunday, February 5, 2023

Network+ 010 - 2.1 Devices, their Features, and their Appropriate Placement

2.0 Networking Implementations

2.1 Devices, their Features, and their Appropriate Placement


Networking Devices
Layer 2 Switch - Forwards based on MAC, connects networks, may provide Power over Ethernet (PoE)

Layer 3 Capable Switch - Includes routing capabilities, multilayer switch

Router - Routes traffic between IP subnets, connects networks

Hub - Multiport repeater, OSI Layer 1, everything is half duplex (send or receive

Access Point
- Point of connection to the network, often used for wireless access

Bridge - Connects different physical networks, OSI Layer 2, traffic based on MAC

Wireless LAN Controller - Centralized management of Wireless Access Points (WAP)

Load Balancer
- Distribute traffic load across multiple servers, provides fault tolerance, configurable, TCP offload (protocol overhead), SSL offload (encrypting/decrypting), Caching, Prioritization (QoS), Content switching (App-based balancing)

Proxy Server
- Sits between the users and the external network, receives the user requests and sends the request on their behalf. Useful for caching info, access control, URL filtering, content scanning. The proxy understands the way the application works (http, ftp).

Cable Modem
- Broadband, Data Over Cable Service Interface Specification (DOCSIS), Speeds of 4 Mbits/s - 250 Mbit/s are common, gigabit speeds possible

DSL Modem
- Asymmetric Digital Subscriber Line (ADSL), download is faster than upload speeds, uses POTS lines, 52 Mbit/s down, 16 Mbit/s up are common, 10,000 ft limit from central office (CO)

Repeater
- Receives a signal, regenerates and resends the signal out, OSI Layer 1

Voice Gateway - Converts between VoIP protocols and PSTN (public switch telephone network) protocols, often built into the VoIP PBX (private branch exchange)

Media Converter - Converts signal to another media and sends it back out

Intrusion Prevention System (IPS) - Stops an intrusion

Intrusion Detection System (IDS) - Alerts if an intrusion is found

Firewall - Filters traffic by port number or application, can encrypt traffic between sites, can act as a router, offers Network Address Translation (NAT) and dynamic routing (BGP), sits and the ingress/egress of a network

VPN Headend - VPN concentrator, purpose built device to provide high speed encryption/decryption through hardware, software-based options available, sometimes built into OS software.


Networked Devices
Voice over Internet Protocol (VoIP) Phone - Desk phone, often powered over ethernet

Printer - Office/networked printer, all-in-one device,

Physical Access Control Devices - Card readers, biometric authentication

Cameras - CCTV, IP addressable, often powered over ethernet

Heating, Ventilation, and Air Conditioning (HVAC) Sensors - Connected through network to allow for centralized control of HVAC systems.

Internet of Things (IoT) - Good idea to segment IoT devices to limit security issues

Refrigerator - Wirelessly connected appliances

Smart Speakers - Bluetooth or otherwise

Smart Thermostats
- Connected through an app over the internet

Smart Doorbells
- Camera, connected through the internet

Industrial Control Systems (ICS)/Supervisory Control And Data Acquisition (SCADA) - Large scale, multi-site industrial equipment management. Network that manages power generation, refining, manufacturing, etc.

Network+ 009 - 1.8 Cloud Concepts and Connectivity Options

1.0 Networking Fundamentals

1.8 Cloud Concepts and Connectivity Options


Deployment Models
    Public - Anyone connected to the Internet has could have access

    Private - Cloud environment supported by internal resources

    Hybrid - A mix of public and private cloud environments

    Community - A shared cloud environment with pooled resources used by multiple orgs

Service Models
     Software as a Service (SaaS) - Cloud-based software

    Infrastructure as a Service (IaaS) - 3rd party hardware you have contracted to use

    Platform as a Service (PaaS) - Cloud-based software that lets you control and build deployments to fit your needs.

    Desktop as a Service (DaaS) - Virtual desktop infrastructure

Infrastructure as Code (IaC) - Software-Defined Infrastructure

    Automation/orchestration - Container management

Connectivity Options
     Virtual Private Network - Encrypted communication to cloud resources

    Private-direct connection to cloud provider - Private network connecting directly to public cloud environment

Multitenancy - Cloud infrastructure separated and isolated for multiple customers

Elasticity - The ability to scale up and down resources for systems in the cloud

Scalability - Cloud resources are able to be generated at large scale quickly, a built in provisioning system should be used to manage/prevent sprawl.

Security Implications - Security must be built into every step of cloud development

Saturday, February 4, 2023

Network+ 008 - 1.7 Network Architecture

1.0 Networking Fundamentals

1.7 Network Architecture

Three-Tiered - network hierarchy

    Core - Location of major servers (web, databases, applications)

    Distribution/Aggregation Layer - Manages communication to end users

    Access/Edge - User level, end-points




Software-Defined Networking - Infrastructure as Code

    Application Layer - Manage/configure the device, IDS, firewalls, load balancing

    Control Layer - Manages the data plane (Infrastructure Layer), routing tables, session tables, NAT tables

    Infrastructure Layer - Data plane, Processes the network frames/packets, Forwarding, Trunking, Encrypting, NAT

    Management Plane - See Application Layer

Spine and Leaf - Each spine switch connects to each leaf switch

    Software-Defined Network - High availability network model

    Top-of-Rack switching - Datacenter rack architecture for high-performance routing

    Backbone - Spine switches



Traffic Flows - Data traffic flows within a data center

    North-South - Traffic to/from an outside device

    East-West - Traffic between devices within the data center.

Branch Office - Remote location, end-point devices, IDF

On-Premises - Data center owned and operated from within.

Colocation - Shared data center

Storage Area Network (SAN) - Block level network storage, efficient read/write, high bandwidth

Connection Types
     Fiber Channel over Ethernet (FCoE) - Usually integrates with FC without additional hardware. Not routable.

    Fiber Channel (FC) - Supports 2, 4, 8, and 16 Gbps rates. Server (initiator) and storage (target) connect to a FC interface.

    Internet Small Computer System Interface (iSCSI) - Created by IBM and Cisco, RFC standard. Sends SCSI commands over an IP network. Routable, managed well in software, drivers available for many operating systems.

Tuesday, December 27, 2022

N10-008 Exam Simulation - 1st Attempt Results

 

N10-008 Exam Simulation

Simulation Date: December 27, 2022


Results:
Score: 65.56%

Points Scored / Total: 59 / 90

Number of Questions: 90

Total Time: 01:22:24

 

Breakdown:
Networking Fundamentals: 56.25%

Network Implementations: 38.89%

Network Operations: 71.43%

Network Security: 86.67%

Network Troubleshooting: 81.82%

 

Notes: Trying to get back into the swing of studying for this now that the holidays are mostly in the rear-view mirror. I honestly thought I was going to do better than these results going into it, but during the test quickly realized I will need to work on memorizing some specific things such as protocol port numbers and learning more about implementing a network from the ground up.

Wednesday, December 21, 2022

BeyondTrust - Cloud Identity and Access Management Solution

BeyondTrust - Cloud Identity and Access Management Solutions

Access Console (Bomgar) - A remote connection tool that can manage access to systems on your network, require on-use approval to connect to a system, and can integrate with password management solutions to inject passwords into a session without sharing the password. It also records everything during the session which can be used to generate reports in real-time, and it only uses outbound traffic to connect the systems so the connection cannot be reversed.


BeyondTrust Graphic

Thursday, December 8, 2022

PowerShell 008 - Add registry items and Extension-based Edge IE mode Compatibility

Add registry items and Extension-based Edge IE mode Compatibility


    I recently had to find a way to make Microsoft Visio Viewer, an old Internet Explorer add-on, work on a computer that no longer has IE on it. Microsoft offered a registry fix to allow the file extension to run through Edge IE Mode, and I took that into PowerShell with the resulting code below. Originally I tried to use variables, but ran into issues and ended up hard coding the paths, names, and values. This is the first time I used PowerShell to add registry items, and I used New-Item to generate new paths (folders/subfolders) and New-ItemProperty to add new keys. I also piped the results into Out-Null to remove the output spam. After some experimenting I believe this can be applied to any file extension type, however there might be other prereqs to making other file extensions work. This fix for example below requires the Visio Viewer software to be installed first. To apply the fix to other file extensions find and replace “VSDX” with whatever extension you are trying to make this work with. Once the fix is applied, you can right click the file and a new “Open With” menu can now expand where you can select Open with MS Edge in IE Mode.


#Visio Viewer Edge IE mode registry fix script

New-Item -Path "HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\FileExts\.vsdx\OpenWithProgids" -Force | Out-Null

New-ItemProperty -Path "HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\FileExts\.vsdx\OpenWithProgids" -Name "MSEdgeIEModeVSDX" -Value "0" -PropertyType DWORD -Force | Out-Null


New-Item -Path "HKCU:\SOFTWARE\Classes\MSEdgeIEModeVSDX" -Force | Out-Null


New-Item -Path "HKCU:\SOFTWARE\Classes\MSEdgeIEModeVSDX\Application" -Force | Out-Null

New-ItemProperty -Path "HKCU:\SOFTWARE\Classes\MSEdgeIEModeVSDX\Application" -Name "ApplicationCompany" -Value "Microsoft Corporation" -PropertyType String -Force | Out-Null

New-ItemProperty -Path "HKCU:\SOFTWARE\Classes\MSEdgeIEModeVSDX\Application" -Name "ApplicationName" -Value "Microsoft Edge with IE Mode" -PropertyType String -Force | Out-Null

New-ItemProperty -Path "HKCU:\SOFTWARE\Classes\MSEdgeIEModeVSDX\Application" -Name "ApplicationIcon" -Value "C:\\Program Files (x86)\\Microsoft\\Edge\\Application\\msedge.exe,4" -PropertyType String -Force | Out-Null

New-ItemProperty -Path "HKCU:\SOFTWARE\Classes\MSEdgeIEModeVSDX\Application" -Name "AppUserModelId" -Value "" -PropertyType String -Force | Out-Null


New-Item -Path "HKCU:\SOFTWARE\Classes\MSEdgeIEModeVSDX\DefaultIcon" -Force | Out-Null

New-ItemProperty -Path "HKCU:\SOFTWARE\Classes\MSEdgeIEModeVSDX\DefaultIcon" -Name "@" -Value "C:\\Program Files (x86)\\Microsoft\\Edge\\Application\\msedge.exe,4" -PropertyType String -Force | Out-Null


New-Item -Path "HKCU:\SOFTWARE\Classes\MSEdgeIEModeVSDX\shell" -Force | Out-Null


New-Item -Path "HKCU:\SOFTWARE\Classes\MSEdgeIEModeVSDX\shell\open" -Force | Out-Null


New-Item -Path "HKCU:\SOFTWARE\Classes\MSEdgeIEModeVSDX\shell\open\command" -Force | Out-Null

New-ItemProperty -Path "HKCU:\SOFTWARE\Classes\MSEdgeIEModeVSDX\shell\open\command" -Name "@" -Value "C:\\Program Files (x86)\\Microsoft\\Edge\\Application\\msedge.exe,4" -PropertyType String -Force | Out-Null

Sunday, October 23, 2022

Network+ 007 - 1.6 Network Services

1.0 Networking Fundamentals

1.6 Network Services


DHCP (Dynamic Host Configuration Protocol) - Automated IP configuration for network devices.

Scope - IP address range used and reserved IP addresses not to be used.

Exclusion Ranges - IP address range within the scope not to use.

Reservation - IP address reserved to provide as a static IP address.

Dynamic Assignment
- Automatic IP address assigning.

Static Assignment
- Non-changing IP address, typically to provide to a specific device.

Lease Time
- The duration an IP address is assigned for.

Scope Options - Used to set additional network info when a host is assigned an IP address.

Available Leases - IP addresses available to be assigned.

DHCP Relay/IP Helper
- Router that converts a device’s DHCP broadcast into a unicast to forward it to a DHCP server.

UDP Forwarding - Used when you are limited to the amount of destination you can communicate to, allows you to forward data to a UDP replicator which then can send to any number of destinations.


DNS (Domain Name System) - Protocol that translates IP addresses/domain names.

Record Types
        Address (A vs AAAA) - Used to resolve a domain to IPv4 and IPv6 addresses respectively.

        Canonical Name (CNAME) - Maps an alias name to the true domain name.

Mail Exchange (MX) - Indicates how email should be routed based on SMTP

Start of Authority (SOA) - Administrative DNS records for the DNS zone at the cutover point from the parent DNS zone.

Pointer (PTR) - Resolves an IP address to a domain. (reverse DNS lookup)

Text (TXT) - Originally made for human-readable DNS notes, can also be used to filter out spam email and to verify domain ownership.

Service (SRV) - Indicates a host and port for a given service. (VoIP, IM, etc)

Name Server (NS) - Indicates which DNS server is authoritative for a given domain.

Global Hierarchy
- Domain Name Space hierarchy

Root DNS Servers
- Top level domain in the Domain Name Space hierarchy.

Internal vs. External - IP addresses and Domains that reside within a network (internal) opposed to outside the network (external sites).

Zone Transfers - Process of copying the contents of the zone file on a primary DNS server to a secondary DNS server

Authoritative Name Servers - Contains data to provide in response to questions about domains in its zone.

Time To Live (TTL) - The amount of hops a packet will make before getting discarded.

DNS Caching - Temporarily stored data for previously looked up DNS data.

Reverse DNS/Reverse Lookup/Forward Lookup - Reverse translating a domain from an IP address.

Recursive Lookup - Source domain data from several other DNS servers.

Iterative Lookup - Source domain data directly from the DNS server involved.

NTP - Network Time Protocol, clock synchronization for network devices.

        Stratum - Degrees away from “real time” (Atomic clock:0, highly accurate)

        Clients - Connects to the network time server for syncing, stratum 2.

        Servers - Network Time Server provides time data to network devices, stratum 1.

Wednesday, September 14, 2022

SY0-601 Exam Simulation - 1st Attempt Results

SY0-601 Exam Simulation

Simulation Date: September 14, 2022


Results:
Score: 61.11%

Points Scored / Total: 55 / 90

Number of Questions: 90

Total Time: 01:12:59

 

Notes: I felt good about the content I have studied and was able to answer those questions quickly, but I also felt the opposite when I came across questions for content I have not reached yet. I did not prep for this practice test with any prior review the day of the simulated exam.

Saturday, August 27, 2022

PowerShell 007 - Registry Permissions

Registry Permissions

        Example:

                $key = [Microsoft.Win32.Registry]::LocalMachine.OpenSubKey("SOFTWARE\Wow6432Node",[Microsoft.Win32.RegistryKeyPermissionCheck]::ReadWriteSubTree,[System.Security.AccessControl.RegistryRights]::ChangePermissions)
                $acl = $key.GetAccessControl()
                $rule = New-Object System.Security.AccessControl.RegistryAccessRule (".\USERS","FullControl",@("ObjectInherit","ContainerInherit"),"None","Allow")
                $acl.SetAccessRule($rule)
                $key.SetAccessControl($acl)

This will take the registry key “SOFTWARE\Wow6432Node” and give the “\USERS” (local users) group permissions to have “FullControl” (Read/Write access).


Breakdown:

                $key =

        $key is the variable object the code will be set to.


                [Microsoft.Win32.Registry]::

        Indicates this will involve the registry, the :: operator accesses members (properties) of a namespace (hierarchy structure).


                LocalMachine.OpenSubKey("SOFTWARE\Wow6432Node",

        Targets a registry item, path for registry key. *Note: The ( is left open.


                [Microsoft.Win32.RegistryKeyPermissionCheck]::ReadWriteSubTree,

        Targets the Microsoft.Win32 namespace, RegistryKeyPermissionCheck property, and accesses the ReadWriteSubTree member. This indicates the code should save over what is there with what is provided.


                [System.Security.AccessControl.RegistryRights]::ChangePermissions)

        Targets the System.Security.AccessControl namespace (hierarchy), RegistryRights property, ChangePermissions member. *) closes the parenthesis left open from before. This is what the code will replace within this targeted member.

So far the code is targeting a registry item and saving over a targeted member (property under the namespace hierarchy) with provided info.


                $acl = $key.GetAccessControl()

        The next line sets $acl as a variable object for the above (reg path/overwrite/provided info) targeting its ACL (Windows Access Control List).


                $rule = New-Object System.Security.AccessControl.RegistryAccessRule (

        Sets a variable object, $rule, as something that target the System.Security.AccessControl namepsace, RegistryAccessRule property.


                ".\USERS","FullControl",

        Give the Users group full control


                @("ObjectInherit","ContainerInherit"),"None"

        Allows the permissions to be inherited by child objects but not propagated .


                ,"Allow")

        Specifies if access rights are allowed or denied.


                $acl.SetAccessRule($rule)

        Takes the variable $acl, targets the ACL (Access Control List) properties and sets them to the variable $rule above.

                $key.SetAccessControl($acl)

        This takes the target $key and applies $acl permissions that had been configured with $rule.


        Results:

        Targeted registry file: 

                HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node

        Is updated with permissions below.

                IdentityReference: “.\USERS” (local users)
                RegistryRights: "FullControl" (get full control)
                InheritanceFlags: "ObjectInherit","ContainerInherit" (Inherited to all child objects)
                PropagationFlags: “None” (Permissions are not to be propagated to those child objects)
                AccessControlType: “Allow” (Access rights are allowed)

Thursday, August 25, 2022

PowerShell 006 - Send Keystrokes

Send Keystrokes

        Example:

                $wshell = New-Object -ComObject wscript.shell;
                $wshell.SendKeys('text')
                $wshell.SendKeys(~)

        This will type out “text” followed by an Enter keystroke


        Breakdown:

                $wshell = New-Object -ComObject wscript.shell;

        Creates a COM Object with a wscript command and assigns it to the variable $wshell


                $wshell.SendKeys([KEYSTROKES])

        The Object runs the SendKeys command for what is between (). Use single quotes for ‘text’ or one of the codes for non-displayed keys.


Common Non-Displayed Keys

Key

Code

BACKSPACE

{BACKSPACE}, {BS}, or {BKSP}

ENTER

{ENTER} or ~

ESC

{ESC}

DEL or DELETE

{DELETE} or {DEL}

PRINT SCREEN

{PRTSC} (reserved for future use)

TAB

{TAB}


You can combo these with SHIFT, CTRL, and/or ALT by starting with the keys

Key

Code

SHIFT

+

CTRL

^

ALT

%