Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

不支持Python3 #10

Open
seoul2k opened this issue May 8, 2022 · 6 comments
Open

不支持Python3 #10

seoul2k opened this issue May 8, 2022 · 6 comments

Comments

@seoul2k
Copy link

seoul2k commented May 8, 2022

python3 /Users/seoul1k/Downloads/cloacked-pixel-master/lsb.py '/Users/seoul1k/Desktop/截屏2022-05-08 12.26.41.png' index.txt 123
File "/Users/seoul1k/Downloads/cloacked-pixel-master/lsb.py", line 56
print "[] Input image size: %dx%d pixels." % (width, height)
^
SyntaxError: invalid syntax
改成python3版本后,又报:
python3 /Users/seoul1k/Downloads/cloacked-pixel-master/lsb.py hide '/Users/seoul1k/Desktop/截屏2022-05-08 12.26.41.png' ./Desktop/index.txt 123
[
] Input image size: 116x48 pixels.
[*] Usable payload size: 2.04 KB.
[+] Payload size: 0.006 KB
Traceback (most recent call last):
File "/Users/seoul1k/Downloads/cloacked-pixel-master/lsb.py", line 192, in
embed(sys.argv[2], sys.argv[3], sys.argv[4])
File "/Users/seoul1k/Downloads/cloacked-pixel-master/lsb.py", line 67, in embed
data_enc = cipher.encrypt(data)
File "/Users/seoul1k/Downloads/cloacked-pixel-master/crypt.py", line 16, in encrypt
raw = self._pad(raw)
File "/Users/seoul1k/Downloads/cloacked-pixel-master/crypt.py", line 27, in _pad
return s + (self.bs - len(s) % self.bs) * chr(self.bs - len(s) % self.bs)
TypeError: can't concat str to bytes

@LanYunDev
Copy link

一样

@constantinedev
Copy link

自己加返D()係print後面啦

@kfbfarley
Copy link

there is a commit/pr with the solution here

@NatteeSetobol
Copy link

Fixed for Python 3: https://github.com/NatteeSetobol/cloacked-pixel . I tried fix it using chat-gpt but it didn't work as well so I so I learned how it works and now it runs on python3.

@2477231995
Copy link

已修复 Python 3:https://github.com/NatteeSetobol/cloacked-pixel 。我尝试使用 chat-gpt 修复它,但它的效果不佳,所以我学习了它的工作原理,现在它在 python3 上运行。

Very impressive, thank you, big shot

@aristorechina
Copy link

I also encountered the same issue, so I recently fixed it. It now perfectly supports Python 3. Meanwhile, I have added a Chinese translation to the README.
我也遇到了这个问题,于是我最近修复了它,使其支持 Python 3。同时我还为 README 添加了中文翻译。

aristorechina/cloacked-pixel: LSB steganography and detection

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants