Skip to main content

Cached form fields


The application does not disable caching of input fields, thus the information will be stored in the browser's cache.


Obtain valid users of the application.


The data cache to browsers level must be disabled using some of these methods:

  • Use HTTP control headers that prevent cache.
  • Use meta-tags in HTML pages.
  • Disable the autocomplete field to prevent cache to fields level.


Anonymous attacker from local network.

Expected Remediation Time

⌚ 15 minutes.


Default score using CVSS 3.1. It may change depending on the context of the vulnerability.


  • Attack vector: L
  • Attack complexity: L
  • Privileges required: N
  • User interaction: R
  • Scope: U
  • Confidentiality: L
  • Integrity: N
  • Availability: N


  • Exploit code madurity: X
  • Remediation level: X
  • Report confidence: X


  • Vector string: CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:L/I:N/A:N/E:X/RL:X/RC:X
  • Score:
    • Base: 3.3
    • Temporal: 3.3
  • Severity:
    • Base: Low
    • Temporal: Low

Code Examples

Compliant code

The http headers of the application are set to prevent cache

GET /tutorials/other/top-20-mysql-best-practices/ HTTP/1.1
Host: hostname
User-Agent: Mozilla/5.0
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8
Accept-Language: en-us,en;q=0.5
Cache-control: no-cache

Example without cache type vulnerabilities

<title>Webpage without cache type vulnerabilities</title>
<META HTTP-EQUIV="Pragma" CONTENT="no-cache">
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=utf-8">
<form autocomplete="off" onsubmit="return false;">
<input autofocus="autofocus" class="form-control" id="username" type="email" autocomplete="off"/>
<label>Password</label><input class="form-control" id="password" type="password" autocomplete="off"/>
<button class="btn btn-primary btn-block" id="btn-login">
&nbsp; Sign In
<script src=""
<link href="/media/examples/link-element-example.css" rel="stylesheet"

Non compliant code

There are forms in the application that allow for auto-complete functionalities, also the application does not use meta tags to disable browsers cache

<!DOCTYPE html>
<title>Cache type vulnerabilities</title>
<meta charset="UTF-8" />
<form action="/help/readerlogin-auth" method="POST">
<input type="hidden" name="r" value="/help/" />
<div class="form-group">
<label class="control-label" for="password">Username:</label>
<input type="text" id="username" name="username" class="form-control" />
<div class="form-group">
<label class="control-label" for="password">Password:</label>
<input type="password" id="password" name="password" class="form-control" />
<div class="col-lg-4 pw-reset-link">
<a href="#" data-toggle="modal" id="pw-reset-link" data-target="#hg-password-reset">Reset Password</a>
<div class="text-right">
<button type="submit" class="btn btn-primary">Submit</button>
<script src="">
<link href="/media/examples/link-element-example.css" rel="stylesheet">


free trial

Search for vulnerabilities in your apps for free with our automated security testing! Start your 21-day free trial and discover the benefits of our Continuous Hacking Machine Plan. If you prefer a full service that includes the expertise of our ethical hackers, don't hesitate to contact us for our Continuous Hacking Squad Plan.