Refactoring and fixing security issues.