← All tasks
🧮
Intermediate

Write a Redirect Allowlist Check

⏱ 3 min ⭐ 90 XP 🔁 3 attempts allowed

What you'll do

Write the PHP expression that only allows a redirect if the target path is in a predefined allowlist.

Scenario

A previous open-redirect bug let attackers send victims to arbitrary external domains via a 'next' parameter.

Ready to try it?

Create a free account and subscribe to take "Write a Redirect Allowlist Check". Earn 90 XP and track your internship progress.

Already have an account? Sign in