forked from juice-shop/juice-shop
-
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 info file for "Forged Review" coding challenge
(also adds neutral lines)
- Loading branch information
1 parent
5f1746f
commit 0cbc30f
Showing
3 changed files
with
23 additions
and
3 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
fixes: | ||
- id: 1 | ||
explanation: "This solution would reassign an updated review to the last editor, but it would not prevent to change other user's reviews in the first place." | ||
- id: 2 | ||
explanation: 'Setting the author on server-side based on the user retrieved from the authentication token in the HTTP request is the right call. It prevents users from just passing any author email they like along with the request.' | ||
- id: 3 | ||
explanation: "Removing the option to update multiple documents at once is a good idea and might actually help against another flaw in this code. But it does not fix the problem of allowing users to update other user's reviews." | ||
hints: | ||
- "To find the culprit lines, you need to understand how MongoDB handles updating records." | ||
- "Did you notice that the developers retrieved a reference to the user but never actually use it for anything? This might be part of the problem." | ||
- "Another problematic line you need to select, is actually missing something that ties the user to the review." | ||
|
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
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