Blocking extension in the suffix | Community
Skip to main content
Level 2
October 18, 2022
Solved

Blocking extension in the suffix

  • October 18, 2022
  • 1 reply
  • 568 views

Hi,

 

We have a requirement wherein we need to restrict/block the .json extension under suffix.

For e.g, https://<domain>/content/dam/somepath.form.html/en-us.json

We have tried adding the following dispatcher rule,

/0281 { /type "deny" /path "/content/dam/*" /selectors '(form|selector1)' /extension '(.*infinity.*|.*children.*|.*tidy.*|.*json.*)'}

But when deploying this rule, the cloud deployment pipleline fails. Any idea to fix this issue.

 

Thanks,

Pawan.

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by SwetaB

Hi @pawan_g_007 ,

 

Try the below rule

 

/0281 { /type "deny" /path "/content/dam/*/somepath" /selectors '(form|selector1)' /extension '(infinity|children|tidy|json)'}

 

In the above rule I have restricted the path more.

 

1 reply

SwetaBAccepted solution
Level 4
October 18, 2022

Hi @pawan_g_007 ,

 

Try the below rule

 

/0281 { /type "deny" /path "/content/dam/*/somepath" /selectors '(form|selector1)' /extension '(infinity|children|tidy|json)'}

 

In the above rule I have restricted the path more.