Skip to content

Commit 2d7c7ff

Browse files
apply suggestions from doc review
Co-authored-by: mc <42146119+mchammer01@users.noreply.github.com>
1 parent 0a26e89 commit 2d7c7ff

File tree

1 file changed

+5
-6
lines changed

1 file changed

+5
-6
lines changed

javascript/ql/src/Security/CWE-020/MissingOriginCheck.qhelp

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77

88
<p>
99
The <code>"message"</code> event is used to send messages between windows.
10-
An untrusted window can send a message to a trusted window, and it is up to the receiver to verify the legitimacy of the message. One way of doing that verification is to check the <code>origin</code> of the message ensure that it origins from a trusted window.
10+
An untrusted window can send a message to a trusted window, and it is up to the receiver to verify the legitimacy of the message. One way of performing that verification is to check the <code>origin</code> of the message ensure that it originates from a trusted window.
1111
</p>
1212
</overview>
1313

@@ -27,18 +27,17 @@ to execute arbitrary code.
2727

2828
<p>
2929
The example is fixed below, where the origin is checked to be trusted.
30-
It is therefore not possible for an attacker to attack using an untrusted origin.
30+
It is therefore not possible for a malicious user to attack using an untrusted origin.
3131
</p>
3232
<sample src="examples/MissingOriginCheckGood.js" />
3333

3434
</example>
3535

3636
<references>
3737

38-
<li><a href="https://cwe.mitre.org/data/definitions/20.html">CWE-020: Improper Input Validation</a></li>
39-
<li><a href="https://developer.mozilla.org/en-US/docs/Web/API/Window/postMessage">Window.postMessage()</a></li>
40-
<li><a href="https://portswigger.net/web-security/dom-based/web-message-manipulation">Web-message manipulation</a></li>
41-
<li><a href="https://labs.detectify.com/2016/12/08/the-pitfalls-of-postmessage/">The pitfalls of postMessage</a></li>
38+
<li><a href="https://developer.mozilla.org/en-US/docs/Web/API/Window/postMessage">Window.postMessage()</a>.</li>
39+
<li><a href="https://portswigger.net/web-security/dom-based/web-message-manipulation">Web message manipulation</a>.</li>
40+
<li><a href="https://labs.detectify.com/2016/12/08/the-pitfalls-of-postmessage/">The pitfalls of postMessage</a>.</li>
4241

4342
</references>
4443
</qhelp>

0 commit comments

Comments
 (0)