wongyee11
wongyee11
安装pycryptodomex后,更改为from Cryptodome.Cipher import AES,再次运行后报错: ERROR: test_aes_interface (__main__.AESTest) test aes interface ---------------------------------------------------------------------- Traceback (most recent call last): File "G:/PycharmProjects/Django/guest-master/tests/interface_AES_test.py", line 37, in test_aes_interface encoded = self.encryptAES(json.dumps(payload), self.app_key).decode() File "G:/PycharmProjects/Django/guest-master/tests/interface_AES_test.py", line 27,...
修改了两行代码: self.app_key = str.encode('W7v4D60fds2Cmk2U') ciphertext = cryptor.encrypt(str.encode(self.pad(src))) 再次运行报错和未更改库之前一样: Traceback (most recent call last): File "G:/PycharmProjects/Django/guest-master/tests/interface_AES_test.py", line 46, in test_aes_interface result = r.json() File "D:\Anaconda3\lib\site-packages\requests\models.py", line 892, in json return complexjson.loads(self.text,...