Join our Newsletter — 33% off our NHI Course

What happens when a redirect feature accepts unvalidated user input?

The application can become a delivery path to a malicious destination. An attacker supplies a crafted URL, the site redirects the victim without checking it, and the victim may then enter credentials or follow further malicious prompts. In practice, the legitimate domain in the original link can create enough trust to make the attack more convincing.

Why a Redirect That Trusts User Input Becomes an Attack Path

A redirect feature is not just a navigation convenience when it accepts unvalidated input. It becomes a trust boundary the application is willing to hand over to the user, which means the original brand, page context, and URL structure can be used to shepherd someone toward a destination the application did not intend to endorse. That is why the risk is less about the redirect itself and more about the trust the application transfers.

The practical failure mode is simple: the application reflects or accepts a destination parameter, then sends the browser there without checking whether the target is approved, local, or otherwise safe. Attackers use that to make a malicious destination look like it was reached through a legitimate property, especially when the victim only sees the trusted starting domain before the jump.

The difference between a harmless redirect and an open redirect is whether the application constrains destination control. If it does not, the redirect can support phishing, credential harvesting, malware delivery, or chained attacks that start from a trusted application and end somewhere the user would not have visited on their own.

What Practitioners Should Verify Before Treating a Redirect as Safe

Validation is the key control. A redirect should accept only known-good targets, such as fixed paths, allowlisted hosts, or internal route identifiers that are translated server-side into destinations. If the design requires external destinations, the application should at minimum enforce explicit approval logic and make the target visible enough for users and testers to understand where they are being sent.

  • Prefer server-side allowlists over direct user-supplied URLs.
  • Use relative paths or opaque route keys when external destinations are not required.
  • Reject schemes and hosts that are not explicitly approved.
  • Test whether a crafted parameter can send a user to an arbitrary domain, protocol, or encoded destination.

It is also worth checking how redirects behave in login, password reset, SSO handoff, and post-action flows. Those are the places where trust is highest and where a misleading redirect has the greatest chance of changing user behaviour. If the feature can be reached from emails, deep links, or shared URLs, the abuse potential rises because the attacker can package the redirect inside a convincing message.

Risk and Threat Considerations

Open redirects are often treated as low severity until they are chained into phishing or session abuse. The issue is not merely that the browser moves to another site, it is that the application’s legitimacy can be used as a credibility amplifier for an attacker-controlled destination.

Failure mechanism: The application accepts a destination value from the user, fails to validate it against an allowlist or safe routing rule, and sends the browser to an arbitrary location. That lets an attacker disguise a malicious URL behind a trusted domain and, in some cases, use it as a step in broader credential theft or social engineering.

Impact: Victims may trust the path enough to enter credentials, approve a prompt, or continue into a malicious workflow. The downstream effect can include account compromise, fraud, malware exposure, or a stronger phishing campaign because the initial trusted domain reduces suspicion.

Standards & Framework Alignment

This section maps relevant standards and security frameworks to the operational risks and controls described in this guidance.

OWASP Non-Human Identity Top 10 and OWASP Agentic AI Top 10 address the attack and risk surface, while CIS Controls v8 and NIST CSF 2.0 set the governance and control requirements practitioners need to meet.

Framework Control / Reference Relevance
CIS Controls v8 6 — Access Control Management Validating redirect targets reduces abuse of trusted application paths.
Recommendation — Restrict redirect destinations to approved routes and block arbitrary user-controlled URLs.
OWASP Non-Human Identity Top 10 NHI-07 — Redirects and Trust Boundary Abuse Open redirects create trust-boundary abuse that can aid credential theft and phishing.
Recommendation — Validate redirect targets and prevent user-controlled destinations from becoming trust pivots.
OWASP Agentic AI Top 10 A3 — Tool and Action Abuse User-steered redirects can be abused to send users into malicious downstream actions.
Recommendation — Constrain externally influenced action paths so untrusted input cannot steer sensitive outcomes.
NIST CSF 2.0 PR.AC-3 — Identity Proofing and Binding Trusted application flows should not be weakened by unvalidated destination control.
Recommendation — Bind trusted flows to approved destinations and reject unvalidated redirect parameters.

Practitioner Guidance

What to prioritise: Treat any redirect reachable from public input as a security-sensitive input-handling issue, not just a usability detail. If the redirect appears in authentication, account recovery, or email-linked journeys, prioritise it ahead of lower-impact navigation features because the trust value of the page materially changes the abuse potential.

What to verify: Confirm that the application never accepts arbitrary absolute URLs unless there is a documented business need and explicit server-side approval logic. Test encoded, nested, and parameter-smuggled destinations as well as obvious ones, because attackers often rely on parser differences rather than the simplest payload.

Practitioner takeaway: The safest redirect is one the user cannot freely steer. If user input can influence the destination, the control should be designed so the application, not the attacker, decides where trust is allowed to travel.