forked from WebGoat/WebGoat
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add endpoint for the JavaScript to post to
The JavaScript posts to a random endpoint resulting in a HTTP/405 we now post to an existing endpoint. Resolves: WebGoat#1142
- Loading branch information
Showing
4 changed files
with
17 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
webgoat-lessons/insecure-login/src/main/resources/js/credentials.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
function submit_secret_credentials() { | ||
var xhttp = new XMLHttpRequest(); | ||
xhttp['open']('POST', '#attack/307/100', true); | ||
xhttp['open']('POST', 'InsecureLogin/login', true); | ||
//sending the request is obfuscated, to descourage js reading | ||
var _0xb7f9=["\x43\x61\x70\x74\x61\x69\x6E\x4A\x61\x63\x6B","\x42\x6C\x61\x63\x6B\x50\x65\x61\x72\x6C","\x73\x74\x72\x69\x6E\x67\x69\x66\x79","\x73\x65\x6E\x64"];xhttp[_0xb7f9[3]](JSON[_0xb7f9[2]]({username:_0xb7f9[0],password:_0xb7f9[1]})) | ||
} |
6 changes: 3 additions & 3 deletions
6
...ssons/insecure-login/src/main/resources/lessonPlans/en/InsecureLogin_Intro.adoc
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
|
||
== Concept | ||
Encryption is a very important tool for secure communication. In this lesson, we will find out, why it should always be employed when sending sensitive data. | ||
=== Concept | ||
Encryption is an essential tool for secure communication. In this lesson, we will find out why it should always be employed when sending sensitive data. | ||
|
||
== Goals | ||
=== Goals | ||
* The user should have a basic understanding of packet sniffer usage | ||
* The user will be able to intercept and read unencrypted requests |
4 changes: 2 additions & 2 deletions
4
...essons/insecure-login/src/main/resources/lessonPlans/en/InsecureLogin_Task.adoc
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
=== Let's try | ||
Click the "log in" button to send a request containing login credentials of another user. | ||
Then, write these credentials into the appropriate fields and submit to confirm. | ||
Click the "log in" button to send a request containing the login credentials of another user. | ||
Then, write these credentials into the appropriate fields and submit them to confirm. | ||
Try using a packet sniffer to intercept the request. |