ly4k / Certipy

Tool for Active Directory Certificate Services enumeration and abuse
MIT License
2.34k stars 318 forks source link

certipy: error: unrecognized arguments: ESC7 #186

Closed kali64amd closed 10 months ago

kali64amd commented 10 months ago

I'm clueless on this error ......... appreciate any insight !!!

certipy ca -ca 'XYZ-DC01-CA' -add-officer raven -username 'raven@xyz.htb' -password 'password123' -target xyz.htb

certipy: error: unrecognized arguments: certipy ca -ca 'XYZ-DC01-CA' -add-officer raven -username 'raven@xyz.htb' -password 'password123' -target xyz.htb

bug??

ly4k commented 10 months ago

How did you install Certipy? Which version is it?

kali64amd commented 10 months ago

└─$ pip3 install certipy-ad Defaulting to user installation because normal site-packages is not writeable DEPRECATION: Loading egg at /usr/local/lib/python3.11/dist-packages/auto_py_to_exe-2.34.0-py3.11.egg is deprecated. pip 24.3 will enforce this behaviour change. A possible replacement is to use pip for package installation.. Discussion can be found at https://github.com/pypa/pip/issues/12330 DEPRECATION: Loading egg at /usr/local/lib/python3.11/dist-packages/pyinstaller-5.10.1-py3.11-linux-x86_64.egg is deprecated. pip 24.3 will enforce this behaviour change. A possible replacement is to use pip for package installation.. Discussion can be found at https://github.com/pypa/pip/issues/12330 DEPRECATION: Loading egg at /usr/local/lib/python3.11/dist-packages/wifiphisher-1.4-py3.11.egg is deprecated. pip 24.3 will enforce this behaviour change. A possible replacement is to use pip for package installation.. Discussion can be found at https://github.com/pypa/pip/issues/12330 Requirement already satisfied: certipy-ad in /usr/lib/python3/dist-packages (4.7.0)

┌──(shinobix㉿shinobix)-[~] └─$ pip --version pip 23.3 from /usr/lib/python3/dist-packages/pip (python 3.11)

┌──(shinobix㉿shinobix)-[~] └─$ certipy-ad -v Certipy v4.7.0 - by Oliver Lyak (ly4k)

ly4k commented 10 months ago

Can you show me the output of certipy ca -h and certipy -h?

kali64amd commented 10 months ago

┌──(shinobix㉿shinobix)-[~] └─$ certipy ca -h usage: certipy [-h] [--ca-name CA_NAME] [--overwrite] [--rm] [--cert-type {rsa,dsa}] [--bits BITS] [--valid VALID] [--alt-names ALT_NAMES] [--store-dir STORE_DIR] name

Certipy: Create simple, self-signed certificate authorities and certs.

positional arguments: name Name of the cert to create, defaults to creating a CA cert. If no signing --ca-name specified.

options: -h, --help show this help message and exit --ca-name CA_NAME The name of the CA to sign this cert. --overwrite If the cert already exists, bump the serial and overwrite it. --rm Remove the cert specified by name. --cert-type {rsa,dsa} The type of cert to create. --bits BITS The number of bits to use. --valid VALID Years the cert is valid for. --alt-names ALT_NAMES Alt names for the certificate (comma delimited). --store-dir STORE_DIR The location for the store and certs.

┌──(shinobix㉿shinobix)-[~] └─$ certipy -h usage: certipy [-h] [--ca-name CA_NAME] [--overwrite] [--rm] [--cert-type {rsa,dsa}] [--bits BITS] [--valid VALID] [--alt-names ALT_NAMES] [--store-dir STORE_DIR] name

Certipy: Create simple, self-signed certificate authorities and certs.

positional arguments: name Name of the cert to create, defaults to creating a CA cert. If no signing --ca-name specified.

options: -h, --help show this help message and exit --ca-name CA_NAME The name of the CA to sign this cert. --overwrite If the cert already exists, bump the serial and overwrite it. --rm Remove the cert specified by name. --cert-type {rsa,dsa} The type of cert to create. --bits BITS The number of bits to use. --valid VALID Years the cert is valid for. --alt-names ALT_NAMES Alt names for the certificate (comma delimited). --store-dir STORE_DIR The location for the store and certs.

ly4k commented 10 months ago

You have the wrong Certipy installed. pip3 uninstall certipy and then reinstall the correct one.

ly4k commented 10 months ago

Or simply run certipy-ad instead of certipy