[GH-ISSUE #97] [Question] - Crypto usage #92

Closed
opened 2026-02-26 12:20:28 +03:00 by kerem · 5 comments
Owner

Originally created by @vankk on GitHub (May 17, 2020).
Original GitHub issue: https://github.com/brentvollebregt/auto-py-to-exe/issues/97

Hello, I was trying to use the crypto key and I came across with this thread on stackoverflow, also tried to use pip install pycrypto and didn't worked as well. Seems that the package has some issues, there is any plan to update this feature or just I may doing some wrong?!😛

Edit: nvm, just saw that the pyinstaller still requires the pycrypto and didn't updated yet.

Regards,
vankk.

Originally created by @vankk on GitHub (May 17, 2020). Original GitHub issue: https://github.com/brentvollebregt/auto-py-to-exe/issues/97 Hello, I was trying to use the crypto key and I came across with [this thread](https://stackoverflow.com/a/58077358) on stackoverflow, also tried to use `pip install pycrypto` and didn't worked as well. Seems that the package has [some issues](https://pastebin.com/q3he9uEv), there is any plan to update this feature or just I may doing some wrong?!😛 *Edit*: nvm, just saw that the pyinstaller still requires the pycrypto and didn't updated yet. Regards, vankk.
kerem closed this issue 2026-02-26 12:20:28 +03:00
Author
Owner

@brentvollebregt commented on GitHub (May 18, 2020):

If you want to use the --key argument from PyInstaller, I definitely recommend using pycryptodome instead of PyCrypto as it is safer. It has almost the same API as PyCrypto so it should work.

You can install pycryptodome using:

python -m pip install pycryptodome
<!-- gh-comment-id:629950781 --> @brentvollebregt commented on GitHub (May 18, 2020): If you want to use the `--key` argument from PyInstaller, I definitely recommend using `pycryptodome` instead of `PyCrypto` as it is safer. It [has almost the same API as PyCrypto](https://pycryptodome.readthedocs.io/en/latest/src/vs_pycrypto.html) so it should work. You can install `pycryptodome` using: ``` python -m pip install pycryptodome ```
Author
Owner

@vankk commented on GitHub (May 19, 2020):

Could you post an usage sample? Did a few searchs the past days and everytime that I open the the .exe returns an Failed to execute script pyiboot01_bootstrap.

<!-- gh-comment-id:631096845 --> @vankk commented on GitHub (May 19, 2020): Could you post an usage sample? Did a few searchs the past days and everytime that I open the the .exe returns an `Failed to execute script pyiboot01_bootstrap`.
Author
Owner

@brentvollebregt commented on GitHub (May 20, 2020):

Outlined in "Encrypting Python Bytecode" are some details on how to encrypt your executable contents.

I had been told that pycryptodome works with pyinstaller but when trying it myself, it appears that may not be the case. I get an error saying: zlib.error: Error -3 while decompressing data: incorrect header check.

I have noticed in PyInstallers GitHub issues that the maintainer has mentioned that --key is no longer available. I did a search for --key in PyInstallers GitHub issues and found this PR but unfortunately it hasn't been merged yet - looks promising though.

<!-- gh-comment-id:631326984 --> @brentvollebregt commented on GitHub (May 20, 2020): Outlined in ["Encrypting Python Bytecode"](https://pyinstaller.readthedocs.io/en/stable/usage.html#encrypting-python-bytecode) are some details on how to encrypt your executable contents. I had been told that `pycryptodome` works with `pyinstaller` but when trying it myself, it appears that may not be the case. I get an error saying: `zlib.error: Error -3 while decompressing data: incorrect header check`. I have noticed in PyInstallers GitHub issues that the maintainer has mentioned that `--key` is no longer available. I did a search for `--key` in PyInstallers GitHub issues and [found this PR](https://github.com/pyinstaller/pyinstaller/pull/4652) but unfortunately it hasn't been merged yet - looks promising though.
Author
Owner

@vankk commented on GitHub (May 25, 2020):

Thanks my friend, that helped alot.

<!-- gh-comment-id:633656211 --> @vankk commented on GitHub (May 25, 2020): Thanks my friend, that helped alot.
Author
Owner

@brentvollebregt commented on GitHub (May 25, 2020):

Sweet. Since this is more related to PyInstaller than this tool, I'll close the issue. If you do find an issue with this, feel free to open a new issue.

<!-- gh-comment-id:633709406 --> @brentvollebregt commented on GitHub (May 25, 2020): Sweet. Since this is more related to PyInstaller than this tool, I'll close the issue. If you do find an issue with this, feel free to open a new issue.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/auto-py-to-exe#92
No description provided.