Describe the bug
Passwords with special characters causes the ldap-checker module to break. Using the password Password?! with the ldap-checker module results in the error:
something went wrong during ldaps_withEPA bind:Port could not be cast to integer value as 'Password'
Bypass:
Change the password to a password without special chars.
Expected behavior
The scan should work normally
Crackmapexec info
OS: Kali
Version: 5.4.0
Installed from: Source
Additional context
The exact culprit appears to be the LDAPConnectionFactory.from_url method, which incorrectly parses the questionmark and sees it as query parameters.
The best way to approach this would be to not create and re-parse credentials, but simply make the required objects by hand.
from msldap.commons.target import MSLDAPTarget
from msldap.commons.factory import LDAPConnectionFactory
from asyauth.common.credentials import UniCredential
target = MSLDAPTarget(...)
credential = UniCredential(...)
factory = LDAPConnectionFactory(credential, target)
Describe the bug Passwords with special characters causes the ldap-checker module to break. Using the password
Password?!
with theldap-checker
module results in the error:To Reproduce
Bypass: Change the password to a password without special chars.
Expected behavior The scan should work normally
Crackmapexec info
Additional context The exact culprit appears to be the LDAPConnectionFactory.from_url method, which incorrectly parses the questionmark and sees it as query parameters.
The best way to approach this would be to not create and re-parse credentials, but simply make the required objects by hand.