egovframe-scaffold-mcp 0.41.0 → 0.43.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/README.en.md +13 -8
- package/README.md +86 -28
- package/dist/agents-md.js +2 -2
- package/dist/catalog-sync.js +5 -0
- package/dist/ci-config.js +148 -13
- package/dist/cli.js +12 -3
- package/dist/component-origin.js +20 -3
- package/dist/dependencies.js +10 -0
- package/dist/i18n.js +4 -3
- package/dist/index.js +5 -2
- package/dist/network.js +11 -0
- package/dist/offline-bundle-plan.js +23 -0
- package/dist/offline-bundle.js +336 -0
- package/dist/output-schemas.js +15 -2
- package/dist/sbom-check.js +26 -9
- package/dist/sbom.js +30 -9
- package/dist/server.js +33 -12
- package/dist/shared.js +7 -0
- package/dist/spdx.js +298 -0
- package/dist/tool-meta.js +2 -0
- package/docs/design-cli.md +21 -0
- package/docs/design-offline-bundle.md +59 -0
- package/package.json +8 -4
package/README.en.md
CHANGED
|
@@ -13,9 +13,9 @@ From an AI tool that speaks MCP (Claude, VS Code Copilot, Cursor, …) you can,
|
|
|
13
13
|
|
|
14
14
|
- create a project from one of the **22 official templates** (repository or Initializr zip, pinned by commit and sha256),
|
|
15
15
|
- assemble **common components** (190 catalog entries from the official v5.0.7 release) with sources, mappers, JSPs, messages, Spring/web fragments and per-database DDL/DML,
|
|
16
|
-
- generate CRUD code (official Development wizard inputs), Spring configuration (21 official Initializr templates, offline) and
|
|
16
|
+
- generate CRUD code (official Development wizard inputs), Spring configuration (21 official Initializr templates, offline) and CI configuration for GitHub Actions, GitLab CI or Jenkins,
|
|
17
17
|
- build and test with Maven/Gradle and get compiler errors and JUnit results structured by file and line,
|
|
18
|
-
- diagnose an existing project, **migrate 3.x/4.x code to 5.x (Jakarta EE, Spring 6, Java 17)** — diagnosis first, then transactional apply, then compile-and-link verification —, check declared or fully resolved dependencies against the official 5.x parents, the full Spring Boot BOM and the RTE transitive versions (optionally with OSV), **generate a CycloneDX SBOM and check it as a submission artifact** (minimum elements, diff against a previous SBOM, VEX draft), produce a one-call **migration readiness assessment** with A–D grades and the printed scoring formula, diagnose network/proxy problems, and generate `AGENTS.md` for AI coding tools.
|
|
18
|
+
- diagnose an existing project, **migrate 3.x/4.x code to 5.x (Jakarta EE, Spring 6, Java 17)** — diagnosis first, then transactional apply, then compile-and-link verification —, check declared or fully resolved dependencies against the official 5.x parents, the full Spring Boot BOM and the RTE transitive versions (optionally with OSV), **generate a CycloneDX or SPDX 2.3 SBOM and check it as a submission artifact** (minimum elements, diff against a previous SBOM, VEX draft), produce a one-call **migration readiness assessment** with A–D grades and the printed scoring formula, diagnose network/proxy problems, and generate `AGENTS.md` for AI coding tools.
|
|
19
19
|
|
|
20
20
|
Every write tool offers `dryRun`, runs inside a file transaction (rollback on failure), never overwrites user files silently, and honours an optional allowed-roots sandbox.
|
|
21
21
|
|
|
@@ -44,7 +44,7 @@ Requires Node.js 18+. Downloads go to `codeload.github.com`, `raw.githubusercont
|
|
|
44
44
|
| `EGOVFRAME_ALLOWED_ROOTS` | Optional sandbox: every directory argument (`projectDir`, `outputDir`) must be inside one of these roots (path-separator-delimited, realpath-checked). |
|
|
45
45
|
| `EGOVFRAME_LANG` | `en` → English tool descriptions in `tools/list`. Responses stay Korean. |
|
|
46
46
|
|
|
47
|
-
## Tools (
|
|
47
|
+
## Tools (32)
|
|
48
48
|
|
|
49
49
|
| Tool | What it does |
|
|
50
50
|
|---|---|
|
|
@@ -61,7 +61,7 @@ Requires Node.js 18+. Downloads go to `codeload.github.com`, `raw.githubusercont
|
|
|
61
61
|
| `list_egovframe_recipes` / `apply_egovframe_recipe` | Curated bundles: project → components → AI layer with one atomic commit |
|
|
62
62
|
| `generate_egovframe_crud` | VO, Mapper XML, Service, Controller, optional JSP and JUnit 5 following the official CRUD wizard |
|
|
63
63
|
| `generate_egovframe_config` | Spring configuration from the 21 official Initializr templates (xml/javaConfig/yaml/properties), offline |
|
|
64
|
-
| `generate_egovframe_ci` |
|
|
64
|
+
| `generate_egovframe_ci` | CI configuration for `platform` github (default), gitlab (`.gitlab-ci.yml`) or jenkins (Declarative `Jenkinsfile`), Maven/Gradle auto-detected; `supplyChain=true` adds the SBOM → minimum-elements → assessment gate |
|
|
65
65
|
| `build_egovframe_project` / `test_egovframe_project` | Run builds and tests; compiler errors and JUnit XML structured by file/line |
|
|
66
66
|
| `diagnose_egovframe_project` / `generate_egovframe_report` | Scan any existing project; Markdown report — `sections=["assessment"]` adds the 5.x migration readiness assessment (overview, migration scope, dependency actions, security settings, SBOM summary, two A–D grades with the formula printed), `format=json`, optional `outputPath` (new file only) |
|
|
67
67
|
| `get_egovframe_guide` / `search_egovframe_docs` | Official guide documents (151 mappings) and offline keyword search |
|
|
@@ -69,8 +69,9 @@ Requires Node.js 18+. Downloads go to `codeload.github.com`, `raw.githubusercont
|
|
|
69
69
|
| `check_egovframe_dependencies` | Compare dependencies (declared, or with `resolve=true` the whole tree resolved by Maven/Gradle — transitive artifacts with their path, declared-vs-resolved differences) with the official 5.x parent baseline (139 coordinates + BOM families), the full Spring Boot BOM (1,473 coordinates) and the transitive dependencies of the 18 RTE modules (58): ok / outdated / parent-managed / legacy / replace / vendor / unknown, each with the basis it was compared against; security-config presence checks; optional OSV lookup |
|
|
70
70
|
| `reassemble_egovframe_components` | Reassemble the common-component sources copied into a 3.x/4.x project onto v5.0.7: identifies the original tag by git blob ids (no downloads), three-way classifies every file, keeps user changes as patches plus a worklist, backs up and removes files 5.x dropped, writes the manifest (then upgrade/validate/remove work); dryRun by default, one transaction, optional compile verify |
|
|
71
71
|
| `rehearse_egovframe_migration` | Rehearse the 5.x migration on a copy without touching the project: reassemble components (first, so the origin tag is still recognisable), apply the automatic items, compile (every javac error, no 100-error cap), align the copy's pom to the official common-components pom of the pinned tag, compile again. Reports both error counts, missing packages with candidate coordinates, cascade errors, remaining files, a worklist and the pom patch; the original is fingerprinted before and after. The official v4.3.2 tree goes from 6,003 errors (JDK 17; 6,335 on JDK 21) to 1 |
|
|
72
|
-
| `
|
|
73
|
-
| `
|
|
72
|
+
| `prepare_egovframe_offline_bundle` | For air-gapped (network-separated) environments: on an internet PC, bundle the full OSV Maven dump, the pinned common-components archive, the Initializr zip templates and a mirror of the official common-components tags with a sha256 manifest. On the air-gapped PC set `EGOVFRAME_OFFLINE_BUNDLE`: downloads are served from the bundle after fingerprint checks, OSV lookups use the local dump (snapshot date noted, warning after 30 days) and reassembly uses the mirror. The local dump matched online OSV on 73/73 queries |
|
|
73
|
+
| `generate_egovframe_sbom` | CycloneDX 1.6 JSON (default) or SPDX 2.3 JSON (`bomFormat="spdx-json"`) SBOM without touching build files — Maven via cyclonedx-maven-plugin (hashes, licenses), Gradle from the resolved tree; baseline verdict per component (`egovframe:*` properties), optional OSV `vulnerabilities[]`; writes inside the project only, `dryRun` by default |
|
|
74
|
+
| `check_egovframe_sbom` | Check an existing CycloneDX or SPDX 2.x SBOM (format detected) without changing it: the 7 minimum elements (supplier, name, version, unique identifier, dependency relationship, author, timestamp) per component with a ready / needs-work verdict, a purl-only re-check (changed baseline verdicts, OSV findings published since generation), a diff against `baselinePath`, and with `vex=true` a CycloneDX VEX draft (`in_triage`, BOM-Link) that keeps human decisions |
|
|
74
75
|
| `diagnose_egovframe_network` | Probe the hosts the server downloads from, classify failures (DNS, timeout, TLS, proxy auth) and prescribe environment settings as bash/cmd/PowerShell commands |
|
|
75
76
|
| `generate_agents_md` | `AGENTS.md` for AI coding tools: build/test commands, RTE and migration status, components, rules, available MCP tools (ko/en) |
|
|
76
77
|
|
|
@@ -81,7 +82,7 @@ Resources: `egovframe://catalog/components`, `…/components/{id}`, `…/templat
|
|
|
81
82
|
- **Pinned sources**: component catalog (official v5.0.7 tag, commit, archive sha256), Initializr zip templates (commit, sha256, size), config templates (commit, per-file sha256, CRLF-safe), migration rules derived from `egovframe-runtime` tags v3.10.0 / v4.3.0-Final / v5.0.2-Final and `egovframe-common-components` v3.10.0 / v5.0.7, dependency baseline extracted from the official 5.x parent poms (5.0.2), `spring-boot-dependencies` 3.5.6 and the RTE 5.0.2 module poms — every pom with url and sha256. `sync_egovframe_templates` reports when any of these drifts upstream.
|
|
82
83
|
- **Release gate**: `npm run prepublishOnly` runs the build and ~28 offline suites (over 1,300 assertions) on ubuntu and windows × Node 18/20/22; an integration job downloads real upstream assets, compiles generated CRUD and a migrated 3.10 project with JDK 17, checks that every migration target coordinate exists in the Maven repositories, watches upstream drift of the bundled rules and baseline, and validates `server.json` against the MCP Registry.
|
|
83
84
|
- **Automated releases** (v0.35+): once a PR is merged and CI passes on `main`, `release.yml` publishes to npm with OIDC trusted publishing (provenance attached, no tokens), tags the verified commit, creates the GitHub Release from the changelog and publishes to the MCP Registry with GitHub OIDC — only when the version in `package.json`, `server.json` and the changelog agree and the version is not released yet.
|
|
84
|
-
- **Protocol metadata**: every tool carries ko/en `title` and MCP annotations (`readOnlyHint`, `destructiveHint`, `idempotentHint`, `openWorldHint`); the five diagnostic tools, the SBOM generator and checker, the report tool, the reassembly tool and the
|
|
85
|
+
- **Protocol metadata**: every tool carries ko/en `title` and MCP annotations (`readOnlyHint`, `destructiveHint`, `idempotentHint`, `openWorldHint`); the five diagnostic tools, the SBOM generator and checker, the report tool, the reassembly tool, the rehearsal tool and the bundle tool also declare `outputSchema` and return `structuredContent`.
|
|
85
86
|
- **Regression corpus** (v0.37): CI runs diagnosis, dry-run apply, the dependency check and the assessment against the official `egovframe-common-components` **v3.10.0 and v4.3.2** source trees (pinned commits, sparse partial clones) and asserts the counts in `catalog/migration-corpus.json` within ±1% — so a rule or baseline change that moves real-world results is caught, and the 4.x→5.x path is verified on real assets.
|
|
86
87
|
- **Resumable releases**: `release-check` looks at npm (including the published `gitHead`), the tag, the GitHub Release and the MCP Registry and runs only the missing steps, so an interrupted release continues on the next merge instead of needing manual tags.
|
|
87
88
|
- **Safety**: transactions with structured rollback reports, `dryRun` everywhere, allowed roots with realpath checks, zip-slip guards, process-tree kill on build timeouts.
|
|
@@ -104,12 +105,16 @@ check_egovframe_dependencies(projectDir="/work/legacy-app", resolve=true, offlin
|
|
|
104
105
|
generate_egovframe_sbom(projectDir="/work/legacy-app", dryRun=false, offline=false, supplier="Agency", author="Vendor") # sbom/bom.cdx.json (CycloneDX 1.6)
|
|
105
106
|
check_egovframe_sbom(projectDir="/work/legacy-app", offline=false, vex=true) # minimum elements + new OSV findings + sbom/vex.cdx.json
|
|
106
107
|
check_egovframe_sbom(projectDir="/work/legacy-app", baselinePath="sbom/bom-prev.cdx.json") # diff against the previous submission
|
|
108
|
+
generate_egovframe_sbom(projectDir="/work/legacy-app", dryRun=false, bomFormat="spdx-json", supplier="Agency") # sbom/bom.spdx.json (SPDX 2.3)
|
|
109
|
+
check_egovframe_sbom(projectDir="/work/legacy-app", sbomPath="sbom/bom.spdx.json") # same checks on SPDX
|
|
107
110
|
```
|
|
108
111
|
|
|
109
112
|
The official `egovframe-web` template declares 19 dependencies and looks clean; resolving the tree shows 65 artifacts, 11 below the baseline and 24 OSV advisories. The SBOM carries the same verdict per component (`egovframe:status`, `egovframe:basis`, `egovframe:baseline`) and the OSV findings as `vulnerabilities[]`.
|
|
110
113
|
|
|
111
114
|
Public-sector SBOM submission in Korea is to be institutionalised by 2027. `check_egovframe_sbom` checks the 7 minimum elements (rules as data in `catalog/sbom-rules.json`, NTIA minimum elements = the Korean SW supply-chain security guideline 1.0 core elements). The plugin output for the official web template misses the supplier on 18 of 68 components (no `<organization>` in their poms) and the SBOM author; `generate_egovframe_sbom(supplier, author)` plus a small supplier table with per-entry evidence (marked `egovframe:supplierBasis=catalog`) makes it pass. The VEX draft marks new findings `in_triage`; people record `not_affected`/`exploitable`/… and later runs keep those decisions and only add new findings. Generated SBOMs and VEX documents validate against the official CycloneDX 1.6.1 JSON schema in the tests.
|
|
112
115
|
|
|
116
|
+
When SPDX is required, `bomFormat="spdx-json"` writes the same content as SPDX 2.3 JSON: packages, `DESCRIBES` and `DEPENDS_ON` relationships (`NONE` for "no dependencies", so it differs from "unknown"), purl/cpe/swid external refs, supplier/originator, creators and created, checksums, declared licenses, OSV advisories (`SECURITY`/`advisory`) and the baseline verdicts (`egovframe:*` annotations). `check_egovframe_sbom` reads SPDX by mapping it onto the same checks (supplier = `PackageSupplier`/`PackageOriginator`, dependency relationship = `DEPENDS_ON` with the package as subject, author = `Person`/`Organization` creators). For the official web template built with real Maven, the SPDX document passes the official spdx-spec v2.3 schema and checks exactly like the CycloneDX one (67 components, same per-element counts, diff 0). VEX stays CycloneDX-only.
|
|
117
|
+
|
|
113
118
|
## Running in CI (CLI mode)
|
|
114
119
|
|
|
115
120
|
```bash
|
|
@@ -119,7 +124,7 @@ npx -y egovframe-scaffold-mcp sbom --project . --write
|
|
|
119
124
|
npx -y egovframe-scaffold-mcp sbom-check --project . --offline=false --fail-on "minimum,newVulns"
|
|
120
125
|
```
|
|
121
126
|
|
|
122
|
-
With no arguments the package starts the MCP stdio server as before; with a command (`assess`, `check`, `sbom`, `sbom-check`, `rehearse`, `migrate`, `validate`, `diagnose`, `network`) it runs that one tool through an in-memory MCP client and exits. Options use the tool parameter names (kebab-case allowed); `--json` prints the same object as MCP `structuredContent`; `--step-summary` appends the Markdown to `$GITHUB_STEP_SUMMARY`; `--fail-on` takes grade (`supplyChain:C`) or count (`vulnerabilities`, `manual>20`) conditions. Exit codes: 0 pass, 2 over the `--fail-on` threshold, 3 execution failure, 64 usage error. Write tools are not exposed. `generate_egovframe_ci(supplyChain=true)` adds
|
|
127
|
+
With no arguments the package starts the MCP stdio server as before; with a command (`assess`, `check`, `sbom`, `sbom-check`, `rehearse`, `bundle`, `migrate`, `validate`, `diagnose`, `network`) it runs that one tool through an in-memory MCP client and exits. Options use the tool parameter names (kebab-case allowed); `--json` prints the same object as MCP `structuredContent`; `--step-summary` appends the Markdown to `$GITHUB_STEP_SUMMARY`; `--fail-on` takes grade (`supplyChain:C`) or count (`vulnerabilities`, `manual>20`) conditions. Exit codes: 0 pass, 2 over the `--fail-on` threshold, 3 execution failure, 64 usage error. Write tools are not exposed. `generate_egovframe_ci(platform, supplyChain=true)` adds the same gate on GitHub Actions, GitLab CI (JUnit and CycloneDX reports, validated against the official GitLab CI schema in the tests) or Jenkins (Declarative, `sh` on Linux and `bat` on Windows agents): SBOM → `sbom-check --fail-on minimum` → assessment above `failOn` fails, with the reports and SBOM kept as artifacts; `npmRegistry` and `offlineBundle` become `NPM_CONFIG_REGISTRY` and `EGOVFRAME_OFFLINE_BUNDLE`. Design notes: [docs/design-cli.md](docs/design-cli.md) (Korean).
|
|
123
128
|
|
|
124
129
|
## Reassembling copied common components
|
|
125
130
|
|
package/README.md
CHANGED
|
@@ -13,11 +13,11 @@
|
|
|
13
13
|
Claude, VS Code(Copilot), Cursor 등 MCP를 지원하는 AI 도구에서 **대화 중 즉시** 표준프레임워크
|
|
14
14
|
프로젝트를 만들고 공통컴포넌트·AI 계층을 조립할 수 있습니다. 기존 프로젝트 진단, 리포트, 안전한 upstream 재동기화도 지원합니다.
|
|
15
15
|
|
|
16
|
-
현재 v0.
|
|
16
|
+
현재 v0.43.0은 **도구 32종(title·annotations·구조화 출력 11종) + CLI 명령 10종, 공식 템플릿 22종, 설정 템플릿 21종, 5.x 전환 규칙(RTE 18모듈·클래스 331종 + 공통컴포넌트 1,089종 근거)과 적용·검증·재조립·사본 리허설, 의존성 기준(공식 parent 관리 좌표 139종+계열 6종+Spring Boot BOM 1,473종+RTE 전이 58종)·해석된 의존성 트리·CycloneDX·SPDX SBOM 생성·점검(최소 요소·비교·VEX), GitHub·GitLab·Jenkins CI 공급망 게이트, 규칙·기준 drift 감시, 폐쇄망 오프라인 번들, 네트워크 진단·AGENTS.md 생성, 공통컴포넌트 카탈로그 190항목(리프 176종+그룹 14종, v5.0.7)**을 제공합니다.
|
|
17
17
|
|
|
18
|
-
## 진행 현황 (2026-10-
|
|
18
|
+
## 진행 현황 (2026-10-11)
|
|
19
19
|
|
|
20
|
-
- **소스 기준**: v0.
|
|
20
|
+
- **소스 기준**: v0.43.0(`package.json`), 도구 32종 + CLI 명령 10종·공식 템플릿 22종·설정 템플릿 21종·카탈로그 190항목(공통컴포넌트 v5.0.7).
|
|
21
21
|
- **안전성 기준선 완료**: [PR #7](https://github.com/EricSeokgon/egovframe-scaffold-mcp/pull/7)~[#16](https://github.com/EricSeokgon/egovframe-scaffold-mcp/pull/16)을 반영해 provenance·strict assertion·safe remove와 프로젝트 생성/레시피/직접 조립/AI 조립/업그레이드 transaction을 갖췄습니다.
|
|
22
22
|
- **v0.22.0 추가**: `EGOVFRAME_ALLOWED_ROOTS`를 19개 도구 진입점에 적용해 `..`·symlink/junction 이탈을 차단하고, 실패 시 rollback 결과를 구조화해 반환합니다. [PR #16](https://github.com/EricSeokgon/egovframe-scaffold-mcp/pull/16)은 7파일(+340/−31), 로컬 16종 스위트 전체 통과 후 병합됐습니다.
|
|
23
23
|
- **v0.23.0 추가**: `build_egovframe_project` — 생성한 프로젝트를 실제로 빌드(maven/gradle·mvnw/gradlew 자동 감지)하고 컴파일·테스트 오류를 파일/라인 단위로 구조화해 생성→검증 루프를 완성합니다. 타임아웃·로그 상한·허용 root·dryRun 포함. [PR #18](https://github.com/EricSeokgon/egovframe-scaffold-mcp/pull/18)은 4파일(+458/−3), 오프라인 40단언과 실제 spawn 경로를 검증했습니다.
|
|
@@ -32,6 +32,8 @@ Claude, VS Code(Copilot), Cursor 등 MCP를 지원하는 AI 도구에서 **대
|
|
|
32
32
|
- **v0.30.0 추가**: `migrate_egovframe_project` 2단계(`apply=true`) — 진단의 auto 항목을 하나의 transaction 으로 실제 치환합니다(dryRun 기본, 원본 `migration-backup/` 보관, `migration-plan.json`, 실패 시 복구). 3.10 좌표·javax 픽스처를 적용한 뒤 JDK 17 `mvn compile` 통과를 CI 에서 확인합니다. `check_egovframe_dependencies` — 공식 5.x parent 2종에서 추출한 기준(관리 좌표 139종 + BOM 계열 7종, `catalog/dependency-baseline.json`)과 의존성을 대조해 기준 충족/미만/parent 관리/전환 대상/교체 필요/기준 없음으로 분류하고, 보안 설정(sec.security·CSRF·XSS 필터·보안 헤더·HTTPS 저장소) 존재 여부를 근거와 함께 보고합니다. 기본 오프라인, `offline=false` 면 OSV 취약점 조회(설계: [docs/design-dependency-check.md](docs/design-dependency-check.md)).
|
|
33
33
|
- **v0.31.0 추가**: 운영 편의 — `diagnose_egovframe_network`(도구가 쓰는 호스트 7종에 DNS·HEAD 프로브, 실패 종류 분류, HTTPS_PROXY+NODE_USE_ENV_PROXY·IPv4 우선·사내 CA 처방을 bash/cmd/PowerShell 명령으로), 모든 다운로드 실패 메시지에 같은 처방 한 줄 부착, `generate_agents_md`(진단 결과로 AI 코딩 도구용 AGENTS.md, ko/en), 영문 README(`README.en.md`)와 `EGOVFRAME_LANG=en` 영문 도구 설명, MCP Registry 메타데이터(`server.json`·`mcpName`). 기획 3개 버전(v0.29–v0.31)이 모두 완료됐습니다.
|
|
34
34
|
- **v0.32.0 추가**: MCP 프로토콜 현대화 — 도구 27종을 `registerTool` 로 전환해 `title`(ko/en)과 annotations(`readOnlyHint` 14종·`destructiveHint` 4종·`idempotentHint`·`openWorldHint`)를 `tools/list` 에 노출하고, `format=json` 을 제공하던 5종(`diagnose_egovframe_project`·`validate_egovframe_project`·`migrate_egovframe_project`·`check_egovframe_dependencies`·`diagnose_egovframe_network`)은 `outputSchema` 와 `structuredContent` 를 함께 돌려줍니다(기존 `text` 유지). 테스트 이식성 가드(`scripts/check-test-portability.mjs`, 게이트 포함)와 플랫폼 주입 단언으로 Windows 전용 실패 재발을 막습니다.
|
|
35
|
+
- **v0.43.0 추가**: CI·제출 형식 다변화 — `generate_egovframe_ci(platform="gitlab"|"jenkins")` 가 GitHub Actions 와 같은 빌드·공급망 게이트를 `.gitlab-ci.yml`(JUnit·CycloneDX 리포트)·`Jenkinsfile`(Declarative, Linux `sh`·Windows `bat` 공용)로 만들고, 게이트에 **SBOM 최소 요소 점검**(`sbom-check --fail-on minimum`)을 세 플랫폼 모두 추가했습니다. 사내 npm 레지스트리(`npmRegistry`)·오프라인 번들 경로(`offlineBundle`)는 환경 변수로 들어가고, 공급자 단서가 없으면 게이트가 실패할 것을 미리 알립니다. SBOM 은 **SPDX 2.3 JSON** 으로도 냅니다 — `generate_egovframe_sbom(bomFormat="spdx-json")` 이 패키지·`DEPENDS_ON` 관계(의존 없음은 `NONE`)·purl·공급자·creators·created·체크섬·선언 라이선스·OSV 권고·기준 판정(annotations)을 담고, `check_egovframe_sbom` 은 형식을 자동 판별해 SPDX 도 같은 최소 요소 7종·재판정·비교로 점검합니다(VEX 는 CycloneDX 만). 공식 web 템플릿을 실제 Maven 으로 만든 SBOM 은 SPDX 로 바꿔도 component 67·최소 요소 판정(요소별 충족 수까지)이 같고 SPDX ↔ CycloneDX 비교 차이 0 이며, 생성 `.gitlab-ci.yml` 은 GitLab 공식 CI 스키마를, SPDX 출력은 공식 spdx-spec v2.3 스키마를 통과합니다. 도구 수는 32종 그대로입니다.
|
|
36
|
+
- **v0.42.0 추가**: 폐쇄망(망분리) 운영 — 새 도구 **`prepare_egovframe_offline_bundle`**(32번째)이 인터넷 PC 에서 OSV Maven 취약점 전체 덤프(≈10MB, 7,190건)·고정 공통컴포넌트 아카이브(sha256 검증)·Initializr zip 템플릿(고정 지문)·재조립용 공식 공통컴포넌트 태그 22개 미러(≈37MB)를 한 디렉터리에 담고 `bundle-manifest.json`(파일별 sha256·크기·출처 URL·받은 시각)을 씁니다. 폐쇄망 PC 에서 `EGOVFRAME_OFFLINE_BUNDLE` 만 지정하면 다운로드는 번들 파일을 지문 검증 후 쓰고(변조 거부), `offline=false` 의 OSV 조회는 로컬 덤프로 판정하며(스냅숏 기준일 표시, 30일 넘으면 경고), 재조립은 번들 미러를 씁니다. 같은 날 받은 덤프의 로컬 판정이 온라인 OSV 와 **질의 73/73·ID 134/134 일치**했고, 네트워크를 막은 상태에서 프로젝트 생성·공통컴포넌트 조립·재조립 미리보기·SBOM 재점검이 번들만으로 끝나는 것(네트워크 시도 0건)을 CI 에서 확인합니다. CLI `bundle`, 네트워크 진단의 오프라인 번들 처방.
|
|
35
37
|
- **v0.41.0 추가**: 전환 리허설 — 새 도구 **`rehearse_egovframe_migration`**(31번째)이 프로젝트를 건드리지 않고 사본에서 공통컴포넌트 재조립 → 전환 자동 항목 적용 → 컴파일 → pom 을 공식 공통컴포넌트 v5.0.7 기준으로 맞춤 → 다시 컴파일까지 돌려 "자동 단계 뒤 사람이 고칠 것이 실제로 몇 건인가"를 잽니다(javac 의 오류 100개 상한 없이 전부 셈, 실행 전후 지문으로 원본 불변 확인). 공식 공통컴포넌트 **v4.3.2 전체 트리**(6,523 파일)는 자동 단계 뒤 컴파일 오류 **6,003건**(CI·JDK 17, JDK 21 은 6,335건) 중 4건을 뺀 전부가 누락 패키지와 그 연쇄(pom 의존성, 그 때문에 Lombok 이 돌지 못한 getter 등)였고, pom 을 맞추면 **1건**(GPKI 벤더 jar 의 javax 참조)만 남습니다 — CI 가 이 값을 기대값으로 고정합니다. 실측 중 찾은 두 결함도 고쳤습니다: 재조립은 전환 적용보다 **먼저** 해야 원본 태그가 식별되고(반대로 하면 4.3.2 가 v5.0.1 로 오인), 4.x 의 `org.egovframe.rte` 좌표가 5.x 로 분류되던 문제와 Maven 경고·fork 형식이 컴파일 오류로 잘못 읽히던 문제를 바로잡았습니다. 평가서 6절에 최근 리허설 실측이 함께 나옵니다.
|
|
36
38
|
- **v0.40.0 추가**: SBOM 운영 — 새 도구 **`check_egovframe_sbom`**(30번째)이 이미 만든 CycloneDX SBOM 을 제출물로서 점검합니다. (1) 최소 요소 7종(공급자·구성요소명·버전·고유식별자·의존관계·작성자·생성 시각, NTIA 최소 요소 = 국내 SW 공급망 보안 가이드라인 핵심 구성요소)을 component 마다 세어 "제출 가능/보완 필요"를, (2) 빌드 도구 없이 purl 만으로 기준 판정과 OSV 를 다시 해 생성 이후 바뀐 판정·새로 알려진 취약점을, (3) 이전 SBOM 과의 추가·제거·버전·판정·취약점 차이를, (4) `vex=true` 면 CycloneDX VEX 초안(새 취약점은 `in_triage`, 사람이 적은 판단은 보존)을 냅니다. `generate_egovframe_sbom` 은 `supplier`·`author` 옵션(기본 pom `<organization>`)과 공급자 표로 최소 요소를 생성 단계에서 채웁니다. 공식 web 템플릿 SBOM 은 공급자(주 component 포함 18종)·작성자가 비어 "보완 필요", 옵션으로 다시 만들면 "제출 가능"이고, SBOM·VEX 모두 CycloneDX 1.6 공식 스키마를 통과합니다. CLI `sbom-check`, 평가서 5절에 최소 요소·VEX 상태. 기획 세 버전(v0.38–v0.40)이 모두 완료됐습니다.
|
|
37
39
|
- **v0.39.0 추가**: CLI 모드와 CI 공급망 게이트 — `npx egovframe-scaffold-mcp <assess|check|sbom|migrate|validate|diagnose|network>` 가 AI 클라이언트 없이 같은 분석을 실행하고 종료합니다(인자 없는 실행은 기존 stdio 서버). `--json` 은 MCP `structuredContent` 와 같은 객체이고, `--fail-on supplyChain:C`·`vulnerabilities`·`manual>20` 같은 기준을 넘으면 종료 코드 2 로 파이프라인을 멈춥니다. `generate_egovframe_ci(supplyChain=true)` 는 SBOM 생성 → 평가서(등급을 PR 요약에) → 아티팩트로 이어지는 게이트 job 을 만듭니다(생성 결과는 CI 에서 actionlint 로 검사). MCP SDK 1.32.1(프로토콜 2025-11-25)로 올렸습니다.
|
|
@@ -41,7 +43,7 @@ Claude, VS Code(Copilot), Cursor 등 MCP를 지원하는 AI 도구에서 **대
|
|
|
41
43
|
- **v0.35.0 추가**: 릴리스 자동화 — `main` 에서 CI 가 성공하면 `release.yml` 이 네 조건(`server.json` 버전 일치·변경 이력 항목·태그 없음·npm 미배포)을 검사해 npm(OIDC trusted publishing, provenance 자동) → 그 커밋에 태그 → GitHub Release(변경 이력에서 추출) → MCP Registry(GitHub OIDC) 순으로 게시합니다. 사람은 PR 병합만 합니다. 게이트에 `test:release`(판정 함수·릴리스 노트·`npm pack` 내용·크기 상한)와 `server.json` 설명 100자 제한(레지스트리 검증 조건 — 실제 `mcp-publisher validate` 로 발견한 결함 수정)을 추가했습니다.
|
|
42
44
|
- **v0.34.0 추가**: 의존성 기준 완성 + 규칙·기준 drift 감시 — `check_egovframe_dependencies` 의 기준에 **Spring Boot BOM 전체**(`spring-boot-dependencies` 3.5.6 직접 항목 + BOM import 44종을 한 단계 풀어 1,473 좌표)와 **RTE 모듈 18종의 전이 의존성**(58 좌표, 어느 모듈이 끌어오는지)을 더해 항목마다 기준 출처(parent 직접·계열·Boot BOM·RTE 전이·전환 규칙)를 표시하고, 국내 벤더·기관 배포 좌표는 `vendor` 로, EOL·이전 좌표(옛 MySQL/Oracle 드라이버·Jackson 1·xmlbeans·Ehcache 2·HttpClient 4·ANTLR 3·Spring Social)는 교체 규칙으로 분류해 공식 공통컴포넌트 3.10 pom 의 '기준 없음'을 17 → 1 로 줄였습니다. `sync_egovframe_templates` 가 동봉 규칙·기준의 upstream drift(`egovframe-runtime`·공통컴포넌트 새 태그, 공식 parent 새 버전, 고정 pom sha256 변화)를 갱신 절차와 함께 보고합니다. 기준 parent 를 5.0.2 로 올렸습니다.
|
|
43
45
|
- **v0.33.0 추가**: `migrate_egovframe_project` 3단계 — `verify=true` 가 compile 을 실행해 컴파일 오류를 수동 항목과 연결하고 "처리하면 해결될 오류 수" 순 작업 목록을 냅니다(javac `symbol:`/`location:` 파싱). 규칙 카탈로그(schemaVersion 2)에 공통컴포넌트 3.x→5.x 대응표(`egovframe-common-components` v3.10.0↔v5.0.6, 제거 54·이동 4)를 추가해 `egovframework.com.*` 제거·이동 클래스를 진단하고, 3.x 공통컴포넌트 소스가 섞인 프로젝트에는 컴포넌트 단위 재조립 권고(`skipComponents` 로 치환 제외)를 냅니다.
|
|
44
|
-
- **다음 계획**: v0.
|
|
46
|
+
- **다음 계획**: v0.41–v0.43 기획을 모두 마쳤습니다([기획 원문과 결과](#다음-버전-기획-v041v043)). 다음 세 버전 기획은 아직 없습니다.
|
|
45
47
|
- **배포 상태**: npm 최신 배포 버전은 상단 npm 배지와 [npm 패키지 페이지](https://www.npmjs.com/package/egovframe-scaffold-mcp)를 단일 출처로 확인합니다. 이 문서의 버전 표기는 저장소 소스(`package.json`) 기준이며, git 태그 `vX.Y.Z`가 해당 배포본의 커밋을 가리킵니다.
|
|
46
48
|
|
|
47
49
|
## 제공 도구
|
|
@@ -67,7 +69,7 @@ Claude, VS Code(Copilot), Cursor 등 MCP를 지원하는 AI 도구에서 **대
|
|
|
67
69
|
| `rehearse_egovframe_migration` | **전환 리허설** — 프로젝트 사본에서 재조립 → 전환 적용 → 컴파일 → pom 맞춤(공식 공통컴포넌트 v5.0.7 기준 parent·좌표·버전·scope) → 컴파일. 두 시점의 오류 수(javac 상한 없이), 누락 패키지·후보 좌표·연쇄 오류, 남는 수동 항목·파일, 사라지는 오류 순 작업 목록, 사본 pom 패치. 원본 불변(지문 비교), 최근 결과는 평가서에 실측으로 |
|
|
68
70
|
| `upgrade_egovframe_project` | 설치 컴포넌트를 upstream과 3-way 비교해 갱신 — 사용자 수정 보존, dryRun 기본, 적용 직전 재검증, 파일·백업·매니페스트 단일 transaction (파괴적, 게이트) |
|
|
69
71
|
| `explain_egovframe_component` | 컴포넌트 하나의 상세(설명·직접/전이 의존성·역의존·참조 테이블·가이드 링크·설치 명령)를 한 번에 반환 (읽기 전용) |
|
|
70
|
-
| `generate_egovframe_ci` | GitHub Actions CI
|
|
72
|
+
| `generate_egovframe_ci` | CI 설정 생성 — `platform` 으로 GitHub Actions(기본)·GitLab CI(`.gitlab-ci.yml`)·Jenkins(`Jenkinsfile`, Declarative), maven/gradle 자동 감지, dryRun, 기존 파일 보호. `supplyChain=true` 면 SBOM → 최소 요소 점검 → 전환 준비도 평가서 게이트(`failOn` 기준 초과 시 실패, 보고서·SBOM 보관), `npmRegistry`·`offlineBundle` 환경 변수 |
|
|
71
73
|
| `build_egovframe_project` | 생성한 프로젝트를 실제로 빌드(compile·test·package) — maven/gradle·mvnw/gradlew 자동 감지, 타임아웃·로그 상한, 컴파일 오류 파일/라인 구조화, dryRun |
|
|
72
74
|
| `test_egovframe_project` | 테스트 실행 + JUnit XML 리포트(surefire·gradle) 구조화 — 스위트별 통과/실패/오류/건너뜀, 실패 케이스 메시지·예외 타입·테스트 파일/라인, `testFilter`, 이전 실행 리포트 제외, dryRun |
|
|
73
75
|
| `generate_egovframe_crud` | 공식 Development CRUD wizard 입력 체계 기반 코드 생성 — VO·Mapper(XML)·Service·Controller·JSP(선택)·JUnit 5(선택), Classic/Boot 분기, 전체 충돌 사전 검사 |
|
|
@@ -76,8 +78,9 @@ Claude, VS Code(Copilot), Cursor 등 MCP를 지원하는 AI 도구에서 **대
|
|
|
76
78
|
| `migrate_egovframe_project` | 3.x/4.x 프로젝트의 5.x(Jakarta EE 9+·Spring 6·Java 17) 전환 — **진단**(기본, 읽기 전용): RTE Maven 좌표(`egovframework.rte:egovframework.rte.*`·`org.egovframe.rte:org.egovframe.rte.*` → `org.egovframe.rte:egovframe-rte-*`)·RTE 버전·저장소 URL·5.x parent, 패키지 접두어·이름 변경·제거 클래스(대체 안내), `javax→jakarta` 패키지·의존성 좌표, web.xml 스키마, 제거된 `egov-security/access/crypto` 네임스페이스, 교체 필요 라이브러리를 파일·라인 단위 `auto`/`manual` 항목으로 보고. **적용**(`apply=true`): auto 항목을 transaction 으로 치환, dryRun 기본, 원본 `migration-backup/` 보관·`migration-plan.json`, 실패 시 복구, 적용 후 재진단. **검증**(`verify=true`): compile 실행 후 컴파일 오류를 수동 항목과 연결한 작업 목록(해결될 오류 수 순). 공통컴포넌트 3.x→5.x 대응표(제거·이동 클래스)와 컴포넌트 단위 재조립 권고, `skipComponents` |
|
|
77
79
|
| `check_egovframe_dependencies` | 의존성 점검(읽기 전용) — 선언된 의존성(`resolve=true` 면 Maven `dependency:tree`·Gradle `dependencies` 로 해석한 전이 의존성까지, 트리 경로·선언/해석 버전 차이 포함)을 공식 5.x parent 기준(관리 좌표 139종 + Spring/Security/Boot 등 BOM 계열) + Spring Boot BOM 전체(1,473종) + RTE 모듈 전이 의존성(58종)과 대조해 기준 충족/기준 미만/parent 관리/전환 대상(3.x·4.x RTE·javax)/교체 필요(DBCP 1.x·Log4j 1.x·Jackson 1·Ehcache 2 등)/벤더 배포(국내 DBMS·GPKI)/기준 없음 분류(항목마다 기준 출처 표시), 5.x parent·Java 버전 판정, 보안 설정 존재 점검(sec.security·CSRF·XSS 필터·보안 헤더·HTTPS 저장소, 파일·라인 근거). 기본 오프라인, `offline=false` 면 OSV 취약점 조회 |
|
|
78
80
|
| `diagnose_egovframe_network` | 도구가 내려받는 호스트 7종(codeload·raw·media.githubusercontent, maven.egovframe.go.kr, repo1.maven.org, registry.npmjs.org, api.osv.dev)에 DNS 조회·HEAD 요청을 보내 도달 여부·소요 시간·실패 종류(DNS·타임아웃·TLS·프록시 인증·거부)를 보고하고, 환경에 맞는 처방(`HTTPS_PROXY`+`NODE_USE_ENV_PROXY=1`, `NODE_OPTIONS=--dns-result-order=ipv4first`, `NODE_EXTRA_CA_CERTS`)을 bash/cmd/PowerShell 명령으로 안내. 프로젝트 디렉터리 불필요, 파일 무기록 |
|
|
79
|
-
| `
|
|
80
|
-
| `
|
|
81
|
+
| `prepare_egovframe_offline_bundle` | **폐쇄망 오프라인 번들** — 인터넷 PC 에서 OSV Maven 덤프·고정 공통컴포넌트 아카이브·Initializr zip 템플릿·공통컴포넌트 태그 미러를 sha256 manifest 와 함께 새 디렉터리에 담음(dryRun 기본). 폐쇄망에서는 `EGOVFRAME_OFFLINE_BUNDLE` 로 다운로드·OSV·재조립 원본을 번들로 대체 |
|
|
82
|
+
| `generate_egovframe_sbom` | **SBOM 생성** — Maven/Gradle 프로젝트의 CycloneDX 1.6 JSON(기본) 또는 SPDX 2.3 JSON(`bomFormat="spdx-json"`)을 빌드 파일 변경 없이 생성(Maven: cyclonedx-maven-plugin makeAggregateBom, 해시·라이선스 포함 / Gradle: 해석된 의존성 트리로 구성). `enrich` 로 component 마다 기준 판정(`egovframe:status·basis·baseline`) 속성, `offline=false` 로 OSV 취약점을 `vulnerabilities[]` 에 포함. 출력은 프로젝트 안 경로(기본 `sbom/bom.cdx.json`, SPDX 는 `sbom/bom.spdx.json`), 기존 파일은 `overwrite` 없이는 거부, `dryRun`(기본)은 계획만 |
|
|
83
|
+
| `check_egovframe_sbom` | **SBOM 점검** — 기존 CycloneDX·SPDX 2.x SBOM(형식 자동 판별)의 최소 요소 7종(공급자·구성요소명·버전·고유식별자·의존관계·작성자·생성 시각) 충족 여부와 빠진 component, 빌드 도구 없이 purl 로 기준 재판정·OSV 재조회(생성 이후 새 취약점), `baselinePath` 와 비교(추가·제거·버전·판정·취약점), `vex=true` 면 CycloneDX VEX 초안(`in_triage`, BOM-Link, 사람의 판단 보존, CycloneDX 입력만). SBOM 파일은 바꾸지 않음 |
|
|
81
84
|
| `generate_agents_md` | 프로젝트 진단 결과로 AI 코딩 도구용 `AGENTS.md` 생성 — 빌드·테스트 명령(래퍼 감지), RTE·5.x 전환 상태, DbType, 기본 패키지·설정 디렉터리, 설치 컴포넌트(매니페스트 여부), 규칙(좌표·백업 디렉터리·비밀 정보·의존성 기준), MCP 도구 목록. 기존 파일은 `overwrite` 없이는 거부, `dryRun`, ko/en, 파일명 변경(`CLAUDE.md` 등) |
|
|
82
85
|
|
|
83
86
|
### create_egovframe_project 파라미터
|
|
@@ -181,7 +184,8 @@ check_egovframe_dependencies(projectDir="/work/my-egov-app", resolve=true, offli
|
|
|
181
184
|
### generate_egovframe_sbom 파라미터
|
|
182
185
|
|
|
183
186
|
- `projectDir` — Maven 또는 Gradle 프로젝트(허용 root 적용)
|
|
184
|
-
- `
|
|
187
|
+
- `bomFormat` — `cyclonedx-json`(기본, CycloneDX 1.6) | `spdx-json`(v0.43, SPDX 2.3 — CycloneDX 로 만든 뒤 변환)
|
|
188
|
+
- `outputPath` — 프로젝트 상대 경로(기본 `sbom/bom.cdx.json`, SPDX 는 `sbom/bom.spdx.json`; `..`·절대 경로·symlink 이탈 거부), `overwrite` — 기존 파일 덮어쓰기(기본 거부)
|
|
185
189
|
- `scope` — `runtime`(기본: compile+runtime) | `all`(test·provided 포함)
|
|
186
190
|
- `enrich` — `true`(기본) component 마다 `egovframe:status`·`egovframe:basis`·`egovframe:baseline` 속성 부착
|
|
187
191
|
- `offline` — `true`(기본) | `false` OSV 결과를 CycloneDX `vulnerabilities[]`(`affects` 로 component 참조)로 포함
|
|
@@ -192,15 +196,16 @@ check_egovframe_dependencies(projectDir="/work/my-egov-app", resolve=true, offli
|
|
|
192
196
|
generate_egovframe_sbom(projectDir="/work/my-egov-app") # 계획만
|
|
193
197
|
generate_egovframe_sbom(projectDir="/work/my-egov-app", dryRun=false, offline=false) # sbom/bom.cdx.json + OSV
|
|
194
198
|
generate_egovframe_sbom(projectDir="/work/my-egov-app", dryRun=false, supplier="○○기관", author="○○정보기술") # 최소 요소까지
|
|
199
|
+
generate_egovframe_sbom(projectDir="/work/my-egov-app", dryRun=false, bomFormat="spdx-json", supplier="○○기관") # sbom/bom.spdx.json (SPDX 2.3)
|
|
195
200
|
```
|
|
196
201
|
|
|
197
202
|
Maven 은 `org.cyclonedx:cyclonedx-maven-plugin:2.9.3:makeAggregateBom` 을 좌표를 완전히 적어 호출하므로 pom 을 바꾸지 않으며(해시·라이선스 포함, 멀티 모듈 합산), Gradle 은 해석된 트리로 이 서버가 문서를 구성합니다(해시·라이선스 없음, 빌드 파일 변경 없음). 문서의 `metadata.tools` 에 이 서버가 기록됩니다. 기준 판정은 `check_egovframe_dependencies` 와 같은 규칙입니다(설계: [의존성 점검 설계](docs/design-dependency-check.md)).
|
|
198
203
|
|
|
199
204
|
### check_egovframe_sbom 파라미터 (SBOM 점검)
|
|
200
205
|
|
|
201
|
-
- `sbomPath` — 점검할 SBOM(기본 `sbom/bom.cdx.json
|
|
206
|
+
- `sbomPath` — 점검할 SBOM(기본 `sbom/bom.cdx.json`; CycloneDX JSON 또는 SPDX 2.x JSON, 형식 자동 판별), `baselinePath` — 비교할 이전 SBOM(선택, 형식이 달라도 purl 좌표로 비교)
|
|
202
207
|
- `offline` — `true`(기본) | `false` OSV 재조회(생성 이후 새로 알려진 취약점·지금 조회되지 않는 취약점)
|
|
203
|
-
- `vex` — `true` 면 VEX 초안 작성·갱신(`vexPath`, 기본 `sbom/vex.cdx.json
|
|
208
|
+
- `vex` — `true` 면 VEX 초안 작성·갱신(`vexPath`, 기본 `sbom/vex.cdx.json`, CycloneDX 입력만), `dryRun` — vex 미리보기
|
|
204
209
|
- SBOM 파일은 바꾸지 않습니다. VEX 는 새 파일로 만들고, 다음 실행은 기존 판단을 그대로 두고 새 항목만 덧붙입니다(깨진 VEX 는 덮어쓰지 않고 중단)
|
|
205
210
|
|
|
206
211
|
### SBOM 제출 준비
|
|
@@ -215,16 +220,18 @@ check_egovframe_sbom(projectDir, offline=false, vex=true) # 3. 새
|
|
|
215
220
|
check_egovframe_sbom(projectDir, baselinePath="sbom/bom-2026Q3.cdx.json", offline=false, vex=true) # 4. 다음 제출 전: 비교 + 새 취약점만 VEX 에 추가
|
|
216
221
|
```
|
|
217
222
|
|
|
218
|
-
| 최소 요소 | CycloneDX 위치 | 비고 |
|
|
219
|
-
|
|
220
|
-
| 공급자 | component `supplier`·`publisher`·`manufacturer` (주 component 는 `metadata.supplier` 도) | 플러그인은 pom `<organization>` 이 있는 라이브러리만 `publisher` 를 채움 — 공식 web 템플릿 67종 중 17종(RTE 등)이 비어 공급자 표로 보완 |
|
|
221
|
-
| 구성요소명 · 버전 | `name` · `version` | |
|
|
222
|
-
| 고유식별자 | `purl`(또는 `cpe`·`swid`) | |
|
|
223
|
-
| 의존관계 | `dependencies[]` 에 그 component 의 `bom-ref` 항목 | 의존이 없어도 빈 `dependsOn`
|
|
224
|
-
| 작성자 | `metadata.authors`(또는 `metadata.manufacturer`) | 생성 도구(`metadata.tools`)만으로는 작성 주체가 드러나지 않음 |
|
|
225
|
-
| 생성 시각 | `metadata.timestamp` | ISO 8601 |
|
|
223
|
+
| 최소 요소 | CycloneDX 위치 | SPDX 2.3 위치 (v0.43) | 비고 |
|
|
224
|
+
|---|---|---|---|
|
|
225
|
+
| 공급자 | component `supplier`·`publisher`·`manufacturer` (주 component 는 `metadata.supplier` 도) | `PackageSupplier`(없으면 `PackageOriginator`) | 플러그인은 pom `<organization>` 이 있는 라이브러리만 `publisher` 를 채움 — 공식 web 템플릿 67종 중 17종(RTE 등)이 비어 공급자 표로 보완 |
|
|
226
|
+
| 구성요소명 · 버전 | `name` · `version` | `PackageName` · `PackageVersion`(`versionInfo`) | |
|
|
227
|
+
| 고유식별자 | `purl`(또는 `cpe`·`swid`) | `externalRefs` 의 `purl`(또는 `cpe23Type`·`cpe22Type`·`swid`) | |
|
|
228
|
+
| 의존관계 | `dependencies[]` 에 그 component 의 `bom-ref` 항목 | 그 패키지가 주어인 `DEPENDS_ON`(또는 `*_DEPENDENCY_OF` 의 대상) | 의존이 없어도 빈 `dependsOn` / `DEPENDS_ON NONE` 이 있어야 함(`NOASSERTION` 은 모름) |
|
|
229
|
+
| 작성자 | `metadata.authors`(또는 `metadata.manufacturer`) | `creationInfo.creators` 의 `Person:`·`Organization:` | 생성 도구(`metadata.tools` / `Tool:`)만으로는 작성 주체가 드러나지 않음 |
|
|
230
|
+
| 생성 시각 | `metadata.timestamp` | `creationInfo.created` | ISO 8601 — SPDX 는 필수 항목이라 원본에 없으면 변환 시각을 넣고 알림 |
|
|
231
|
+
|
|
232
|
+
규칙은 `catalog/sbom-rules.json` 데이터입니다(출처: NTIA 최소 요소 2021, SW 공급망 보안 가이드라인 1.0) — 국내 지침이 요소를 더하면 데이터로 추가합니다. CI 에서는 `npx -y egovframe-scaffold-mcp sbom-check --offline=false --fail-on "minimum,newVulns"` 로 제출 전 점검을 게이트로 걸 수 있습니다.
|
|
226
233
|
|
|
227
|
-
|
|
234
|
+
제출처가 SPDX 를 요구하면(가이드라인 1.0 은 SPDX·CycloneDX 를 모두 언급) `bomFormat="spdx-json"` 으로 같은 내용을 SPDX 2.3 JSON 으로 냅니다. 체크섬·선언 라이선스(이름만 있는 라이선스는 `LicenseRef-` + `hasExtractedLicensingInfos`)·OSV 권고(`SECURITY`/`advisory` externalRefs)·기준 판정(`egovframe:*` annotations)도 옮기므로, SPDX 로 낸 뒤 `check_egovframe_sbom(sbomPath="sbom/bom.spdx.json")` 의 재판정·비교가 CycloneDX 와 같은 결과를 냅니다. SPDX 3.0, 취약점 판단 자동화(VEX 상태는 사람의 결정), 중앙 저장소 제출 API 는 범위 밖입니다.
|
|
228
235
|
|
|
229
236
|
### generate_egovframe_report 파라미터 (전환 준비도 평가서)
|
|
230
237
|
|
|
@@ -383,15 +390,57 @@ npx -y egovframe-scaffold-mcp rehearse --project . --fail-on "errors>50"
|
|
|
383
390
|
|---|---|---|
|
|
384
391
|
| `assess` | `generate_egovframe_report(sections=["assessment"])` | 등급 지표 `migration`·`supplyChain`(예: `supplyChain:C` = C 이상이면 실패) |
|
|
385
392
|
| `check` | `check_egovframe_dependencies` | `outdated`·`legacy`·`replace`·`unknown`·`vulnerabilities`·`securityMissing` |
|
|
386
|
-
| `sbom` | `generate_egovframe_sbom` | `--write` 가 있어야 파일을 씀(기본 계획만) |
|
|
393
|
+
| `sbom` | `generate_egovframe_sbom` | `--write` 가 있어야 파일을 씀(기본 계획만), `--bom-format spdx-json` 이면 SPDX 2.3 |
|
|
394
|
+
| `bundle` | `prepare_egovframe_offline_bundle` | 인터넷 PC 용, `--output-dir` 필수, `--write` 가 있어야 받음(기본 목록만) |
|
|
387
395
|
| `rehearse` | `rehearse_egovframe_migration` | 사본에서 실측(원본 불변), 지표 `errors`(최종)·`automation`·`aligned`·`files`·`unlinked`·`failedSteps` |
|
|
388
|
-
| `sbom-check` | `check_egovframe_sbom` | `minimum`(보완 필요면 1)·`gaps`·`newVulns`·`changed`·비교 `added`·`removed`·`versionChanged`·`diffVulns`·VEX `triage`, `--write` 면 VEX 작성·갱신 |
|
|
396
|
+
| `sbom-check` | `check_egovframe_sbom` | CycloneDX·SPDX 자동 판별, `minimum`(보완 필요면 1)·`gaps`·`newVulns`·`changed`·비교 `added`·`removed`·`versionChanged`·`diffVulns`·VEX `triage`, `--write` 면 VEX 작성·갱신 |
|
|
389
397
|
| `migrate` | `migrate_egovframe_project` | 진단만(`--apply` 차단), `manual`·`auto`·`items` |
|
|
390
398
|
| `validate` · `diagnose` · `network` | 같은 이름의 도구 | `invalid`·`missing` · `issues` · `failed` |
|
|
391
399
|
|
|
392
400
|
옵션은 도구 파라미터와 같은 이름(kebab-case 가능)이고, 공통 옵션은 `--project`·`--json`(MCP `structuredContent` 와 같은 객체)·`--out`·`--step-summary`(Markdown 을 `$GITHUB_STEP_SUMMARY` 에)·`--fail-on` 입니다. 종료 코드는 **0 통과 · 2 `--fail-on` 기준 초과 · 3 실행 실패 · 64 사용법 오류**, 본문은 stdout·한 줄 요약은 stderr 입니다. 쓰기 도구(생성·조립·적용·재조립)는 CLI 에 노출하지 않습니다.
|
|
393
401
|
|
|
394
|
-
|
|
402
|
+
### CI 설정 생성: GitHub Actions · GitLab CI · Jenkins
|
|
403
|
+
|
|
404
|
+
`generate_egovframe_ci(projectDir, platform, supplyChain=true)` 가 세 플랫폼에 같은 빌드와 같은 게이트를 만듭니다. 게이트는 SBOM 생성(`sbom --write --offline=false`) → **최소 요소 7종 점검**(`sbom-check --fail-on minimum`, v0.43) → 전환 준비도 평가서(`assess --fail-on <failOn>`) 순서이고, CLI 의 종료 코드 2(기준 초과)·3(실행 실패)는 job 실패입니다. 보고서(`egovframe-assessment.md`·`egovframe-sbom-check.md`)와 `sbom/bom.cdx.json` 은 실패해도 보관하며, 패키지 버전은 생성 시점의 서버 버전으로 고정됩니다.
|
|
405
|
+
|
|
406
|
+
| platform | 파일 | 빌드 | 게이트 |
|
|
407
|
+
|---|---|---|---|
|
|
408
|
+
| `github`(기본) | `.github/workflows/egovframe-ci.yml` | `mvn -B verify` · `./gradlew build` | 별도 job, 등급을 PR 요약(`--step-summary`)에, upload-artifact |
|
|
409
|
+
| `gitlab` | `.gitlab-ci.yml` | `maven:3.9-eclipse-temurin-<JDK>`(Gradle 은 `eclipse-temurin:<JDK>`) 이미지, 로컬 저장소 캐시, JUnit 리포트 | `supply-chain` job(`needs: []`), Node 가 없으면 apt 로 설치 시도, `artifacts:reports:cyclonedx` |
|
|
410
|
+
| `jenkins` | `Jenkinsfile`(Declarative) | `stage('Build')` — Linux `sh`·Windows `bat` 공용 | `SBOM` → `SBOM check` → `Assessment` 단계, `post { always { archiveArtifacts } }` |
|
|
411
|
+
|
|
412
|
+
```text
|
|
413
|
+
generate_egovframe_ci(projectDir="/work/my-egov-app", platform="gitlab", supplyChain=true, supplier="○○기관")
|
|
414
|
+
generate_egovframe_ci(projectDir="/work/my-egov-app", platform="jenkins", supplyChain=true, failOn="supplyChain:C",
|
|
415
|
+
npmRegistry="https://nexus.example.go.kr/repository/npm-group/", offlineBundle="/opt/egov-bundle")
|
|
416
|
+
```
|
|
417
|
+
|
|
418
|
+
- `npmRegistry` 는 `NPM_CONFIG_REGISTRY`(npx 가 이 서버를 받는 사내 레지스트리), `offlineBundle` 은 `EGOVFRAME_OFFLINE_BUNDLE`(러너·에이전트에서 본 번들 경로)로 들어갑니다. 값은 따옴표·`$`·줄바꿈 없는 URL·절대 경로만 허용합니다(설정 파일 주입 차단).
|
|
419
|
+
- 공급자 단서가 없으면(`supplier` 미지정, pom `<organization><name>` 없음) SBOM 의 주 component 공급자·작성자가 비어 `sbom-check` 단계가 실패하므로, 생성 응답이 이를 미리 알립니다.
|
|
420
|
+
- GitLab 이미지는 공개 Docker Hub 기준입니다. 폐쇄망에서는 사내 레지스트리의 같은 이미지(JDK + Node.js 18 이상)로 바꾸세요. Jenkins 는 Pipeline 기본 단계(`sh`·`bat`·`archiveArtifacts`)만 쓰며 에이전트에 JDK·Maven·Node.js 가 있어야 합니다.
|
|
421
|
+
- 생성 `.gitlab-ci.yml` 은 테스트에서 GitLab 공식 CI 스키마로 검증하고, `Jenkinsfile` 은 Declarative 구조를 단언합니다(실제 Jenkins 실행 검증은 보류). 설계: [docs/design-cli.md](docs/design-cli.md).
|
|
422
|
+
|
|
423
|
+
## 폐쇄망에서 쓰기 (오프라인 번들)
|
|
424
|
+
|
|
425
|
+
공공 개발 환경은 대부분 망분리라 인터넷 PC 에서 받은 자료를 반입해 씁니다. 이 서버가 실행 중에 인터넷을 쓰는 곳(공통컴포넌트 아카이브·Initializr zip 템플릿 다운로드, OSV 취약점 조회, 재조립 원본 태그 조회)을 번들 하나로 대신합니다.
|
|
426
|
+
|
|
427
|
+
```bash
|
|
428
|
+
# 1) 인터넷 PC — 번들 만들기(≈110MB: OSV 10 · 아카이브 45 · web 템플릿 15 · 태그 미러 37, 템플릿 12종 전부면 ≈150MB)
|
|
429
|
+
npx -y egovframe-scaffold-mcp bundle --output-dir ./egov-bundle --write
|
|
430
|
+
npx -y egovframe-scaffold-mcp bundle --output-dir ./egov-bundle --templates web,boot-web --write # 템플릿 골라 담기
|
|
431
|
+
|
|
432
|
+
# 2) 폐쇄망 PC — 옮긴 디렉터리를 지정(MCP 클라이언트 설정의 env 에도 같은 값)
|
|
433
|
+
export EGOVFRAME_OFFLINE_BUNDLE=/opt/egov-bundle # cmd: setx EGOVFRAME_OFFLINE_BUNDLE D:\egov-bundle
|
|
434
|
+
```
|
|
435
|
+
|
|
436
|
+
| 번들 항목 | 대신하는 것 | 검증 |
|
|
437
|
+
|---|---|---|
|
|
438
|
+
| `osv/Maven-all.zip` (OSV Maven 전체 덤프) | `offline=false` 의 OSV 조회(`check_egovframe_dependencies`·`generate_egovframe_sbom`·`check_egovframe_sbom`·평가서) | 결과에 "스냅숏 YYYY-MM-DD 기준" 표시, 30일(`EGOVFRAME_BUNDLE_MAX_AGE_DAYS`) 넘으면 경고 |
|
|
439
|
+
| `archives/…-7912e13ca5a0.zip` (공통컴포넌트 v5.0.7) | `add_egovframe_components`·재조립·업그레이드의 아카이브 다운로드 | 카탈로그 고정 sha256·크기·파일 수 |
|
|
440
|
+
| `templates/<id>.zip` (Initializr zip 템플릿) | `create_egovframe_project` 의 zip 템플릿 | 템플릿 고정 sha256·크기 |
|
|
441
|
+
| `origin/…git` (공식 태그 22개, 내용 포함) | 재조립·리허설의 원본 태그 식별·패치 | 원격 조회 없이 로컬 미러만 |
|
|
442
|
+
|
|
443
|
+
번들 파일은 쓸 때마다 manifest 의 sha256·크기와 대조하고 다르면 거부합니다. 번들에 없는 URL 은 평소처럼 네트워크로 가므로, 저장소 템플릿(`simple-backend` 등)이 필요하면 `--templates` 로 지정해 함께 담으세요. Maven 의존성 jar 는 번들에 넣지 않습니다 — 기관 Nexus·Artifactory 미러를 `settings.xml` 에 지정하세요. upstream 대조 도구(`sync_egovframe_*`)와 가이드 문서 조회는 인터넷이 필요합니다. 설계: [docs/design-offline-bundle.md](docs/design-offline-bundle.md).
|
|
395
444
|
|
|
396
445
|
## 리소스·프롬프트 (MCP Resources/Prompts)
|
|
397
446
|
|
|
@@ -458,9 +507,11 @@ curl "https://registry.modelcontextprotocol.io/v0.1/servers?search=io.github.Eri
|
|
|
458
507
|
- 네트워크 진단 레벨: 오류 분류 8종, 프로브·DNS 주입으로 7가지 시나리오(전부 도달, 405/404/407/503, 프록시+타임아웃, 프록시 없음+IPv6 혼재, TLS, DNS, 필터)의 처방·안내·자격 증명 가림·셸별 명령을 단언하고, `fetchWithTimeout` 실패 메시지에 처방이 붙는지 확인 (`npm run test:network`, 33단언, 네트워크 불필요). 실제 호스트 7종 프로브는 CI 통합 job (`npm run test:network-live`)
|
|
459
508
|
- AGENTS.md 레벨: 5.x(매니페스트·래퍼·컴포넌트 2종·백업 디렉터리)와 3.x gradle 픽스처, 빈 디렉터리에서 사실 수집·ko/en 렌더링·dryRun 무기록·기존 파일 거부·overwrite·파일명 검증·staging 정리 (`npm run test:agents-md`, 22단언, 네트워크 불필요)
|
|
460
509
|
- 레지스트리 메타데이터 레벨: `server.json` ↔ `package.json` 의 이름(`mcpName`)·버전·npm 좌표·스키마 URL·환경변수 문서화 정합 (`npm run test:registry`, 네트워크 불필요)
|
|
461
|
-
- 프로토콜 레벨(추가): `EGOVFRAME_LANG=en` 으로 띄운 서버의 도구
|
|
510
|
+
- 프로토콜 레벨(추가): `EGOVFRAME_LANG=en` 으로 띄운 서버의 도구 32종 설명이 모두 영문이고 표에 빠진 도구가 없는지, `tools/list` 에 `title`·annotations(readOnly 13종·destructive 5종)·`outputSchema` 11종이 노출되는지 확인 (`npm run test:handshake`)
|
|
462
511
|
- SBOM·해석 레벨: Maven·Gradle 트리 파서(실제 출력 픽스처), `resolve=true` 의 전이 항목·경로·선언/해석 차이·실패 경로, CycloneDX 문서 구성·보강·취약점 병합·출력 경로 거부·overwrite·dryRun (`npm run test:dependencies`, `npm run test:sbom`, 네트워크 불필요); CI 통합이 공식 `egovframe-web` 템플릿을 실제 Maven 으로 해석하고 SBOM 을 생성 (`npm run test:sbom-live`)
|
|
512
|
+
- 오프라인 번들 레벨: Maven 버전 비교(숫자·한정자 순서·같은 표기), OSV 범위(여러 구간·fixed·last_affected), 덤프 색인(Maven 만·철회 제외·GIT 범위 무시)과 querybatch 같은 모양의 결과, 번들 만들기(dryRun·manifest 지문·고정 지문 불일치 거부·실패 시 무흔적·덮어쓰기 거부·로컬 git 원본 미러), 번들 읽기(fetch 훅·POST 제외·변조 거부·깨진 manifest), 원본 미러(태그·커밋·트리·blob, 없는 태그 안내), OSV 출처 노트와 30일 경고, 의존성 점검 연동, 네트워크 진단 처방 (`npm run test:offline-bundle`, 30단언, 네트워크 불필요); CI 통합이 실제 번들을 만들고 로컬 OSV 와 온라인 OSV 를 대조(97% 이상 일치 요구, 실측 100%)한 뒤 fetch 를 막고 생성·조립·재조립 미리보기·SBOM 재점검을 번들만으로 확인 (`npm run test:bundle-live`)
|
|
463
513
|
- 전환 리허설 레벨: pom 맞춤(parent 추가·교체, 누락 좌표, 버전·scope, parent 관리 속성, 주석·dependencyManagement·plugin 제외, 멱등), 누락 패키지·연쇄·수동 항목 분류와 후보 좌표, Maven fork 형식·경고 제외 파서, 사본 제외 규칙·원본 지문 불변, 단계 순서(재조립 → 적용 → 컴파일 → pom 맞춤 → 컴파일)·javac 상한 해제 인자, 단계 실패 계속, 기록과 평가서 6절 (`npm run test:rehearse`, 38단언, 네트워크 불필요); CI 통합이 공식 공통컴포넌트 v4.3.2 전체 트리를 실제로 리허설해 재조립·적용 수와 오류 6,003(±10%, 누락 패키지·연쇄 95% 이상)→≤5 를 단언 (`npm run test:rehearse-live`)
|
|
514
|
+
- SPDX 레벨: 실제 플러그인 출력 고정물을 SPDX 2.3 으로 바꿔 공식 spdx-spec v2.3 스키마 통과, 패키지 68·`DEPENDS_ON` 간선 수 = CycloneDX 의존 간선·의존 없음 `NONE`·체크섬·라이선스(LicenseRef)·DESCRIBES, 되읽었을 때 최소 요소 요소별 충족 수·purl·의존 간선·기준 판정(annotations)·취약점(advisory) 보존, 다른 도구 모양 SPDX(`DEPENDENCY_OF`·`NOASSERTION`·여러 DESCRIBES·Person/Organization/Tool)의 필드 대응, `bomFormat="spdx-json"` 생성·SPDX 입력 점검(형식 판별·CycloneDX 와 같은 판정·SPDX↔CycloneDX 비교 차이 0·VEX 거부)·outputSchema (`npm run test:spdx`, 43단언, 네트워크 불필요). 실제 Maven SBOM 의 SPDX 판정 일치는 CI 통합 `test:sbom-live` 가 확인
|
|
464
515
|
- SBOM 운영 레벨: 실제 플러그인 출력 고정물(공식 web 템플릿 67 component)로 최소 요소 7종(빠진 항목별)·공급자 표 보완·purl 재판정·가짜 OSV(새/사라진 ID)·비교(추가·제거·버전·판정·취약점)·VEX 생성/판단 보존/같은 ID 의 새 영향 component·깨진 VEX 중단을 단언하고, 생성 SBOM·VEX 를 CycloneDX 1.6 공식 JSON 스키마(specification 1.6.1)로 검증 (`npm run test:sbom-check`, 54단언, 네트워크 불필요); CI 통합이 실제 SBOM 으로 보완 필요(주 component 공급자·작성자) → supplier·author 로 보완(환경에 따른 다른 공백은 `info:` 로그), 두 SBOM 비교 차이 0, 실제 OSV VEX 초안·판단 보존을 확인 (`npm run test:sbom-live`)
|
|
465
516
|
- 메타데이터·구조화 출력 레벨: `TOOL_META` ↔ 등록 도구 일치, 읽기 전용·파괴·네트워크 힌트 배정, 영문 title, 7종 도구의 실제 결과(진단·검증·전환 진단/적용·의존성·네트워크·리포트, 빈 프로젝트 포함)가 `outputSchema` 를 통과하고 최상위 키가 전부 선언돼 있으며 잘못된 값은 거부 (`npm run test:output-schemas`, 47단언, 네트워크 불필요). MCP 프로토콜 경유 호출 시 SDK 가 `structuredContent` 를 스키마로 검증합니다
|
|
466
517
|
- 테스트 이식성 레벨: `scripts/check-test-portability.mjs` 가 `test/*.mjs` 에서 Windows 에서 깨지는 가정(정규화 없는 `path.relative` 비교, `./mvnw` 리터럴 기대값, POSIX 절대 경로)을 찾아 실패시킵니다(`npm run check:portability`, 게이트 포함, 의도된 줄은 `// portability: ok <사유>`). 플랫폼 분기 함수(`resolveCommand`·`collectAgentsFacts`)는 `platform` 주입으로 linux·win32 양쪽을 단언합니다
|
|
@@ -472,7 +523,7 @@ curl "https://registry.modelcontextprotocol.io/v0.1/servers?search=io.github.Eri
|
|
|
472
523
|
- 회귀 코퍼스 레벨: 공식 공통컴포넌트 v3.10.0·v4.3.2 부분 트리(커밋 고정, sparse 클론, 캐시)에 진단·dryRun 적용·의존성 점검·평가서를 돌려 `catalog/migration-corpus.json` 기대값과 ±1% 안인지, 세대 판정·확인 필요 클래스 0·기준 없음은 `xerces` 뿐·계획=자동 전부·재조립 권고·등급 D/D·60초 미만을 단언 (`npm run test:migrate-corpus`, 20단언, git·네트워크 필요, CI 통합). 기대값 갱신은 `npm run generate:migration-corpus`(`--check` 는 차이만)
|
|
473
524
|
- 업그레이드 레벨: 3-way 판정 6분류(unchanged/update/user-modified/conflict/added/removed)·v1 보수모드·정상 적용/백업 계획·파일/매니페스트 fault-injection rollback·상위 symlink 경계 검증 (`npm run test:upgrade`, 네트워크 불필요)
|
|
474
525
|
- 컴포넌트 설명 레벨: `explain_egovframe_component`의 의존성(직접·전이)·역의존·테이블·가이드 URL·미존재 예외 검증 (`npm run test:explain`, 네트워크 불필요)
|
|
475
|
-
- CI 생성 레벨: `generate_egovframe_ci`의 maven/gradle 감지·YAML·dryRun 무기록·기존 파일 거부·빌드파일 부재 예외·`jdk
|
|
526
|
+
- CI 생성 레벨: `generate_egovframe_ci`의 maven/gradle 감지·YAML·dryRun 무기록·기존 파일 거부·빌드파일 부재 예외·`jdk`·`failOn`·`supplier`·환경 변수 주입 입력 거부, 세 플랫폼 공통 게이트 명령(sbom → sbom-check → assess), 생성 `.gitlab-ci.yml` 의 GitLab 공식 CI 스키마(v19.4.1-ee 고정물) 통과, `Jenkinsfile` 의 Declarative 구조(pipeline·agent·options·stages·post, 괄호 짝, 단계 순서)·Windows 경로 이스케이프, 공급자 단서 없을 때 게이트 실패 예고 (`npm run test:ci`, 네트워크 불필요)
|
|
476
527
|
- CRUD 생성 레벨: 공식 wizard 그룹, Classic/Boot 분기, DB 생성키, JUnit 5, dryRun, PK·경로 검증, 충돌 시 전체 무기록 검증 (`npm run test:crud`, 네트워크 불필요)
|
|
477
528
|
- CRUD 컴파일 레벨: 공식 simple-backend/Boot CRUD 7파일과 web-sample/Classic CRUD 9파일 생성 → JDK 17에서 `mvn -q -DskipTests compile` (`npm run test:crud-integration`, 네트워크 필요, CI 실행)
|
|
478
529
|
- 안전성 레벨: 19개 도구 공통 허용 root의 미설정 호환·격리·`..` 이탈·symlink 우회·다중 root·비대상 인자 무해 6케이스와 구조화 rollback 필드를 검증합니다 (`npm run test:allowed-roots`, `npm run test:transaction`, 네트워크 불필요).
|
|
@@ -490,7 +541,7 @@ curl "https://registry.modelcontextprotocol.io/v0.1/servers?search=io.github.Eri
|
|
|
490
541
|
|
|
491
542
|
v0.31.0까지 프로젝트·CRUD 생성, 검증된 공통컴포넌트 실행 자산 조립, 안전성 기반(테스트 판정 강제·사용자 파일 보호·전 도구 트랜잭션·허용 root·구조화 rollback 보고), 생성→검증 루프(실제 빌드·오류 구조화·테스트 리포트 구조화), 공식 템플릿 카탈로그 단일화와 커버리지 확대(22종 중 21종), 설정 파일 생성, 5.x 전환(진단·적용), 의존성 점검, 운영 편의(네트워크 진단·AGENTS.md·영문 설명·레지스트리 메타데이터)를 완료했습니다.
|
|
492
543
|
|
|
493
|
-
v0.32–v0.34 로 MCP 프로토콜 현대화, 5.x 전환 3단계(검증)와 공통컴포넌트 대응표, 의존성 기준 완성과 규칙·기준 drift 감시를, v0.35–v0.37 로 릴리스 자동화, 해석된 의존성 트리와 SBOM, 전환 준비도 평가서와 회귀 코퍼스를, v0.38–v0.40 으로 공통컴포넌트 재조립 실행, CLI 모드와 CI 공급망 게이트, SBOM 운영(최소 요소·비교·VEX)
|
|
544
|
+
v0.32–v0.34 로 MCP 프로토콜 현대화, 5.x 전환 3단계(검증)와 공통컴포넌트 대응표, 의존성 기준 완성과 규칙·기준 drift 감시를, v0.35–v0.37 로 릴리스 자동화, 해석된 의존성 트리와 SBOM, 전환 준비도 평가서와 회귀 코퍼스를, v0.38–v0.40 으로 공통컴포넌트 재조립 실행, CLI 모드와 CI 공급망 게이트, SBOM 운영(최소 요소·비교·VEX)을, v0.41–v0.43 으로 전환 리허설, 폐쇄망 오프라인 번들, GitLab·Jenkins CI 와 SPDX 를 마쳤습니다(기획 원문과 결과: [v0.41–v0.43](#다음-버전-기획-v041v043) · [v0.38–v0.40](#이전-기획-v038v040-완료) · [v0.35–v0.37](#이전-기획-v035v037-완료)). Homebrew 탭은 후순위에서 내렸습니다(npx 로 충분).
|
|
494
545
|
|
|
495
546
|
| 버전 | 핵심 기능 | 목표 |
|
|
496
547
|
|---|---|---|
|
|
@@ -516,8 +567,8 @@ v0.32–v0.34 로 MCP 프로토콜 현대화, 5.x 전환 3단계(검증)와 공
|
|
|
516
567
|
| **v0.39 완료** | CLI 모드 + CI 공급망 게이트 | `npx egovframe-scaffold-mcp <assess\|check\|sbom\|migrate\|validate>` — AI 클라이언트 없이 CI·배치에서 같은 분석을 실행(JSON/Markdown, `--fail-on` 등급·판정 임계값, 종료 코드), `generate_egovframe_ci` 의 공급망 게이트 단계(평가서·SBOM 아티팩트), SDK 1.32(프로토콜 2025-11-25) |
|
|
517
568
|
| **v0.40 완료** | SBOM 운영: 최소 요소·비교·VEX | `check_egovframe_sbom`: 기존 SBOM 의 최소 요소(공급자·구성요소명·버전·고유식별자·의존관계·작성자·생성시각) 충족 점검, 빌드 도구 없이 purl 로 OSV 재조회, 이전 SBOM 과 비교(추가·제거·버전 변경·새 취약점), CycloneDX VEX 초안 생성; `generate_egovframe_sbom` 에 공급자·작성자 메타데이터 — 2027년 공공 SBOM 제출 제도화 대비 |
|
|
518
569
|
| **v0.41 완료** | 전환 리허설 | `rehearse_egovframe_migration`: 프로젝트 사본에서 migrate apply → reassemble → JDK 17 compile 을 돌려 남는 컴파일 오류 수·분포와 "처리하면 오류가 가장 많이 줄어드는 작업" 목록을 실측(원본 불변), 평가서 등급 옆 실측 표시, CLI `rehearse` — 공식 공통컴포넌트 v4.3.2 전체 트리 기대값 고정 |
|
|
519
|
-
| **v0.42
|
|
520
|
-
| **v0.43
|
|
570
|
+
| **v0.42 완료** | 폐쇄망 운영: 오프라인 번들 | `prepare_egovframe_offline_bundle`: OSV Maven 덤프·고정 컴포넌트 아카이브·Initializr zip·원본 태그 미러 + sha256 manifest, `EGOVFRAME_OFFLINE_BUNDLE` 로 모든 다운로드·OSV 조회를 번들로 대체(스냅숏 기준일 표시·오래됨 경고) |
|
|
571
|
+
| **v0.43 완료** | CI·제출 형식 다변화 | `generate_egovframe_ci(platform=gitlab\|jenkins)`(GitLab 공식 스키마 통과·Declarative Jenkinsfile)와 세 플랫폼 게이트에 `sbom-check --fail-on minimum`, 사내 npm 레지스트리·오프라인 번들 변수, SBOM SPDX 2.3 JSON 출력·점검(공식 spdx-spec v2.3 스키마, 실제 Maven SBOM 에서 CycloneDX 와 판정 일치) |
|
|
521
572
|
|
|
522
573
|
## 다음 버전 기획 (v0.41–v0.43)
|
|
523
574
|
|
|
@@ -556,6 +607,8 @@ v0.40.0 까지 끝난 상태(2026-10-07, 도구 30종 + CLI 명령 8종, 테스
|
|
|
556
607
|
|
|
557
608
|
**완료 정의**: 도구 32종, README 「폐쇄망에서 쓰기」 절, `docs/design-offline-bundle.md`
|
|
558
609
|
|
|
610
|
+
**결과(2026-10-10) — 완료**: `src/offline-bundle.ts`(번들 만들기·읽기·로컬 OSV·Maven 버전 비교)와 `src/offline-bundle-plan.ts`. 실측: 번들 106.8MB(OSV 덤프 9.9MB·7,190건, 아카이브 44.7MB, web 템플릿 14.8MB, 태그 22개 미러 37.3MB), 만드는 데 약 10초. 같은 날 받은 덤프의 로컬 판정이 온라인 querybatch 와 공식 web 템플릿 SBOM 67 component + 옛 버전 표본 6개에서 **질의 73/73·ID 134/134 일치**, fetch 를 막고 git 을 file 프로토콜로 제한한 상태에서 web 템플릿 생성·bbs 조립(797파일)·4.3.2 재조립 미리보기(원본 v4.3.2 식별)·SBOM 재점검(OSV 27건)이 네트워크 시도 0건으로 끝났습니다. 계획과 달라진 점: (a) 다운로드 훅을 도구마다 두지 않고 공용 `fetchWithTimeout`(와 카탈로그 아카이브 다운로드)에서 manifest 의 URL 과 맞춰 대체해, 앞으로 생기는 GET 다운로드도 번들에 넣기만 하면 됩니다. (b) 원본 미러는 blob 없는 캐시가 아니라 태그마다 내용까지 받은 미러로 담았습니다 — 22개 태그가 37MB 라 패치 생성까지 폐쇄망에서 됩니다. (c) 저장소 템플릿(브랜치 기준)은 고정 지문이 없어 기본에서 빼고 `templates` 로 지정할 때만 담습니다. (d) 번들은 새(또는 빈) 디렉터리에만 임시 디렉터리를 거쳐 쓰고 실패하면 남기지 않습니다.
|
|
611
|
+
|
|
559
612
|
### v0.43.0 — CI·제출 형식 다변화: Jenkins·GitLab, SPDX
|
|
560
613
|
|
|
561
614
|
**목표**: 공공 사업의 빌드 서버는 GitHub Actions 보다 Jenkins·GitLab 이 흔하고, SBOM 제출 형식은 아직 특정되지 않아(가이드라인 1.0 은 SPDX·CycloneDX 를 모두 언급) SPDX 를 요구받을 수 있습니다. v0.39 의 게이트와 v0.40 의 점검을 그 환경까지 넓힙니다.
|
|
@@ -571,11 +624,14 @@ v0.40.0 까지 끝난 상태(2026-10-07, 도구 30종 + CLI 명령 8종, 테스
|
|
|
571
624
|
|
|
572
625
|
**완료 정의**: 도구 32종(변화 없음), README 「CI 에서 쓰기」 에 GitLab·Jenkins 예시와 「SBOM 제출 준비」 에 SPDX, `docs/design-cli.md` 플랫폼 절
|
|
573
626
|
|
|
627
|
+
**결과(2026-10-11) — 완료**: `src/ci-config.ts`(세 플랫폼이 같은 게이트 명령 목록 `supplyChainCommands` 를 씀)와 `src/spdx.ts`(`cdxToSpdx`·`spdxToCdx`). 실측: 공식 web 템플릿을 실제 Maven·cyclonedx-maven-plugin 으로 만든 SBOM(67 component, OSV 27건)을 SPDX 2.3 으로 바꾸면 패키지 68·관계 165 로 공식 spdx-spec v2.3 스키마를 통과하고, SPDX 를 점검한 결과가 CycloneDX 점검과 **component 67·최소 요소 7종의 요소별 충족 수(68/68 …)·판정 ready 까지 같으며** 둘을 비교하면 차이 0 입니다. 생성 `.gitlab-ci.yml` 은 maven·gradle·게이트 유무·환경 변수 조합 4가지 모두 GitLab 공식 CI 스키마(v19.4.1-ee 고정물)를 통과합니다. 계획과 달라진 점: (a) **SPDX 점검은 별도 규칙을 두지 않고** SPDX 를 내부 CycloneDX 모양으로 옮겨 같은 최소 요소·재판정·비교 코드를 그대로 씁니다 — 대응(공급자 = `PackageSupplier`/`PackageOriginator`, 의존관계 = 그 패키지가 주어인 `DEPENDS_ON`, 작성자 = `creators` 의 Person·Organization)은 `src/spdx.ts` 머리 주석과 「SBOM 제출 준비」 표에 있습니다. (b) "의존 없음"과 "모름"을 구분하려고 의존이 없는 패키지는 `DEPENDS_ON NONE`(SPDX 2.3 §11.1)으로 쓰고, `NOASSERTION` 은 모름으로 읽습니다. (c) 기준 판정(`egovframe:*`)과 OSV 결과를 SPDX 의 annotations·`SECURITY`/`advisory` externalRefs 로 옮겨, SPDX 로 낸 뒤에도 재판정의 "생성 이후 바뀐 판정"·"새로 알려진 취약점"이 동작합니다. (d) 생성 시각은 SPDX 필수 항목이라 원본에 없으면 변환 시각을 넣고 알립니다(이 경우만 판정이 달라질 수 있음). (e) 게이트의 `sbom-check --fail-on minimum` 은 공급자 단서(`supplier` 또는 pom `<organization>`)가 없으면 실패하므로 `supplier` 파라미터를 더하고 생성 응답이 미리 알립니다. (f) GitLab 은 JUnit 리포트와 `artifacts:reports:cyclonedx`, Jenkins 는 Linux·Windows 에이전트 공용 실행(`isUnix()` 로 `sh`/`bat`)을 넣었습니다. Jenkins 실제 실행 검증은 보류 항목으로 남깁니다.
|
|
628
|
+
|
|
574
629
|
### 보류·운영 항목
|
|
575
630
|
|
|
631
|
+
- **Jenkins 실행 검증**: 생성 `Jenkinsfile` 은 Declarative 구조만 단언합니다. 실제 Jenkins(컨테이너)에서 돌리는 통합 검증은 아직 없습니다.
|
|
576
632
|
- **브랜치 보호(소유자 1회)**: `main` 에 "Require status checks to pass"(gate 6 + integration)를 켜면 실패 상태 병합이 재발하지 않습니다. `gh api -X PUT repos/EricSeokgon/egovframe-scaffold-mcp/branches/main/protection --input protection.json`(`required_status_checks.contexts` 에 체크 이름 7개, `enforce_admins: false`, `required_pull_request_reviews: null`, `restrictions: null`).
|
|
577
633
|
- **Initializr upstream**: 최신 태그 `v5.0.6`(`84d3682`)과 `main`(`bc18641`) 모두 템플릿 pom 의 parent 가 여전히 5.0.0 입니다(공식 parent 최신 5.0.2). 기존 3건과 함께 upstream 이슈로 제출할 가치가 있습니다.
|
|
578
|
-
- **sbom-live
|
|
634
|
+
- **sbom-live 간헐 실패 — 원인 확인·해결(v0.43)**: CI 러너에서 cyclonedx-maven-plugin 출력에 `metadata.timestamp` 가 빠지는 경우가 있어(로컬에서는 재현 안 됨) 최소 요소 '생성 시각'이 비었습니다. v0.40 PR 의 첫 실패와 v0.43 PR 의 SPDX 판정 불일치(SPDX 는 생성 시각이 필수라 변환 시각이 들어감)가 같은 원인이었고, 이제 생성기가 비어 있으면 생성 시각을 넣고 알립니다.
|
|
579
635
|
- **기준 없음 잔여**: `xerces:xercesImpl` 은 공개 기준이 없어 그대로 둡니다.
|
|
580
636
|
- **응답 본문 영문화**: 평가서·점검 결과의 라벨·헤더 영문화(`--lang en`)는 계속 후순위입니다.
|
|
581
637
|
- **MCP 신기능**: `tasks`(장시간 도구의 비동기 실행)는 SDK 에서 실험 단계라 보류 — v0.41 리허설이 수 분 걸리는 첫 도구라 안정화되면 가장 먼저 적용합니다. `elicitInput` 은 dryRun 패턴으로 충분해 쓰지 않습니다.
|
|
@@ -884,6 +940,8 @@ v0.28.1 까지의 상태에서 다음 세 릴리스를 아래 순서로 진행
|
|
|
884
940
|
|
|
885
941
|
## 변경 이력
|
|
886
942
|
|
|
943
|
+
- **0.43.0** — CI·제출 형식 다변화: GitLab·Jenkins, SPDX(도구 32종 유지). (1) `generate_egovframe_ci` 에 `platform="github"|"gitlab"|"jenkins"`: `src/ci-config.ts` — `generateGitlabCi`(`.gitlab-ci.yml`, `maven:3.9-eclipse-temurin-<JDK>`·`eclipse-temurin:<JDK>` 이미지, 로컬 저장소 캐시, JUnit 리포트, `supply-chain` job 은 `needs: []`·Node 준비·`artifacts:reports:cyclonedx`)·`generateJenkinsfile`(Declarative — options·environment·`Build`/`SBOM`/`SBOM check`/`Assessment` 단계·`post { always { archiveArtifacts } }`, `isUnix()` 로 `sh`/`bat`), 세 플랫폼 공통 게이트 명령 `supplyChainCommands`(sbom → **`sbom-check --fail-on minimum`**(GitHub 게이트에도 추가) → assess), 새 파라미터 `supplier`(SBOM 공급자)·`npmRegistry`(`NPM_CONFIG_REGISTRY`)·`offlineBundle`(`EGOVFRAME_OFFLINE_BUNDLE`) — 모두 형식 제한으로 설정 파일 주입 차단, 공급자 단서가 없으면 게이트 실패 예고(`notes`). (2) SPDX 2.3: `src/spdx.ts` — `cdxToSpdx`(패키지·`DESCRIBES`·`DEPENDS_ON`(의존 없음 `NONE`)·purl/cpe/swid externalRefs·supplier/originator·creators·created·체크섬·선언 라이선스(`LicenseRef-` + `hasExtractedLicensingInfos`)·OSV 권고 `SECURITY`/`advisory`·`egovframe:*` annotations, serialNumber UUID 로 결정적 namespace)·`spdxToCdx`(점검용, `*_DEPENDENCY_OF` 뒤집기·`NOASSERTION` 은 모름). `generate_egovframe_sbom(bomFormat="spdx-json")`(기본 경로 `sbom/bom.spdx.json`, 최소 요소는 SPDX 를 되읽어 판정), `check_egovframe_sbom` 이 CycloneDX·SPDX 2.x 자동 판별(`document.format`, 형식이 다른 baseline 은 purl 로 비교, SPDX 의 `vex=true` 는 거부). CLI `sbom --bom-format spdx-json`. (3) 테스트: 신규 `test:spdx` 43단언(게이트, 공식 spdx-spec v2.3 스키마 고정물), `test:ci` 에 GitLab 공식 CI 스키마(gitlab v19.4.1-ee 고정물, devDependency `yaml`)·Jenkinsfile 구조·주입 거부, `test:sbom-live`(CI 통합)에 실제 Maven SBOM 의 SPDX 스키마·판정 일치, `test:sbom-check` 의 비 CycloneDX 거부 단언을 SPDX 3.0 등으로 갱신. (4) CI: integration job 의 Maven 이 원격 저장소 5xx(502 등)를 3초 간격 최대 5회 재시도(#53). (5) `generate_egovframe_sbom`: cyclonedx-maven-plugin 출력에 `metadata.timestamp` 가 없으면(CI 러너에서 실측) 생성 시각으로 채우고 알림 — v0.40 이후 간헐적이던 sbom-live 최소 요소 실패의 원인. `server.json` 0.43.0.
|
|
944
|
+
- **0.42.0** — 폐쇄망 오프라인 번들(도구 31 → 32종). (1) 새 도구 `prepare_egovframe_offline_bundle(outputDir, include=["osv","components","templates","origin"], templates?, dryRun=true, format)`: `src/offline-bundle.ts`·`src/offline-bundle-plan.ts` — OSV Maven 전체 덤프(`osv-vulnerabilities/Maven/all.zip`, 레코드 수·원본 갱신 시각 기록), 카탈로그 고정 커밋의 공통컴포넌트 아카이브(sha256·크기 검증), 템플릿(기본: 고정 지문이 있는 Initializr zip 12종, 저장소 템플릿은 지정 시 codeload zip), 공식 공통컴포넌트 태그 전부의 내용 포함 bare 미러(`git fetch --depth 1 +refs/tags/*`)를 임시 디렉터리에 받아 `bundle-manifest.json`(schemaVersion 1, 파일별 path·kind·url·sha256·bytes·fetchedAt)과 함께 새(또는 빈) 디렉터리로 옮김, 고정 지문 불일치·실패 시 무흔적. 도구 메타 비읽기·비파괴·openWorld, outputSchema(11종), 영문 설명, AGENTS.md 도구 목록. (2) `EGOVFRAME_OFFLINE_BUNDLE`: `fetchWithTimeout`(GET)과 카탈로그 아카이브 다운로드가 manifest 의 같은 URL 을 지문 검증 후 번들에서 돌려줌(변조 거부, 프로세스당 1회 검증), `defaultOsvQuery` 가 로컬 덤프로 판정(`buildOsvIndex`·`queryOsvIndex`·`inOsvRange`·`compareMavenVersions` — Maven ComparableVersion 요지, `versions` 목록 또는 ECOSYSTEM 범위, 철회 제외), `GitOriginSource` 가 번들 미러를 씀(`for-each-ref` 태그 목록, 원격 fetch 없음, 없는 태그 안내), OSV 를 쓴 결과(의존성 점검·SBOM 생성·SBOM 점검)에 스냅숏 기준일 노트와 30일 경고(`EGOVFRAME_BUNDLE_MAX_AGE_DAYS`). (3) `diagnose_egovframe_network` 가 실패 시 오프라인 번들 처방(bash·cmd·PowerShell)과 사용 중 표시, CLI `bundle`(`--write` 로만 받음, `--output-dir` 는 현재 디렉터리 기준), `server.json` 환경변수 `EGOVFRAME_OFFLINE_BUNDLE`(4종). (4) 테스트: 신규 `test:offline-bundle` 30단언(게이트)·`test:bundle-live`(CI 통합: 실제 번들, 로컬 OSV = 온라인, fetch 차단 상태의 생성·조립·재조립·SBOM 재점검), `registry` 환경변수 4종, `output-schemas`·`handshake` 32종·11종, `cli` 명령 10종. 설계: [docs/design-offline-bundle.md](docs/design-offline-bundle.md). (5) 런타임 의존성 `handlebars` 4.7.9 → 4.7.10(GHSA-xw65-4hp5-5hc7·GHSA-8r5x-fm3f-whwj·GHSA-p8wg-vrv2-v86f, `npm audit --omit=dev` 게이트). `server.json` 0.42.0.
|
|
887
945
|
- **0.41.0** — 전환 리허설(도구 30 → 31종). (1) 새 도구 `rehearse_egovframe_migration(projectDir, steps=["reassemble","migrate","verify","align-pom"], components?, sourceTag="auto", keepWorkspace=false, timeoutMs=900000, topN=20, format)`: `src/rehearse.ts` — 사본(`EGOVFRAME_CACHE_DIR/rehearsal`, 빌드 산출물·VCS·백업 제외, 작업 디렉터리가 프로젝트 안이면 거부)에서 재조립 → 전환 적용 → 컴파일(Maven 은 `-Dmaven.compiler.fork=true`·`JDK_JAVAC_OPTIONS=-Xmaxerrs 100000`) → `alignPomToReference`(공식 공통컴포넌트 고정 태그 pom 기준: parent 추가·교체, 누락 좌표 추가(test 제외), 버전·scope 정렬, parent 가 정의하는 속성의 프로젝트 재정의 삭제, 주석·dependencyManagement·plugin·profiles 제외, 멱등) → 컴파일. `analyzeErrors`(누락 패키지 — "package X does not exist"·symbol 의 package·파일 import 문으로 찾은 타입의 패키지, 연쇄 — 같은 파일·누락 패키지가 있는 파일이 선언한 타입의 멤버·Lombok 생성 멤버, 기타; 연쇄는 파일의 첫 누락 패키지에 귀속, 후보 좌표 `packageHint`, 기타 오류는 수동 항목·규칙과 연결, 디렉터리·파일 상위), 작업 목록(pom 맞춤이 없애는 오류 수 → 누락 패키지 → 파일), pom 패치(400줄 상한), 실행 전후 지문(`fingerprintTree`)으로 원본 불변 확인, 단계 실패는 기록하고 계속, 최근 결과를 `rehearsal/records/<경로 해시>.json` 에 저장. 도구 메타 비읽기·비파괴·멱등·openWorld, outputSchema(10종), 영문 설명, AGENTS.md 도구 목록. (2) 평가서 6절에 최근 리허설 실측(등급 산식과 별개), 맺음말의 재조립 안내를 `reassemble_egovframe_components`(전환 적용보다 먼저)로 정정. (3) CLI `rehearse`(지표 `errors`·`automation`·`aligned`·`files`·`unlinked`·`failedSteps`). (4) 수정: `parseBuildErrors` 가 Maven `[WARNING]`·javac 린트 경고(`[removal]` 등) 줄을 오류로 세던 문제와 fork 형식의 `error:` 접두, 4.x 의 `org.egovframe.rte` 좌표(버전 4.*)를 5.x 세대로 분류하던 문제(재조립 후보 태그가 5.x 로만 좁혀짐). `runBuild(extraArgs, env)`·`ResolvedCommand.env`, pom 에 소스 인코딩이 없으면 리허설 컴파일에 UTF-8. (5) 테스트: 신규 `test:rehearse` 42단언(게이트)·`test:rehearse-live`(CI 통합: 공식 v4.3.2 전체 트리 리허설 기대값 `catalog/migration-corpus.json` 의 `rehearsal`), `test:output-schemas` 54·`handshake` outputSchema 10종·`test:cli` 명령 9종. 설계: [docs/design-migration.md](docs/design-migration.md) 리허설 절. `server.json` 0.41.0.
|
|
888
946
|
- **0.40.0** — SBOM 운영: 최소 요소·비교·VEX(도구 29 → 30종). (1) 새 도구 `check_egovframe_sbom(projectDir, sbomPath="sbom/bom.cdx.json", baselinePath?, offline=true, vex=false, vexPath="sbom/vex.cdx.json", dryRun=false, format)`: `src/sbom-check.ts` — 최소 요소 7종(`catalog/sbom-rules.json`: 공급자·구성요소명·버전·고유식별자·의존관계·작성자·생성 시각, 출처 NTIA 2021·SW 공급망 보안 가이드라인 1.0)을 주 component 포함 component 마다 세어 `ready`/`needs-work`·빠진 component(최대 20)·힌트, purl 만으로 v0.34 분류기 재판정(SBOM 의 `egovframe:status` 와 다른 것)과 OSV 재조회(`newIds`·`goneIds`, SBOM 에 기록이 없으면 "미기록"으로 표시), `baselinePath` 비교(groupId:artifactId 기준 추가·제거·버전·판정 변화·새/사라진 취약점), `vex=true` 면 CycloneDX VEX(`analysis.state=in_triage`, `affects` 는 BOM-Link `urn:cdx:<serial>/<version>#<bom-ref>`, serial 이 없으면 bom-ref) — 기존 VEX 의 판단·임의 필드 보존, in_triage 항목은 affects 덧붙임, 판단 끝난 ID 의 새 영향은 별도 항목, 탐지되지 않는 ID 는 지우지 않고 `notDetected`, 변경 없으면 파일 그대로, 깨진 VEX 는 중단. SBOM 은 바꾸지 않고 VEX 만 transaction 으로 기록. 도구 메타 비읽기·비파괴·openWorld, outputSchema(9종), 영문 설명, AGENTS.md 도구 목록. (2) `generate_egovframe_sbom(supplier, author, componentName, componentVersion, fillSuppliers)`: `metadata.supplier`·주 component `supplier`·`metadata.authors`(기본 pom `<organization><name>`), `metadata.lifecycles`(build), 공급자 없는 component 를 공급자 표로 보완(`egovframe:supplierBasis=catalog`), 응답 `minimum` 요약. `enrichBom` 재실행이 `egovframe:status·basis·baseline` 만 갱신하도록(다른 `egovframe:*` 보존). (3) 평가서 5절에 최소 요소 판정·VEX 항목/상태/마지막 점검 시각. (4) CLI `sbom-check`(지표 `minimum`·`gaps`·`changed`·`vulnerabilities`·`newVulns`·`added`·`removed`·`versionChanged`·`diffVulns`·`triage`, `--write` → VEX, `--vex` 직접 지정 차단). (5) 테스트: 신규 `test:sbom-check` 54단언(게이트, 실제 플러그인 출력 고정물·CycloneDX 1.6.1 공식 스키마 검증 — devDependencies `ajv`·`ajv-formats`), `test:sbom` 41·`test:cli` 36·`test:assessment` 57·`test:output-schemas` 53 단언, `handshake` outputSchema 9종, `test:sbom-live` 에 실제 SBOM 최소 요소·보강·비교·OSV VEX·판단 보존. 설계: [docs/design-dependency-check.md](docs/design-dependency-check.md) SBOM 운영 절. `server.json` 0.40.0.
|
|
889
947
|
- **0.39.0** — CLI 모드 + CI 공급망 게이트(도구 29종 유지). (0) upstream 이 2026-10-07 `v5.0.7` 태그를 `3756ab2` → `7912e13` 으로 옮겨(README·권한 그룹·북마크 메뉴 컨트롤러·메뉴 이동 JSP 수정 3파일 추가) 카탈로그 고정 검증이 실패했으므로 컴포넌트 카탈로그(아카이브 sha256 `a1a4b9a7…`, 46,904,430 bytes, 6,604 files)와 전환 규칙의 `components.toCommit` 을 새 커밋으로 재고정했습니다(판정·코퍼스 기대값 변화 없음). (1) `src/cli.ts`: `npx egovframe-scaffold-mcp <assess|check|sbom|migrate|validate|diagnose|network> [옵션]` — 인자 없는 실행은 기존 stdio 서버(`index.ts` 분기), 명령은 같은 프로세스의 서버에 `InMemoryTransport` 로 붙은 클라이언트가 `tools/call`(입력 검증·허용 root·outputSchema 검증 동일). 옵션은 도구 파라미터 이름(kebab-case, `tools/list` JSON Schema 로 형 변환), 공통 `--project`·`--json`(structuredContent)·`--out`·`--step-summary`·`--fail-on`·`--write`, 쓰기 옵션 차단(`migrate --apply`·`sbom --dry-run` 등). `--fail-on` 식(`metric`·`metric>N`·`metric>=N`·`grade:C`, 명령별 지표), 종료 코드 0/2/3/64, 본문 stdout·한 줄 요약 stderr, `--help`·`--version`. (2) `generate_egovframe_ci(supplyChain, failOn="supplyChain:D", osv=true)`: SBOM → 평가서(`--step-summary`) → 아티팩트(`if: always()`) 게이트 job, 패키지 버전 고정, `failOn` 형식 제한(`CI_FAIL_ON_RE`, YAML 주입 차단). (3) `@modelcontextprotocol/sdk` 1.29 → 1.32.1. (4) 테스트: 신규 `test:cli` 32단언(게이트), `test:ci` 공급망 게이트·주입 거부, CI 통합에 생성 워크플로 `actionlint` 1.7.7 검사와 코퍼스 트리 CLI 평가서(job 요약). 설계: [docs/design-cli.md](docs/design-cli.md). `server.json` 0.39.0.
|
package/dist/agents-md.js
CHANGED
|
@@ -95,7 +95,7 @@ const T = {
|
|
|
95
95
|
"의존성 버전을 올릴 때는 `check_egovframe_dependencies` 로 공식 5.x parent 기준과 대조하고, parent 가 관리하는 좌표에는 `<version>` 을 적지 않습니다.",
|
|
96
96
|
],
|
|
97
97
|
tools: "## 사용할 수 있는 MCP 도구", toolsNote: `이 프로젝트는 \`egovframe-scaffold-mcp\`(v${SERVER_VERSION}) 로 관리할 수 있습니다. 진단·검증은 읽기 전용이고, 쓰기 도구는 dryRun 과 transaction(실패 시 복구)을 제공합니다.`,
|
|
98
|
-
toolRows: ["`diagnose_egovframe_project` · `validate_egovframe_project` · `generate_egovframe_report` — 진단·검증·리포트", "`add_egovframe_components` · `remove_egovframe_components` · `upgrade_egovframe_project` — 공통컴포넌트 수명주기", "`generate_egovframe_crud` · `generate_egovframe_config` · `generate_egovframe_ci` — 코드·설정·CI 생성", "`build_egovframe_project` · `test_egovframe_project` — 빌드·테스트 실행과 오류 구조화", "`rehearse_egovframe_migration` · `reassemble_egovframe_components` · `migrate_egovframe_project` — 5.x 전환(사본 리허설 → 재조립 → 적용)", "`check_egovframe_dependencies` — 의존성 점검", "`generate_egovframe_sbom` · `check_egovframe_sbom` — SBOM 생성·점검(최소 요소·이전 SBOM 비교·VEX)", "`diagnose_egovframe_network` — 다운로드 실패 시 네트워크
|
|
98
|
+
toolRows: ["`diagnose_egovframe_project` · `validate_egovframe_project` · `generate_egovframe_report` — 진단·검증·리포트", "`add_egovframe_components` · `remove_egovframe_components` · `upgrade_egovframe_project` — 공통컴포넌트 수명주기", "`generate_egovframe_crud` · `generate_egovframe_config` · `generate_egovframe_ci` — 코드·설정·CI 생성(GitHub·GitLab·Jenkins)", "`build_egovframe_project` · `test_egovframe_project` — 빌드·테스트 실행과 오류 구조화", "`rehearse_egovframe_migration` · `reassemble_egovframe_components` · `migrate_egovframe_project` — 5.x 전환(사본 리허설 → 재조립 → 적용)", "`check_egovframe_dependencies` — 의존성 점검", "`generate_egovframe_sbom` · `check_egovframe_sbom` — SBOM 생성·점검(최소 요소·이전 SBOM 비교·VEX)", "`diagnose_egovframe_network` · `prepare_egovframe_offline_bundle` — 다운로드 실패 시 네트워크 진단, 폐쇄망용 오프라인 번들"],
|
|
99
99
|
generated: (d) => `_생성: ${d} · egovframe-scaffold-mcp generate_agents_md. 프로젝트가 바뀌면 다시 생성하세요._`,
|
|
100
100
|
backups: (dirs) => `현재 백업 디렉터리가 있습니다: ${dirs.join(", ")}`,
|
|
101
101
|
},
|
|
@@ -121,7 +121,7 @@ const T = {
|
|
|
121
121
|
"When bumping dependency versions, compare against the official 5.x parent baseline with `check_egovframe_dependencies`; do not write `<version>` for coordinates the parent manages.",
|
|
122
122
|
],
|
|
123
123
|
tools: "## Available MCP tools", toolsNote: `This project can be managed with \`egovframe-scaffold-mcp\` (v${SERVER_VERSION}). Diagnosis and validation are read-only; write tools offer dryRun and transactions (rollback on failure).`,
|
|
124
|
-
toolRows: ["`diagnose_egovframe_project` · `validate_egovframe_project` · `generate_egovframe_report` — diagnosis, validation, report", "`add_egovframe_components` · `remove_egovframe_components` · `upgrade_egovframe_project` — common-component lifecycle", "`generate_egovframe_crud` · `generate_egovframe_config` · `generate_egovframe_ci` — code, configuration and CI generation", "`build_egovframe_project` · `test_egovframe_project` — build/test execution with structured errors", "`rehearse_egovframe_migration` · `reassemble_egovframe_components` · `migrate_egovframe_project` — 5.x migration (rehearse on a copy, reassemble, apply)", "`check_egovframe_dependencies` — dependency check", "`generate_egovframe_sbom` · `check_egovframe_sbom` — SBOM generation and checks (minimum elements, diff, VEX)", "`diagnose_egovframe_network` — network diagnosis when downloads fail"],
|
|
124
|
+
toolRows: ["`diagnose_egovframe_project` · `validate_egovframe_project` · `generate_egovframe_report` — diagnosis, validation, report", "`add_egovframe_components` · `remove_egovframe_components` · `upgrade_egovframe_project` — common-component lifecycle", "`generate_egovframe_crud` · `generate_egovframe_config` · `generate_egovframe_ci` — code, configuration and CI generation (GitHub, GitLab, Jenkins)", "`build_egovframe_project` · `test_egovframe_project` — build/test execution with structured errors", "`rehearse_egovframe_migration` · `reassemble_egovframe_components` · `migrate_egovframe_project` — 5.x migration (rehearse on a copy, reassemble, apply)", "`check_egovframe_dependencies` — dependency check", "`generate_egovframe_sbom` · `check_egovframe_sbom` — SBOM generation and checks (minimum elements, diff, VEX)", "`diagnose_egovframe_network` · `prepare_egovframe_offline_bundle` — network diagnosis when downloads fail, offline bundle for air-gapped networks"],
|
|
125
125
|
generated: (d) => `_Generated ${d} by egovframe-scaffold-mcp generate_agents_md. Regenerate when the project changes._`,
|
|
126
126
|
backups: (dirs) => `Backup directories currently present: ${dirs.join(", ")}`,
|
|
127
127
|
},
|
package/dist/catalog-sync.js
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { bundleResponseFor } from "./offline-bundle.js";
|
|
1
2
|
import AdmZip from "adm-zip";
|
|
2
3
|
import { createHash } from "node:crypto";
|
|
3
4
|
import * as fs from "node:fs";
|
|
@@ -16,6 +17,10 @@ function repositoryOf(source) {
|
|
|
16
17
|
return repository;
|
|
17
18
|
}
|
|
18
19
|
async function fetchWithTimeout(url, timeoutMs) {
|
|
20
|
+
// v0.42: 오프라인 번들에 고정 아카이브가 있으면 지문 검증 후 그 파일을 쓴다
|
|
21
|
+
const bundled = bundleResponseFor(url);
|
|
22
|
+
if (bundled)
|
|
23
|
+
return bundled;
|
|
19
24
|
const controller = new AbortController();
|
|
20
25
|
const timer = setTimeout(() => controller.abort(), timeoutMs);
|
|
21
26
|
// api.github.com 은 비인증 60회/시간(IP 기준) — CI 러너처럼 IP 를 공유하는 곳에서 403 이 난다. GITHUB_TOKEN 이 있으면 쓴다(catalog-drift 와 같은 규칙).
|