You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Due to lib/proxy.js lines 59-61, if the mapUri method returns x-forwarded-for, x-forwarded-proto, or x-forwarded-port headers, their values can end up corrupt in many situations.
When using server.inject the x-forwarded-for and x-forwarded-port headers will end with a trailing comma, due to request.info.remoteAddress and request.info.remotePort containing invalid values.
If the x-forwarded-proto header is set in mapUri, then the resulting x-forwarded-proto header will end with ',undefined' since settings.protocol cannot be specified if mapUri is, and as such will be undefined
The text was updated successfully, but these errors were encountered:
Hoping to get it done this morning, I've got 4 lines left missing coverage.
Two of them are console.error calls, which are annoying since I feel like that means I need to mock globals.console so I can be sure that the error method runs. The other two are just complicated ternary if statements that I haven't deciphered yet.
I'm hung up for the next half-hour to an hour, so if you beat me to it my feelings won't be hurt.
Due to lib/proxy.js lines 59-61, if the
mapUri
method returns x-forwarded-for, x-forwarded-proto, or x-forwarded-port headers, their values can end up corrupt in many situations.When using
server.inject
the x-forwarded-for and x-forwarded-port headers will end with a trailing comma, due torequest.info.remoteAddress
andrequest.info.remotePort
containing invalid values.If the x-forwarded-proto header is set in mapUri, then the resulting x-forwarded-proto header will end with ',undefined' since
settings.protocol
cannot be specified ifmapUri
is, and as such will beundefined
The text was updated successfully, but these errors were encountered: