Duende.BFF.Yarp is vulnerable to Cross-Site Request Forgery (CSRF)
65
Medium Risk
Duende.BFF blocks cross-site request forgery on its API endpoints by requiring a custom X-CSRF: 1 header, but routes that a dynamic frontend configures with WithRemoteApis set their endpoint at request time, after the anti-forgery middleware already ran with no endpoint to check. A cross-site page can make a signed in user's browser send a request to a WithRemoteApis route without that header, and the BFF still proxies it to the backend with the user's access token attached, so the backend performs the state changing operation even though the attacker cannot read the response. The fix checks the anti-forgery header in the remote route handler before it attaches the access token and forwards the request.
You are affected if you are using a version that falls within the vulnerable range and you configure a dynamic frontend with WithRemoteApis to proxy a remote API.
Duende.BFF.Yarp is vulnerable to Cross-Site Request Forgery (CSRF) in versions 4.0.0 - 4.0.3, 4.1.0 - 4.1.2, 4.2.0 - 4.2.0 and 4.3.0 - 4.3.0.
Upgrade the Duende.BFF.Yarp library to the patch version.
Connect your repositories to instantly see whether vulnerable or malicious packages exist in your codebase.
Free. No credit card required.

I consent to receiving marketing communications based on Aikido’s Privacy Policy.
SOC 2Compliant
ISO 27001Compliant
ISO 42001Compliant© All Intel data is openly available and commercially licensed.