Posts THM Advent of Cyber 3 (2021) NoSQL WriteUp
Post
Cancel

THM Advent of Cyber 3 (2021) NoSQL WriteUp

Advent of Cyber 3 (2021) [Day 7 - NoSQL]

[Day 7] Web Exploitation Migration Without Security

Credits: RealTryHackMe

Please Read Day 07 About NoSQL

First Flag - Q: Interact with the MongoDB server to find the flag. What is the flag?

  1. As you read turn on your Machine
  2. Open Terminal
  3. Type ssh thm@MACHINE_IP -p 2222
  4. As you read in This room of day 07
  5. Do the same steps like the image Below
  6. login ssh
  7. Interact with mongo db
  8. show your databases
  9. Use flagdb DataBase
  10. So Now** you’r in flagdb** Database
  11. List All Collections == Tables
  12. Will Find flag Column == Fields in this Records == Documents

Second Flag - Q: Interact with the MongoDB server to find the flag. What is the flag?

  1. Open http://MACHINE_IP
  2. Try to inject dummy data in username and password Fields
  3. Fire up Your Burp
  4. Intercept the Request after sending username and password Inputs Fields
  5. As you read in This room of day 07
  6. As You learned send username parameter with admin
  7. Change password paramter to anything
  8. Paramter password[$ne]=anything
  9. $ne == Not Equal
  10. To make all statement Like True as SQLI
  11. Username is admin & Password not equal anything == [TRUE]
  12. Respose will be 302 Found
  13. Press Follow Redirection
  14. You will find flag Directory
  15. Click Right and Choose Copy Response Link from burp response in repeater
  16. Paste Link in Browser and clcik on flag link

Third Flag - Q: Once you are logged in, use the gift search page to list all usernames that have guest roles. What is the flag?

  1. After login you will see search link
  2. Search with any dummy data
  3. As you read in This room of day 07
  4. Change GET Paramters username & role to be TRUE
  5. How to make it True First and Second Paramter each paramter should be TRUT to make all Request True
  6. Username Paramter Not Equal admin == anyusername
  7. Role Paramter Not Equal admin also == Role=guest
  8. From 7,8 The Request will be True To get All guests Usernames Not Admin
  9. The Response Will Retraive The THM flag

Fourth Flag - Q: Use the gift search page to perform NoSQL injection and retrieve the mcskidy record. What is the details record?

  1. After login you will see search link
  2. Search with any dummy data
  3. As you read in This room of day 07
  4. Change GET Paramters username & role to be TRUE
  5. How to make it True First and Second Paramter each paramter should be TRUT to make all Request True
  6. Username Paramter Value mcskidy
  7. Role Paramter Value Not Equal admin also
  8. But i didn’t ant flag in respose
  9. Change Role Paramter Value Not Equal admin guest == Role=admin
  10. From 7,10 The Request will be True To get mcskidy Username with Admin Role
  11. The Response Will Retraive The THM flag
This post is licensed under CC BY 4.0 by the author.