aboutsummaryrefslogtreecommitdiff
path: root/Recon
diff options
context:
space:
mode:
authorHarmj0y <will@harmj0y.net>2016-06-24 16:11:20 -0400
committerHarmj0y <will@harmj0y.net>2016-06-24 16:11:20 -0400
commit3049211f533b006a08ec6bfca74e498b20a03a05 (patch)
tree091eaca704b52637da7e58eed2ce810881e7ac83 /Recon
parentcd1e10b8fd442f6bd0a5562706e174e4cfd3e65b (diff)
downloadPowerSploit-3049211f533b006a08ec6bfca74e498b20a03a05.tar.gz
PowerSploit-3049211f533b006a08ec6bfca74e498b20a03a05.zip
Fixed Find-LocalAdminAccess to properly check for the object output from Invoke-CheckLocalAdminAccess...whoops
Diffstat (limited to 'Recon')
-rwxr-xr-xRecon/PowerView.ps18
1 files changed, 4 insertions, 4 deletions
diff --git a/Recon/PowerView.ps1 b/Recon/PowerView.ps1
index 0125ed8..5a187e7 100755
--- a/Recon/PowerView.ps1
+++ b/Recon/PowerView.ps1
@@ -8543,7 +8543,7 @@ filter Get-SiteName {
.EXAMPLE
- PS C:\> Get-NetComputer | Invoke-CheckLocalAdminAccess
+ PS C:\> Get-NetComputer | Get-SiteName
Returns the sites for every machine in AD.
#>
@@ -9844,7 +9844,7 @@ function Invoke-UserHunter {
# see if we're checking to see if we have local admin access on this machine
if ($CheckAccess) {
$Admin = Invoke-CheckLocalAdminAccess -ComputerName $CName
- $FoundUser | Add-Member Noteproperty 'LocalAdmin' $Admin
+ $FoundUser | Add-Member Noteproperty 'LocalAdmin' $Admin.IsAdmin
}
else {
$FoundUser | Add-Member Noteproperty 'LocalAdmin' $Null
@@ -9891,7 +9891,7 @@ function Invoke-UserHunter {
# see if we're checking to see if we have local admin access on this machine
if ($CheckAccess) {
$Admin = Invoke-CheckLocalAdminAccess -ComputerName $ComputerName
- $FoundUser | Add-Member Noteproperty 'LocalAdmin' $Admin
+ $FoundUser | Add-Member Noteproperty 'LocalAdmin' $Admin.IsAdmin
}
else {
$FoundUser | Add-Member Noteproperty 'LocalAdmin' $Null
@@ -11743,7 +11743,7 @@ function Find-LocalAdminAccess {
if($Up) {
# check if the current user has local admin access to this server
$Access = Invoke-CheckLocalAdminAccess -ComputerName $ComputerName
- if ($Access) {
+ if ($Access.IsAdmin) {
$ComputerName
}
}