Added config and fixed quit bug.
Added configuration policies and fixed quit bug.