Skip to content

Support for regular expression parsing in header match #199

@rshriram

Description

@rshriram

It would be nice to be able to match headers based on regular expressions. Some simple use cases could be matching based on Cookies, where a specific type of user is making a request.

Depending on the library being used (e.g., PCRE vs something else), for maintaining performance, it might be okay to explicitly ask the user to specify whether the header match block contains a regex or not, with a isregex:true entry. For example,

"headers" : [
                          {
                              "name" : "Cookie",
                              "value" : "user=test-.*?",
                              "isregex" : true
                          }
                      ]

In the absence of the isregex block, the header match can be considered as simple string equality checks.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementFeature requests. Not bugs or questions.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions