For example, if a value matches "an email pattern", then remove the key also associated to it from the url.
If url is
https://stackoverflow.com/?key1=test&[email protected]&key3=something&[email protected]
,
then remove [email protected] and [email protected], so that the new url will be
https://stackoverflow.com/?key1=test&key3=something
Here, key names are not fixed and they can be anything. and also the position of the keys is not fixed.
So, want a regex to get the entire string which does not contain those key value pairs. I tried to generate the regex to match the unwanted key value pairs, but could get the rest of the string which does not match the regex.
I did it using a java program. But looking at a regex so that I can apply in the xml and avoid a java program
This is mainly to use in urlrewritefilter (tuckey) and want to remove certain query strings matching a regex.