fullhunt/log4j-scan

Crypto.Cipher import AES, PKCS1_OAEP

ehsan235 opened this issue · 5 comments

File "/home/parallels/Log4j-RCE-Scanner/log4j-scan/log4j-scan.py", line 22, in
from Crypto.Cipher import AES, PKCS1_OAEP
ModuleNotFoundError: No module named 'Crypto'

Same here. Some additional information:

C:\Users\Born2BeOwned\Downloads\log4j-scan>python log4j-scan.py -u "http://www.<undefined>.de"
Traceback (most recent call last):
  File "C:\Users\Born2BeOwned\Downloads\log4j-scan\log4j-scan.py", line 22, in <module>
    from Crypto.Cipher import AES, PKCS1_OAEP
ModuleNotFoundError: No module named 'Crypto'
C:\Users\Born2BeOwned\Downloads\log4j-scan>python --version
Python 3.10.1

C:\Users\Born2BeOwned\Downloads\log4j-scan>python -m pip list
Package            Version
------------------ ---------
certifi            2021.10.8
charset-normalizer 2.0.9
crypto             1.4.1
idna               3.3
Naked              0.1.31
pip                21.3.1
pycryptodome       3.12.0
PyYAML             6.0
requests           2.26.0
setuptools         58.1.0
shellescape        3.8.1
termcolor          1.1.0
urllib3            1.26.7
C:\Users\Born2BeOwned\Downloads\log4j-scan>ver

Microsoft Windows [Version 10.0.22000.318]

It's because of your python version try to use the latest python version

Running the below resolved the issue for me.
pip install pycryptodome==3.4.3

It's because of your python version try to use the latest python version

According to https://www.python.org/ v3.10.1 is the latest version?

Running the below resolved the issue for me. pip install pycryptodome==3.4.3

C:\Users\Born2BeOwned\Downloads\log4j-scan>pip install pycroptodome==3.4.3
ERROR: Could not find a version that satisfies the requirement pycroptodome==3.4.3 (from versions: none)
ERROR: No matching distribution found for pycroptodome==3.4.3

The installed version I'm using is 3.12.0, see above.

We just pushed a fix that will hopefully resolve this issue when using the latest version of pycroptodome. If you're still facing issues, feel free to use the Docker setup as it should not have Python dependencies issues.