| skipped 21 lines |
22 | 22 | | try |
23 | 23 | | { |
24 | 24 | | write-host "testing site..." -ForegroundColor Gray |
25 | | - | $webtest3 = invoke-webrequest -uri "https://$target/autodiscover/[email protected]/owa/&Email=autodiscover/[email protected]&Protocol=HACKER&Protocol=PowerShell" -Verbose |
| 25 | + | $webtest2 = invoke-webrequest -uri "https://$target/autodiscover/[email protected]/owa/&Email=autodiscover/[email protected]&Protocol=HACKER&Protocol=PowerShell" -Verbose |
26 | 26 | | } |
27 | 27 | | catch |
28 | 28 | | { |
| skipped 23 lines |
52 | 52 | | { |
53 | 53 | | write-host "DNS does not resolve" -ForegroundColor Red |
54 | 54 | | } |
| 55 | + | |
55 | 56 | | if(Get-Variable webtest1 -ErrorAction SilentlyContinue){Clear-Variable webtest1} |
56 | 57 | | if(Get-Variable webtest2 -ErrorAction SilentlyContinue){Clear-Variable webtest2} |
57 | 58 | | |