Giter Site home page Giter Site logo

o365-investigationtooling's Introduction

topic products languages extensions
sample
office-365
powershell
contentType createdDate
tools
2/11/2016 4:22:37 PM

O365-InvestigationTooling

This project is to help faciliate testing and low-volume activity data acquisition from the Office 365 Management Activity API.

Prerequisites for the O365 Investigation Data Acquisition Script

Once you have selected the data store that you want to publish your Activity API data to, simply open the ConfigForO365Investigations.json file and enable and configure the attributes that are relevant to your store. Note you will have to register an application in Azure AD, then populate the config with the AppID (InvestigationAppID) and AppSecret (InvestigationAppSecret) to enable data flow for the Activity API.

Prerequisites for the Activity API

Follow the instructions in the Management Activity API: Getting Started Guide to create a new AAD application and grant it permissions to the tenant's Management Activity API.

Prerequisites for the MySQL Store Pattern

  1. If you don't already have a MySQL database, download the Windows MySQL installer. Make sure to include MySQL server, MySQL Workbench, and the ODBC and .Net connectors. (MySQL docs are here: https://dev.mysql.com/doc/refman/5.7/en/json.html

  2. Using the mysql command-line client, run

    CREATE DATABASE O365Investigations;

    to create the database.

  3. Populate ConfigForO365Investigations.json with your MySQL admin name and password, as well as the hostname and database name.

  4. Run the O365InvestigationDataAcquisition.ps1 script to enable the subscriptions and pull the data. Re-run regularly to continue to consume new data.

  5. Once you have enough data, open MySQL Workbench, open ActivityAPI-InvestigationQueries.sql and run the approach SQL statements to get answers to your questions.

Prerequisites for the Azure Blob Store Pattern

  1. Determine the desired storage account name and update the config file.

  2. Determine the desired container name and update the config file.

  3. Determine the account name you will use to manage the blob storage and update the config file.

  4. Run the PowerShell command

    Read-Host -AsSecureString | ConvertFrom-SecureString

    and provide the password for the account you will use to manage the Azure blob storage, then use the output as the value for AzureAccountSecureString in the ConfigForO365Investigations.json file.

Prerequisites for the SQL Azure Store Pattern

  1. Login to your Azure subscription at https://portal.azure.com

  2. Ensure you have a storage account set up

  3. Select "+ New" in the upper left, then "Data + Storage", then "SQL Database"

  4. Name your new database "O365Investigations"

  5. Select an existing SQL server (and make note of the hostname), or create a new server (making note of the admin account you used to create the database)

  6. Select the source, pricing tier, resource group, and associated subscription, then click "Create".

  7. Select SQL Servers from the main navigation, select the server you just created, then click "Show Firewall Settings". In the "Firewall Settings" blade, click "Add Client IP" and add the IP address of the host where you will be running the investigations tooling from. Save and wait for confirmation that the firewall rules have been updated.

  8. Use Visual Studio, or download SQL Server Management Studio Express 2014 (for free) and connect to your new database.

  9. Create a new SQL database named "O365Investigations"

  10. Ensure you have a username and password for an account that can connect to the database.

This project has adopted the Microsoft Open Source Code of Conduct. For more information, see the Code of Conduct FAQ or contact [email protected] with any additional questions or comments.

o365-investigationtooling's People

Contributors

007 avatar arjancornelissen avatar bkoeller avatar crosse avatar davidchesnut avatar ericvanaken avatar jformacek avatar mcvic1rj avatar o365devx avatar stuartcl avatar yibsu avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

o365-investigationtooling's Issues

Script Times Out When Running Against 5000 Users

This times out constantly, I have increased the IdleTimeout property. But still this runs for a few minutes and then I get :
Starting a command on the remote server failed with the following error message : Access is denied. For more
information, see the about_Remote_Troubleshooting Help topic.
+ CategoryInfo : OperationStopped: (outlook.office365.com:String) [], PSRemotingTransportException
+ FullyQualifiedErrorId : JobFailure
+ PSComputerName : outlook.office365.com

This makes the script almost impossible to use. We don't have that many mailboxes - others have far more, so how do other people manage to run this script? Any help happily received, thanks

"The account does not have permission to impersonate the requested user."

i am running this command as a global admin with application impersonation enabled and MFA on Modren Auth. this is what i get...

Exception calling "Bind" with "2" argument(s): "The account does not have permission to impersonate the requested
user."
At C:\Github\O365-InvestigationTooling\Get-AllTenantRulesAndForms.ps1:182 char:5

  • $rfRootFolder = [Microsoft.Exchange.WebServices.Data.Folder]::Bin ...
    
  • ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    
    • CategoryInfo : NotSpecified: (:) [], MethodInvocationException
    • FullyQualifiedErrorId : ServiceResponseException

Exception calling "FindItems" with "3" argument(s): "The account does not have permission to impersonate the requested
user."
At C:\Github\O365-InvestigationTooling\Get-AllTenantRulesAndForms.ps1:185 char:5

  • $FindResults = $exchService.FindItems([Microsoft.Exchange.WebServ ...
    
  • ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    
    • CategoryInfo : NotSpecified: (:) [], MethodInvocationException
    • FullyQualifiedErrorId : ServiceResponseException

unapproved verbs & UseDatabaseQuotaDefaults

Hello everybody
first scan triggered error:
names of some imported commands from the module 'tmp_gwnisqcb.adj" include unapproved vers that might make them less discoverable,

I then did mistake (looks like a mistake) and run code again and got a warning:
Please update UseDatabaseQuotaDefaults to false in order for mailbox quotas to apply.

It would be nice to complete this audit but it looks like its beyond my knowledge.
regards
b

Get-MailboxPermission : The term 'Get-MailboxPermission' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again.

DumpDelegatesandForwardingRules.ps1

Get-MailboxPermission : The term 'Get-MailboxPermission' is not recognized as the name of a cmdlet, function, script file, or operable program. Check
the spelling of the name, or if a path was included, verify that the path is correct and try again.
At line:23 char:23

  • $UserDelegates += Get-MailboxPermission -Identity $User.UserPrinc ...
    
  •                   ~~~~~~~~~~~~~~~~~~~~~
    
    • CategoryInfo : ObjectNotFound: (Get-MailboxPermission:String) [], CommandNotFoundException
    • FullyQualifiedErrorId : CommandNotFoundException

unable to set webhook via PS

i updated the powershell script to include webhook but the response output i get shows null for webhook.

$headerParams = @{'Authorization'="$($oauth.token_type) $($oauth.access_token)"}

$webhook=@"
{
"webhook" : {
"address": "https://o365managementapiwebhook.azurewebsites.net/",
"authId": "o365activityapinotification",
"expiration": ""
}
}
"@

$jsonbody = $webhook | ConvertTo-Json

Invoke-RestMethod -Method Post -Headers $headerParams -Uri "https://manage.office.com/api/v1.0/$tenantGUID/activity/feed/subscriptions/start?contentType=Audit.SharePoint" -Body $jsonbody

this is the output i get
contentType status webhook

Audit.SharePoint enabled

am i missing something?

EnableMailboxAuditing.ps1 suggest

suggest to include RecipientTypeDetails in check

Get-Mailbox -ResultSize Unlimited `
| Select Name, AuditEnabled, AuditLogAgeLimit,RecipientTypeDetails  `
| Ft -a

Possible Copy and Paste Error

CreateAndSetPasswordsInBulk.ps1

Should not be $user.Object - The below issue will loop through the same user every iteration

foreach ($guid in $UserGuids) { Write-Output "Setting the password for " $user.ObjectId; Set-MsolUserPassword โ€“ObjectId $user.ObjectId โ€“NewPassword $user.NewPassword -ForceChangePassword $True }

Should be $guid .Object

foreach ($guid in $UserGuids) { Write-Output "Setting the password for " $guid.ObjectId; Set-MsolUserPassword โ€“ObjectId $guid.ObjectId โ€“NewPassword $guid.NewPassword -ForceChangePassword $True }

Clarify purpose in comments, fix removal of 'UpdateFolderPermissions' default action

Comment in line 1 is true but misleading:

#This script will enable non-owner mailbox access auditing on every mailbox in your tenancy

It does, in fact, enable auditing of some (but not all) non-owner (i.e., administrator or delegate) mailbox actions, but it also enables auditing for some (but not all) owner actions as well.

So if the purpose is to only enable non-owner mailbox auditing (and its associated default logging actions), then this snippet should be removed:

-AuditOwner Create,HardDelete,MailboxLogin,MoveToDeletedItems,SoftDelete,Update

But if the purpose is to enable both non-owner and owner mailbox auditing, the description of the script should be adjusted to clarify its purpose and the code should be revised so that it doesn't overwrite/remove a default logging action ('UpdateFolderPermissions') that is otherwise turned on for mailbox owners when mailbox auditing is enabled.

This article has a handy table showing available mailbox auditing options for the three user logon types:
https://support.office.com/en-us/article/Enable-mailbox-auditing-in-Office-365-aaca8987-5b62-458b-9882-c28476a66918#ID0EABAAA=Mailbox_auditing_actions

To keep the default logging action ('UpdateFolderPermissions') and add the other actions contemplated by the existing script, replace the snippet above with:
-AuditOwner @{Add="Create","HardDelete","MailboxLogin","MoveToDeletedItems","SoftDelete","Update"}

But perhaps a more comprehensive approach is desirable to enable logging of every auditable action across all user logon types (as listed in the MS Support article)? (I also noticed that the existing code inexplicably leaves out the 'Move' action for owner auditing.) So maybe something like:

-AuditOwner @{Add="Create","HardDelete","MailboxLogin","Move","MoveToDeletedItems","SoftDelete","Update"} -AuditAdmin @{Add="Copy","MessageBind"} -AuditDelegate @{Add="Move","MoveToDeletedItems","SendOnBehalf"}

In any case, the comment should clarify that this script is only enabling logging for certain actions and is not comprehensively doing so for all auditable mailbox actions across all user login types. Users should be cautioned that they may need to add or remove options to fit their auditing objectives.

(Thanks for all the effort thus far! I stumbled across this script from the Secure Score dashboard in O365 which was a pleasant surprise but also somewhat concerning as being officially-sanctioned guidance...)

Too many result than Azure AD Admin Center showed

I run the script and could get a list of users, but that number of result was more than which is shown at Azure AD Admin Center (ID Security Score).
I wonder what makes this difference and if script could get the correct result.

Update to mailbox auditing config doesn't work using Mac OS X powershell

Following recommendation from https://securescore.office.com/#!/dashboard I went to https://github.com/OfficeDev/O365-InvestigationTooling/blob/master/EnableMailboxAuditing.ps1 and then installed powershell for Mac. Would have been good if it mentioned that this doesn't work! I guess related to https://github.com/PowerShell/PowerShell/issues/3708 but not sure.

InactiveUsersLast90Days.ps1 - limit of 5000 audit log items

This script only shows a list of users that have not logged in for 90 days or more if your tenancy happens to have fewer than 5000 matching audit log entries for the following actions over the last 90 days: UserLoggedIn, PasswordLogonInitialAuthUsingPassword, UserLoginFailed.

$loggedOnUsers = Search-UnifiedAuditLog -StartDate $startDate -EndDate $endDate -Operations UserLoggedIn, PasswordLogonInitialAuthUsingPassword, UserLoginFailed -ResultSize 5000

In any reasonably active tenancy, you're going to get mainly false positives.

You need to batch these requests.

RemediateEmployeeLeaving.ps1

Error in RemoveLicences Function:
Set-MsolUserLicense : Unable to assign this license because it is invalid. Use the Get-MsolAccountSku cmdlet to retrieve a list of valid licenses.
At line:11 char:1

  • Set-MsolUserLicense -UserPrincipalName $useremail -RemoveLicenses $St ...
    • CategoryInfo : OperationStopped: (:) [Set-MsolUserLicense], MicrosoftOnlineException
    • FullyQualifiedErrorId : Microsoft.Online.Administration.Automation.InvalidUserLicenseException,Microsoft.Online.Administration.Automation.SetUserLicense


Fixed with this:
Function RemoveLicences($upn, $UL)
{
#$licenseObj = Get-MsolAccountSku
#$license = $licenseObj.AccountSkuId
#Set-MsolUserLicense -UserPrincipalName $upn -RemoveLicenses $license

#$UL = 'US'
$license = Get-MsolUser -UserPrincipalName $upn | select -ExpandProperty licenses

Set-MsolUser -UserPrincipalname $upn -UsageLocation $UL

Set-MsolUserLicense -UserPrincipalName $upn -RemoveLicense $license.AccountSkuId

}

Add TargetAddress to DumpDelegatesandForwardingRules.ps1

Email administrators may use TargetAddress to forward email outside the company, and this property does ignore a tenant's forwarding rules.

I've been able to locate this property using ADSI/On Premise AD, I have not been able to locate it in EOP, O365, AzureAD, or Exchange Online powershell commands. More information:
https://serverfault.com/q/920344/477213

Once the relevant TargetAddress attribute is located, please add it to DumpDelegatesandForwardingRules.ps1 as the logical effect of "forwarding" is the same as what that script is trying to report on.

Set up all scripts to work from docker

Since Microsoft publishes a docker image for powershell, all of these scripts should be set up to work that way.

This will allow you to support all platforms, and you can add things like MFA support without worrying about external dependencies. Trying to run something as simple as EnableMailboxAuditing from not-Windows gave me three different problems:

  1. Need to install powershell
  2. Need 5.x instead of 6.x because Out-Gridview is broken
  3. Need to add an MFA plugin

Building and packaging these in docker would solve all of those.

EnableMailboxAuditing.ps1 add SchedulingMailbox type

There's a mailbox type missing: SchedulingMailbox.

To update the code use this: Get-Mailbox -ResultSize Unlimited -Filter {RecipientTypeDetails -eq "UserMailbox" -or RecipientTypeDetails -eq "SharedMailbox" -or
RecipientTypeDetails -eq "RoomMailbox" -or RecipientTypeDetails -eq "DiscoveryMailbox" -or RecipientTypeDetails -eq "SchedulingMailbox"}
| Set-Mailbox -AuditEnabled $true -AuditLogAgeLimit 180 -AuditAdmin Update, MoveToDeletedItems, SoftDelete, HardDelete, SendAs,
SendOnBehalf, Create, UpdateFolderPermission -AuditDelegate Update, SoftDelete, HardDelete, SendAs, Create, UpdateFolderPermissions,
MoveToDeletedItems, SendOnBehalf -AuditOwner UpdateFolderPermission, MailboxLogin, Create, SoftDelete, HardDelete, Update, MoveToDeletedItems

EnableMailboxAuditing.ps1 missing ?

Microsoft Secure Score Improvement Actions points to this repository to download EnableMailboxAuditing.ps1, but the file appears to be missing?

Category: Data
User impact: Low
Protects against: Account Breach
Complexity: Low

Next steps

In GitHub, you can download the Powershell script called EnableMailboxAuditing.ps1 to turn on mailbox auditing for all users.

How will this affect my users? This change has no known impact on your users.
Compliance Controls
CSA CCM301; Control IAM-01
FedRAMP Moderate; Control AU-9
GDPR; Control 6.9.4
ISO 27001:2013; Control A.12.4.2
ISO 27018:2014_ID; Control C.12.4.2, Part 1
NIST 800-171; Control 3.3.8
NIST 800-53; Control AU-9
NIST CSF; Control RS.AN-1

pulling a lot of active accounts

We just ran the 90 day inactive script and it pulled quite a bit of false positives.
ie confirmed AAD users who are actively using office365 with MFa enabled are appearing on this inactive list.

InactiveUsersLast90Days.ps1 - UserLoginFailed events

I'm not convinced about the relevancy of the "UserLoginFailed" events.

That would seem to lead to false positives.

For instance, even if an account is genuinely unused, but some botnet is trying a brute force attack, it's going to flood this script with entries that get erroneously counted as user activity.

A parameter cannot be found that matches parameter name 'Mailbox'.

DumpDelegatesandForwardingRules.ps1

Running as a GA with latest powershell module:

A parameter cannot be found that matches parameter name 'Mailbox'.
+ CategoryInfo : InvalidArgument: (:) [Get-InboxRule], ParameterBindingException
+ FullyQualifiedErrorId : NamedParameterNotFound,Get-InboxRule
+ PSComputerName : outlook.office365.com

Novice to O365-Investigating tooling and Secure Score

I am new to GitHub. In Secure Score there are Actions that take me to GitHub. I have no idea what to do with for instance O365-InvestigationTooling/DumpDelegatesandForwardingRules.ps1. Please help. I do have PowerShell and PowerShell ISE on my PC. Thank you. Be Blessed
image

InactiveUsersLast90Days.ps1: Doesn't exclude failed logins

Hi, thanks for this script. Unfortunately it isn't excluding failed logins in the $loggedOnUsers list.

That would mean that users who had only failed to login would be counted as having used the system.

It might also make things quicker if the list were limited to unique entries?

It also fails badly for larger tenancies since 5,000 entries is nowhere near enough to cover 90d of use. We really need to have paging built in so that we can recover all entries. Or at least a pointer in the script to direct people to some example paging code.

Here is some example code extracted from another similar script of mine looking for password resets:

# Search for password use (-RecordType AzureActiveDirectoryAccountLogon, -Operations PasswordLogonInitialAuthUsingPassword)
$enddate = get-date

For ( $i = 1; $i -le $days; $i++ ) {
    $startdate = $enddate.AddDays( -1 )

    Write-Output ("Search Day Now-{1} {2}-{3}: {0} min" -f [math]::Round((New-TimeSpan -Start $strt).TotalMinutes,4), $i, $startdate, $enddate )

    $o = Search-UnifiedAuditLog -StartDate $startdate -EndDate $enddate `
                                -Operations PasswordLogonInitialAuthUsingPassword -ResultSize 5000 |
            Select CreationDate, UserIds, AuditData.ResultStatus, AuditData.Client, AuditData.Application

    $out += $o
    $enddate = $enddate.AddDays( -1 )

}
Write-Output ("Found {1} Entries: {0} min" -f (New-TimeSpan -Start $strt).TotalMinutes, $out.Count )

No data is pulled in O365InvestigationDataAcquisition.ps1

No data is pulled in O365InvestigationDataAcquisition.ps1 after i configured ConfigForO365Investigations.json
The configuration is configured well as other calls execute successfully, for example, get oath token, list subscription.
In the mean time, I can get audit data from exchange powershell by using Search-UnifiedAuditLog.
Please get the output for O365InvestigationDataAcquisition.ps1 attached.. (I do not need DLP.ALL so the error on it is fine)
console.txt

Setting tenant name from user name does not work

Hi all, some interesting scripts here so thanks for them.

However, the template code you have for trying to identify the tenancy name from the user name does not work when using custom domains.

I think this should be fixable by looking up the tenancy of the user but I'm not sure of the code off the top of my head I'm afraid.

MailForwardingRulesToExternalDomains

This CSV report needs a lot of work. The description column is cut off so all it displays is "If the message:', there is no field to tell whose rule/mailbox it is, the forwardto column includes users in the same domain (not external)...

won't work for mailboxes with same alias name

It will throw an error of 'The operation couldn't be performed because 'XXX' matches multiple entries' because the pipe automatically use the alias to match the identity

Suggest Fix: Designate distinguishedName as the identity

e.g:

$users=get-mailbox | select name, distinguishedname ;
Foreach($user in $users) { set-mailbox $user.distinguishedname -auditEnabled $true}

inactiveInLastThreeMonthsUsers

i am getting the following error when running the script to get inactive users. https://github.com/OfficeDev/O365-InvestigationTooling/blob/master/InactiveUsersLast90Days.ps1
Get-MsolUser : The term 'Get-MsolUser' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the name, or if a path was included, verify that the path is
correct and try again.
At line:5 char:13

  • $allUsers = Get-MsolUser -All -EnabledFilter EnabledOnly | Select Use ...
  •         ~~~~~~~~~~~~
    
    • CategoryInfo : ObjectNotFound: (Get-MsolUser:String) [], CommandNotFoundException
    • FullyQualifiedErrorId : CommandNotFoundException

RemediateEmployeeLeaving.ps1 missing RedirectTo option

Our usual scenario when employee leaves is giving access to files and redirect mail to a colleague or new worker. So it would be a nice option to have some sort of "transfer ownership to" option that fail-back to admin creds if not specified.

AddNewOwnerToSiteCollection -collectionUrl $collectionUrls[$i] -newOwner $adminCreds.username   

RedirectEmail -redirectFrom $upn -redirectTo $adminCreds.username 

"Too many requests" errors on invoke-webrequest

Getting frequent "Too many requests" errors.

Fixed it:

function Invoke-APIRequest ($Headers, $URI) {
$worked = $false
while (-not $worked) {
try {
Invoke-WebRequest -Headers $headers -Uri $URI
$worked = $true # An exception will skip this
} catch {
# Should check to retry: error record is in $_
write-host "Error, retrying web request"
}
}
`

And then change each call to invoke-webrequest to:
#$thisRabbit = Invoke-WebRequest -Headers $headerParams -Uri $thatRabbit.Headers.NextPageUri $thisRabbit = Invoke-APIRequest $headerParams $thatRabbit.Headers.NextPageUri

as an example

WARNING: Proxy creation has been skipped for the following command:

Running from Win 7 Ent environment with AV disabled.

Have MFA setup but have been able able to use the app password.

When I run this script:

#This script will enable non-owner mailbox access auditing on every mailbox in your tenancy
#First, let's get us a cred!
$userCredential = Get-Credential

#This gets us connected to an Exchange remote powershell service
$ExoSession = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri https://outlook.office365.com/powershell-liveid/ -Credential $userCredential -Authentication Basic -AllowRedirection
Import-PSSession $ExoSession

#Enable global audit logging
Get-Mailbox -ResultSize Unlimited -Filter {RecipientTypeDetails -eq "UserMailbox" -or RecipientTypeDetails -eq "SharedMailbox" -or RecipientTypeDetails -eq "RoomMailbox" -or RecipientTypeDetails -eq "DiscoveryMailbox"} | Set-Mailbox -AuditEnabled $true -AuditLogAgeLimit 180 -AuditAdmin Update, MoveToDeletedItems, SoftDelete, HardDelete, SendAs, SendOnBehalf, Create, UpdateFolderPermission -AuditDelegate Update, SoftDelete, HardDelete, SendAs, Create, UpdateFolderPermissions, MoveToDeletedItems, SendOnBehalf -AuditOwner UpdateFolderPermission, MailboxLogin, Create, SoftDelete, HardDelete, Update, MoveToDeletedItems 

#Double-Check It!
Get-Mailbox -ResultSize Unlimited | Select Name, AuditEnabled, AuditLogAgeLimit | Out-Gridview

I get the following output (see Error Text) in the command line environment and I also get a GUI window that pops up with a table of mailbox names and whether they are enabled or not.

That table shows every mailbox listed as having auditing enabled but I do not think that is the case. Executed the script Friday. Over the weekend, the Microsoft Security Score dashboard still has us with only 87 out of 150 mailboxes with auditing turned on.

Any ideas what is going wrong?

Error Text

Import-PSSession : No command proxies have been created, because all of the requested remote commands would shadow existing local commands.  Use the AllowClobber parameter if you 
want to shadow existing local commands.
At H:\~ Thom's Scripts\AuditMailboxEnabled.ps1:7 char:1
+ Import-PSSession $ExoSession
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidResult: (:) [Import-PSSession], ArgumentException
    + FullyQualifiedErrorId : ErrorNoCommandsImportedBecauseOfSkipping,Microsoft.PowerShell.Commands.ImportPSSessionCommand

Full Output

cmdlet Get-Credential at command pipeline position 1
Supply values for the following parameters:
WARNING: Proxy creation has been skipped for the following command: 'Add-AvailabilityAddressSpace, Add-DistributionGroupMember, Add-MailboxFolderPermission, Add-MailboxLocation, Add
-MailboxPermission, Add-ManagementRoleEntry, Add-PublicFolderClientPermission, Add-RecipientPermission, Add-RoleGroupMember, Add-UnifiedGroupLinks, Approve-ElevatedAccessRequest, Cl
ear-ActiveSyncDevice, Clear-MobileDevice, Clear-TextMessagingAccount, Compare-TextMessagingVerificationCode, Complete-MigrationBatch, ConvertFrom-ExoJobData.ps1, Delete-QuarantineMe
ssage, Deny-ElevatedAccessRequest, Disable-AntiPhishRule, Disable-App, Disable-HostedContentFilterRule, Disable-InboxRule, Disable-JournalArchiving, Disable-JournalRule, Disable-Mai
lbox, Disable-MailPublicFolder, Disable-MalwareFilterRule, Disable-OutlookProtectionRule, Disable-SweepRule, Disable-TransportRule, Disable-UMAutoAttendant, Disable-UMCallAnsweringR
ule, Disable-UMIPGateway, Disable-UMMailbox, Enable-AntiPhishRule, Enable-App, Enable-HostedContentFilterRule, Enable-InboxRule, Enable-JournalRule, Enable-Mailbox, Enable-MailPubli
cFolder, Enable-MalwareFilterRule, Enable-OrganizationCustomization, Enable-OutlookProtectionRule, Enable-SweepRule, Enable-TransportRule, Enable-UMAutoAttendant, Enable-UMCallAnswe
ringRule, Enable-UMIPGateway, Enable-UMMailbox, Export-DlpPolicyCollection, Export-MailboxDiagnosticLogs, Export-MigrationReport, Export-QuarantineMessage, Export-TransportRuleColle
ction, Export-UMCallDataRecord, Export-UMPrompt, Get-AcceptedDomain, Get-ActiveSyncDevice, Get-ActiveSyncDeviceAccessRule, Get-ActiveSyncDeviceClass, Get-ActiveSyncDeviceStatistics,
 Get-ActiveSyncMailboxPolicy, Get-ActiveSyncOrganizationSettings, Get-AddressBookPolicy, Get-AdminAuditLogConfig, Get-AdministrativeUnit, Get-AdvancedThreatProtectionDocumentDetail,
 Get-AdvancedThreatProtectionDocumentReport, Get-AntiPhishPolicy, Get-AntiPhishRule, Get-App, Get-ApplicationAccessPolicy, Get-ATPTotalTrafficReport, Get-AuditConfig, Get-AuditConfi
gurationPolicy, Get-AuditConfigurationRule, Get-AuditLogSearch, Get-AuthenticationPolicy, Get-AuthServer, Get-AvailabilityAddressSpace, Get-AvailabilityConfig, Get-BlockedSenderAddr
ess, Get-CalendarDiagnosticAnalysis, Get-CalendarDiagnosticLog, Get-CalendarDiagnosticObjects, Get-CalendarNotification, Get-CalendarProcessing, Get-CalendarViewDiagnostics, Get-CAS
Mailbox, Get-CASMailboxPlan, Get-ClassificationRuleCollection, Get-ClientAccessRule, Get-Clutter, Get-CompliancePolicyFileSyncNotification, Get-CompliancePolicySyncNotification, Get
-ComplianceTag, Get-ComplianceTagStorage, Get-ConnectionByClientTypeDetailReport, Get-ConnectionByClientTypeReport, Get-ConnectSubscription, Get-Contact, Get-CsActiveUserReport, Get
-CsAVConferenceTimeReport, Get-CsClientDeviceDetailReport, Get-CsClientDeviceReport, Get-CsConferenceReport, Get-CsP2PAVTimeReport, Get-CsP2PSessionReport, Get-CsPSTNConferenceTimeR
eport, Get-CsPSTNUsageDetailReport, Get-CsUserActivitiesReport, Get-CsUsersBlockedReport, Get-DataClassification, Get-DataClassificationConfig, Get-DataEncryptionPolicy, Get-DataRet
entionReport, Get-DeviceComplianceDetailsReport, Get-DeviceComplianceDetailsReportFilter, Get-DeviceCompliancePolicyInventory, Get-DeviceComplianceReportDate, Get-DeviceComplianceSu
mmaryReport, Get-DeviceComplianceUserInventory, Get-DeviceComplianceUserReport, Get-DeviceConditionalAccessPolicy, Get-DeviceConditionalAccessRule, Get-DeviceConfigurationPolicy, Ge
t-DeviceConfigurationRule, Get-DevicePolicy, Get-DeviceTenantPolicy, Get-DeviceTenantRule, Get-DistributionGroup, Get-DistributionGroupMember, Get-DkimSigningConfig, Get-DlpDetailRe
port, Get-DlpDetectionsReport, Get-DlpIncidentDetailReport, Get-DlpKeywordDictionary, Get-DlpPolicy, Get-DlpPolicyTemplate, Get-DlpSensitiveInformationTypeRulePackage, Get-DlpSiDete
ctionsReport, Get-DynamicDistributionGroup, Get-ElevatedAccessApprovalPolicy, Get-ElevatedAccessAuthorization, Get-ElevatedAccessRequest, Get-EligibleDistributionGroupForMigration, 
Get-EmailAddressPolicy, Get-FailedContentIndexDocuments, Get-FederatedOrganizationIdentifier, Get-FederationInformation, Get-FederationTrust, Get-FfoMigrationReport, Get-FocusedInbo
x, Get-Group, Get-GroupActivityReport, Get-GroupMailbox, Get-HistoricalSearch, Get-HostedConnectionFilterPolicy, Get-HostedContentFilterPolicy, Get-HostedContentFilterRule, Get-Host
edOutboundSpamFilterPolicy, Get-HotmailSubscription, Get-HybridMailflow, Get-HybridMailflowDatacenterIPs, Get-ImapSubscription, Get-InboundConnector, Get-InboxRule, Get-InformationB
arrierReportDetails, Get-InformationBarrierReportSummary, Get-IntraOrganizationConfiguration, Get-IntraOrganizationConnector, Get-IRMConfiguration, Get-JournalRule, Get-LicenseVsUsa
geSummaryReport, Get-LinkedUser, Get-LogonStatistics, Get-Mailbox, Get-MailboxActivityReport, Get-MailboxAuditBypassAssociation, Get-MailboxAutoReplyConfiguration, Get-MailboxCalend
arConfiguration, Get-MailboxCalendarFolder, Get-MailboxFolder, Get-MailboxFolderPermission, Get-MailboxFolderStatistics, Get-MailboxJunkEmailConfiguration, Get-MailboxLocation, Get-
MailboxMessageConfiguration, Get-MailboxOverrideConfiguration, Get-MailboxPermission, Get-MailboxPlan, Get-MailboxPreferredLocation, Get-MailboxRegionalConfiguration, Get-MailboxRes
toreRequest, Get-MailboxRestoreRequestStatistics, Get-MailboxSearch, Get-MailboxSpellingConfiguration, Get-MailboxStatistics, Get-MailboxUsageDetailReport, Get-MailboxUsageReport, G
et-MailboxUserConfiguration, Get-MailContact, Get-MailDetailATPReport, Get-MailDetailDlpPolicyReport, Get-MailDetailMalwareReport, Get-MailDetailReport, Get-MailDetailSpamReport, Ge
t-MailDetailTransportRuleReport, Get-MailFilterListReport, Get-MailPublicFolder, Get-MailTrafficATPReport, Get-MailTrafficPolicyReport, Get-MailTrafficReport, Get-MailTrafficSummary
Report, Get-MailTrafficTopReport, Get-MailUser, Get-MalwareFilterPolicy, Get-MalwareFilterRule, Get-ManagementRole, Get-ManagementRoleAssignment, Get-ManagementRoleEntry, Get-Manage
mentScope, Get-MessageCategory, Get-MessageClassification, Get-MessageRecallResult, Get-MessageTrace, Get-MessageTraceDetail, Get-MessageTrackingReport, Get-MigrationBatch, Get-Migr
ationConfig, Get-MigrationEndpoint, Get-MigrationStatistics, Get-MigrationUser, Get-MigrationUserStatistics, Get-MobileDevice, Get-MobileDeviceDashboardSummaryReport, Get-MobileDevi
ceMailboxPolicy, Get-MobileDeviceStatistics, Get-MoveRequest, Get-MoveRequestStatistics, Get-MxRecordReport, Get-MxRecordsReport, Get-Notification, Get-O365ClientBrowserDetailReport
, Get-O365ClientBrowserReport, Get-O365ClientOSDetailReport, Get-O365ClientOSReport, Get-OMEConfiguration, Get-OMEMessageStatus, Get-OnlineMeetingConfiguration, Get-OnPremisesOrgani
zation, Get-OrganizationalUnit, Get-OrganizationConfig, Get-OrganizationRelationship, Get-OutboundConnector, Get-OutboundConnectorReport, Get-OutlookProtectionRule, Get-OwaMailboxPo
licy, Get-PartnerApplication, Get-PartnerCustomerUserReport, Get-PerimeterConfig, Get-PerimeterMessageTrace, Get-PhishFilterPolicy, Get-Place, Get-PolicyTipConfig, Get-PopSubscripti
on, Get-PublicFolder, Get-PublicFolderClientPermission, Get-PublicFolderItemStatistics, Get-PublicFolderMailboxDiagnostics, Get-PublicFolderMailboxMigrationRequest, Get-PublicFolder
MailboxMigrationRequestStatistics, Get-PublicFolderMigrationRequest, Get-PublicFolderMigrationRequestStatistics, Get-PublicFolderStatistics, Get-QuarantineMessage, Get-QuarantineMes
sageHeader, Get-RbacDiagnosticInfo, Get-Recipient, Get-RecipientPermission, Get-RecipientStatisticsReport, Get-RemoteDomain, Get-ReportExecutionInstance, Get-ReportSchedule, Get-Rep
ortScheduleList, Get-ResourceConfig, Get-RetentionEvent, Get-RetentionPolicy, Get-RetentionPolicyTag, Get-RMSTemplate, Get-RMSTrustedPublishingDomain, Get-RoleAssignmentPolicy, Get-
RoleGroup, Get-RoleGroupMember, Get-SCInsights, Get-ScorecardClientDeviceReport, Get-ScorecardClientOSReport, Get-ScorecardClientOutlookReport, Get-ScorecardMetricsReport, Get-Searc
hDocumentFormat, Get-SecurityPrincipal, Get-SendAddress, Get-SenderPermission, Get-ServiceDeliveryReport, Get-ServiceStatus, Get-SharingPolicy, Get-SiteMailbox, Get-SiteMailboxDiagn
ostics, Get-SiteMailboxProvisioningPolicy, Get-SmimeConfig, Get-SPOActiveUserReport, Get-SpoofMailReport, Get-SPOSkyDriveProDeployedReport, Get-SPOSkyDriveProStorageReport, Get-SPOT
eamSiteDeployedReport, Get-SPOTeamSiteStorageReport, Get-SPOTenantStorageMetricReport, Get-StaleMailboxDetailReport, Get-StaleMailboxReport, Get-Subscription, Get-SupervisoryReviewA
ctivity, Get-SupervisoryReviewPolicyReport, Get-SupervisoryReviewPolicyV2, Get-SupervisoryReviewReport, Get-SupervisoryReviewRule, Get-SweepRule, Get-SyncConfig, Get-SyncRequest, Ge
t-SyncRequestStatistics, Get-TenantAnalyticsConfig, Get-TextMessagingAccount, Get-ToolInformation, Get-TransportConfig, Get-TransportRule, Get-TransportRuleAction, Get-TransportRule
Predicate, Get-UMAutoAttendant, Get-UMCallAnsweringRule, Get-UMCallDataRecord, Get-UMCallSummaryReport, Get-UMDialPlan, Get-UMHuntGroup, Get-UMIPGateway, Get-UMMailbox, Get-UMMailbo
xConfiguration, Get-UMMailboxPIN, Get-UMMailboxPlan, Get-UMMailboxPolicy, Get-UMPhoneSession, Get-UnifiedAuditSetting, Get-UnifiedGroup, Get-UnifiedGroupLinks, Get-User, Get-UserAna
lyticsConfig, Get-UserPhoto, Import-ContactList, Import-DlpPolicyCollection, Import-RecipientDataProperty, Import-RMSTrustedPublishingDomain, Import-TransportRuleCollection, Import-
UMPrompt, New-ActiveSyncDeviceAccessRule, New-ActiveSyncMailboxPolicy, New-AdminAuditLogSearch, New-AntiPhishPolicy, New-AntiPhishRule, New-App, New-ApplicationAccessPolicy, New-Aut
henticationPolicy, New-AvailabilityConfig, New-ClassificationRuleCollection, New-ClientAccessRule, New-CompliancePolicySyncNotification, New-ConnectSubscription, New-DataClassificat
ion, New-DistributionGroup, New-DkimSigningConfig, New-DlpPolicy, New-DynamicDistributionGroup, New-ElevatedAccessRequest, New-EmailAddressPolicy, New-Fingerprint, New-HostedConnect
ionFilterPolicy, New-HostedContentFilterPolicy, New-HostedContentFilterRule, New-InboundConnector, New-InboxRule, New-IntraOrganizationConnector, New-JournalRule, New-Mailbox, New-M
ailboxAuditLogSearch, New-MailboxFolder, New-MailboxRestoreRequest, New-MailboxSearch, New-MailContact, New-MailMessage, New-MailUser, New-MalwareFilterPolicy, New-MalwareFilterRule
, New-ManagementRole, New-ManagementRoleAssignment, New-ManagementScope, New-MessageClassification, New-MigrationBatch, New-MigrationEndpoint, New-MobileDeviceMailboxPolicy, New-Mov
eRequest, New-OMEConfiguration, New-OnPremisesOrganization, New-OrganizationRelationship, New-OutboundConnector, New-OutlookProtectionRule, New-OwaMailboxPolicy, New-PartnerApplicat
ion, New-PolicyTipConfig, New-PrivilegedIdentityManagementRequest, New-ProtectionServicePolicy, New-PublicFolder, New-PublicFolderMigrationRequest, New-RemoteDomain, New-ReportSched
ule, New-RetentionPolicy, New-RetentionPolicyTag, New-RoleAssignmentPolicy, New-RoleGroup, New-SchedulingMailbox, New-SharingPolicy, New-SiteMailbox, New-SiteMailboxProvisioningPoli
cy, New-SweepRule, New-SyncMailPublicFolder, New-SyncRequest, New-TransportRule, New-UMAutoAttendant, New-UMCallAnsweringRule, New-UMDialPlan, New-UMHuntGroup, New-UMMailboxPolicy, 
New-UnifiedGroup, Preview-QuarantineMessage, Release-QuarantineMessage, Remove-ActiveSyncDevice, Remove-ActiveSyncDeviceAccessRule, Remove-ActiveSyncMailboxPolicy, Remove-AntiPhishP
olicy, Remove-AntiPhishRule, Remove-App, Remove-ApplicationAccessPolicy, Remove-AuditConfigurationPolicy, Remove-AuditConfigurationRule, Remove-AuditStubFolder, Remove-Authenticatio
nPolicy, Remove-AvailabilityAddressSpace, Remove-AvailabilityConfig, Remove-BlockedSenderAddress, Remove-CalendarEvents, Remove-ClassificationRuleCollection, Remove-ClientAccessRule
, Remove-CompliancePolicyFileSyncNotification, Remove-CompliancePolicySyncNotification, Remove-ConnectSubscription, Remove-DataClassification, Remove-DistributionGroup, Remove-Distr
ibutionGroupMember, Remove-DlpPolicy, Remove-DynamicDistributionGroup, Remove-EmailAddressPolicy, Remove-HostedConnectionFilterPolicy, Remove-HostedContentFilterPolicy, Remove-Hoste
dContentFilterRule, Remove-HybridConfiguration, Remove-InboundConnector, Remove-InboxRule, Remove-IntraOrganizationConnector, Remove-JournalRule, Remove-Mailbox, Remove-MailboxFolde
rPermission, Remove-MailboxLocation, Remove-MailboxPermission, Remove-MailboxRestoreRequest, Remove-MailboxSearch, Remove-MailboxUserConfiguration, Remove-MailContact, Remove-MailUs
er, Remove-MalwareFilterPolicy, Remove-MalwareFilterRule, Remove-ManagementRole, Remove-ManagementRoleAssignment, Remove-ManagementRoleEntry, Remove-ManagementScope, Remove-MessageC
lassification, Remove-MigrationBatch, Remove-MigrationEndpoint, Remove-MigrationUser, Remove-MobileDevice, Remove-MobileDeviceMailboxPolicy, Remove-MoveRequest, Remove-OMEConfigurat
ion, Remove-OnPremisesOrganization, Remove-OrganizationRelationship, Remove-OutboundConnector, Remove-OutlookProtectionRule, Remove-OwaMailboxPolicy, Remove-PartnerApplication, Remo
ve-PolicyTipConfig, Remove-PublicFolder, Remove-PublicFolderClientPermission, Remove-PublicFolderMailboxMigrationRequest, Remove-PublicFolderMigrationRequest, Remove-RecipientPermis
sion, Remove-RemoteDomain, Remove-ReportSchedule, Remove-RetentionPolicy, Remove-RetentionPolicyTag, Remove-RMSTrustedPublishingDomain, Remove-RoleAssignmentPolicy, Remove-RoleGroup
, Remove-RoleGroupMember, Remove-SharingPolicy, Remove-Subscription, Remove-SweepRule, Remove-SyncMailPublicFolder, Remove-SyncRequest, Remove-TransportRule, Remove-UMAutoAttendant,
 Remove-UMCallAnsweringRule, Remove-UMDialPlan, Remove-UMHuntGroup, Remove-UMIPGateway, Remove-UMMailboxPolicy, Remove-UnifiedGroup, Remove-UnifiedGroupLinks, Remove-UserPhoto, Resu
me-MailboxRestoreRequest, Resume-MoveRequest, Resume-PublicFolderMailboxMigrationRequest, Resume-PublicFolderMigrationRequest, Resume-SyncRequest, Revoke-ElevatedAccessAuthorization
, Rotate-DkimSigningConfig, Search-AdminAuditLog, Search-MailboxAuditLog, Search-MessageTrackingReport, Search-UnifiedAuditLog, Send-TextMessagingVerificationCode, Set-AcceptedDomai
n, Set-ActiveSyncDeviceAccessRule, Set-ActiveSyncMailboxPolicy, Set-ActiveSyncOrganizationSettings, Set-AdminAuditLogConfig, Set-AntiPhishPolicy, Set-AntiPhishRule, Set-App, Set-App
licationAccessPolicy, Set-AuthenticationPolicy, Set-AvailabilityConfig, Set-CalendarNotification, Set-CalendarProcessing, Set-CASMailbox, set-CASMailboxPlan, Set-ClassificationRuleC
ollection, Set-ClientAccessRule, Set-Clutter, Set-ConnectSubscription, Set-Contact, Set-DataClassification, Set-DataEncryptionPolicy, Set-DistributionGroup, Set-DkimSigningConfig, S
et-DlpPolicy, Set-DynamicDistributionGroup, Set-ElevatedAccessRequest, Set-EmailAddressPolicy, Set-FederatedOrganizationIdentifier, Set-FocusedInbox, Set-Group, Set-GroupMailbox, Se
t-HostedConnectionFilterPolicy, Set-HostedContentFilterPolicy, Set-HostedContentFilterRule, Set-HostedOutboundSpamFilterPolicy, Set-HotmailSubscription, Set-HybridMailflow, Set-Imap
Subscription, Set-InboundConnector, Set-InboxRule, Set-IntraOrganizationConnector, Set-IRMConfiguration, Set-JournalRule, Set-LinkedUser, Set-Mailbox, Set-MailboxAuditBypassAssociat
ion, Set-MailboxAutoReplyConfiguration, Set-MailboxCalendarConfiguration, Set-MailboxCalendarFolder, Set-MailboxFolderPermission, Set-MailboxJunkEmailConfiguration, Set-MailboxLocat
ion, Set-MailboxMessageConfiguration, Set-MailboxPlan, Set-MailboxRegionalConfiguration, Set-MailboxRestoreRequest, Set-MailboxSearch, Set-MailboxSpellingConfiguration, Set-MailCont
act, Set-MailPublicFolder, Set-MailUser, Set-MalwareFilterPolicy, Set-MalwareFilterRule, Set-ManagementRoleAssignment, Set-ManagementRoleEntry, Set-ManagementScope, Set-MessageClass
ification, Set-MigrationBatch, Set-MigrationConfig, Set-MigrationEndpoint, Set-MigrationUser, Set-MobileDeviceMailboxPolicy, Set-MoveRequest, Set-Notification, Set-OMEConfiguration,
 Set-OMEMessageRevocation, Set-OnPremisesOrganization, Set-Organization, Set-OrganizationConfig, Set-OrganizationRelationship, Set-OutboundConnector, Set-OutlookProtectionRule, Set-
OwaMailboxPolicy, Set-PartnerApplication, Set-PerimeterConfig, Set-PhishFilterPolicy, Set-Place, Set-PolicyTipConfig, Set-PopSubscription, Set-ProtectionServicePolicy, Set-PublicFol
der, Set-PublicFolderMailboxMigrationRequest, Set-PublicFolderMigrationRequest, Set-RemoteDomain, Set-ReportSchedule, Set-ResourceConfig, Set-RetentionPolicy, Set-RetentionPolicyTag
, Set-RMSTemplate, Set-RMSTrustedPublishingDomain, Set-RoleAssignmentPolicy, Set-RoleGroup, Set-SharingPolicy, Set-SiteMailbox, Set-SiteMailboxProvisioningPolicy, Set-SmimeConfig, S
et-SweepRule, Set-SyncRequest, Set-TenantAnalyticsConfig, Set-TextMessagingAccount, Set-TransportConfig, Set-TransportRule, Set-UMAutoAttendant, Set-UMCallAnsweringRule, Set-UMDialP
lan, Set-UMIPGateway, Set-UMMailbox, Set-UMMailboxConfiguration, Set-UMMailboxPIN, Set-UMMailboxPolicy, Set-UnifiedAuditSetting, Set-UnifiedGroup, Set-User, Set-UserAnalyticsConfig,
 Set-UserPhoto, Start-AuditAssistant, Start-HistoricalSearch, Start-ManagedFolderAssistant, Start-MigrationBatch, Start-MigrationUser, Start-UMPhoneSession, Stop-HistoricalSearch, S
top-MigrationBatch, Stop-MigrationUser, Stop-UMPhoneSession, Suspend-MailboxRestoreRequest, Suspend-MoveRequest, Suspend-PublicFolderMailboxMigrationRequest, Suspend-PublicFolderMig
rationRequest, Suspend-SyncRequest, Test-ApplicationAccessPolicy, Test-ClientAccessRule, Test-DataClassification, Test-DataEncryptionPolicy, Test-IRMConfiguration, Test-MAPIConnecti
vity, Test-MigrationServerAvailability, Test-OAuthConnectivity, Test-OrganizationRelationship, Test-SiteMailbox, Test-TextExtraction, Troubleshoot-AgendaMail, Undo-SoftDeletedMailbo
x, Undo-SoftDeletedUnifiedGroup, Update-DistributionGroupMember, Update-HybridConfiguration, Update-PublicFolderMailbox, Update-Recipient, Update-RoleGroupMember, Update-SiteMailbox
, Upgrade-DistributionGroup, Validate-OutboundConnector, Validate-RetentionRuleQuery, Write-AdminAuditLog', because it would shadow an existing local command.  Use the AllowClobber 
parameter if you want to shadow existing local commands.
Import-PSSession : No command proxies have been created, because all of the requested remote commands would shadow existing local commands.  Use the AllowClobber parameter if you 
want to shadow existing local commands.
At AuditMailboxEnabled.ps1:7 char:1
+ Import-PSSession $ExoSession
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidResult: (:) [Import-PSSession], ArgumentException
    + FullyQualifiedErrorId : ErrorNoCommandsImportedBecauseOfSkipping,Microsoft.PowerShell.Commands.ImportPSSessionCommand

MFA

having issues running this with MFA enabled

MailboxAudit Script

Hey, I just ran your script for enabling mailbox auditing on all mailboxes. What I found is the script doesn't include Equipment mailboxes. Is that on purpose?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.