PingAccess allows for the manipulation of the Request URI, the cookie domain, the
cookie path, three of the response headers (
URI), and the response
For example, a site is hosted on
/content/. Users access the site through the following
URL in their browser:
importantContent.htmlpage as well as setting a domain cookie for
.internalsite.com. If you protect this site with PingAccess using the virtual host
publicsite.comunder the application
/importantstuff/, you must rewrite the content. The information below discusses an example scenario.
This conceptual overview assumes that a virtual host, a site, and an application are already configured.
Create a Rewrite Content Rule
- In the Response Content-Types field, you define a
response type of
- In the Find and Replace criteria, you specify
- Add the rule to the application. A query to a page with links in it that
https://server1.internalsite.com/content/now points to
Create a Rewrite Cookie Domain Rule
A rewrite cookie domain rule allows the rewriting of the Domain field on cookies when they are set by the backend site.
- In the server-facing cookie domain, you enter
- In the public-facing cookie domain, you enter
- Add the rule to the application.
Cookies associated with the domain
.publicsite.com, are rewritten to pertain to
Create a Rewrite Cookie Path Rule
A rewrite cookie path rule converts the cookie path returned by the site into a public-facing path.
- In the Server-Facing Cookie Path field, you enter
- In the Public-Facing Cookie Path field, you enter
Add the rule to the application.
Cookies associated with a cookie path of
/content/are rewritten to pertain to
/importantstuff/. After configuring the rewrite rules as discussed above, a user could access the
https://publicsite.com/importantstuff/and PingAccess would route that request to
If the site sends a redirect to
https://server1.internalsite.com/content/index.html, PingAccess would return a redirect to
https://publicsite.com/importantstuff/index.html. If the site then returned a cookie with a domain of
.internalsite.comand a path of
/content/, PingAccess would rewrite that cookie to be relevant to
Create a Rewrite Response Header Rule
A rewrite response header rule alters the response header used in the 302 Redirect.
- In the Server-Facing URI field, you enter
- In the Public Path field, you enter
- Add the rule to the application. A query resulting in a response containing a
302 Redirect to
https://server1.internalsite.com/content/is rewritten to
This also works for relative redirects:
/content/is rewritten to
/importantstuff/. It also works for the path beneath the one defined in the URI:
/content/news/index.htmlis rewritten to
Create a Rewrite URL Rule
A rewrite URL rule alters the request URI.
- In the Map From field, you enter
^/importantstuff/(.*)as the regex of the URL's path and query you want to match.
- In the Map To field, you enter
- Add the rule to the application. A query to
https://publicsite.com/importantstuff/results in PingAccess routing that query to