It'd probably be better to use Puppet::Util::Inifile for this, rather than just slurping and exploding the file.