← 스킬 목록으로 돌아가기

bash-script-linter

v1.0.0 approved Development ⬇ 4 2일 전
USK v3 ✅ Verified ⚡ Auto-Convert
⬇ 다운로드
설치 가이드↓
🤖 에이전트용 설치 명령 (curl / MCP / Claude Desktop)
▸ curl 한 줄 다운로드
curl -L -o bash-script-linter.skill   "https://aiskillstore.io/v1/agent/skills/15481aa0-1a83-4fd2-957f-ad438a12885c/download?platform=ClaudeCode"
▸ MCP 도구 호출 (Skill Store MCP 등록 시)
{
  "tool": "download_skill",
  "arguments": {
    "skill_id": "15481aa0-1a83-4fd2-957f-ad438a12885c",
    "platform": "ClaudeCode"
  }
}
▸ Claude Desktop / Cursor MCP 설정 (1회)
{
  "mcpServers": {
    "skill-store": {
      "url": "https://aiskillstore.io/mcp/"
    }
  }
}
📖 에이전트용 전체 API 가이드: /llms.txt  ·  MCP server card

AI-agent bash script safety linter — detect dangerous patterns, audit external commands, auto-convert to dry-run, and suggest strict-mode fixes

# bash # shell # security # linter # agent-safety # devops # automation # 배시 # 스크립트 # 보안

기본 정보

소유자 👤 Admin 카테고리 Development 등록일 2026-05-19 최종 업데이트 2026-05-19 최신 버전 1.0.0 패키지 날짜 2026-05-19 검증 상태 approved 다운로드 수 4회 체크섬 (SHA256) de8f772b14dae956a09167e4696769362f36cadfbb215abeb076bd0c97f31ac1

⚡ AGENT INFO USK v3

Capabilities
bash_safety_scan dangerous_command_detection dry_run_conversion external_command_audit strict_mode_validation
Permissions
✗ network
✗ filesystem
✗ subprocess
Interface
type: cli   entry_point: main.py   runtime: python3   call_pattern: stdin_stdout
Agent API
# 스킬 스키마 조회 (에이전트가 호출 방법을 파악) GET /v1/agent/skills/15481aa0-1a83-4fd2-957f-ad438a12885c/schema # 플랫폼별 자동 변환 다운로드 GET /v1/agent/skills/15481aa0-1a83-4fd2-957f-ad438a12885c/download?platform=OpenClaw GET /v1/agent/skills/15481aa0-1a83-4fd2-957f-ad438a12885c/download?platform=ClaudeCode GET /v1/agent/skills/15481aa0-1a83-4fd2-957f-ad438a12885c/download?platform=ClaudeCodeAgentSkill GET /v1/agent/skills/15481aa0-1a83-4fd2-957f-ad438a12885c/download?platform=Cursor GET /v1/agent/skills/15481aa0-1a83-4fd2-957f-ad438a12885c/download?platform=GeminiCLI GET /v1/agent/skills/15481aa0-1a83-4fd2-957f-ad438a12885c/download?platform=CodexCLI GET /v1/agent/skills/15481aa0-1a83-4fd2-957f-ad438a12885c/download?platform=CustomAgent

설치 방법

호환 플랫폼: any

1
openclaw_skill_manager.py로 스킬을 설치합니다.
python openclaw_skill_manager.py --install bash-script-linter
2
설치 확인
python openclaw_skill_manager.py --list-installed
3
특정 버전 설치 (선택)
python openclaw_skill_manager.py --install bash-script-linter --version 1.0.0
1
스킬 패키지를 다운로드합니다.
curl -O https://aiskillstore.io/v1/skills/15481aa0-1a83-4fd2-957f-ad438a12885c/download
2
Claude Code commands 디렉터리에 배치합니다.
unzip bash-script-linter.skill -d ~/.claude/commands/bash-script-linter/
3
Claude Code에서 슬래시 커맨드로 사용합니다.
/bash-script-linter
1
Agent Skills 패키지를 다운로드합니다.
curl -O https://aiskillstore.io/v1/agent/skills/15481aa0-1a83-4fd2-957f-ad438a12885c/download?platform=ClaudeCodeAgentSkill
2
Claude Code skills 디렉터리에 압축을 해제합니다.
unzip bash-script-linter-agent-skill-*.skill -d ~/.claude/skills/bash-script-linter/
3
Claude Code를 재시작하면 세션 시작 시 자동으로 로드됩니다. 슬래시 커맨드 없이 자연어로 사용 가능합니다.
1
Cursor 변환 패키지를 다운로드합니다.
curl -O https://aiskillstore.io/v1/agent/skills/15481aa0-1a83-4fd2-957f-ad438a12885c/download?platform=Cursor
2
압축 해제 후 영구 위치에 저장합니다.
unzip bash-script-linter-cursor-*.skill -d ~/.cursor/skills/bash-script-linter/
3
.cursor/mcp.json에 MCP 서버 설정을 추가하고 Cursor를 재시작합니다.
cat ~/.cursor/skills/bash-script-linter/cursor_mcp_config.json
1
Gemini CLI 변환 패키지를 다운로드합니다.
curl -O https://aiskillstore.io/v1/agent/skills/15481aa0-1a83-4fd2-957f-ad438a12885c/download?platform=GeminiCLI
2
압축 해제 후 영구 위치에 저장합니다.
unzip bash-script-linter-geminicli-*.skill -d ~/.gemini/skills/bash-script-linter/
3
~/.gemini/settings.json에 MCP 서버 설정을 추가하고 Gemini CLI를 재시작합니다.
cat ~/.gemini/skills/bash-script-linter/gemini_settings_snippet.json
1
Codex CLI 변환 패키지를 다운로드합니다.
curl -O https://aiskillstore.io/v1/agent/skills/15481aa0-1a83-4fd2-957f-ad438a12885c/download?platform=CodexCLI
2
압축 해제 후 영구 위치에 저장합니다.
unzip bash-script-linter-codexcli-*.skill -d ~/.codex/skills/bash-script-linter/
3
~/.codex/config.toml에 MCP 서버 설정을 추가하고 Codex CLI를 재시작합니다.
cat ~/.codex/skills/bash-script-linter/codex_config_snippet.toml
1
REST API로 스킬 패키지를 다운로드합니다.
GET https://aiskillstore.io/v1/skills/15481aa0-1a83-4fd2-957f-ad438a12885c/download
2
에이전트 플랫폼의 skills 디렉터리에 배치합니다.
cp bash-script-linter.skill ./skills/
3
설치 가이드 API로 플랫폼별 상세 정보를 조회합니다.
GET https://aiskillstore.io/v1/skills/15481aa0-1a83-4fd2-957f-ad438a12885c/install-guide?platform=CustomAgent

보안 검증 보고서

검증 결과 APPROVED

검사 결과: ["메타데이터 경고: 권장 필드 없음: 'requirements' (SKILL.md v2 권장)", "메타데이터 경고: 권장 필드 없음: 'changelog' (SKILL.md v2 권장)"]

✅ 보안 위험 항목이 발견되지 않았습니다.

AI 검수 단계

검수 주체 gemini 위험도 🟢 낮음 검수 요약 AI 에이전트가 생성한 Bash 스크립트의 안전성을 정적으로 분석하고 위험 요소를 탐지하는 보안 린터 스킬입니다. 선언된 권한을 준수하며 악의적인 코드가 없습니다.
판단 근거

1. **선언된 권한 일치 여부:** 스킬 메타데이터에 `network: false`, `filesystem: false`, `subprocess: false`로 명확히 선언되어 있습니다. 코드(`main.py`, `lib/linter.py`)를 분석한 결과, `sys.stdin`, `sys.stdout`, `os.path` (내부 모듈 로딩 목적) 및 `re` 모듈만 사용하고 있으며, 외부 네트워크 통신, 임의의 파일 시스템 접근, 외부 프로세스 실행 등의 기능은 전혀 사용하지 않아 선언된 권한을 철저히 준수합니다. 2. **악의적 목적의 코드 여부:** 이 스킬의 핵심 기능은 Bash 스크립트 내의 위험한 패턴(예: `rm -rf /`, `curl | sh`, `eval` 등)을 *탐지*하는 것입니다. 코드 자체는 정적 분석 로직으로 구성되어 있으며, 데이터 탈취, 시스템 파괴, 난독화 등 악의적인 목적의 코드는 발견되지 않았습니다. 오히려 스킬의 목적이 다른 스크립트의 보안을 강화하는 데 있습니다. 3. **선언되지 않은 외부 통신 여부:** `network: false` 권한에 따라 외부 통신을 시도하는 코드는 전혀 없으며, `requests`, `urllib`, `socket` 등 네트워크 관련 라이브러리도 사용되지 않습니다. 4. **사용자 데이터 무단 수집/전송 여부:** 스킬은 사용자로부터 Bash 스크립트 내용을 입력받아 로컬에서 정적으로 분석하고, 그 결과를 JSON 형태로 반환합니다. 입력된 스크립트나 분석 결과를 외부로 전송하거나 무단으로 수집하는 기능은 없습니다. 5. **코드 품질 및 목적 일치 여부:** 스킬의 설명과 예시, 그리고 코드 구조가 스킬의 목적(Bash 스크립트 안전성 린터)과 완벽하게 일치합니다. `main.py`는 입출력 및 액션 분기를 담당하고, `lib/linter.py`는 정규 표현식을 활용한 핵심 분석 로직을 포함하여 기능별로 잘 분리되어 있습니다. 코드 가독성이 높고, 오류 처리도 적절하게 구현되어 있습니다. **정적 분석 결과:** 제공된 정적 분석 결과에서도 'approved' 상태이며, 'red_flags_found', 'obfuscation_warnings', 'forbidden_exec_files_found' 항목이 모두 비어 있어 추가적인 위험 요소가 발견되지 않았음을 확인했습니다.

버전 히스토리

버전 USK v3 검증 상태 패키지 날짜 다운로드 변경사항
v1.0.0 approved 2026-05-19 ⬇ 4

사용 예시 (Examples) 8 개

이 스킬의 대표적인 입출력 예시입니다. 에이전트는 이 예시를 보고 스킬 호출 방법과 결과 형태를 이해할 수 있습니다.

Scan dangerous deletion and pipe-to-shell patterns

Detect recursive forced deletion and pipe-to-shell patterns in AI-generated scripts

📥 입력
{
  "action": "scan",
  "script": "Bash script containing recursive forced deletion targeting root and curl output piped to shell"
}
📤 출력
{
  "action": "scan",
  "ok": true,
  "result": {
    "finding_count": 2,
    "findings": [
      {
        "line": 2,
        "message": "Detected critical risk: recursive forced deletion targeting root \u2014 will destroy the filesystem",
        "pattern": "recursive force delete root",
        "risk": "critical"
      },
      {
        "line": 3,
        "message": "Detected critical risk: remote code execution via pipe-to-shell",
        "pattern": "curl/wget pipe to shell",
        "risk": "critical"
      }
    ],
    "max_risk": "critical",
    "safe": false
  }
}
Validate strict mode compliance

Check if script uses set -euo pipefail and proper variable quoting

📥 입력
{
  "action": "validate",
  "script": "#!/bin/bash\nFILE=$1\ncp $FILE /tmp/\n"
}
📤 출력
{
  "action": "validate",
  "ok": true,
  "result": {
    "compliant": false,
    "issue_count": 2,
    "issues": [
      {
        "message": "Script does not use \u0027set -euo pipefail\u0027 or equivalent",
        "rule": "MISSING_STRICT_MODE"
      },
      {
        "line": 3,
        "message": "Unquoted variable: $FILE (use double quotes to prevent word-splitting)",
        "rule": "UNQUOTED_VARIABLE"
      }
    ]
  }
}
Convert script to dry-run safe_mode

Replace destructive commands with echo equivalents for safe preview

📥 입력
{
  "action": "safe_mode",
  "script": "Bash script using strict mode that deletes a temp directory and moves an app directory, then echoes done"
}
📤 출력
{
  "action": "safe_mode",
  "ok": true,
  "result": {
    "commands_neutralized": 2,
    "dry_run_script": "Dry-run version of the script with deletion and move commands replaced by echo statements, prefixed with DRY-RUN header",
    "original_lines": 6
  }
}
Audit external commands and risk scores

List all external binaries used and their associated risk level

📥 입력
{
  "action": "audit",
  "script": "Bash deployment script that uses curl to fetch API data, privilege escalation to restart nginx, ssh for remote operations, and echo for status messages"
}
📤 출력
{
  "action": "audit",
  "ok": true,
  "result": {
    "commands": [
      {
        "name": "curl",
        "reason": "Network access \u2014 can exfiltrate data or fetch malicious content",
        "risk": "medium"
      },
      {
        "name": "privilege_escalation_cmd",
        "reason": "Privilege escalation \u2014 bypasses normal permission checks",
        "risk": "high"
      },
      {
        "name": "ssh",
        "reason": "Remote execution \u2014 executes commands on external host",
        "risk": "high"
      },
      {
        "name": "echo",
        "reason": "Safe output command",
        "risk": "low"
      }
    ],
    "risk_summary": {
      "critical": 0,
      "high": 2,
      "low": 1,
      "medium": 1
    },
    "total_commands": 4
  }
}
Auto-fix suggestions

Suggest automatic fixes for common bash safety issues

📥 입력
{
  "action": "fix",
  "script": "#!/bin/bash\nFILE=$1\nif [ $FILE == \u0027\u0027 ]; then\n  echo error\nfi\ncat $FILE\n"
}
📤 출력
{
  "action": "fix",
  "ok": true,
  "result": {
    "fix_count": 3,
    "fixes": [
      {
        "auto_fixable": true,
        "issue": "Missing strict mode",
        "suggestion": "Add \u0027set -euo pipefail\u0027 after shebang line"
      },
      {
        "auto_fixable": true,
        "issue": "Unquoted variable $FILE at line 2",
        "suggestion": "Change to FILE=\"$1\""
      },
      {
        "auto_fixable": true,
        "issue": "Use of [ ] for string comparison",
        "suggestion": "Use [[ ]] for safer string tests"
      }
    ],
    "patched_script": "Script with strict mode header and quoted variables applied"
  }
}
Clean script passes scan

A well-written script should have no findings

📥 입력
{
  "action": "scan",
  "script": "Bash script with strict mode, quoted variable from arg, file existence check, and wc line count \u2014 no dangerous patterns"
}
📤 출력
{
  "action": "scan",
  "ok": true,
  "result": {
    "finding_count": 0,
    "findings": [],
    "max_risk": "none",
    "safe": true
  }
}
Eval detection

Detect dynamic eval of variables — common in AI-generated scripts

📥 입력
{
  "action": "scan",
  "script": "Bash script that fetches a command string from a remote URL and passes it to eval"
}
📤 출력
{
  "action": "scan",
  "ok": true,
  "result": {
    "finding_count": 1,
    "findings": [
      {
        "message": "eval with variable input is critical risk \u2014 arbitrary code execution",
        "pattern": "eval with variable",
        "risk": "critical"
      }
    ],
    "max_risk": "critical",
    "safe": false
  }
}
Error on missing script field

Returns structured error when script is missing

📥 입력
{
  "action": "scan",
  "script": ""
}
📤 출력
{
  "action": "scan",
  "error": {
    "code": "MISSING_FIELD",
    "message": "Field \u0027script\u0027 must not be empty"
  },
  "ok": false
}

모든 예시는 에이전트 API로도 조회 가능: /v1/agent/skills/15481aa0-1a83-4fd2-957f-ad438a12885c/schema

리뷰 & 평점

아직 리뷰가 없습니다. 첫 번째 리뷰를 남겨보세요!

✍️ 리뷰 작성