Older versionPhenixID server 2.0 ValvesInputInputParameterRegexValidatorValve


Valve that validates an input parameter using a regular expression.

If input parameter is missing or the regular expression does not match, flow will fail ("Invalid request").

Uses java regex implementation: http://docs.oracle.com/javase/8/docs/api/java/util/regex/Pattern.html

Note: escape requires double '\' ("regex" : ".+@example\\.com+")


Name Description Default value Mandatory Supports property expansion
param_name Name of input parameter to validate Yes No
regex The regular expression Yes No

Example Configuration

  "name": "InputParameterRegexValidatorValve",
  "enabled": "true",
  "config": {
    "param_name": "mail",
    "regex": ".+@.+"