Overview

Walkthrough

1. How websites work

  • What term best describes the component of a web application rendered by your browser?

=> Answer: Front End

2. HTML

  • One of the images on the cat website is broken - fix it, and the image will reveal the hidden text answer!

Change the <img src='img/cat-2'> to <img src='img/cat-2.jpg'>: Guide image

=> Answer: HTMLHERO

  • Add a dog image to the page by adding another img tag (<img>) on line 11. The dog image location is img/dog-1.png. What is the text in the dog image?

Add a new <img src='img/dog-1.png'> Guide image

=> Answer: DOGHTML

3. JavaScript

  • Click the “View Site” button on this task. On the right-hand side, add JavaScript that changes the demo element’s content to “Hack the Planet”

Change <div id="demo">Hi there!</div> to <div id="demo">Hack the Planet</div> Guide image

=> Answer: JSISFUN

4. Sensitive Data Exposure

  • View the website on this link. What is the password hidden in the source code?

Visit https://static-labs.tryhackme.cloud/sites/howwebsiteswork/html_data_exposure/ and click View page source, you should see the credentials

Guide image

=> Answer: testpasswd

5. HTML Injection

  • View the website on this task and inject HTML so that a malicious link to http://hacker.com is shown.

Submit the payload <a href="http://hacker.com">Safe content</a>

Guide image

=> Answer: HTML_INJ3CTI0N