← All tasks
🧮
Advanced

Write a Secure Redirect Header With Validated Host

⏱ 3 min ⭐ 90 XP 🔁 3 attempts allowed

What you'll do

Write the PHP expression that validates a redirect URL's host matches the application's own domain before redirecting.

Scenario

An open-redirect vulnerability was found because the host portion of a redirect URL was never checked.

Ready to try it?

Create a free account and subscribe to take "Write a Secure Redirect Header With Validated Host". Earn 90 XP and track your internship progress.

Already have an account? Sign in