#12 Failing to dump games

Offen
vor 1 Jahr geöffnet von jefferyrlc · 3 Kommentare
jefferyrlc kommentierte vor 1 Jahr

every time I try to run this with my drive, this is what happens

libray -i /dev/sr2 -o /home/jeffery/Tales_of_Graces_f.iso
[*] Searching for PARAM.SFO
[*] PARAM.SFO found
Traceback (most recent call last):
  File "/usr/bin/libray", line 57, in <module>
    core.decrypt(args)
  File "/usr/lib/python3.10/site-packages/libray/core.py", line 211, in decrypt
    input_iso = iso.ISO(args)
  File "/usr/lib/python3.10/site-packages/libray/iso.py", line 168, in __init__
    cipher = AES.new(core.ISO_SECRET, AES.MODE_CBC, core.ISO_IV)
  File "/home/jeffery/.local/lib/python3.10/site-packages/Crypto/Cipher/AES.py", line 95, in new
    return AESCipher(key, *args, **kwargs)
  File "/home/jeffery/.local/lib/python3.10/site-packages/Crypto/Cipher/AES.py", line 59, in __init__
    blockalgo.BlockAlgo.__init__(self, _AES, key, *args, **kwargs)
  File "/home/jeffery/.local/lib/python3.10/site-packages/Crypto/Cipher/blockalgo.py", line 141, in __init__
    self._cipher = factory.new(key, *args, **kwargs)
SystemError: PY_SSIZE_T_CLEAN macro must be defined for '#' formats

My specs Arch Linux

kernel linux-tkg-pds 6.2.9-273

python 3.10.10-1

libray 0.0.9-1 (installed from the AUR)

drive: ASUS External Blu-Ray Writer Black, BW-16D1H-U PRO/BLK/G/AS/PDVD

not sure if this matters, but KDE Plasma 5.27.3 w/ wayland

every time I try to run this with my drive, this is what happens ``` libray -i /dev/sr2 -o /home/jeffery/Tales_of_Graces_f.iso [*] Searching for PARAM.SFO [*] PARAM.SFO found Traceback (most recent call last): File "/usr/bin/libray", line 57, in <module> core.decrypt(args) File "/usr/lib/python3.10/site-packages/libray/core.py", line 211, in decrypt input_iso = iso.ISO(args) File "/usr/lib/python3.10/site-packages/libray/iso.py", line 168, in __init__ cipher = AES.new(core.ISO_SECRET, AES.MODE_CBC, core.ISO_IV) File "/home/jeffery/.local/lib/python3.10/site-packages/Crypto/Cipher/AES.py", line 95, in new return AESCipher(key, *args, **kwargs) File "/home/jeffery/.local/lib/python3.10/site-packages/Crypto/Cipher/AES.py", line 59, in __init__ blockalgo.BlockAlgo.__init__(self, _AES, key, *args, **kwargs) File "/home/jeffery/.local/lib/python3.10/site-packages/Crypto/Cipher/blockalgo.py", line 141, in __init__ self._cipher = factory.new(key, *args, **kwargs) SystemError: PY_SSIZE_T_CLEAN macro must be defined for '#' formats ``` My specs Arch Linux kernel linux-tkg-pds 6.2.9-273 python 3.10.10-1 libray 0.0.9-1 (installed from the AUR) drive: ASUS External Blu-Ray Writer Black, BW-16D1H-U PRO/BLK/G/AS/PDVD not sure if this matters, but KDE Plasma 5.27.3 w/ wayland
Nichlas Severinsen kommentierte vor 1 Jahr
Besitzer

Sorry for the late reply - how did you install libray? Through AUR, pip, or manually?

I'm asking because on first look it seems it might use the wrong Crypto library on your system, do you have pycryptodome installed?

E.g., if you used pip - have you tried the proposed fix in the README.md?

sudo pip uninstall crypto
sudo pip uninstall pycrypto
sudo pip install pycryptodome
Sorry for the late reply - how did you install libray? Through AUR, pip, or manually? I'm asking because on first look it seems it might use the wrong Crypto library on your system, do you have pycryptodome installed? E.g., if you used pip - have you tried the proposed fix in the README.md? ``` sudo pip uninstall crypto sudo pip uninstall pycrypto sudo pip install pycryptodome ```
jefferyrlc kommentierte vor 1 Jahr
Ersteller

I used the AUR.

I used the AUR.
Nichlas Severinsen kommentierte vor 1 Jahr
Besitzer

Well the AUR is supposed to install python-pycryptodome to /usr/lib/python3.10/site-packages/, and your error hints to Crypto being loaded from /home/jeffery/.local/lib/python3.10/site-packages/Crypto/Cipher/AES.py which is both the wrong path and library - and as far as I know Crypto can't be installed from neither official repos nor AUR

So try to uninstall Crypto with pip uninstall crypto and see if that works. And if it doesn't try sudo. And if it still doesn't work also uninstall pycrypto both with and without sudo.

I'll look into if I can force libray to use pycryptodome somehow, but pycryptodome is a drop in replacement for Crypto and pycrypto. Also see

Well the AUR is supposed to install python-pycryptodome to `/usr/lib/python3.10/site-packages/`, and your error hints to Crypto being loaded from `/home/jeffery/.local/lib/python3.10/site-packages/Crypto/Cipher/AES.py` which is both the wrong path and library - and as far as I know `Crypto` can't be installed from neither official repos nor AUR So try to uninstall Crypto with `pip uninstall crypto` and see if that works. And if it doesn't try sudo. And if it still doesn't work also uninstall pycrypto both with and without sudo. I'll look into if I can force libray to use pycryptodome somehow, but pycryptodome is a drop in replacement for Crypto and pycrypto. Also see - https://theartofmachinery.com/2017/02/02/dont_use_pycrypto.html - https://blog.sqreen.com/stop-using-pycrypto-use-pycryptodome/
Anmelden, um an der Diskussion teilzunehmen.
Kein Meilenstein
Niemand zuständig
2 Beteiligte
Laden…
Abbrechen
Speichern
Hier gibt es bis jetzt noch keinen Inhalt.