Setting Up OWASP Juice Shop Training Platform on Kali Linux in VMware — A Simple Guide

IritT
6 min readSep 29, 2024

--

Site Link: https://owasp.org/www-project-juice-shop/

Are you interested in learning web application security and practicing ethical hacking? If yes, then OWASP Juice Shop is the perfect platform for you! Juice Shop is a purposely vulnerable web application that helps you practice identifying and exploiting common web vulnerabilities in a safe environment.

Using intentionally vulnerable applications like OWASP Juice Shop is critical for learning ethical hacking in a controlled and legal manner. These platforms allow security professionals and learners to develop their skills without risking harm to real-world systems. By practicing in an isolated environment, such as a virtual machine, you can safely explore vulnerabilities like SQL Injection, Cross-Site Scripting (XSS), and more, while ensuring that your activities remain ethical and compliant with cybersecurity laws.

This addition will provide more context on the importance of Juice Shop as a safe and legitimate platform for ethical hacking, helping readers understand why it’s a valuable tool.

Let’s get started!

Step 1: Install Docker on Kali Linux

Docker is a tool that allows you to run applications (like Juice Shop) inside containers, which are small, isolated environments. First, we need to install Docker on Kali Linux.

  1. Update your system: Open your terminal in Kali and run the following command to update all your packages:
sudo apt update && sudo apt upgrade -y

This ensures that your system is ready for Docker installation.

2. Install Docker: Now, let’s install Docker on your Kali machine by running this command:

sudo apt install docker.io -y

This will download and install Docker for you.

3. Start Docker: After Docker is installed, we need to start the Docker service and make sure it runs automatically when you start your computer:

sudo systemctl start docker
sudo systemctl enable docker

4. Check Docker Installation: Let’s make sure Docker was installed successfully. Run this command to check the version:

sudo docker --version

If everything is correct, you’ll see the version of Docker installed on your system.

Step 2: Download and Run OWASP Juice Shop

Now that Docker is up and running, it’s time to download and start OWASP Juice Shop.

  1. Run Juice Shop: To download and run Juice Shop, type the following command in your terminal:
sudo docker run -d -p 3000:3000 bkimminich/juice-shop

This command will download Juice Shop from Docker Hub and start it on port 3000.

2. Check Running Containers: You can verify that Juice Shop is running by listing all active Docker containers with this command:

sudo docker ps

If Juice Shop is running, you will see it listed in the terminal output.

Step 3: Access Juice Shop in Your Browser

Now that Juice Shop is running, you can access it through your web browser.

  1. Open your browser and go to:
http://localhost:3000

This will open the Juice Shop interface where you can start practicing your web security skills.

If you want to access Juice Shop from another device on your network, use the IP address of your Kali Linux machine followed by :3000. For example:

http://[YOUR_KALI_IP]:3000

Step 4: (Optional) Run Docker Without sudo

If you want to use Docker without typing sudo every time, you can add your user to the Docker group:

sudo usermod -aG docker $USER

After this, log out and log back in, and now you can run Docker commands without using sudo.

key vulnerabilities you can practice on OWASP Juice Shop:

1. SQL Injection

  • What to practice: Injecting SQL queries into input fields like login forms or search bars.
  • Goal: Retrieve or manipulate database information by exploiting poorly handled SQL queries.
  • Example: Try entering ' OR '1'='1 in a login field to bypass authentication.

2. Cross-Site Scripting (XSS)

  • What to practice: Injecting malicious scripts (e.g., JavaScript) into web pages viewed by other users.
  • Goal: Execute scripts in another user’s browser to steal cookies, redirect them, or display malicious content.
  • Example: Use <script>alert('XSS');</script> in a comment box or search field.

3. Cross-Site Request Forgery (CSRF)

  • What to practice: Crafting a request that forces a logged-in user to perform actions without their knowledge.
  • Goal: Perform unauthorized actions on behalf of an authenticated user, like changing their password.
  • Example: Build a form that submits a malicious request when a user clicks on a link.

4. Broken Authentication

  • What to practice: Exploiting weak authentication mechanisms.
  • Goal: Gain unauthorized access by cracking passwords, using default credentials, or bypassing login mechanisms.
  • Example: Try common passwords or analyze how sessions are managed.

5. Sensitive Data Exposure

  • What to practice: Identifying unprotected sensitive data like passwords or credit card numbers.
  • Goal: Find and exploit data being stored or transmitted without encryption.
  • Example: Monitor network traffic using tools like Burp Suite to identify sensitive data being transmitted in plaintext.

6. Broken Access Control

  • What to practice: Accessing resources or actions that should be restricted based on user roles.
  • Goal: Access admin functionalities or other users’ data without proper permissions.
  • Example: Manipulate URLs or request parameters to access restricted areas.

7. Security Misconfigurations

  • What to practice: Finding misconfigurations in servers, applications, or frameworks that expose vulnerabilities.
  • Goal: Exploit improper configurations like default settings, unused pages, or debugging information.
  • Example: Look for exposed configuration files or error messages that reveal system details.

8. Insecure Deserialization

  • What to practice: Manipulating serialized objects passed between the client and server.
  • Goal: Inject malicious payloads in serialized objects to execute code or escalate privileges.
  • Example: Modify serialized data (like JSON or XML) and check how the application processes it.

9. File Upload Vulnerabilities

  • What to practice: Uploading malicious files (like scripts) to a server.
  • Goal: Execute code on the server or bypass restrictions by uploading files like PHP scripts.
  • Example: Try uploading files with various extensions or content and check if they are processed insecurely.

10. Business Logic Flaws

  • What to practice: Identifying weaknesses in the application’s logic that can be abused.
  • Goal: Exploit flaws in how the application handles tasks, such as bypassing workflows or reducing item prices.
  • Example: Attempt to manipulate the checkout process to alter the price of a product.

Conclusion:

Practicing these vulnerabilities on OWASP Juice Shop will sharpen your skills in identifying and exploiting real-world web application flaws. This platform provides a legal and safe environment to test a wide range of common vulnerabilities and improve your web security knowledge.

Good luck, and happy hacking!

--

--

IritT
IritT

Written by IritT

In the world of cybersecurity, the strongest defense is knowledge. Hack the mind, secure the future.

No responses yet