Security refactoring.