Refactoring secrets