Writing config file with authentication details