-
Notifications
You must be signed in to change notification settings - Fork 12
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Binary attributes are cut on \x00 #32
Comments
Because we don't really use binary attributes internally, it hadn't been implemented yet. The Please try it out and let me know if it works for you. If it does, I'll merge it and do a release sometime soon. |
(following #30) Hum, I don't know what happen. Sorry about that. So, fetching an entry works fine, I get the right value in When I set a new value and save the entry. I get an error:
I have try to fetch the entry before setting the attribute, same error. But if I set something else, it will work:
|
Hm, I don't really have a good idea to fix this. Would it be possible for you to get some logs and figure out what exactly the LDAP server is complaining about? Debug level 256 ( |
Ok, I understand. In wireshark, I see the error message : So thank you, this works perfectly. I really look forward to see this branch merged in master and published on pypi. |
Good to hear that it's working for you. The error when saving without modifications doesn't sound familiar to me. Just to clarify, do you also get an error when you do this?
|
In fact, there is 2 different errors, when I doesn't set any attribute, and when I set an attribute with the same value it already have. The first is raised by LDAPom, so it is ok. The second is quite annoying because the error is not very clear.
|
Ha, the second error is interesting, because the following order of operations works perfectly for me:
Hopefully, we can trace this down. I've opened #33 to deal with this. |
I've merged this feature into |
Thank you very much. |
Hi,
I have a problem when I set a binary attribute with a value containing "\x00" (Null Character).
In connection.py, line 391, after doing
strval = ffi.new("char[]", value)
:This must cause a problem in CFFI, because
\x00
means "end of string" in C.What do you think ? Can I escape theses bytes ?
Thanks.
The text was updated successfully, but these errors were encountered: