Tips for finding Knowledge Articles

  • - Enter just a few key words related to your question or problem
  • - Add Key words to refine your search as necessary
  • - Do not use punctuation
  • - Search is not case sensitive
  • - Avoid non-descriptive filler words like "how", "the", "what", etc.
  • - If you do not find what you are looking for the first time,reduce the number of key words you enter and try searching again.
  • - Minimum supported Internet Explorer version is IE9
Home  >
article

KB-7086: Samba displays incorrect OS information

29 June,16 at 05:40 PM


Applies to: 

Samba 4.2 and later. 


Question: 

Why does Samba report its OS as Windows when it is running on a Unix / Linux OS? 
 
[ckelly@centos7-1 ~]$ smbclient -U ckelly //centos7-1/Samba-Select
Enter ckelly's password:
Domain=[ALWAYS] OS=[Windows 6.1] Server=[Samba 4.2.10]
smb: \>


Answer: 

This is due to Samba 4.2.x and later codes native_os = "Windows %d.%d" while Samba 4.1.x and older uses native_os = "Unix". Please see below for clarification.
This is a Samba issue and Centrify does not have any control over this. 

 
Samba-4.2.x, the push_signature() uses native_os = "Windows %d.%d" 
==============
samba-4.2.x:
static int push_signature(uint8 **outbuf)
{
	char *lanman;
	int result, tmp;
	fstring native_os;

	result = 0;

	fstr_sprintf(native_os, "Windows %d.%d", SAMBA_MAJOR_NBT_ANNOUNCE_VERSION,
		SAMBA_MINOR_NBT_ANNOUNCE_VERSION);

	tmp = message_push_string(outbuf, native_os, STR_TERMINATE);

  ...
}
==============

while samba-4.1.x uses native_os = "Unix"   
==========
static int push_signature(uint8 **outbuf)
{
	char *lanman;
	int result, tmp;

	result = 0;

	tmp = message_push_string(outbuf, "Unix", STR_TERMINATE);

	...
}
================



 

Still have questions? Click here to log a technical support case, or collaborate with your peers in Centrify's Online Community.