Skip to content

Commit 255123c

Browse files
Apply suggestions from docs review
Co-authored-by: Sam Browning <[email protected]>
1 parent 7ae41ff commit 255123c

File tree

2 files changed

+5
-8
lines changed

2 files changed

+5
-8
lines changed

java/ql/src/Security/CWE/CWE-524/SensitiveKeyboardCache.qhelp

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -4,21 +4,18 @@
44
<qhelp>
55

66
<overview>
7-
<p>When a user enters information to a text input field on an Android application, then by default their input is saved to a keyboard cache,
8-
which provides autocomplete suggestions and predictions. If the input field is expected to contain sensitive information, such as a password or banking details,
9-
this sensitive data may be leaked to other applications via the keyboard cache.</p>
7+
<p>When a user enters information in a text input field on an Android application, their input is saved to a keyboard cache which provides autocomplete suggestions and predictions. There is a risk that sensitive user data, such as passwords or banking information, may be leaked to other applications via the keyboard cache.</p>
108

119
</overview>
1210
<recommendation>
1311

14-
<p>For input fields expected to accept sensitive information, an input type such as <code>"textNoSuggestions"</code> (or <code>"textPassword"</code> for a password)
15-
should be used to ensure that the input does not get stored in the keyboard cache.</p>
12+
<p>For input fields expected to accept sensitive information, use input types such as <code>"textNoSuggestions"</code> (or <code>"textPassword"</code> for a password) to ensure the input does not get stored in the keyboard cache.</p>
1613
<p>The input type can also be set in code through <code>TextView.setInputType()</code> rather than declared through XML.</p>
1714
</recommendation>
1815
<example>
1916

20-
<p>In the following example, the field labeled BAD could allow the password to be saved to the keyboard cache;
21-
whereas the field labeled GOOD uses the <code>"textPassword"</code> input type, which ensures that it is not.</p>
17+
<p>In the following example, the field labeled BAD allows the password to be saved to the keyboard cache,
18+
whereas the field labeled GOOD uses the <code>"textPassword"</code> input type to ensure the password is not cached.</p>
2219

2320
<sample src="Example.xml" />
2421

java/ql/src/Security/CWE/CWE-524/SensitiveKeyboardCache.ql

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
/**
22
* @name Android sensitive keyboard cache
3-
* @description Sensitive information should not be saved to the keyboard cache.
3+
* @description Allowing the keyboard to cache sensitive information may result in information leaks to other applications.
44
* @kind problem
55
* @problem.severity warning
66
* @security-severity 8.1

0 commit comments

Comments
 (0)