Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Select an option

  • Save ApigeeSamples/2634017 to your computer and use it in GitHub Desktop.

Select an option

Save ApigeeSamples/2634017 to your computer and use it in GitHub Desktop.
Regular Expression Protection
<RegularExpressionProtection name="mypolicy">
<Source>response</Source>
<IgnoreUnresolvedVariables>false</IgnoreUnresolvedVariables>
<URIPath>
<Pattern>[tT]rue</Pattern>
<Pattern>.*true.*</Pattern>
</URIPath>
<QueryParam name="greeting">
<Pattern>[tT]rue</Pattern>
<Pattern>.*true.*</Pattern>
</QueryParam>
<Header name="greeting">
<Pattern>[tT]rue</Pattern>
<Pattern>.*true.*</Pattern>
</Header>
<FormParam name="greeting">
<Pattern>[tT]rue</Pattern>
<Pattern>.*true.*</Pattern>
</FormParam>
<Variable name="request.content">
<Pattern>[tT]rue</Pattern>
<Pattern>.*true.*</Pattern>
</Variable>
<XMLPayload>
<Namespaces>
<Namespace prefix="apigee">http://www.apigee.com</Namespace>
</Namespaces>
<XPath>
<Expression>/apigee:Greeting/apigee:User</Expression>
<Type>string</Type>
<Pattern>[tT]rue</Pattern>
<Pattern>.*true.*</Pattern>
</XPath>
</XMLPayload>
<JSONPayload>
<JSONPath>
<Expression>$.store.book[*].author</Expression>
<Pattern>[tT]rue</Pattern>
<Pattern>.*true.*</Pattern>
</JSONPath >
</JSONPayload>
</RegularExpressionProtection>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment