Skip to content

Commit

Permalink
Merge pull request #1758 from microsoft/lusassl-HCInternetWebProxyImp…
Browse files Browse the repository at this point in the history
…rovement

Proxy type check improved to prevent false-positives
  • Loading branch information
lusassl-msft authored Jul 13, 2023
2 parents 77a652a + 9c3d309 commit 3534c83
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -253,7 +253,7 @@ function Invoke-AnalyzerExchangeInformation {

if ([string]::IsNullOrEmpty($internetProxy)) {
$params.Details = "Not Set"
} elseif ($internetProxy -notmatch "(http:\/\/)(?:[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?\.)+[a-z0-9][a-z0-9-]{0,61}[a-z0-9]") {
} elseif ($internetProxy.Scheme -ne "http") {
<#
We use the WebProxy class WebProxy(Uri, Boolean, String[]) constructor when running Set-ExchangeServer -InternetWebProxy,
which throws an UriFormatException if the URI provided cannot be parsed.
Expand Down

0 comments on commit 3534c83

Please sign in to comment.