dlegs / php-jpeg-injector

Injects php payloads into jpeg images
454 stars 118 forks source link

Error: concatenating bytes with str #3

Closed apehex closed 4 years ago

apehex commented 4 years ago

Hey there, thanks a lot for this snippet! It got me kickstarted with steganography while I thought it was out of reach :)

I had a few issues running it though, here's one about type mismatching:

Traceback (most recent call last):
  File "gd-jpeg.py", line 53, in <module>
    main()
  File "gd-jpeg.py", line 18, in main
    inject_payload(jpeg, loc, payload, output)
  File "gd-jpeg.py", line 37, in inject_payload
    bin_payload = bin(int(binascii.hexlify(payload),16))
TypeError: a bytes-like object is required, not 'str'