THJCC CTF 2024 Winter
Sat, 14 - 15 Dec 2024
๐ Crypto
Girlfriend
Description
Kohiroๆฟๅฐไบไธๆฎตๅฅณๅ็ตฆ็ๅฏๆ๏ผไฝๆฏไปไธ็ฅ้้ๆฏไป้บผ่ซๅนซๅฅน่งฃๅฏ Kohiro received a mysterious encoded message from his girlfriend, but he doesn't know what it is. Please help him decode it.
WkdsWmIwbFRSazFaUkVKTFdIcHdhazFFTVdaa01EUTk=Author : kohiro
Solve
So, this challenge doesn't provide any file attachment or something else. Then, i know this is a classical cipher that we can solve from any online tools. For a quick solve, i used CyberChef.
Firstly, i tried to use Base64 to decode it because it's identically similiar with Base64 format. But it is still encrypted. I tried Base64 again and again until 3 times. After that, the encrypted format looks like ROT47.
The last cipher is ROT13 anddd yeahh! i got the flag
Flag :
S-box
Description
In cryptography, an S-box (substitution-box) is a basic component of symmetric key algorithms which performs substitution. In block ciphers, they are typically used to obscure the relationship between the key and the ciphertext, thus ensuring Shannon's property of confusion. Mathematically, an S-box is a nonlinear vectorial Boolean function.
Author : Dr. Dog
Solve
In this challenge, author provided 2 attachment files, chal.py and output.txt. The output.txt is the encrypted flag, and the chal.py is the encrypting system used for output.
It's an S-box encryption system. Then, i search in google and found the exact paragraph as the description does.
In cryptography, an S-box (substitution-box) is a basic component of symmetric key algorithms which performs substitution. In block ciphers, they are typically used to obscure the relationship between the key and the ciphertext, thus ensuring Shannon's property of confusion. Mathematically, an S-box is a nonlinear[1] vectorial Boolean function.[2] (Wikipedia).
So, just make a script to reverse the S-box, then decode the Base64 cipher text. Here is my script
Once you run it, you will finnd the actual flag (plaintext).
Flag :
๐ Web
Notepad
Description
I made a notepad+++ in python! http://cha-thjcc.scint.org:10001/
Author: xiulan
Solve
Yeah, he just made a notepad++ in python. This is how the web look like.
Firstly, i go to the source code that is provided from author. It has a redacted flag file and the HTML file is in a subfolder.
So, index.htmlis in the /template folder and flag.txt is in the main folder. If i want to access the flag.txt, i have to change the cookies value of the web that i accessing.

Change the "Value" from 5b132a89...... to ../flag.txt to access the flag file.

Yeah, we got the real flag from changing a value of cookie session
Flag :
Thanks for reading this writeup. Support me by buy me a coffee here
Last updated