[dependencies] Simplify Cryptodome

Closes #6292, closes #6272, closes #6338
This commit is contained in:
pukkandan
2023-02-28 23:10:54 +05:30
parent b059188383
commit 65f6e80780
11 changed files with 52 additions and 64 deletions

View File

@@ -50,10 +50,10 @@ class WrestleUniverseBaseIE(InfoExtractor):
data=data, headers=headers, query=query, fatal=fatal)
def _call_encrypted_api(self, video_id, param='', msg='API', data={}, query={}, fatal=True):
if not Cryptodome:
if not Cryptodome.RSA:
raise ExtractorError('pycryptodomex not found. Please install', expected=True)
private_key = Cryptodome.PublicKey.RSA.generate(2048)
cipher = Cryptodome.Cipher.PKCS1_OAEP.new(private_key, hashAlgo=Cryptodome.Hash.SHA1)
private_key = Cryptodome.RSA.generate(2048)
cipher = Cryptodome.PKCS1_OAEP.new(private_key, hashAlgo=Cryptodome.SHA1)
def decrypt(data):
if not data: