Web lists-archives.com

[Samba] AD: password change bug?


I'm using samba 4.5.8 (have not tried later), in a domain (linux servers, windows clients). some applications need to use IMAP and force us to use ASCII only password
(read: thunderbird and other mobile apps)

If a user on win7/win10 changes password and uses non-ascii characters
the mail obviously does not work, but the rest of the domain is ok.

so we thought to use the "check password script".

something like:


read -t 2 PWD
ASCII_PWD=$(echo "$PWD"|iconv -f utf-8 -t ascii//TRANSLIT)
if [ "${PWD}" != "${ASCII_PWD}" ]; then
    exit 1
exit 0

Simple, and it **seems** to work.

During testing and debugging I had the script output the input and all
possible conversions from all iconv-supported charsets to utf-8,
because I was seeing strange things. Nothing helped.

Sometimes I would get the correct euro (€) and pund (£) symbols,
but then the password would be truncated 5-8 chars later.
On input, **before** passing to iconv.
most of the times the conversion failed to produce something coherent.

So I would *guess* the input is utf-8, but although the script seems to work,
I am not sure it should go in production, if it is a known problem/bug.

given this:

I suspect it is an old bug, so the question is: should I report it again?
anyone had this problem? thoughts?

Thank you,

To unsubscribe from this list go to the following URL and read the
instructions:  https://lists.samba.org/mailman/options/samba