-
Notifications
You must be signed in to change notification settings - Fork 14.1k
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
Add support for Ruby 3.3 #18668
Add support for Ruby 3.3 #18668
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -67,7 +67,7 @@ jobs: | |
- '3.0' | ||
- '3.1' | ||
- '3.2' | ||
- '3.3.0-preview3' | ||
- '3.3' | ||
os: | ||
- ubuntu-20.04 | ||
- ubuntu-latest | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -83,8 +83,7 @@ Gem::Specification.new do |spec| | |
# NTLM authentication | ||
spec.add_runtime_dependency 'rubyntlm' | ||
# Needed by anemone crawler | ||
# Locked until build env can handle newer version due to native compile issue in 1.15.x | ||
spec.add_runtime_dependency 'nokogiri', '~> 1.14.0' | ||
spec.add_runtime_dependency 'nokogiri' | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Nokogiri v16 is required for Ruby 3.3 support But it looks like this was pinned previously by #18103 when there were issues with compiling the nightly omnibus installers with older. Before we merge this, we'll need to manually rebuild the omnibus installer to see if the previous issues are resolved or not, as it looks like some changes have been made to how they handle libxml |
||
# Needed by db.rb and Msf::Exploit::Capture | ||
spec.add_runtime_dependency 'packetfu' | ||
# For sniffer and raw socket modules | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,5 @@ | ||
# -*- coding: binary -*- | ||
|
||
## | ||
# This module requires Metasploit: https://metasploit.com/download | ||
# Current source: https://github.com/rapid7/metasploit-framework | ||
|
@@ -70,7 +72,9 @@ def generate(_opts = {}) | |
shellcode = shellcode + command_string + "\x00" | ||
|
||
# we need to align our shellcode to 4 bytes | ||
(shellcode = shellcode + "\x00") while shellcode.length%4 != 0 | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Bit of a weird behaviour change here between ruby versions: shellcode = ""
(shellcode = shellcode + "\x00") while shellcode.bytesize%4 != 0
puts RUBY_DESCRIPTION
puts shellcode.bytesize Ruby 3.0:
Ruby 3.3:
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Looks like this is fixed in the head of Ruby now; Will leave it as-is |
||
while shellcode.bytesize%4 != 0 | ||
shellcode = shellcode + "\x00" | ||
end | ||
|
||
return super + shellcode | ||
|
||
|
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.
Bump required for Ruby 3.3 support
https://github.com/sparklemotion/sqlite3-ruby/blob/536152860daf4e4acbf0608d0840941f1a878722/CHANGELOG.md#170--2023-12-27