from PIL import Imageimport numpy as np im = Image.open('heartbleed.png') # In this case, it's a 3-band (red, green, blue) image# so we'll unpack the bands into 3 separate 2D arrays.r, g, b = np.array(im).T # Let's make an alpha (transparency) band based on where blue is < 100a = np.zeros_like(b)a[b
import numpy as npimport mpl_toolkits.mplot3d.axes3d as p3import matplotlib.pyplot as pltimport colorsysfrom PIL import Image # (1) Import the file to be analyzed!img_file = Image.open("sunset.jpg")img = img_file.load() # (2) Get image width & height in pixels[xs, ys] = img_file.sizemax_intensity = 100hues = {} # (3) Examine each pixel in the image filefor x in xrange(0, xs): for y in xrange(0, ..
heartbleed 는 2015년 보안 취약점 중 대표적인 취약점이라 할수 있다. heartbleed 취약점은 공격자가 서버의 메모리의 일부분을 읽어 올 수 있는 openSSL의 취약점으로 요청할때 요청할 단어가 만약 aaa이면 3바이트를 요청하면 되는데 이 보다 더 큰 바이트인 500을 하게 된다면 aaa를 반환하고 남은 메모리를 다른 값으로 뱉어 주는 취약점을 말한다. 취약점을 실습해볼 때에는 1. https://raw.githubusercontent.com/HackerFantastic/Public/master/exploits/heartbleed.c여기서 다운을 받은 후 2. gcc heartbleed.c -o heartbleed -Wl,-Bstatic -ssl -Wl,-Bdynamic -lssl3 ..