Is there a reason why there isn't support for `deny_status <code>` in
`http-response` as it already exists in `http-request`?

Looking at the configuration code:

  
https://github.com/haproxy/haproxy/blob/06f5b6435ba99b7a6a034d27b56192e16249f6f0/src/http_rules.c#L83
  
https://github.com/haproxy/haproxy/blob/06f5b6435ba99b7a6a034d27b56192e16249f6f0/src/http_rules.c#L588

It seems like there just isn't the code necessary to configure that status code?

----

I've then tried to look into the actual handling code:

  
https://github.com/haproxy/haproxy/blob/21c741a665f4c7b354e961267824c81ec44f503f/src/proto_http.c#L1906
  
https://github.com/haproxy/haproxy/blob/afe57846bfb2edfb0db53f942b9500d090377c54/src/proto_htx.c#L3185

, and especially:

  
https://github.com/haproxy/haproxy/blob/21c741a665f4c7b354e961267824c81ec44f503f/src/proto_http.c#L4942
  
https://github.com/haproxy/haproxy/blob/afe57846bfb2edfb0db53f942b9500d090377c54/src/proto_htx.c#L2079

It seems that the code already exists there to handle any code (if
permitted by `errorfile` related structures), but it just defaults to
502.

----

Would a patch adding this feature be accepted?

Thanks,
Ciprian.

Reply via email to