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
Some extractors, like Host or Scheme, can use the values of some HTTP headers that could be spoofed by malicious users.
We should find a way to make users aware of the risks of using those extractors.
Some ideas:
using unsafe. This is not the idea of unsafe and we would be mis-using it. I think that this can be discarded.
encapsulating the value in a new struct like SpoofableValue so that users have to call some function to get the value. The name and the documentation of the function should make the user aware of the risk. Example:
asyncfnhandler(Host(host):Host) -> String{
val value = host.spoofable_value();
value
}