adapt key config