8000 `ProxyHeadersMiddleware` not using the `X-Forwarded-Port` header · Issue #1974 · encode/uvicorn · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
ProxyHeadersMiddleware not using the X-Forwarded-Port header #1974
Open
@fiannac

Description

@fiannac

Discussed in #1948

Originally posted by fiannac April 21, 2023
From the documentation:
--proxy-headers / --no-proxy-headers Enable/Disable X-Forwarded-Proto, X-Forwarded-For, X-Forwarded-Port to populate remote address info.

But I've noticed that, when the flag is set, the X-Forwarded-Port is not actually used by the application, and the source port is always set to 0.
This has to do with how the `ProxyHeadersMiddleware' is implemented, which does not match the behavior described in the docs.

Important

  • We're using Polar.sh so you can upvote and help fund this issue.
  • We receive the funding once the issue is completed & confirmed by you.
  • Thank you in advance for helping prioritize & fund our backlog.
Fund with Polar

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0