Level 6: Linking javascript

Tired of prompts? Lets solve this one quickly and move to next mission. When you check the source code for his mission you will not find a function like the previous levels. It is because the we necessarily do not need to write the javascript codes in our main file. We can also write it in a separate js file and link it.

<SCRIPT SRC=”psswd.js” LANGUAGE=”JavaScript” type=”text/javascript”></script>

Like its done here. The javascript function is written in a separate psswd.js file. So lets just open this file using directory traversal and move on.

<!--
var pass;
pass=prompt("Password:","");
if (pass=="hackertestz") {
window.location="included.htm";
}else 
alert("Try again...");
//-->

The answer is hackertestz.

Good luck!!!

Follow me

Abhishek Gupta

I am Abhishek from Lucknow (India). I have been working as a software engineer from last 6+ years, and its my passion to learn new things and implement them as a practice.
Follow me

Latest posts by Abhishek Gupta (see all)

Leave a Reply