Documentation Index
Fetch the complete documentation index at: https://mintlify.com/the-useless-one/pywerview/llms.txt
Use this file to discover all available pages before exploring further.
get-netsmsa queries Active Directory for all objects of class msDS-ManagedServiceAccount, the older, single-host variant of Managed Service Accounts. For each account the command returns the samAccountName, distinguished name, object SID, description, the computer it is bound to (msDS-HostServiceAccountBL), and a derived Enabled field based on the userAccountControl flags. Because sMSA accounts are scoped to exactly one machine, discovery is useful during assessments to identify service accounts, understand the host-to-account relationship, and detect any misconfigured or orphaned accounts across the domain.
gMSA vs sMSA: Group Managed Service Accounts (
msDS-GroupManagedServiceAccount) can be shared across many computers and support automatic password retrieval over LDAPS. Standalone Managed Service Accounts (msDS-ManagedServiceAccount) predate gMSA and are restricted to a single computer — the host is recorded in msDS-HostServiceAccountBL. sMSA passwords are managed automatically by the domain but cannot be retrieved via LDAP the way gMSA passwords can. Where possible, modern deployments favour gMSA. Use get-netgmsa to enumerate gMSA accounts.Flags
Global flags
IP address of the Domain Controller to target.
Name of the domain to authenticate with.
Username used to connect to the Domain Controller.
Password associated with the username.
NTLM hashes for pass-the-hash authentication. Format:
[LMHASH:]NTHASH. Use :$NTHASH to supply only the NT hash.Use Kerberos authentication. Credentials are sourced from the
KRB5CCNAME ccache file based on target parameters, falling back to the values provided on the command line.Force a TLS (LDAPS) connection to the Domain Controller.
Path to a certificate file for certificate-based authentication.
Path to the private key associated with the certificate.
Force SIMPLE LDAP authentication instead of the default SASL/NTLM bind.
STDERR logging verbosity. Choices:
CRITICAL (default), WARNING, DEBUG, ULTRA.Print results in JSON format instead of the default key-value output.
Command-specific flags
Filter results by object SID. Wildcards accepted.
Filter results by
samAccountName. Wildcards accepted (e.g. svc*$).Filter results by object name attribute. Wildcards accepted.
Target domain to query. Defaults to the domain of the authenticating user.
Additional ADS path to narrow the LDAP search base (e.g.
CN=Managed Service Accounts,DC=contoso,DC=com).