AtD: use HTTPS for requests when on HTTPS url.

Fixes #723