Add SetBody method and fix IDNA optimization