@aiclude/security-skill 1.2.0 → 2.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/SKILL.md +39 -65
- package/dist/index.d.ts +6 -9
- package/dist/index.js +30 -33
- package/package.json +11 -10
- package/LICENSE +0 -201
package/SKILL.md
CHANGED
|
@@ -1,112 +1,85 @@
|
|
|
1
1
|
---
|
|
2
|
-
name: aiclude-
|
|
2
|
+
name: aiclude-vulns-scan
|
|
3
3
|
description: Scan MCP Servers and AI Agent Skills for security vulnerabilities. 7 parallel engines detect prompt injection, tool poisoning, malware, supply chain attacks, and more.
|
|
4
4
|
tags: [security, vulnerability, scanner, mcp, ai-agent, sast, sca, malware]
|
|
5
|
+
homepage: https://vs.aiclude.com
|
|
6
|
+
repository: https://github.com/aiclude/asvs
|
|
5
7
|
---
|
|
6
8
|
|
|
7
9
|
# /security-scan - AIclude Security Vulnerability Scanner
|
|
8
10
|
|
|
9
|
-
Scan MCP Servers and AI Agent Skills for security vulnerabilities.
|
|
10
|
-
|
|
11
|
-
## How It Works
|
|
12
|
-
|
|
13
|
-
This skill operates in **two modes**:
|
|
14
|
-
|
|
15
|
-
1. **Name-based lookup (`--name`)**: Queries the AIclude API (`https://vs-api.aiclude.com`) to check if a scan report already exists for the given package name. If found, the report is returned immediately. If not found, the target is registered and a server-side scan is triggered. **No local code is uploaded** — only the package name and metadata are sent.
|
|
16
|
-
|
|
17
|
-
2. **Local scan (`<target-path>`)**: Reads source files from the specified local directory and runs all 7 scan engines **locally on your machine**. Results are generated locally and **no code or scan artifacts are sent to any external service**. The scan is entirely offline.
|
|
18
|
-
|
|
19
|
-
## Network Behavior
|
|
20
|
-
|
|
21
|
-
| Action | Endpoint | Data Sent | Data Received |
|
|
22
|
-
|--------|----------|-----------|---------------|
|
|
23
|
-
| Name lookup | `POST https://vs-api.aiclude.com/api/v1/scan/lookup` | Package name, type | Scan report (JSON) |
|
|
24
|
-
| Scan status polling | `GET https://vs-api.aiclude.com/api/v1/scan/status/{id}` | Job ID | Scan status |
|
|
25
|
-
| Local scan | None (offline) | Nothing | Nothing |
|
|
26
|
-
|
|
27
|
-
**No source code, file contents, or scan artifacts are ever uploaded.** Name-based lookups only transmit the package name and type.
|
|
28
|
-
|
|
29
|
-
## Required Environment Variables
|
|
30
|
-
|
|
31
|
-
| Variable | Required | Description |
|
|
32
|
-
|----------|----------|-------------|
|
|
33
|
-
| `ASVS_SIGNING_SECRET` | **Yes** (for `--name` mode) | HMAC signing secret for authenticating API requests. Must be set before using name-based lookups. Without it, name-based mode will fail with an error. |
|
|
34
|
-
| `ASVS_API_URL` | No | API server URL. Defaults to `https://vs-api.aiclude.com` |
|
|
35
|
-
|
|
36
|
-
**Local scan mode** (`/security-scan ./path`) requires **no environment variables** and works fully offline.
|
|
37
|
-
|
|
38
|
-
## Authentication & Privacy
|
|
39
|
-
|
|
40
|
-
- API requests are authenticated via HMAC-SHA256 signatures using `ASVS_SIGNING_SECRET`. No user tokens or credentials are stored.
|
|
41
|
-
- Name-based lookups transmit only: package name, target type, and a timestamp-based signature.
|
|
42
|
-
- Local scans are fully offline — no network requests are made.
|
|
43
|
-
- Scan reports on the web dashboard (https://vs.aiclude.com) are public and contain only vulnerability metadata, not source code.
|
|
44
|
-
- No telemetry, analytics, or tracking data is collected.
|
|
11
|
+
Scan MCP Servers and AI Agent Skills for security vulnerabilities. Queries existing scan results from the AIclude database, or registers a new scan and returns the results.
|
|
45
12
|
|
|
46
13
|
## Usage
|
|
47
14
|
|
|
48
15
|
```
|
|
49
|
-
# Search by name (
|
|
16
|
+
# Search by package name (queries AIclude scan database)
|
|
50
17
|
/security-scan --name <package-name> [options]
|
|
51
18
|
|
|
52
|
-
# Scan a local directory
|
|
19
|
+
# Scan a local directory (offline, no network)
|
|
53
20
|
/security-scan <target-path> [options]
|
|
54
21
|
```
|
|
55
22
|
|
|
56
23
|
## Parameters
|
|
57
24
|
|
|
58
|
-
- `--name`:
|
|
59
|
-
- `target-path`: Local path to scan
|
|
25
|
+
- `--name`: Package name to search (npm package, GitHub repo, etc.)
|
|
26
|
+
- `target-path`: Local directory path to scan directly
|
|
60
27
|
- `--type`: Target type (`mcp-server` | `skill`) - auto-detected if omitted
|
|
61
|
-
- `--profile`: Sandbox
|
|
62
|
-
- `--format`:
|
|
28
|
+
- `--profile`: Sandbox profile (`strict` | `standard` | `permissive`)
|
|
29
|
+
- `--format`: Output format (`markdown` | `json`)
|
|
63
30
|
- `--engines`: Scan engines to use (comma-separated)
|
|
64
31
|
|
|
65
32
|
## Examples
|
|
66
33
|
|
|
67
34
|
```
|
|
68
|
-
#
|
|
35
|
+
# Look up scan results for an MCP server
|
|
69
36
|
/security-scan --name @anthropic/mcp-server-fetch
|
|
70
37
|
|
|
71
|
-
#
|
|
38
|
+
# Look up scan results for a Skill
|
|
72
39
|
/security-scan --name my-awesome-skill --type skill
|
|
73
40
|
|
|
74
41
|
# Scan local source code (fully offline)
|
|
75
42
|
/security-scan ./my-mcp-server
|
|
76
43
|
```
|
|
77
44
|
|
|
45
|
+
## How It Works
|
|
46
|
+
|
|
47
|
+
- **Name-based lookup** queries the AIclude scan database. If a report exists, it is returned immediately. If not, the target is registered for scanning and results are returned when ready. Only the package name is sent. No source code is uploaded.
|
|
48
|
+
- **Local scan** reads files from the specified directory and runs all 7 engines locally. No network requests are made.
|
|
49
|
+
|
|
50
|
+
No environment variables or credentials are required.
|
|
51
|
+
|
|
78
52
|
## What It Checks
|
|
79
53
|
|
|
80
|
-
- **Prompt Injection**: Hidden
|
|
81
|
-
- **Tool Poisoning**: Malicious instructions
|
|
82
|
-
- **Command Injection**: Unvalidated input passed to exec/spawn
|
|
83
|
-
- **Supply Chain**: Known CVEs
|
|
84
|
-
- **Malware**: Backdoors, cryptominers, ransomware, data stealers
|
|
85
|
-
- **Permission Abuse**: Excessive filesystem
|
|
54
|
+
- **Prompt Injection**: Hidden patterns targeting LLMs
|
|
55
|
+
- **Tool Poisoning**: Malicious instructions in tool descriptions
|
|
56
|
+
- **Command Injection**: Unvalidated input passed to exec/spawn
|
|
57
|
+
- **Supply Chain**: Known CVEs, typosquatting
|
|
58
|
+
- **Malware**: Backdoors, cryptominers, ransomware, data stealers
|
|
59
|
+
- **Permission Abuse**: Excessive filesystem/network/process permissions
|
|
86
60
|
|
|
87
61
|
## Scan Engines
|
|
88
62
|
|
|
89
|
-
7 engines run in parallel
|
|
63
|
+
7 engines run in parallel:
|
|
90
64
|
|
|
91
65
|
| Engine | Description |
|
|
92
66
|
|--------|-------------|
|
|
93
|
-
| SAST | Static code pattern matching
|
|
94
|
-
| SCA | Dependency CVE lookup via OSV.dev
|
|
95
|
-
| Tool Analyzer | MCP tool definition analysis
|
|
96
|
-
| DAST | Parameter fuzzing
|
|
97
|
-
| Permission Checker |
|
|
98
|
-
| Behavior Monitor | Runtime behavior
|
|
99
|
-
| Malware Detector | Signature scanning, entropy analysis
|
|
67
|
+
| SAST | Static code pattern matching |
|
|
68
|
+
| SCA | Dependency CVE lookup via OSV.dev |
|
|
69
|
+
| Tool Analyzer | MCP tool definition analysis |
|
|
70
|
+
| DAST | Parameter fuzzing |
|
|
71
|
+
| Permission Checker | Permission analysis |
|
|
72
|
+
| Behavior Monitor | Runtime behavior detection |
|
|
73
|
+
| Malware Detector | Signature scanning, entropy analysis |
|
|
100
74
|
|
|
101
75
|
## Output
|
|
102
76
|
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
4. **Remediation Recommendations** (how to fix each vulnerability)
|
|
77
|
+
1. **Risk Level** (CRITICAL / HIGH / MEDIUM / LOW / INFO)
|
|
78
|
+
2. **Vulnerability List** with code locations
|
|
79
|
+
3. **Risk Assessment** and impact analysis
|
|
80
|
+
4. **Remediation Recommendations**
|
|
108
81
|
|
|
109
|
-
##
|
|
82
|
+
## Links
|
|
110
83
|
|
|
111
84
|
- **npm**: [`@aiclude/security-skill`](https://www.npmjs.com/package/@aiclude/security-skill)
|
|
112
85
|
- **MCP Server**: [`@aiclude/security-mcp`](https://www.npmjs.com/package/@aiclude/security-mcp)
|
|
@@ -115,3 +88,4 @@ The report includes:
|
|
|
115
88
|
## License
|
|
116
89
|
|
|
117
90
|
MIT - AICLUDE Inc.
|
|
91
|
+
Inc.
|
package/dist/index.d.ts
CHANGED
|
@@ -3,7 +3,8 @@ import { ReportFormat, ScanEngineId } from '@asvs/core';
|
|
|
3
3
|
/**
|
|
4
4
|
* Skill Handler
|
|
5
5
|
* Processes /security-scan skill invocations from Claude Code
|
|
6
|
-
*
|
|
6
|
+
* 서버 조회 → 없으면 등록 → 스캔 결과 반환 (vs.aiclude.com에 누적)
|
|
7
|
+
* 로컬 스캔도 지원
|
|
7
8
|
*/
|
|
8
9
|
|
|
9
10
|
interface SkillInvocation {
|
|
@@ -24,24 +25,20 @@ interface SkillLookupInvocation {
|
|
|
24
25
|
declare class SkillHandler {
|
|
25
26
|
private scanner;
|
|
26
27
|
private reporter;
|
|
27
|
-
private apiBase;
|
|
28
28
|
constructor();
|
|
29
|
-
/** API
|
|
29
|
+
/** API 인증 헤더 생성 — 시간 기반 서명, 환경변수 불필요 */
|
|
30
30
|
private createAuthHeaders;
|
|
31
31
|
/**
|
|
32
|
-
* API 기반 보안 스캔
|
|
33
|
-
* 기존 스캔 결과를 검색하고, 없으면 등록
|
|
32
|
+
* API 기반 보안 스캔 조회/등록
|
|
33
|
+
* 기존 스캔 결과를 검색하고, 없으면 서버에 등록 → 스캔 실행 → 결과 반환
|
|
34
34
|
*/
|
|
35
35
|
lookup(invocation: SkillLookupInvocation): Promise<string>;
|
|
36
|
-
/** Handle a /security-scan invocation (
|
|
36
|
+
/** Handle a /security-scan invocation (local path scan) */
|
|
37
37
|
handle(invocation: SkillInvocation): Promise<string>;
|
|
38
|
-
/** Auto-detect whether target is an MCP server or skill */
|
|
39
38
|
private detectTargetType;
|
|
40
|
-
/** Format the report output with detailed findings */
|
|
41
39
|
private formatOutput;
|
|
42
40
|
/** API에서 받은 상세 리포트를 마크다운으로 포맷 */
|
|
43
41
|
private formatApiReport;
|
|
44
|
-
/** 스캔 요약만 포맷 */
|
|
45
42
|
private formatScanSummary;
|
|
46
43
|
}
|
|
47
44
|
|
package/dist/index.js
CHANGED
|
@@ -8,7 +8,6 @@ import {
|
|
|
8
8
|
PermissionCheckerEngine,
|
|
9
9
|
DastEngine,
|
|
10
10
|
BehaviorMonitorEngine,
|
|
11
|
-
loadGlobalConfig,
|
|
12
11
|
RiskLevel,
|
|
13
12
|
validateScanPath
|
|
14
13
|
} from "@asvs/core";
|
|
@@ -16,14 +15,19 @@ import { ReportGenerator } from "@asvs/reporter";
|
|
|
16
15
|
import { existsSync } from "fs";
|
|
17
16
|
import { resolve } from "path";
|
|
18
17
|
import { createHmac } from "crypto";
|
|
18
|
+
var API_BASE = "https://vs-api.aiclude.com";
|
|
19
|
+
function createRequestSignature(name, timestamp) {
|
|
20
|
+
const minuteSeed = Math.floor(Number(timestamp) / 6e4).toString(36);
|
|
21
|
+
const payload = `asvs:${name}:${minuteSeed}`;
|
|
22
|
+
const derivedKey = createHmac("sha256", minuteSeed).update("aiclude-vs").digest("hex").slice(0, 32);
|
|
23
|
+
return createHmac("sha256", derivedKey).update(payload).digest("hex");
|
|
24
|
+
}
|
|
19
25
|
var SkillHandler = class {
|
|
20
26
|
scanner;
|
|
21
27
|
reporter;
|
|
22
|
-
apiBase;
|
|
23
28
|
constructor() {
|
|
24
29
|
this.scanner = new Scanner();
|
|
25
30
|
this.reporter = new ReportGenerator();
|
|
26
|
-
this.apiBase = process.env["ASVS_API_URL"] ?? "https://vs-api.aiclude.com";
|
|
27
31
|
this.scanner.registerEngine(new SastEngine());
|
|
28
32
|
this.scanner.registerEngine(new ScaEngine());
|
|
29
33
|
this.scanner.registerEngine(new ToolAnalyzerEngine());
|
|
@@ -32,15 +36,10 @@ var SkillHandler = class {
|
|
|
32
36
|
this.scanner.registerEngine(new DastEngine());
|
|
33
37
|
this.scanner.registerEngine(new BehaviorMonitorEngine());
|
|
34
38
|
}
|
|
35
|
-
/** API
|
|
39
|
+
/** API 인증 헤더 생성 — 시간 기반 서명, 환경변수 불필요 */
|
|
36
40
|
createAuthHeaders(name) {
|
|
37
|
-
const secret = process.env["ASVS_SIGNING_SECRET"];
|
|
38
|
-
if (!secret) {
|
|
39
|
-
throw new Error("ASVS_SIGNING_SECRET environment variable is required for API authentication");
|
|
40
|
-
}
|
|
41
41
|
const timestamp = String(Date.now());
|
|
42
|
-
const
|
|
43
|
-
const signature = createHmac("sha256", secret).update(payload).digest("hex");
|
|
42
|
+
const signature = createRequestSignature(name, timestamp);
|
|
44
43
|
return {
|
|
45
44
|
"Content-Type": "application/json",
|
|
46
45
|
"X-ASVS-Source": "skill",
|
|
@@ -49,11 +48,11 @@ var SkillHandler = class {
|
|
|
49
48
|
};
|
|
50
49
|
}
|
|
51
50
|
/**
|
|
52
|
-
* API 기반 보안 스캔
|
|
53
|
-
* 기존 스캔 결과를 검색하고, 없으면 등록
|
|
51
|
+
* API 기반 보안 스캔 조회/등록
|
|
52
|
+
* 기존 스캔 결과를 검색하고, 없으면 서버에 등록 → 스캔 실행 → 결과 반환
|
|
54
53
|
*/
|
|
55
54
|
async lookup(invocation) {
|
|
56
|
-
const apiUrl = `${
|
|
55
|
+
const apiUrl = `${API_BASE}/api/v1/scan/lookup`;
|
|
57
56
|
const lookupRes = await fetch(apiUrl, {
|
|
58
57
|
method: "POST",
|
|
59
58
|
headers: this.createAuthHeaders(invocation.name),
|
|
@@ -84,7 +83,7 @@ var SkillHandler = class {
|
|
|
84
83
|
const startTime = Date.now();
|
|
85
84
|
while (Date.now() - startTime < maxWait) {
|
|
86
85
|
await new Promise((r) => setTimeout(r, interval));
|
|
87
|
-
const statusRes = await fetch(`${
|
|
86
|
+
const statusRes = await fetch(`${API_BASE}/api/v1/scan/status/${jobId}`, {
|
|
88
87
|
headers: this.createAuthHeaders(invocation.name)
|
|
89
88
|
});
|
|
90
89
|
const statusData = await statusRes.json();
|
|
@@ -99,32 +98,36 @@ var SkillHandler = class {
|
|
|
99
98
|
}
|
|
100
99
|
if (statusData["status"] === "failed") {
|
|
101
100
|
const job = statusData["job"];
|
|
102
|
-
throw new Error(
|
|
101
|
+
throw new Error(`Scan failed: ${job?.["error"] ?? "unknown error"}`);
|
|
103
102
|
}
|
|
104
103
|
}
|
|
105
104
|
return [
|
|
106
|
-
`#
|
|
105
|
+
`# Scan In Progress: ${invocation.name}`,
|
|
107
106
|
"",
|
|
108
|
-
|
|
107
|
+
`The scan is still running. Please try again shortly.`,
|
|
109
108
|
`Job ID: ${jobId}`,
|
|
110
|
-
|
|
109
|
+
`Target: ${target["canonicalName"] ?? invocation.name}`,
|
|
111
110
|
"",
|
|
112
|
-
|
|
111
|
+
`*View details at https://vs.aiclude.com*`
|
|
113
112
|
].join("\n");
|
|
114
113
|
}
|
|
115
|
-
return `API
|
|
114
|
+
return `API response: ${JSON.stringify(lookupData, null, 2)}`;
|
|
116
115
|
}
|
|
117
|
-
/** Handle a /security-scan invocation (
|
|
116
|
+
/** Handle a /security-scan invocation (local path scan) */
|
|
118
117
|
async handle(invocation) {
|
|
119
|
-
const
|
|
118
|
+
const defaultConfig = {
|
|
119
|
+
engines: ["sast", "sca", "tool-analyzer", "permission-checker", "malware-detector", "dast", "behavior-monitor"],
|
|
120
|
+
sandboxProfile: "standard",
|
|
121
|
+
rulesets: ["default"],
|
|
122
|
+
timeout: 3e5,
|
|
123
|
+
maxConcurrency: 4,
|
|
124
|
+
skipPatterns: ["node_modules/**", ".git/**", "dist/**", "coverage/**"]
|
|
125
|
+
};
|
|
120
126
|
const scanConfig = {
|
|
121
|
-
...
|
|
127
|
+
...defaultConfig,
|
|
122
128
|
...invocation.profile && { sandboxProfile: invocation.profile },
|
|
123
129
|
...invocation.engines && { engines: invocation.engines }
|
|
124
130
|
};
|
|
125
|
-
if (!scanConfig.engines.includes("malware-detector")) {
|
|
126
|
-
scanConfig.engines.push("malware-detector");
|
|
127
|
-
}
|
|
128
131
|
const targetPath = validateScanPath(invocation.targetPath);
|
|
129
132
|
const targetType = invocation.type ?? this.detectTargetType(targetPath);
|
|
130
133
|
const target = {
|
|
@@ -137,14 +140,12 @@ var SkillHandler = class {
|
|
|
137
140
|
const report = this.reporter.generate(scanResult, format);
|
|
138
141
|
return this.formatOutput(report, format, scanResult.engineResults.flatMap((r) => r.vulnerabilities));
|
|
139
142
|
}
|
|
140
|
-
/** Auto-detect whether target is an MCP server or skill */
|
|
141
143
|
detectTargetType(targetPath) {
|
|
142
144
|
if (existsSync(resolve(targetPath, "SKILL.md")) || targetPath.endsWith("SKILL.md") || targetPath.includes("/skill")) {
|
|
143
145
|
return "skill";
|
|
144
146
|
}
|
|
145
147
|
return "mcp-server";
|
|
146
148
|
}
|
|
147
|
-
/** Format the report output with detailed findings */
|
|
148
149
|
formatOutput(report, format, vulnerabilities) {
|
|
149
150
|
if (format === "json") {
|
|
150
151
|
return JSON.stringify(report, null, 2);
|
|
@@ -231,9 +232,6 @@ var SkillHandler = class {
|
|
|
231
232
|
}
|
|
232
233
|
return lines.join("\n");
|
|
233
234
|
}
|
|
234
|
-
// -----------------------------------------------------------------------
|
|
235
|
-
// API 리포트 포맷팅 헬퍼
|
|
236
|
-
// -----------------------------------------------------------------------
|
|
237
235
|
/** API에서 받은 상세 리포트를 마크다운으로 포맷 */
|
|
238
236
|
formatApiReport(report, target) {
|
|
239
237
|
const lines = [];
|
|
@@ -324,7 +322,6 @@ var SkillHandler = class {
|
|
|
324
322
|
lines.push(`*Web Dashboard: https://vs.aiclude.com/targets*`);
|
|
325
323
|
return lines.join("\n");
|
|
326
324
|
}
|
|
327
|
-
/** 스캔 요약만 포맷 */
|
|
328
325
|
formatScanSummary(target, scan) {
|
|
329
326
|
const lines = [];
|
|
330
327
|
const targetName = target["canonicalName"] ?? target["displayName"] ?? "Unknown";
|
|
@@ -344,7 +341,7 @@ var SkillHandler = class {
|
|
|
344
341
|
lines.push(`| INFO | ${scan["infoCount"] ?? 0} |`);
|
|
345
342
|
lines.push(`| Scanned At | ${scan["scannedAt"] ?? "N/A"} |`);
|
|
346
343
|
lines.push("");
|
|
347
|
-
lines.push(
|
|
344
|
+
lines.push(`*View full report at https://vs.aiclude.com*`);
|
|
348
345
|
return lines.join("\n");
|
|
349
346
|
}
|
|
350
347
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@aiclude/security-skill",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "2.0.0",
|
|
4
4
|
"description": "AIclude Security Vulnerability Scanner - Claude Code Skill for inline security scanning",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/index.js",
|
|
@@ -46,18 +46,19 @@
|
|
|
46
46
|
"README.md",
|
|
47
47
|
"LICENSE"
|
|
48
48
|
],
|
|
49
|
+
"scripts": {
|
|
50
|
+
"build": "tsup src/index.ts --format esm --dts",
|
|
51
|
+
"dev": "tsup src/index.ts --format esm --dts --watch",
|
|
52
|
+
"test": "vitest run",
|
|
53
|
+
"clean": "rm -rf dist",
|
|
54
|
+
"prepublishOnly": "npm run build"
|
|
55
|
+
},
|
|
49
56
|
"dependencies": {
|
|
50
|
-
"@asvs/core": "
|
|
51
|
-
"@asvs/reporter": "
|
|
57
|
+
"@asvs/core": "workspace:*",
|
|
58
|
+
"@asvs/reporter": "workspace:*"
|
|
52
59
|
},
|
|
53
60
|
"devDependencies": {
|
|
54
61
|
"tsup": "^8.0.0",
|
|
55
62
|
"typescript": "^5.5.0"
|
|
56
|
-
},
|
|
57
|
-
"scripts": {
|
|
58
|
-
"build": "tsup src/index.ts --format esm --dts",
|
|
59
|
-
"dev": "tsup src/index.ts --format esm --dts --watch",
|
|
60
|
-
"test": "vitest run",
|
|
61
|
-
"clean": "rm -rf dist"
|
|
62
63
|
}
|
|
63
|
-
}
|
|
64
|
+
}
|
package/LICENSE
DELETED
|
@@ -1,201 +0,0 @@
|
|
|
1
|
-
Apache License
|
|
2
|
-
Version 2.0, January 2004
|
|
3
|
-
http://www.apache.org/licenses/
|
|
4
|
-
|
|
5
|
-
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
|
|
6
|
-
|
|
7
|
-
1. Definitions.
|
|
8
|
-
|
|
9
|
-
"License" shall mean the terms and conditions for use, reproduction,
|
|
10
|
-
and distribution as defined by Sections 1 through 9 of this document.
|
|
11
|
-
|
|
12
|
-
"Licensor" shall mean the copyright owner or entity authorized by
|
|
13
|
-
the copyright owner that is granting the License.
|
|
14
|
-
|
|
15
|
-
"Legal Entity" shall mean the union of the acting entity and all
|
|
16
|
-
other entities that control, are controlled by, or are under common
|
|
17
|
-
control with that entity. For the purposes of this definition,
|
|
18
|
-
"control" means (i) the power, direct or indirect, to cause the
|
|
19
|
-
direction or management of such entity, whether by contract or
|
|
20
|
-
otherwise, or (ii) ownership of fifty percent (50%) or more of the
|
|
21
|
-
outstanding shares, or (iii) beneficial ownership of such entity.
|
|
22
|
-
|
|
23
|
-
"You" (or "Your") shall mean an individual or Legal Entity
|
|
24
|
-
exercising permissions granted by this License.
|
|
25
|
-
|
|
26
|
-
"Source" form shall mean the preferred form for making modifications,
|
|
27
|
-
including but not limited to software source code, documentation
|
|
28
|
-
source, and configuration files.
|
|
29
|
-
|
|
30
|
-
"Object" form shall mean any form resulting from mechanical
|
|
31
|
-
transformation or translation of a Source form, including but
|
|
32
|
-
not limited to compiled object code, generated documentation,
|
|
33
|
-
and conversions to other media types.
|
|
34
|
-
|
|
35
|
-
"Work" shall mean the work of authorship, whether in Source or
|
|
36
|
-
Object form, made available under the License, as indicated by a
|
|
37
|
-
copyright notice that is included in or attached to the work
|
|
38
|
-
(an example is provided in the Appendix below).
|
|
39
|
-
|
|
40
|
-
"Derivative Works" shall mean any work, whether in Source or Object
|
|
41
|
-
form, that is based on (or derived from) the Work and for which the
|
|
42
|
-
editorial revisions, annotations, elaborations, or other modifications
|
|
43
|
-
represent, as a whole, an original work of authorship. For the purposes
|
|
44
|
-
of this License, Derivative Works shall not include works that remain
|
|
45
|
-
separable from, or merely link (or bind by name) to the interfaces of,
|
|
46
|
-
the Work and Derivative Works thereof.
|
|
47
|
-
|
|
48
|
-
"Contribution" shall mean any work of authorship, including
|
|
49
|
-
the original version of the Work and any modifications or additions
|
|
50
|
-
to that Work or Derivative Works thereof, that is intentionally
|
|
51
|
-
submitted to Licensor for inclusion in the Work by the copyright owner
|
|
52
|
-
or by an individual or Legal Entity authorized to submit on behalf of
|
|
53
|
-
the copyright owner. For the purposes of this definition, "submitted"
|
|
54
|
-
means any form of electronic, verbal, or written communication sent
|
|
55
|
-
to the Licensor or its representatives, including but not limited to
|
|
56
|
-
communication on electronic mailing lists, source code control systems,
|
|
57
|
-
and issue tracking systems that are managed by, or on behalf of, the
|
|
58
|
-
Licensor for the purpose of discussing and improving the Work, but
|
|
59
|
-
excluding communication that is conspicuously marked or otherwise
|
|
60
|
-
designated in writing by the copyright owner as "Not a Contribution."
|
|
61
|
-
|
|
62
|
-
"Contributor" shall mean Licensor and any individual or Legal Entity
|
|
63
|
-
on behalf of whom a Contribution has been received by Licensor and
|
|
64
|
-
subsequently incorporated within the Work.
|
|
65
|
-
|
|
66
|
-
2. Grant of Copyright License. Subject to the terms and conditions of
|
|
67
|
-
this License, each Contributor hereby grants to You a perpetual,
|
|
68
|
-
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
|
69
|
-
copyright license to reproduce, prepare Derivative Works of,
|
|
70
|
-
publicly display, publicly perform, sublicense, and distribute the
|
|
71
|
-
Work and such Derivative Works in Source or Object form.
|
|
72
|
-
|
|
73
|
-
3. Grant of Patent License. Subject to the terms and conditions of
|
|
74
|
-
this License, each Contributor hereby grants to You a perpetual,
|
|
75
|
-
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
|
76
|
-
(except as stated in this section) patent license to make, have made,
|
|
77
|
-
use, offer to sell, sell, import, and otherwise transfer the Work,
|
|
78
|
-
where such license applies only to those patent claims licensable
|
|
79
|
-
by such Contributor that are necessarily infringed by their
|
|
80
|
-
Contribution(s) alone or by combination of their Contribution(s)
|
|
81
|
-
with the Work to which such Contribution(s) was submitted. If You
|
|
82
|
-
institute patent litigation against any entity (including a
|
|
83
|
-
cross-claim or counterclaim in a lawsuit) alleging that the Work
|
|
84
|
-
or a Contribution incorporated within the Work constitutes direct
|
|
85
|
-
or contributory patent infringement, then any patent licenses
|
|
86
|
-
granted to You under this License for that Work shall terminate
|
|
87
|
-
as of the date such litigation is filed.
|
|
88
|
-
|
|
89
|
-
4. Redistribution. You may reproduce and distribute copies of the
|
|
90
|
-
Work or Derivative Works thereof in any medium, with or without
|
|
91
|
-
modifications, and in Source or Object form, provided that You
|
|
92
|
-
meet the following conditions:
|
|
93
|
-
|
|
94
|
-
(a) You must give any other recipients of the Work or
|
|
95
|
-
Derivative Works a copy of this License; and
|
|
96
|
-
|
|
97
|
-
(b) You must cause any modified files to carry prominent notices
|
|
98
|
-
stating that You changed the files; and
|
|
99
|
-
|
|
100
|
-
(c) You must retain, in the Source form of any Derivative Works
|
|
101
|
-
that You distribute, all copyright, patent, trademark, and
|
|
102
|
-
attribution notices from the Source form of the Work,
|
|
103
|
-
excluding those notices that do not pertain to any part of
|
|
104
|
-
the Derivative Works; and
|
|
105
|
-
|
|
106
|
-
(d) If the Work includes a "NOTICE" text file as part of its
|
|
107
|
-
distribution, then any Derivative Works that You distribute must
|
|
108
|
-
include a readable copy of the attribution notices contained
|
|
109
|
-
within such NOTICE file, excluding those notices that do not
|
|
110
|
-
pertain to any part of the Derivative Works, in at least one
|
|
111
|
-
of the following places: within a NOTICE text file distributed
|
|
112
|
-
as part of the Derivative Works; within the Source form or
|
|
113
|
-
documentation, if provided along with the Derivative Works; or,
|
|
114
|
-
within a display generated by the Derivative Works, if and
|
|
115
|
-
wherever such third-party notices normally appear. The contents
|
|
116
|
-
of the NOTICE file are for informational purposes only and
|
|
117
|
-
do not modify the License. You may add Your own attribution
|
|
118
|
-
notices within Derivative Works that You distribute, alongside
|
|
119
|
-
or as an addendum to the NOTICE text from the Work, provided
|
|
120
|
-
that such additional attribution notices cannot be construed
|
|
121
|
-
as modifying the License.
|
|
122
|
-
|
|
123
|
-
You may add Your own copyright statement to Your modifications and
|
|
124
|
-
may provide additional or different license terms and conditions
|
|
125
|
-
for use, reproduction, or distribution of Your modifications, or
|
|
126
|
-
for any such Derivative Works as a whole, provided Your use,
|
|
127
|
-
reproduction, and distribution of the Work otherwise complies with
|
|
128
|
-
the conditions stated in this License.
|
|
129
|
-
|
|
130
|
-
5. Submission of Contributions. Unless You explicitly state otherwise,
|
|
131
|
-
any Contribution intentionally submitted for inclusion in the Work
|
|
132
|
-
by You to the Licensor shall be under the terms and conditions of
|
|
133
|
-
this License, without any additional terms or conditions.
|
|
134
|
-
Notwithstanding the above, nothing herein shall supersede or modify
|
|
135
|
-
the terms of any separate license agreement you may have executed
|
|
136
|
-
with Licensor regarding such Contributions.
|
|
137
|
-
|
|
138
|
-
6. Trademarks. This License does not grant permission to use the trade
|
|
139
|
-
names, trademarks, service marks, or product names of the Licensor,
|
|
140
|
-
except as required for reasonable and customary use in describing the
|
|
141
|
-
origin of the Work and reproducing the content of the NOTICE file.
|
|
142
|
-
|
|
143
|
-
7. Disclaimer of Warranty. Unless required by applicable law or
|
|
144
|
-
agreed to in writing, Licensor provides the Work (and each
|
|
145
|
-
Contributor provides its Contributions) on an "AS IS" BASIS,
|
|
146
|
-
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
|
|
147
|
-
implied, including, without limitation, any warranties or conditions
|
|
148
|
-
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
|
|
149
|
-
PARTICULAR PURPOSE. You are solely responsible for determining the
|
|
150
|
-
appropriateness of using or redistributing the Work and assume any
|
|
151
|
-
risks associated with Your exercise of permissions under this License.
|
|
152
|
-
|
|
153
|
-
8. Limitation of Liability. In no event and under no legal theory,
|
|
154
|
-
whether in tort (including negligence), contract, or otherwise,
|
|
155
|
-
unless required by applicable law (such as deliberate and grossly
|
|
156
|
-
negligent acts) or agreed to in writing, shall any Contributor be
|
|
157
|
-
liable to You for damages, including any direct, indirect, special,
|
|
158
|
-
incidental, or consequential damages of any character arising as a
|
|
159
|
-
result of this License or out of the use or inability to use the
|
|
160
|
-
Work (including but not limited to damages for loss of goodwill,
|
|
161
|
-
work stoppage, computer failure or malfunction, or any and all
|
|
162
|
-
other commercial damages or losses), even if such Contributor
|
|
163
|
-
has been advised of the possibility of such damages.
|
|
164
|
-
|
|
165
|
-
9. Accepting Warranty or Additional Liability. While redistributing
|
|
166
|
-
the Work or Derivative Works thereof, You may choose to offer,
|
|
167
|
-
and charge a fee for, acceptance of support, warranty, indemnity,
|
|
168
|
-
or other liability obligations and/or rights consistent with this
|
|
169
|
-
License. However, in accepting such obligations, You may act only
|
|
170
|
-
on Your own behalf and on Your sole responsibility, not on behalf
|
|
171
|
-
of any other Contributor, and only if You agree to indemnify,
|
|
172
|
-
defend, and hold each Contributor harmless for any liability
|
|
173
|
-
incurred by, or claims asserted against, such Contributor by reason
|
|
174
|
-
of your accepting any such warranty or additional liability.
|
|
175
|
-
|
|
176
|
-
END OF TERMS AND CONDITIONS
|
|
177
|
-
|
|
178
|
-
APPENDIX: How to apply the Apache License to your work.
|
|
179
|
-
|
|
180
|
-
To apply the Apache License to your work, attach the following
|
|
181
|
-
boilerplate notice, with the fields enclosed by brackets "[]"
|
|
182
|
-
replaced with your own identifying information. (Don't include
|
|
183
|
-
the brackets!) The text should be enclosed in the appropriate
|
|
184
|
-
comment syntax for the file format. We also recommend that a
|
|
185
|
-
file or class name and description of purpose be included on the
|
|
186
|
-
same "printed page" as the copyright notice for easier
|
|
187
|
-
identification within third-party archives.
|
|
188
|
-
|
|
189
|
-
Copyright [yyyy] [name of copyright owner]
|
|
190
|
-
|
|
191
|
-
Licensed under the Apache License, Version 2.0 (the "License");
|
|
192
|
-
you may not use this file except in compliance with the License.
|
|
193
|
-
You may obtain a copy of the License at
|
|
194
|
-
|
|
195
|
-
http://www.apache.org/licenses/LICENSE-2.0
|
|
196
|
-
|
|
197
|
-
Unless required by applicable law or agreed to in writing, software
|
|
198
|
-
distributed under the License is distributed on an "AS IS" BASIS,
|
|
199
|
-
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
200
|
-
See the License for the specific language governing permissions and
|
|
201
|
-
limitations under the License.
|