Last active
October 20, 2019 09:00
-
-
Save bonprosoft/3dba4e4c499a2b1c5b84d6291b1ddcee to your computer and use it in GitHub Desktop.
SECCON 2019 Online CTF: sandstorm
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import cv2 | |
import numpy | |
image = cv2.imread('./sandstorm.png') | |
height, width = image.shape[:2] | |
new_height = height // 8 | |
new_width = width // 8 | |
new_image = numpy.zeros((new_height, new_width, 3)) | |
for h in range(0, new_height): | |
for w in range(0, new_width): | |
new_image[h][w] = image[h*8][w*8] | |
cv2.imwrite('key.png', new_image) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment