NotSoSecure/Blacklist3r

encrypteddata value for AspDotNetWrapper too long for windows command line

ConnorSnee opened this issue · 2 comments

The maximum length of the string that you can use in command prompt is 8191 characters. I am trying to use AspDotNetWrapper, however the viewstate is over 50,000 characters long. In the case that the encrypteddata is longer than the maximum allowed length I don't know of any way to run the executable other than changing it so that a file path is accepted in place of the value itself

@ConnorSnee You may use bat file as an option.

The new code is deployed, according to which it will consider encrypted data as a file path and if the file not found then only it will consider it as a raw encrypted data.

Example:

  1. AspDotNetWrapper.exe --keypath MachineKeys.txt --encrypteddata viewstate.txt --decrypt --purpose=viewstate --modifier=CA0B0334 --macdecode

  2. AspDotNetWrapper.exe --keypath MachineKeys.txt --encrypteddata /wEPDwUKLTkyMTY0MDUxMg9kFgICAw8WAh4HZW5jdHlwZQUTbXVsdGlwYXJ0L2Zvcm0tZGF0YWRkbdrqZ4p5EfFa9GPqKfSQRGANwLs= --decrypt --purpose=viewstate --modifier=CA0B0334 --macdecode