For example in the context of an authenticator and with the following conditions:
- the wiki descriptor has HTTPS and no port
- the current request has HTTP and explicit port (for example badly configured HTTP proxy loosing the source URL)
- asking for the external URL for the current wiki
You will end up with wiki descriptor HTTPS and current request port which generally does not work.