ideas for supporting long smb.conf variables?

Gerald (Jerry) Carter jerry at samba.org
Wed Mar 8 20:43:30 GMT 2006


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Gerald (Jerry) Carter wrote:
> Folks,
> 
> 
> I'm going to toy with long variable names in smb.conf
> along with support SID strings in the valid users, etc...
> Right now %%(name) looks attractive since we already use
> %$(name) for environment variable support.
> 
> So for example, we would have something like:
> 
> 	valid users = %%(domainsid)-513
> 
> for the DOMAIN\Domain Users SID.  Remember that the purpose
> of this is to allow programmatic access without having
> worry about localization issues surrounding well know domain
> groups.  I'm sure people will find other clever ways to use
> it as well.
> 
> How do people fell about that syntax ?

Volker and I (and others) chatted briefly on #samba-technical.

I see 3 goals here:

a) develop an unambiguous or at least rarely conflicting syntax
   for smb.conf variables.  We all know the %L vs. %LOGONSERVER%
   issues
b) consolidate the number of static, alloc()'d and talloc()'d
   versions of the substitute routines.
c) get rid of the dependency on global variables for state.

Volker's idea for solving (c) was to move to an environment
type API.  The caller would be responsible for setting the
necessary smb.conf env strings that it cared about.

And finally, there's some debate over the string format.  I
choose %%(...) to coincide with %$(...) which we already use for
shell environment variables.  Some people would prefer %(...)
which is fine with me as long as we feel fairly confident that
Win32 won't use %(...)% in client side environment variable
settings.

I'll probably start drafting some things later tonight so
any immediate feedback would be appreciated.





cheers, jerry

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.2 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFED0HyIR7qMdg1EfYRAs+tAKCbSiv7FHMy/TFPHdSIBe9CJYx+OwCfRKvX
J9hRosD2zHlFhzwNyTg2P4w=
=MBCe
-----END PGP SIGNATURE-----


More information about the samba-technical mailing list