I have a javascript code from a page that looks like
var link = '{"ct":"AAQz1rUDqp849MRxu0tqGRGvPcLzVG24xa5zbYxpwVHH6Z2p95xPPzNhMIRMcaTPvijE71RQU1X3cQhtnXdRScA6UBiLWNs9vMul2gldnMTpT92sDYHl+hKBGy2dR22Un7ElToipSqeqRrwhEK8T9ROMChrBw8i7JOICpOYoVhqDB72BH2RG\/PqjRqsKittES5BVhTTY9cs+zQI0rM+FQA62bVCL57P3RD+E+aWJJLjUvoXBqct6Jc5W7li9mk9udgn9rPKkCbXSCvwIxcWS5C1kw4uSO7y0IlovaTWLAIw5nY0l4REjbC1wPWrtxDWLlr8J+\/sQdDF+P61VHz6yiC+w56QLDjVwz4kBl3r3uP\/VZ7kUuLwWHSHnbmmXv31f","iv":"feae762ac889376169708872d9676319","s":"9b2328e8a4ee2717"}';
var msg = "f12c8b59265dc1e898135211cc30be49";
var finalUrl = JSON.parse(CryptoJS.AES.decrypt(link, msg, {format: CryptoJSAesJson}).toString(CryptoJS.enc.Utf8));
I figure that ct is encrypted msg, s is for Salt and iv is iv
I am trying to decode the finalUrl with python.
AES = AESDecrypter()
decryptor = AES.new(s, AES.MODE_CBC, IV=iv)
dec = decryptor.decrypt(ct)
I know it is not going to work as I can't figure how to use
var msg = "f12c8b59265dc1e898135211cc30be49"
in Python.
Also figured that CryptoJSAesJson
may have some extra function.
Someone please show me steps how I can retrieve the finalUrl with Python with the data given here.
Any suggestion is really appreciated. Apology for my poor coding knowledge.