[HV22.01] QR means quick reactions, right?
Santa’s brother Father Musk just bought out a new decoration factory. He sacked all the developers and tried making his own QR code generator but something seems off with it. Can you try and see what he’s done wrong?
Solution
So, we got a .gif file showing lot’s of QR codes. The challenge is to split them frame by frame and read the codes, which is pretty straightforward.
Here is the file:
I used PIL to open the image file and split it into frames and pyzbar (python bindings for zbar, a known barcode scanner) to scan each frame.
#!/usr/bin/env python3.11
from PIL import Image
from pyzbar.pyzbar import decode
im = Image.open('./hv22_01_gif.gif')
i = 0
result = ''
try:
while 1:
im.seek(i) # seeks to the next frame
imframe = im.copy() # creates a copy of the frame
decoded = decode(imframe) # uses pyzbar decoder
result += decoded[0].data.decode('utf-8') # adds the decoded value to the result string
i += 1
except EOFError:
print(result)
pass
This returns the flag HV22{I_CaN_HaZ_Al_T3h_QRs_Plz}