Hi,

We found a (minor) limit case when using variables containing LDAP
credentials in resources.cfg :
We have a $DOMAINUSER$ variable of the form
$DOMAINUSER$=CN=xxxx,OU=xxxx,dc=xxx
When using this variable for launching commands, we found that the variable
was only substitued with "CN".

Investigating a bit further, we found the culprit in config.py, function
load_params :
each line of the config file was parsed with "=" being the separator char
(with elt.split("="), around line 338) to get on one hand the variable name,
and on the other hand the variable content.
When parsing a value with "=" in it, the string was split in more
components, so what was after the second "=" was lost.
By modifying
elt.split('=')
to
elt.split('=',1)
We ensured that our variable was getting the correct content. So far (one
day after), we didn't experience any side effect regarding to this
modification.

Did it happen to anyone else?
Is there a way to correctly parse the variable content without modifying the
actual code? Or should we submit a proper patch?

Best regards,

Etienne Obriot
------------------------------------------------------------------------------
uberSVN's rich system and user administration capabilities and model 
configuration take the hassle out of deploying and managing Subversion and 
the tools developers use with it. Learn more about uberSVN and get a free 
download at:  http://p.sf.net/sfu/wandisco-dev2dev
_______________________________________________
Shinken-devel mailing list
Shinken-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/shinken-devel

Reply via email to