diff --git a/Fix-OfficeModernAuth.ps1 b/Fix-OfficeModernAuth.ps1 new file mode 100644 index 0000000..c5efd06 --- /dev/null +++ b/Fix-OfficeModernAuth.ps1 @@ -0,0 +1,7 @@ +$REG_PATH = 'HKCU:\SOFTWARE\Microsoft\Exchange' +$REG_PROP = 'AlwaysUseMSOAuthForAutoDiscover' +If ( !((Get-ItemProperty -Path $REG_PATH -Name $REG_PROP).$REG_PROP) ) { + LogMsg "Adding registry entry: ""${REG_PATH}\${REG_PROP}"" = 1" + Try { New-ItemProperty -Path $REG_PATH -Name $REG_PROP -PropertyType DWord -Value 1 } + Catch { LogErr $_.Exception.Message } +} \ No newline at end of file diff --git a/rmm/Fix-OfficeModernAuth.ps1 b/rmm/Fix-OfficeModernAuth.ps1 new file mode 100644 index 0000000..6e0bf9b --- /dev/null +++ b/rmm/Fix-OfficeModernAuth.ps1 @@ -0,0 +1,2 @@ +. $([Scriptblock]::Create((New-Object Net.WebClient).DownloadString('https://dev.emberkom.com/emberkom/management-scripts/raw/branch/master/Tools.ps1'))) +Run-Script -LivePSScript Fix-OfficeModernAuth \ No newline at end of file