For more information regarding the security incident at F5, the actions we are taking to address it, and our ongoing efforts to protect our customers, click here.

Forum Discussion

YELEVISION_1746's avatar
YELEVISION_1746
Icon for Nimbostratus rankNimbostratus
Jul 15, 2015
Solved

respond with 417 expextection failed

trying to convert this netscaler config to an irule   add responder action act_417 respondwith "\"HTTP/1.1 417 Expectation Failed\r\n\r\n\"" add responder policy expect_100 "HTTP.REQ.HEADER(\"Expe...
  • mimlo_61970's avatar
    Jul 15, 2015

    I think this is what you are after. I don't have a good way to test. The content can be modified or removed as it is the body of the response. HTTP::respond 417 -version 1.1 on its own will return "HTTP/1.1 417 Expectation Failed" if that is all you want.

    when HTTP_REQUEST {
        if { [string tolower [HTTP::header "Expect"]] equals "100-continue" } {
            HTTP::respond -version 1.1 417 content "Expectation Failed"
        }
    }