Bug 12834 - 'unix charset' issue in 4.6 branch
Summary: 'unix charset' issue in 4.6 branch
Status: RESOLVED FIXED
Alias: None
Product: Samba 4.1 and newer
Classification: Unclassified
Component: File services (show other bugs)
Version: 4.6.0
Hardware: All All
: P5 normal (vote)
Target Milestone: ---
Assignee: Samba QA Contact
QA Contact: Samba QA Contact
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-06-12 09:07 UTC by Francesco
Modified: 2020-05-06 11:08 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Francesco 2017-06-12 09:07:42 UTC
In a samba server 4.6.*, if I set in smb.conf the directive:

unix charset = ISO-8859-15

The command:

$ ./bin/smbclient -U% -L localhost -d10
[...]
smb_signing_sign_pdu: sent SMB signature of
[0000] 42 53 52 53 50 59 4C 20                             BSRSPYL
convert_string_talloc: Conversion error: Illegal multibyte sequence()
SPNEGO login failed: Undetermined error
session setup failed: NT_STATUS_UNSUCCESSFUL

fails if smbclient version is 4.6.* (otherwise it works even with 'unix
charset' setting).

This happen 100% of the time, behaviour started with the 4.6 branch.

Matching log on server is:

[...]
 NativeOS=[Unix] NativeLanMan=[Samba] PrimaryDomain=[]
[2017/06/09 11:43:01.509339,  3]
../lib/ldb-samba/ldb_wrap.c:325(ldb_wrap_connect)
  ldb_wrap open of secrets.ldb
[2017/06/09 11:43:01.512271,  3]
../auth/ntlmssp/ntlmssp_util.c:69(debug_ntlmssp_flags)
  Got NTLMSSP neg_flags=0x62088215
[2017/06/09 11:43:01.513515,  3]
../source3/smbd/server_exit.c:246(exit_server_common)
  Server exit (failed to receive smb request)
[2017/06/09 11:43:01.519089,  3]
../source3/lib/util_procid.c:54(pid_to_procid)
  pid_to_procid: messaging_dgm_get_unique failed: File or directory not
found
Comment 1 Giulio 2017-06-21 12:07:36 UTC
Similar issue here.

Problem only if using SMB1, ie:

smbclient ... -m nt1 -> error:
...
convert_string_talloc: Conversion error: Illegal multibyte sequence()
SPNEGO login failed: Undetermined error
got OID=1.3.6.1.4.1.311.2.2.10
convert_string_talloc: Conversion error: Illegal multibyte sequence()
SPNEGO login failed: Undetermined error
session setup failed: NT_STATUS_UNSUCCESSFUL

smbclient ... -m smb2 -> OK


Applying patch from https://bugzilla.samba.org/show_bug.cgi?id=12824
seems to solve this issue.
Comment 2 Björn Jacke 2020-05-06 11:08:09 UTC
just tested that this works.

"client min protocol = NT1" has to be set in smb.conf *and* -m nt1 has to be used for smbclient. Just "-m nt1" will cause smbclient to claim "protocol negotiation failed: NT_STATUS_INVALID_PARAMETER_MIX", which is a bit unexpected behaviour imho.