* Added a switch not to force RC4-HMAC when requesting a TGT as newer servers (e.g., 2025) won't issue service tickets when provided with RC4-HMAC TGT.
* Update examples/GetUserSPNs.py
Co-authored-by: alexisbalbachan <alexisbalbachan@gmail.com>
---------
Co-authored-by: alexisbalbachan <alexisbalbachan@gmail.com>
* GetUserSPN's update to test machineonly flag
* GetUserSPN's update to test machineonly flag
* GetUserSPN's update to test machineonly flag
* GetUserSPN's update to test machineonly flag
* GetUserSPN's update to test machineonly flag
* GetUserSPN's update to test machineonly flag
* GetUserSPN's update to test machineonly flag
* GetUserSPN's update to test machineonly flag
* GetUserSPN's update to test machineonly flag
* Better naming of argument
* Better naming of argument
* Logging of machineOnly code
* Logging of machineOnly code
* ArgParse Description
* ArgParse Description
* ArgParse Description
* ArgParse Description
* Update examples/GetUserSPNs.py
Co-authored-by: alexisbalbachan <alexisbalbachan@gmail.com>
* Update examples/GetUserSPNs.py
Co-authored-by: alexisbalbachan <alexisbalbachan@gmail.com>
* Update GetUserSPNs.py
Added `or self.__requestMachine is not None`
* Update GetUserSPNs.py
Restore old formatting
---------
Co-authored-by: alexisbalbachan <alexisbalbachan@gmail.com>
* Standardized examples logger init method
* Fixing missing import
* Standardized examples init_ldap_session function #1
* Calling new shared function _ldap3_kerberos_login from example addcomputer
* Removed considering -debug in each example. Now it's handled in utils.
* Standardized EMPTY_LM_HASH in impacket.examples.utils
* Unify parse_identity function (phase 1)
* Standardized parse_identity
* Renamed "_ldap3_kerberos_login" to "ldap3_kerberos_login" (as it is called from outside)
* Standardize "logger" init in regsecrets.py
* Standardized LDAP login into a single function in utils.py:ldap_login
* Fixed unicode shares not being found
* Fixed unicode SPNs not being decoded appropriately
* Fixed spn not being found in getST, fixes#1595
* Fixed unicode issues on login when using ntlmV1 fallback
Fixes#1419
* Support for ASREPKerberoast
* Fixing undefined name 'tgs'
* Typo on the argument, -preauth changed to -no-preauth
* Fixing args handling, -usersfile is needed if -no-preauth
* Handling case when service is None
* Update kerberosv5.py
* adding param to getKerberosTGT to return or raise depending on context
* specifying serverName param in getKerberosTGT calls
* specifying serverName param in getKerberosTGT calls
This was a pending change to:
- Use the same tagline, copyright and license notice across files.
- Remove authors' contacts that are no longer valid (due to affiliation changes).
- Update repository location.
- Update license file with missing licenses (althought those were already in source files).
This doesn't include any change on the source code, nor any change on current copyright or licenses. Just formatting and phrasing to make our and distro's maintainers life easier.
Similar to and on top of #1053, this moves the credentials/account parsing regex to an utils module and reduces duplicated code in example scripts.
The expected credential format is:
`<DOMAIN></USERNAME><:PASSWORD>`
Note that the regular expression used in `exchanger.py` was different (excluded ':' from the hostname) but I didn't found any reason to keep it different from all other scripts.
This PR:
- Moved credentials parsing routine to an utils module.
- Added unit tests for the new function.
- Using the new function across example scripts that accept a credential/account.
* Added -usersfile flag to GetUserSPNs.py
* Handling of -usersfile flag in GetNPUsers.py is moved higher to skip unnecessary connections to SMB (BTW, it's weird that the script connects to SMB in Kerberoasting)
Added a column to GetUserSPNs.py that returns delegation information associated with the account. Useful to help identify accounts to target & to expose additional potential attack paths.