Travis Glenn Hansen

Results 832 comments of Travis Glenn Hansen
trafficstars

`$` is a special char in yaml so you may need to quote or escape it in your yaml. As long as the `header_name` is not `authorization` I *think* you...

Actually, I just tested it and you've found a bug in the library (https://github.com/dchester/jsonpath) the problem has nothing to do with the `$` it's the `-` in the query. Based...

Did you remove the `rule` block?

You still need the rule with the js engine as well FYI. I think the regex syntax you had may work if you simply to `/.*/` but I would need...

I’ll look at this later in the day and get you a working example.

I think this will work with the existing codebase: ```yaml - query_engine: js query: "try { return data.req.headers[\"my-jwt-header\"]; } catch (e) { return ''; }" rule: method: regex value: /\w/i...

Yes it will. I typically would use the skip also with a stop (this helps ensure the response to applicable clients is more focused and relevant to the client). For...

Yeah, update the `query`: ``` query: "try { return data.req.headers[\"my-jwt-header\"] || ''; } catch (e) { return ''; }" ```

A `stop` without the `skip` will result in the 2nd plugin never getting executed. Basically you want to `skip` if the header is not present at all and `stop` if...

Oh right, that should work. The performance gains of using `skip` in this scenario are likely minimal. Regarding the empty `rd` value maybe nginx snippet syntax has changed? I actually...