-
Notifications
You must be signed in to change notification settings - Fork 14.4k
Support AES-128-CBC as an additional option for TLV encryption #13783
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I was going to nitpick and say "use type != NONE
rather than type == .. || type ==
"... for future-proofing, then I realised that we're calling AES encryption functions.. not generic ones. So it makes perfect sense.
Looks good to me! Nice work as always mate.
Now that rapid7/metasploit-payloads#418 has landed and payloads gem 2.0.7 has been released, would you like to add the payload bump to this PR? |
Bumped this to use metasploit-payloads 2.0.9 now. |
We need rapid7/metasploit-payloads#421 on the 6.x branch for 100% test passes. |
Original Release Notes |
Release NotesFixed a bug related to recent cryptography changes, where Java Meterpreter payloads may not have access to 256-bit encryption. This fix allows Meterpreter running in older Java environments to use AES-128-CBC if 256-bit encryption is not available. |
This adds AES-128-CBC as an additional option for TLV encryption. Currently, the only instance in which this should be used is when a Java Meterpreter is running in an environment which lacks strong crypto (such as the default configuration of older versions). Alot of the logic I added relies on the notion that if encrypt is enabled, it's AES-something and the key length is used to determine whether it's AES-128 or AES-256.
See: rapid7/metasploit-payloads#418
Verification
sessions -v
to see the encryption type that's used (again based on the key length)post/test/meterpreter
)Example
Example Output
Landing Notes
Once ready to be merged into 6.x, this will need to follow slightly modified instructions from here.