← All scrolls
巻 rank
Darkest Hour CTF · Web

Love Portal: LFI with base64 reads

Local file inclusion across the portal's pages, decoding base64 reads to dig through the source.

16 Feb 20251 min read
#lfi#php#base64

Description

Be creative Challenge Link

Author : Enigma

This challenge was quite fun ! Let’s see how it’s done

LovePotal1

Let’s see the source code

LovePortal2

Now we’re gonna try some LFI exploitation! I tried on every page and then decoded from base64 but only got something interessting from the index page !

LovePortal3

Here’s some explanation of the used command :

LovePortal4

And that’s what we get from decoding what we got from the index page exploitation !

LovePortal45

Let’s do what we did earlier but with the navbar bcz we see its name in the decoded script

LovePortal475

And when we decode from base64 again we see a hidden directory !

LovePortal5

Now we access to /log_546545/index.php

LovePortal6

Let’s go back to burpsuite and manipulate the User-Agent field !

LovePortal7

We clearly see the result of ‘ls’ command

LovePortal8

Now we go back to burpsuite and do cat our flag

LovePortal9

And here’s our flag !

LovePortal10