🕸️Web

Here you'll find different Web tasks solved step-by-step

Inspector

First web tasks are beginner friendly in this case the flag will be found in the files of the website

Let's start by hitting CTRL + SHIFT + i in the website then go to Sources

1st part of the flag
2nd part of the flag

Beji Matrix

I opened the sources to fetch for the flag all I ever found was a JS function called flag() calling another function called hex_to_ascii()

I went to the console and called flag()

& The flag was given

Headers

HTTP header fields are a list of strings sent and received by both the client program and server on every HTTP request and response.

If you visit the website you'll find "Hello there, did you check your head?" as a message

To check headers hit CTRL + SHIFT + i then Network then reload the page

Flag is given under flag Header

Verbz

There are various HTTP methods but in this case a hint was given

We need to use the OPTIONS method

Curling the website w/ the OPTIONS method gave us the flag

Replace

The given file contains this PHP code :

<?php
// flag is at flag.txt
show_source('index.php'); 

if (isset($_GET['file'])){ // if file parameter is set
    $file = $_GET['file'];
    $clean_file = preg_replace('/flag/i','',$file); //Removes flag from parameter
    echo file_get_contents($clean_file);
}else{
    echo "pls hax me";
}
?>

As "flag" is removed, I tricked the function with flag within every character of the word like this ?file=fflaglflagaflagg.txt and It returned our flag

Spark{preg_replace_ftw!!}

Gift

As I visited the Web page,All I ever found was a simple <a> Tag referring to "/cany#uget_the_flag?!" --> I did notice that the URL needs Encoding

& It became /cany%23uget_the_flag%3F%21 then I got the flag

Spark{Helo-UwU-noob}

Adm_IN

Last updated

Was this helpful?