Challenge Description:
what happens on earth stays on earth
Click to Reveal Meme
i thought this would be funny
what we got
kendrick lamar themed flask app called kung fu kennys dojo
hint says "what happens on earth stays on earth" — that's from element btw and the challenge name is heart part 7 so heartbleed vibes from the jump
werkzeug/flask python backend with a /search page and a /login portal
sqli on /search
search uses SQL LIKE so % dumps everything and UNION SELECT works with 2 columns. We can dump the schema and tables directly using SQLi.

encrypted scrolls table with an iv — flag is in there but we need the key.
dumping creds + encrypted flag
We dump the users table and scrolls table containing the ciphertext and IV.
admin panel
logged in with admin:duckworth — sets a jwt cookie and redirects to /admin.

admin panel has two endpoints that matter:
/api/flag— returns the encrypted flag as aes-256-cbc/cipher/health— takes json with data and size fields and echoes back
/api/flag response
heartbleed — leaking the key
the /cipher/health endpoint takes your data and a size param — if you set size bigger than your actual data it reads past the buffer and leaks memory. That's literally heartbleed and that's what the challenge name is about.
decrypting the flag
We write a python decryption script using the leaked AES key:
decrypt.py
from cryptography.hazmat.primitives.ciphers import Cipher, algorithms, modes
from cryptography.hazmat.primitives import padding
import base64
key = bytes.fromhex('9e1b8a5f8ed44e4711c0f4768c13f5a336bc4a6deeea307720a87b9fca44f02d')
ct = base64.b64decode('baCIJCXuBcIOJ23q0FS8GDaSN5/71aIqY156ju5Z6oc=')
iv = base64.b64decode('fcSvIZ1LMw72z34mvr0O5A==')
cipher = Cipher(algorithms.AES(key), modes.CBC(iv))
pt = cipher.decryptor().update(ct) + cipher.decryptor().finalize()
flag = padding.PKCS7(128).unpadder().update(pt) + padding.PKCS7(128).unpadder().finalize()
print(flag)
output
Decrypted flag: dalctf{p1mp_p1mp_h00r4y}
Flag
Thanks master Kendrick i know im worthy enough😊
dalctf{p1mp_p1mp_h00r4y}
At least Master Kendrick loves his fans 😊😊 😊😊 😊😊 😊😊