SMBMAP OSError: Cannot load native module 'Cryptodome.Hash._MD5'

edited June 2020 in Off-topic

I've tried uninstalling + reisntalling smbmap, cloning and installing from the Github repo. re-installing Pycryptodome. I continue to get the following error when running the most basic smbmap commands:

python ./smbmap.py -H 10.10.10.100

File "smbmap.py", line 72
print(' '*32, end='')
^
SyntaxError: invalid syntax
(The arrow is pointing at the equal sign)

OR outside the smbmap folder

smbmap -H 10.10.10.100

Traceback (most recent call last):
File "/usr/bin/smbmap", line 19, in <module>
from impacket import version, smbserver
File "/home/inkjet-printer/.local/lib/python3.7/site-packages/impacket/smbserver.py", line 47, in <module> from impacket import smb, nmb, ntlm, uuid
File "/home/inkjet-printer/.local/lib/python3.7/site-packages/impacket/smb.py", line 54, in <module> from impacket.krb5.gssapi import KRB5_AP_REQ
File "/home/inkjet-printer/.local/lib/python3.7/site-packages/impacket/krb5/gssapi.py", line 20, in <module> from Cryptodome.Hash import HMAC, MD5
File "/usr/lib/python3/dist-packages/Cryptodome/Hash/HMAC.py", line 38, in <module> from Cryptodome.Hash import MD5
File "/usr/lib/python3/dist-packages/Cryptodome/Hash/MD5.py", line 47, in <module> """)
File "/usr/lib/python3/dist-packages/Cryptodome/Util/_raw_api.py", line 303, in load_pycryptodome_raw_lib

raise OSError("Cannot load native module '%s': %s" % (name, ", ".join(attempts)))
OSError: Cannot load native module 'Cryptodome.Hash._MD5': Trying '_MD5.cpython-37m-x86_64-linux-gnu.so': cannot load library '/usr/lib/python3/dist-packages/Cryptodome/Util/../Hash/_MD5.cpython-37m-x86_64-linux-gnu.so': /usr/lib/python3/dist-packages/Cryptodome/Util/../Hash/_MD5.cpython-37m-x86_64-linux-gnu.so: cannot open shared object file: No such file or directory. Additionally, ctypes.util.find_library() did not manage to locate a library called '/usr/lib/python3/dist-packages/Cryptodome/Util/../Hash/_MD5.cpython-37m-x86_64-linux-gnu.so', Trying '_MD5.abi3.so': cannot load library '/usr/lib/python3/dist-packages/Cryptodome/Util/../Hash/_MD5.abi3.so': /usr/lib/python3/dist-packages/Cryptodome/Util/../Hash/_MD5.abi3.so: cannot open shared object file: No such file or directory. Additionally, ctypes.util.find_library() did not manage to locate a library called '/usr/lib/python3/dist-packages/Cryptodome/Util/../Hash/_MD5.abi3.so', Trying '_MD5.so': cannot load library '/usr/lib/python3/dist-packages/Cryptodome/Util/../Hash/_MD5.so': /usr/lib/python3/dist-packages/Cryptodome/Util/../Hash/_MD5.so: cannot open shared object file: No such file or directory. Additionally, ctypes.util.find_library() did not manage to locate a library called '/usr/lib/python3/dist-packages/Cryptodome/Util/../Hash/_MD5.so'

What is happening here?
Thanks

Tagged:

Comments

  • edited June 2020

    Just notice that you was using it with Python3 (edited)

  • Thanks for the reply. When I do the first command using python3 instead of python I get the same error output as the second command. The output mentioning Cryptodome.Hash._MD5

  • Cruft, did you ever find a solution to the error? When I run smbmap -H 10.x.x.x I get the following error also.

    ModuleNotFoundError: No module named 'Cryptodome.Hash'

  • edited February 4

    Unfortunately I do not remember. It was something simple, maybe add sudo. Sorry.

Sign In to comment.