DataScript Examples Library
Clone or download

readme.md

DataScript Examples

Content Switching

HTTP Host Switching
HTTP Host Switching using Host Header
HTTP Host Switching using Host Header and String Groups
HTTP URI Switching - Simple
HTTP URI Switching - Advanced
HTTP IP Switching
HTTP Content Switch based on HTTP POST / REQUEST DATA

Availability

HTTP Retry 500 Errors
Fall back to secondary pool or custom maintenance page
Load Balancing during Maintenance Window
HTTP redirect based on Client location taken from source IP address
Rewrite HTTP redirect response from 301 to 302
Ratio based Load Balancing
Location header rewrite with non-standard port
Prepend request path
Append string(www) and redirect to http(s) host

Persistence

Header Persistence
JSessionID Persistence
Site Persistence using Cookie - Solution A
Site Persistence using Cookie - Solution B
Site Persistence using Cookie - Solution C
Site Persistence Leveraging Server Persistence Cookie for Two Sites Scenario
Persistence using URI with options for timeout

Security

HTTP to HTTPS Port Redirect
Client Cert check
Block SSLv3.0, TLSv1.0 or cipher suites that don't provide encryption
Blacklist Specific URIs using String Group
Disable HTTP Processing For Selective HTTP Methods
Mitigate Microsoft vulnerability MS15-034 and CVE-2015-1635
Computing HMAC
Controlling Bots
Cross Origin Resource Sharing Implementation
Parse and Log Username from HTTP requests

Security - Cookie

Validate String Characters in Cookie / Cookie Sanitizer
Cookie Encryption Gateway
Cookie Rewrite / Cookie Sanitizer

Security - Header

X-Forwarded-For Header Insert
X-Client-IP allow requests from range of IPs
Header Insertion for Content Security
Remove X-* and Server Headers from Response
Close Connections without Host header
Redirect Location header validator

Acceleration

Client Cache Control Behavior

Rate Limiting

Setting up Rate Limiter to use in DataScript
Add Custom Headers to Local Response
Enforce a Penalty Timeout for Blacklisted Clients

Troubleshooting

Log SSL Version
Log HTTP Headers

Misc

Pseudo-random hex character generator
Random Letter generator