server_port is unnecessary, since the HTTP Host header sent by the client already includes any non-standard port. (This is stuffed into http_host.)
In addition, when the Python application server is sitting behind a reverse proxy/TLS terminator, SERVER_PORT is likely to be wrong anyway (since it would be the server port of the non-reverse-proxied server).
@pitbulk Review concerns addressed. I don't know where the review comments went – maybe you had made them as comments on the commit instead of a PR review?
server_port
is unnecessary, since the HTTP Host header sent by the client already includes any non-standard port. (This is stuffed intohttp_host
.)In addition, when the Python application server is sitting behind a reverse proxy/TLS terminator, SERVER_PORT is likely to be wrong anyway (since it would be the server port of the non-reverse-proxied server).
See https://github.com/onelogin/python3-saml/issues/273#issuecomment-885566427