I found in Akamai, if you need to perform a regex-match on something, it doesn’t actually regex match.

The situation: Your web service sends a “set-cookie” response header, however the domain specified is an internal or different domain. You need to modify the domain.

Here is the set-cookie response:

(in the below example, this is for ARR affinity within Azure/IIS)


The domain part of the response won’t work, as that domain isn’t accessible externally.

For a ‘modify outgoing response’ find-and-replace behaviour, Akamai state you can “regex_match PCRE” (pearl compatible regex).

This means if we want to set a BLANK domain, we could simply do something like this:

Find: (Path.*)
Replace with: ;

In theory, this would match the string “Path” and everything after it, replacing with a single “;”. However, you will find that doesn’t work.

No combination of PCRE language will work. You have to specify the entire string to replace, like so:

Find: Path=/;Domain=internal.domain.local
Replace with: ;

And that works fine. Akamai plz.