From 9201f4ed5e3ba2ba1a21458f3ebdb190229cc56e Mon Sep 17 00:00:00 2001 From: Postmodern Date: Sat, 18 May 2024 18:29:56 -0700 Subject: [PATCH] Group methods together. --- exploits/activemq/CVE-2023-46604.rb | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/exploits/activemq/CVE-2023-46604.rb b/exploits/activemq/CVE-2023-46604.rb index d065195..96c8c21 100755 --- a/exploits/activemq/CVE-2023-46604.rb +++ b/exploits/activemq/CVE-2023-46604.rb @@ -80,6 +80,17 @@ class CVE_2023_46604 < Exploit "https://github.com/mrpentst/CVE-2023-46604/blob/main/poc.xml" ] + default_port 61616 + + param :web_host, default: "localhost", + desc: "A routable hostname for the exploit runner's web server" + + param :web_port, Integer, default: 1024 + rand(65535 - 1024), + desc: "A listen port for the exploit runner's web server" + + param :exfil_file, default: '/etc/passwd', + desc: 'The file to exfiltrate' + # # Test whether the target system is vulnerable. # @@ -112,17 +123,6 @@ def test end end - default_port 61616 - - param :web_host, default: "localhost", - desc: "A routable hostname for the exploit runner's web server" - - param :web_port, Integer, default: 1024 + rand(65535 - 1024), - desc: "A listen port for the exploit runner's web server" - - param :exfil_file, default: '/etc/passwd', - desc: 'The file to exfiltrate' - JAVA_CLASSNAME = "org.springframework.context.support.ClassPathXmlApplicationContext" PROVIDER_VERSION = "ProviderVersion" STRING_TYPE = 9