Implement domain extraction and domain changing.