rescue OpenURI::HTTPError during port check too

In restrictive environments you're not allowed to open some urls.
You will face this exception, which now will be rescued.