generated from FIS2425/template
-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Labels
🐞 BugBug identifiedBug identified
Description
Description
When accessing the ip of the request in a microservice, we expect the ip of the user, not the API Gateway
Steps to Reproduce
- Activate a microservice and the api-gateway
- Send a request via the api gateway to the microservice
- Note the ip address logged in the microservice is the ip of the api-gateway
Expected Behavior
The IP of the user is forwarded
Actual Behavior
The IP of the user is not forwarded
Proposed fix
Change instances of req.ip
to req.headers && req.headers['x-forwarded-for'] || req.ip
Metadata
Metadata
Assignees
Labels
🐞 BugBug identifiedBug identified