New profile management code.