Connect to Exchange Online

Multi-Factor Authentication

<# 

Author: Scott Head

Version: 1.0

Date: 5/4/2021

#>

# Basic setup for connecting to Exchange Online after setting up dual authentication

# Run PowerShell ISE as Administrator | Internet Access Required, Gets Module and Installs to Current PS Session

Install-Module -Name ExchangeOnlineManagement -RequiredVersion 2.0.4

# Connects to Exchange Online , By Using My Username It Directed Me to my Exchange Server Online

# Should See Pop Up on Screen to Authenticate On PC and then Send Message to Cell Phone Authenticator

Connect-ExchangeOnline -UserPrincipalName UserName@Scriptsbyscott.com

#Mail Commands:

Get-EXOMailbox Scotts

#Disconnect Session 

Disconnect-ExchangeOnline

cmdlets_screeenshot.PNG