By enforcing geographic-based allow lists at the edge, this use case improves security and compliance by blocking requests from embargoed countries with a 403 response while allowing legitimate traffic through. This reduces the load on the origin server and enhances response times.
Loading...
https://www.edgecompute.live/traffic-allow-list
Copied to clipboard!
Implements an allow list depending on the geographic locale of the end user. If the user is arriving from United States embargoed countries, a 403 deny will occur.
Ease Development
Enable developers to modify application behavior without touching origin server logic.
Enhance Security
Enable security features at the edge, preventing bad requests from reaching your origin server.
Geolocation Information
Apply dynamic business logic based on the request's origin location information.
Improve Reliability
Move compute cycles to the edge, reducing load and improving reliability and performance of origin servers.
Related Examples
View More
A/B Testing
Randomly assigns a new user to a group for A/B testing. The assignment is stored in a cookie and passed to the origin in a query parameter. The A/B group can be forced via a query string parameter for easy testing. The group names, percentage split, cookie name, and query parameter name are configured through constants in the EdgeWorker JavaScript module.

Conference/Meeting Details
Implements a Conference Attendance Code API call that returns the meeting details of a conference as HTML if the user provides the correct code. With abc123 in the key GET parameter, the user is shown conference details. If the parameter is incorrect, an error is returned, keeping the information away from the browser to maintain confidentiality.

Content Security Policy
A Content Security Policy (CSP) is a security feature implemented in web browsers to protect websites and web applications from attacks such as cross-site scripting (XSS) and data injection. CSP controls and limits the source of various types of content loaded and executed on a web page, including scripts, stylesheets, and images. EdgeWorkers provides numerous performance benefits for CSPs, which need to complement the security measures on the application server-side.