backporting fix for writing auth values to yaml