Regexp is not working in Apache Sling Referrer filter
I need to allow some of the external domains to access the application which is built on AEM. For that I have given the full domain url (<protocol>://<server>:<port>) in Allowed Hosts under Apache Sling Referrer filter in OSGI console. It works fine and its able to make the POST requests. Now I want to change that to a regex so that it will allow a series of external application domains. So I have added the below regex on the Apache Sling Referrer filter:
/^(https?):\/\/([A-Z\d\.-]{2,})\.([A-Z]{2,})(:\d{2,4})?/i
But its not working. Its throwing Forbidden error - 403 for POST requests.
So my question is can we include regexp in Allowed Hosts under Apache Sling Referrer filter in OSGI console ?