Relative Content

Tag Archive for c#.net-corereverse-proxyms-yarp

How to configure YARP reverse proxy in .NET Core 8 with external IP and port, and handle cookies/sessions in iframe?

I have a .NET Core 8 project and I want to use the YARP library to implement a reverse proxy operation. The goal is to tunnel a URL defined in the Index with an external IP and port for the proxy, and perform the reverse proxy operation in an action named Proxy. I have written the Controller code and assembled it from various sources, but currently, the reverse proxy operation only works with my system’s IP. In the Proxy action, there are two variables that I don’t know how to use: httpClientFactory and httpClient.