added implementation to readconf + minor changes