Forum Discussion

quangtran's avatar
quangtran
Icon for Cirrus rankCirrus
Jun 04, 2023
Solved

irule reject request when payload field is null

Hello everyone, I have the following case, when there is a request to my url: https://10.10.10.10/aaa/v1/xx/test/okokokok,  the payload will have to have the fields test, test1, test2, test3. Attac...
  • Hi quangtran , 
    try to modify this line : 

    if { [HTTP::uri] starts_with "https://10.10.10.10/aaa/v1/xx/test/okokokok" } {

    to this line : 

    if { [HTTP::uri] starts_with "/aaa" } {
    
    or 
    
    if { [HTTP::uri] contains "/aaa/v1/xx/test/okokokok" } {

    I relied on the below article to write it : 
    https://clouddocs.f5.com/api/irules/HTTP__uri.html

     

    Hope this helps you