[Samba] Password change via samba-tool: encoding issue

Sergio Rizzi sergio.rizzi at labs.it
Mon Mar 24 10:09:38 MDT 2014


On 24/03/2014 17:00, Chan Min Wai wrote:
> Just to ask
>
> Care to try
>
> samba-tool user setpassword foo
>
> and type the password in command line?
>
> Your "�" seem to be not supported... as password

Using keyboard input seems to work.

How to fix using --newpassword ?




>
>
>
>
> On Mon, Mar 24, 2014 at 11:43 PM, Sergio Rizzi <sergio.rizzi at labs.it
> <mailto:sergio.rizzi at labs.it>> wrote:
>
>     On 20/03/2014 15:13, Sergio Rizzi wrote:
>
>         root at samba4dc:~# samba-tool user setpassword "foo" --newpassword="�"
>         ERROR: Failed to set password for user 'foo': 'utf8' codec can't
>         decode
>         byte 0xa8 in position 1: invalid start byte
>             File
>         "/usr/local/samba-4.1.6/lib/__python2.7/site-packages/samba/__netcmd/user.py",
>         line 586, in run
>               username=username)
>             File
>         "/usr/local/samba-4.1.6/lib/__python2.7/site-packages/samba/__samdb.py",
>         line 476, in setpassword
>               pw = unicode('"' + password + '"',
>         'utf-8').encode('utf-16-le')
>
>         How to fix it?
>
>
>     Any hint?
>
>
>     --
>     To unsubscribe from this list go to the following URL and read the
>     instructions: https://lists.samba.org/__mailman/options/samba
>     <https://lists.samba.org/mailman/options/samba>
>
>


More information about the samba mailing list