What You’ll Achieve
After completing these steps, visitors tohttps://yourdomain.com/license.xml will receive your RSL license XML from Supertab Connect servers, while the URL stays on your domain. No redirects, completely transparent.
Your existing site remains completely unchanged.
How It Works
When a user requests/license.xml:
- CloudFront matches the
/license.xmlcache behavior - A CloudFront Function rewrites the path to include your merchant URN
- CloudFront fetches the license from Supertab Connect
- The response is cached and returned to the user
/, /api/*, etc.) continue working exactly as before.
Setup Steps
Create CloudFront Function
Navigate to Functions
- Log into AWS Console
- Go to CloudFront service
- In the left sidebar, click Functions
- Click Create function
Configure Function
Enter the following:
- Name:
supertab-rewrite-license-path - Description:
Rewrites /license.xml to supertab-connect path - Runtime:
cloudfront-js-2.0
Test the Function (Recommended)
- Click Test tab
- Click Edit JSON, change the
"uri"field to"/license.xml" - Click Test function
- Verify the output shows your rewritten path
Add Supertab Connect Origin
Open Your Distribution
- Go to CloudFront → Distributions
- Click on your distribution
- Click Origins tab
Create Cache Behavior
Configure Path and Origin
| Setting | Value |
|---|---|
| Path pattern | /license.xml |
| Origin and origin groups | supertab-connect-origin |
Configure Viewer Settings
| Setting | Value |
|---|---|
| Viewer protocol policy | Redirect HTTP to HTTPS |
| Allowed HTTP methods | GET, HEAD |
| Restrict viewer access | No |
Configure Cache Settings
| Setting | Value |
|---|---|
| Cache policy | CachingOptimized |
| Origin request policy | AllViewerExceptHostHeader |
Associate CloudFront Function
Scroll to Function associations
| Setting | Value |
|---|---|
| Viewer request - Function type | CloudFront Functions |
| Viewer request - Function ARN/Name | supertab-rewrite-license-path |
Deploy and Wait
After creating the behavior, your distribution status changes to Deploying.
- CloudFront is copying your function to all edge locations worldwide
- This takes 10-15 minutes
You’re Done!
Your RSL license is now published athttps://yourdomain.com/license.xml. Bots and AI agents can access your licensing terms directly from your domain.
The final step is updating your robots.txt so bots know where to find it.
Next Steps
Update robots.txt
Add the License directive so bots can discover your license.