[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M6KJCBBWVFRMNSXMC2RF16G4":3,"skill-same:01M6KJCBBWVFRMNSXMC2RF16G4":65},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":15,"categories":16,"keywords":17,"publishedAt":38,"linkOnly":39,"markdownContent":40,"markdownBody":41,"frontMatter":42,"refName":43,"commitSha":44,"skillDirectory":45,"forksCount":46,"repositoryHtmlUrl":47,"repositoryHomepageUrl":48,"ownerHtmlUrl":49,"ownerBlogUrl":6,"ownerDescription":6,"updatedAt":50,"install":51,"resources":64},"01M6KJCBBWVFRMNSXMC2RF16G4","druid-javascript-injection-fix",null,"How to patch the Apache Druid 0.20.0 JavaScript sandbox bypass vulnerability. Use this skill when fixing CVE in Druid where authenticated attackers can execute arbitrary code through malicious JavaScript payloads via the sampler endpoint. The vulnerability allows empty key \"\" in filter specifications to bypass JavaScript security settings.","cxcscmu\u002FSkillLearnBench","cxcscmu","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F142838272?v=4","01M6KCQDFQWPDSN0MKZY96MSQP","01M6KCQDM7G70TKJ28NTSQC0RZ",93,"MIT","https:\u002F\u002Fgithub.com\u002Fcxcscmu\u002FSkillLearnBench\u002Fblob\u002Fmain\u002Fskills\u002Fb4-skill-creator-claude-haiku-4-5\u002Ffix-security-bug\u002Fdruid-javascript-injection-fix\u002FSKILL.md",[],[18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37],"fix","druid javascript injection fix","injection","javascript","payloads","sandbox","can","specifications","via","filter","how to","patch","use","code","malicious","settings","how","vulnerability","cve","apache","2026-11-10 10:12:30",false,"---\nname: druid-javascript-injection-fix\ndescription: How to patch the Apache Druid 0.20.0 JavaScript sandbox bypass vulnerability. Use this skill when fixing CVE in Druid where authenticated attackers can execute arbitrary code through malicious JavaScript payloads via the sampler endpoint. The vulnerability allows empty key \"\" in filter specifications to bypass JavaScript security settings.\n---\n\n# Fixing Apache Druid JavaScript Injection Vulnerability\n\n## Vulnerability Overview\n\nApache Druid 0.20.0 contains a critical vulnerability where authenticated attackers can execute arbitrary Java code through malicious JavaScript payloads. The vulnerability exists in the `\u002Fdruid\u002Findexer\u002Fv1\u002Fsampler` endpoint where the empty key `\"\"` in filter specifications can bypass JavaScript security settings.\n\n**Affected Component:** Druid indexer sampler - specifically the `JavaScriptFilter` validation\n\n**Root Cause:** Insufficient validation of filter specification keys before JavaScript execution\n\n## Identifying the Vulnerable Code\n\nThe vulnerability is typically found in:\n- `druid-core\u002Fsrc\u002Fmain\u002Fjava\u002Forg\u002Fapache\u002Fdruid\u002Fquery\u002Ffilter\u002FJavaScriptFilter.java`\n- Filter parsing\u002Fvalidation logic that processes the `transformSpec.filter` JSON\n\nLook for:\n1. JavaScript filter implementations that execute user-provided functions\n2. Lack of validation on the filter specification keys\n3. Missing checks for suspicious keys (especially empty strings `\"\"`)\n\n## Patch Strategy\n\n### 1. Validate Filter Specification Keys\n\nAdd validation to reject or sanitize suspicious keys in the filter specification:\n\n```java\n\u002F\u002F Reject empty keys or keys that bypass security\nif (filterSpec.containsKey(\"\") || filterSpec.containsKey(null)) {\n    throw new IllegalArgumentException(\"Invalid filter specification: contains empty or null keys\");\n}\n```\n\n### 2. Strengthen JavaScript Context Setup\n\nEnsure the JavaScript execution context:\n- Explicitly disables dangerous Java interop\n- Validates function syntax before execution\n- Runs in a restricted scope\n\n```java\n\u002F\u002F Example: Check for java.lang.Runtime references\nString function = getFunction();\nif (function.contains(\"java.lang.Runtime\") ||\n    function.contains(\"java.lang.ProcessBuilder\")) {\n    throw new IllegalArgumentException(\"JavaScript functions cannot access Java runtime\");\n}\n```\n\n### 3. Validate Filter Configuration Structure\n\nBefore executing any JavaScript filter, validate the complete filter specification:\n- All keys should be expected, known keys\n- Nested objects should follow the documented schema\n- Reject any non-standard keys\n\n## Testing the Patch\n\nAfter patching, verify:\n\n1. **Legitimate requests work:**\n   - Standard JavaScript filters execute correctly\n   - Filters with valid syntax pass validation\n   - Normal sampler operations complete successfully\n\n2. **Exploit attempts are blocked:**\n   - Requests with empty key `\"\"` are rejected\n   - Java Runtime calls in JavaScript are blocked\n   - Invalid filter specifications throw clear errors\n   - Error messages don't leak sensitive information\n\n## Common Patch Locations in Druid\n\n- `druid-core\u002Fsrc\u002Fmain\u002Fjava\u002Forg\u002Fapache\u002Fdruid\u002Fquery\u002Ffilter\u002FJavaScriptFilter.java`\n- `druid-indexing-service\u002Fsrc\u002Fmain\u002Fjava\u002Forg\u002Fapache\u002Fdruid\u002Findexing\u002F*\u002FSamplerResource.java`\n- `druid-core\u002Fsrc\u002Fmain\u002Fjava\u002Forg\u002Fapache\u002Fdruid\u002Fquery\u002Ffilter\u002FFilterJsonHolder.java` (if parsing logic here)\n\n## Patch File Format\n\nCreate patches using `git diff` to generate unified diff format:\n\n```bash\ngit diff > fix-javascript-injection.patch\n```\n\nPatches should be applied to the repository with:\n```bash\ncd \u002Froot\u002Fdruid\ngit apply \u002Froot\u002Fpatches\u002Ffix-javascript-injection.patch\n```\n\nor\n\n```bash\ncd \u002Froot\u002Fdruid\ngit am \u002Froot\u002Fpatches\u002Ffix-javascript-injection.patch\n```\n","# Fixing Apache Druid JavaScript Injection Vulnerability\n\n## Vulnerability Overview\n\nApache Druid 0.20.0 contains a critical vulnerability where authenticated attackers can execute arbitrary Java code through malicious JavaScript payloads. The vulnerability exists in the `\u002Fdruid\u002Findexer\u002Fv1\u002Fsampler` endpoint where the empty key `\"\"` in filter specifications can bypass JavaScript security settings.\n\n**Affected Component:** Druid indexer sampler - specifically the `JavaScriptFilter` validation\n\n**Root Cause:** Insufficient validation of filter specification keys before JavaScript execution\n\n## Identifying the Vulnerable Code\n\nThe vulnerability is typically found in:\n- `druid-core\u002Fsrc\u002Fmain\u002Fjava\u002Forg\u002Fapache\u002Fdruid\u002Fquery\u002Ffilter\u002FJavaScriptFilter.java`\n- Filter parsing\u002Fvalidation logic that processes the `transformSpec.filter` JSON\n\nLook for:\n1. JavaScript filter implementations that execute user-provided functions\n2. Lack of validation on the filter specification keys\n3. Missing checks for suspicious keys (especially empty strings `\"\"`)\n\n## Patch Strategy\n\n### 1. Validate Filter Specification Keys\n\nAdd validation to reject or sanitize suspicious keys in the filter specification:\n\n```java\n\u002F\u002F Reject empty keys or keys that bypass security\nif (filterSpec.containsKey(\"\") || filterSpec.containsKey(null)) {\n    throw new IllegalArgumentException(\"Invalid filter specification: contains empty or null keys\");\n}\n```\n\n### 2. Strengthen JavaScript Context Setup\n\nEnsure the JavaScript execution context:\n- Explicitly disables dangerous Java interop\n- Validates function syntax before execution\n- Runs in a restricted scope\n\n```java\n\u002F\u002F Example: Check for java.lang.Runtime references\nString function = getFunction();\nif (function.contains(\"java.lang.Runtime\") ||\n    function.contains(\"java.lang.ProcessBuilder\")) {\n    throw new IllegalArgumentException(\"JavaScript functions cannot access Java runtime\");\n}\n```\n\n### 3. Validate Filter Configuration Structure\n\nBefore executing any JavaScript filter, validate the complete filter specification:\n- All keys should be expected, known keys\n- Nested objects should follow the documented schema\n- Reject any non-standard keys\n\n## Testing the Patch\n\nAfter patching, verify:\n\n1. **Legitimate requests work:**\n   - Standard JavaScript filters execute correctly\n   - Filters with valid syntax pass validation\n   - Normal sampler operations complete successfully\n\n2. **Exploit attempts are blocked:**\n   - Requests with empty key `\"\"` are rejected\n   - Java Runtime calls in JavaScript are blocked\n   - Invalid filter specifications throw clear errors\n   - Error messages don't leak sensitive information\n\n## Common Patch Locations in Druid\n\n- `druid-core\u002Fsrc\u002Fmain\u002Fjava\u002Forg\u002Fapache\u002Fdruid\u002Fquery\u002Ffilter\u002FJavaScriptFilter.java`\n- `druid-indexing-service\u002Fsrc\u002Fmain\u002Fjava\u002Forg\u002Fapache\u002Fdruid\u002Findexing\u002F*\u002FSamplerResource.java`\n- `druid-core\u002Fsrc\u002Fmain\u002Fjava\u002Forg\u002Fapache\u002Fdruid\u002Fquery\u002Ffilter\u002FFilterJsonHolder.java` (if parsing logic here)\n\n## Patch File Format\n\nCreate patches using `git diff` to generate unified diff format:\n\n```bash\ngit diff > fix-javascript-injection.patch\n```\n\nPatches should be applied to the repository with:\n```bash\ncd \u002Froot\u002Fdruid\ngit apply \u002Froot\u002Fpatches\u002Ffix-javascript-injection.patch\n```\n\nor\n\n```bash\ncd \u002Froot\u002Fdruid\ngit am \u002Froot\u002Fpatches\u002Ffix-javascript-injection.patch\n```\n",{"name":5,"description":7},"main","726e1f79b96b0cb3d729d0e55a1c847e0b5353ae","skills\u002Fb4-skill-creator-claude-haiku-4-5\u002Ffix-security-bug\u002Fdruid-javascript-injection-fix",8,"https:\u002F\u002Fgithub.com\u002Fcxcscmu\u002FSkillLearnBench","https:\u002F\u002Fcxcscmu.github.io\u002FSkillLearnBench","https:\u002F\u002Fgithub.com\u002Fcxcscmu","2026-10-02 22:55:36",{"source":8,"skillName":5,"commands":52,"prompt":62,"zipAvailable":63},[53,56,59],{"tool":54,"command":55},"npx","npx skills add cxcscmu\u002FSkillLearnBench --skill druid-javascript-injection-fix",{"tool":57,"command":58},"bunx","bunx skills add cxcscmu\u002FSkillLearnBench --skill druid-javascript-injection-fix",{"tool":60,"command":61},"pnpm","pnpm dlx skills add cxcscmu\u002FSkillLearnBench --skill druid-javascript-injection-fix","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fcxcscmu\u002FSkillLearnBench\u002Fblob\u002Fmain\u002Fskills\u002Fb4-skill-creator-claude-haiku-4-5\u002Ffix-security-bug\u002Fdruid-javascript-injection-fix\u002FSKILL.md",true,[],[66,79,101,119,139,150],{"skillNo":67,"name":68,"nameZh":6,"description":69,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":70,"categories":71,"keywords":72,"publishedAt":38},"01M6KM5KH175P5ABP5JMX2SBDQ","object_counter","Count occurrences of an object in the image using computer vision algorithm.","https:\u002F\u002Fgithub.com\u002Fcxcscmu\u002FSkillLearnBench\u002Fblob\u002Fmain\u002Fskills\u002Fhuman_authored\u002Fvideo-object-counting\u002Fobject_counter\u002FSKILL.md",[],[73,74,75,76,77,78],"object counter","object","vision","computer","Computer Vision","image",{"skillNo":80,"name":81,"nameZh":6,"description":82,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":83,"categories":84,"keywords":85,"publishedAt":38},"01M6KM51TMVXG79MMPCS6Y8G86","travel-planning-workflow","Invoke this skill when performing travel planning. It defines a structured workflow for generating itineraries. Following this workflow is essential to ensure the final plan satisfies user requirements.","https:\u002F\u002Fgithub.com\u002Fcxcscmu\u002FSkillLearnBench\u002Fblob\u002Fmain\u002Fskills\u002Fhuman_authored\u002Ftravel-planning\u002Ftravel-planning-workflow\u002FSKILL.md",[],[86,87,88,89,90,91,92,93,94,95,96,97,98,99,100],"workflow","planning","planning workflow","travel","travel planning","travel planning workflow","structured","performing","plan","for","user","it","requirements","essential","itineraries",{"skillNo":102,"name":103,"nameZh":6,"description":104,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":105,"categories":106,"keywords":107,"publishedAt":38},"01M6KM4DY820XHS9YTSK5QP5HD","bundled-dataset-search-tool","invoke this skill when you need to perform database search for travel planning. This skill provides some useful pre-packaged tools to look up accommodations, attractions, cities, driving distance, flights, and restaurants from the bundled dataset.","https:\u002F\u002Fgithub.com\u002Fcxcscmu\u002FSkillLearnBench\u002Fblob\u002Fmain\u002Fskills\u002Fhuman_authored\u002Ftravel-planning\u002Fbundled-dataset-search-tool\u002FSKILL.md",[],[108,109,110,111,112,113,114,89,115,116,90,117,95,118,87],"search","tool","dataset","bundled dataset search tool","restaurants","Tools","up","look","flights","you","database",{"skillNo":120,"name":121,"nameZh":6,"description":122,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":123,"categories":124,"keywords":125,"publishedAt":38},"01M6KM465BB9PQ0B548HQSVAWZ","glm-output","Output-processing guidance for GLM tasks. Especially useful after glm-basics and glm-calibration when you need verifier-matching metrics from output.nc and a final \u002Froot\u002Fmetrics.json.","https:\u002F\u002Fgithub.com\u002Fcxcscmu\u002FSkillLearnBench\u002Fblob\u002Fmain\u002Fskills\u002Fhuman_authored\u002Ftemperature-simulation\u002Fglm-output\u002FSKILL.md",[],[126,127,128,95,129,130,131,132,133,134,135,136,117,137,138],"glm output","output","glm","tasks","metrics","json","basics","guidance","matching","verifier","processing","root","calibration",{"skillNo":140,"name":141,"nameZh":6,"description":142,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":143,"categories":144,"keywords":145,"publishedAt":38},"01M6KM40KY3QWDW5W97S39R2BC","glm-calibration","Calibration guidance for GLM tasks. Often most effective after glm-basics has clarified the setup; glm-output is the companion skill for exact final metric computation.","https:\u002F\u002Fgithub.com\u002Fcxcscmu\u002FSkillLearnBench\u002Fblob\u002Fmain\u002Fskills\u002Fhuman_authored\u002Ftemperature-simulation\u002Fglm-calibration\u002FSKILL.md",[],[146,138,128,127,133,132,129,147,148,95,149],"glm calibration","setup","companion","metric",{"skillNo":151,"name":152,"nameZh":6,"description":153,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":154,"categories":155,"keywords":156,"publishedAt":38},"01M6KM3VHHVSGMGHJQB3PPT6YG","glm-basics","A good starting point for GLM calibration tasks. Use to inspect glm3.nml, confirm how GLM runs, and identify the relevant files before moving on to calibration and output evaluation.","https:\u002F\u002Fgithub.com\u002Fcxcscmu\u002FSkillLearnBench\u002Fblob\u002Fmain\u002Fskills\u002Fhuman_authored\u002Ftemperature-simulation\u002Fglm-basics\u002FSKILL.md",[],[157,128,132,158,146,138,95,127,159,160,161,30,34,162,129],"glm basics","inspect","relevant","files","good","Evaluation"]