[CTF] DEFCON31 Quals
2023. 5. 29. 20:11ㆍ정보보안/CTFLOG
반응형
Welcome to Quals
This challenge is probably a mic check. In the beginning, there was an issue where the server didn't work properly due to a high influx of users.
Anyway, I will explain this chall
.
.
.
You can access the server of the problem through the provided URL. The problem was simple.
By using "ls /," it was possible to confirm the existence of "flag.txt" in the root directory, and reading it was all that needed to be done.
However, there was one issue here. When entering "ls /," it didn't provide the correct response.
I thought that it was being substituted (like Caesar cipher), so I had to transform the command accordingly
def rotate_string(s):
rotation = 13
result = ""
for char in s:
if char.isalpha():
ascii_offset = 97 if char.islower() else 65
rotated = (ord(char) - ascii_offset + rotation) % 26 + ascii_offset
result += chr(rotated)
else:
result += char
return result
original_string = "cd / && cat welcome_flag.txt"
rotated_string = rotate_string(original_string)
print(rotated_string)
gotcha!!
반응형
'정보보안 > CTFLOG' 카테고리의 다른 글
[CTF] CCE2023 final (1) | 2023.07.13 |
---|---|
[CTF] SECCON Beginners 2023 (0) | 2023.06.04 |
[CTF] GreyCTF'23 write up (0) | 2023.05.22 |
[CTF] LINE CTF 2023 - old pal (0) | 2023.03.26 |
[CTF] LINE CTF 2023 - baby simple go url (0) | 2023.03.26 |