synfron / ReshaperForBurp

Burp Suite Extension - Trigger actions and reshape HTTP request/response and WebSocket traffic using configurable rules
https://synfron.github.io/ReshaperForBurp/
MIT License
91 stars 12 forks source link

Reshaper startup failed due to the usage of the string 'Spider' #63

Closed AkikoOrenji closed 6 months ago

AkikoOrenji commented 6 months ago

Had burp crash while scanning and now upon trying to launch Reshaper i get the following.....

"message" : "Reshaper startup failed", "exception" : "com.fasterxml.jackson.databind.exc.InvalidFormatException: Cannot deserialize value of type synfron.reshaper.burp.core.BurpTool from String \"Spider\": not one of the values accepted for Enum class: [Target, Session, Extender, Repeater, WebSockets, Scanner, Intruder, Proxy]\n at [Source: (StringReader); line: 1, column: 70377] (through reference chain: java.util.ArrayList[31]->synfron.reshaper.burp.core.rules.Rule[\"whens\"]->java.util.ArrayList[7]->synfron.reshaper.burp.core.rules.whens.WhenFromTool[\"tool\"])\nsynfron.reshaper.burp.core.exceptions.WrappedException: com.fasterxml.jackson.databind.exc.InvalidFormatException: Cannot deserialize value of type synfron.reshaper.burp.core.BurpTool from String \"Spider\": not one of the values accepted for Enum class: [Target, Session, Extender, Repeater, WebSockets, Scanner, Intruder, Proxy]\n at [Source: (StringReader); line: 1, column: 70377] (through reference chain:

Removed and reinstalled the latest version of the plugin from bapp store but no good. Any idea what to try next ? Burp diagnostics below...


SYSTEM PROPERTIES

awt.dnd.drag.threshold 15 awt.useSystemAAFontSettings on com.sun.net.ssl.requireCloseNotify false exe4j.moduleName /home/asdf/BurpSuitePro/BurpSuitePro file.encoding UTF-8 file.separator / flatlaf.uiScale.enabled false install4j.appDir /home/asdf/BurpSuitePro/ install4j.exeDir /home/asdf/BurpSuitePro/ install4j.jvmDir /home/asdf/BurpSuitePro/jre install4j.launcherId 70 install4j.swt false java.class.path /home/asdf/BurpSuitePro/.install4j/i4jruntime.jar:/home/asdf/BurpSuitePro/.install4j/launcherccf7dac9.jar:/home/asdf/BurpSuitePro/burpsuite_pro.jar java.class.version 65.0 java.home /home/andrewc/BurpSuitePro/jre java.io.tmpdir /tmp java.library.path /usr/java/packages/lib:/usr/lib64:/lib64:/lib:/usr/lib java.net.useSystemProxies true java.runtime.name OpenJDK Runtime Environment java.runtime.version 21.0.1+12-29 java.specification.name Java Platform API Specification java.specification.vendor Oracle Corporation java.specification.version 21 java.vendor Oracle Corporation java.vendor.url https://java.oracle.com/ java.vendor.url.bug https://bugreport.java.com/bugreport/ java.version 21.0.1 java.version.date 2023-10-17 java.vm.compressedOopsMode Zero based java.vm.info mixed mode java.vm.name OpenJDK 64-Bit Server VM java.vm.specification.name Java Virtual Machine Specification java.vm.specification.vendor Oracle Corporation java.vm.specification.version 21 java.vm.vendor Oracle Corporation java.vm.version 21.0.1+12-29 jdk.debug release jdk.tls.allowUnsafeServerCertChange true jdk.tls.maxCertificateChainLength 1337 native.encoding UTF-8 org.bouncycastle.jsse.client.dh.minimumPrimeBits 1024 org.bouncycastle.jsse.client.dh.unrestrictedGroups true os.arch amd64 os.name Linux os.version 5.18.0-kali5-cloud-amd64 path.separator : stderr.encoding UTF-8 stdout.encoding UTF-8 sun.arch.data.model 64 sun.awt.enableExtraMouseButtons true sun.boot.library.path /home/asdf/BurpSuitePro/jre/lib sun.cpu.endian little sun.io.unicode.encoding UnicodeLittle sun.java.command install4j.burp.StartBurp sun.java.launcher SUN_STANDARD sun.jnu.encoding UTF-8 sun.management.compiler HotSpot 64-Bit Tiered Compilers swing.aatext true user.dir /home/asdf/BurpSuitePro user.home /home/asdf user.language en user.name asdf user.timezone Australia/Melbourne


SYSTEM RESOURCES

Number of processors 8 Total JVM memory 536 MiB Max JVM memory 15.68 GiB Free JVM memory 255.1 MiB

Total physical memory 31.36 GiB Free physical memory 28.79 GiB Total swap 0 bytes Free swap 0 bytes


BURP PROPERTIES

Burp Version 2024.2.1.5 Build Number 28354 Product Name Burp Suite Professional Update Channel Stable Burp Browser [version=123.0.6312.122, installationPath=/home/adsfas/BurpSuitePro/burpbrowser/123.0.6312.122] Code source /home/sdfasdf/BurpSuitePro/burpsuite_pro.jar JAR type Installer currenttimemillis 1714016635628 nanotime 1032347101400 superuser false

ddwightx commented 6 months ago

That's interesting. Spider was removed as Burp Tool option from Reshaper back in 2022. Odd that you would get the error now unless you loaded an old rules import.

Unfortunately, there is no quick UI based solution. The solution is similar what was suggested in https://github.com/synfron/ReshaperForBurp/issues/43#issuecomment-1734269959, though in your case, since you appear to be on Linux, the location of the preferences is different, see https://stackoverflow.com/a/1320798.

In your case, you will need to replace Spider in the JSON in the preferences with a supported value (one of Target, Session, Extender, Repeater, WebSockets, Scanner, Intruder, Proxy). Once Reshaper is able to load successfully, you can edit the Rule to what you really want it to be.

AkikoOrenji commented 6 months ago

thanks. That fixed it. Some gnarly directory names to deal with on linux in /home/username/.java/.userPrefs/burp/extensions/ so easiest just to delete the problematic prefs.xml to resolve the issue e.g.

grep -rl Spider /home/username/.java/.userPrefs/burp/ rm ' /home/username/.java/.userPrefs/burp/extensions/_!&8!`g"l!(:!a!"h!(!!~@"y/prefs.xml'