refactor configuration, fix file headers