Invalid Netbios Names? Re: [SCM] Samba Shared Repository - branch master updated

2010-10-30 Thread Stefan (metze) Metzmacher
Hi Matthieu, Author: Matthieu Patou m...@matws.net Date: Thu Oct 28 13:09:51 2010 +0400 provision: when deriving netbiosname from hostname force the netbiosname to be compliant It means no space/_/-/@ and less than 16 chars. What's wrong with '-'? It's allowed in

Re: Invalid Netbios Names? Re: [SCM] Samba Shared Repository - branch master updated

2010-10-30 Thread Matthieu Patou
Hi Metze Date: Thu Oct 28 13:09:51 2010 +0400 provision: when deriving netbiosname from hostname force the netbiosname to be compliant It means no space/_/-/@ and less than 16 chars. What's wrong with '-'? It's allowed in netbios and dns names. See

Re: Invalid Netbios Names? Re: [SCM] Samba Shared Repository - branch master updated

2010-10-30 Thread Jelmer Vernooij
On Sat, 2010-10-30 at 20:04 +0400, Matthieu Patou wrote: Hi Metze Date: Thu Oct 28 13:09:51 2010 +0400 provision: when deriving netbiosname from hostname force the netbiosname to be compliant It means no space/_/-/@ and less than 16 chars. What's wrong with '-'?

Re: Invalid Netbios Names? Re: [SCM] Samba Shared Repository - branch master updated

2010-10-30 Thread Matthieu Patou
def valid_netbios_name(name): Check whether a name is valid as a NetBIOS name. # See crh's book (1.4.1.1) if len(name) 15: return False for x in name: if not x.isalnum() and not x in !#$%'()-...@^_{}~: return False return True