본문으로 건너뛰기
cccskills
무료GitHub에 공개

ssh-connection-import

Implement and debug onetcli SSH connection importers that read OpenSSH config and known_hosts. Trace why previews return no records, check candidate file access and manifests, and match serialized authentication data to the host protocol’s expected JSON shape.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

원문원문 설명 보기

Use when implementing or debugging onetcli SSH connection importers, including OpenSSH config, known_hosts, candidate file manifests, local composite installs, SSH auth_method JSON decode errors such as unknown variant kind, or preview scans that show available sources but return zero records.

feigeCode/navop스타 1,941(GitHub 1,941 + cccskills 0)

실행 점수 미검증

설치 방법 보기

이럴 때 유용합니다

  • Adding OpenSSH config import support
  • Using known_hosts to discover SSH hosts
  • Debugging previews that show sources but no records
  • Fixing SSH authentication JSON decode errors

포함된 파일(4)

  • SKILL.md4.8 KB
  • agents/openai.yaml197 B
  • references/openssh-sources.md2.6 KB
  • references/ssh-protocol-debugging.md2.5 KB

SKILL.md(원문)

설치하기 전에 에이전트에게 전달되는 지시 내용을 확인할 수 있습니다.

SSH Connection Import

Overview

Build and debug SSH importers against the host protocol first. Most failures are not parsing failures; they are mismatches between manifest visibility, candidate file access, WASM output JSON, and connection-import-protocol decode rules.

For shared WASM component structure, manifests, packaging, and host runtime work, also use connection-import-wasm.

References

NeedReference
OpenSSH config and known_hosts parsing rulesOpenSSH Sources
SSH protocol JSON, auth methods, and preview failuresSSH Protocol Debugging

Protocol Contract

Inspect the host protocol before defining extension structs:

  • Host model: ../onetcli/crates/connection-import-protocol/src/model.rs
  • Importer output must serialize to the host's serde shape, not a local convenience shape.

For SSH auth, match SshImportAuthMethod with #[serde(rename_all = "snake_case")]:

VariantJSON shape
AutoPublicKey"auto_public_key"
Agent"agent"
PrivateKey{"private_key":{"key_path":"...","passphrase":null}}
Password{"password":{"password":null}} or an omitted secret when not importing passwords

Never emit {"kind":"auto_public_key"}. The host error unknown variant kind, expected one of password, private_key, private_key_material, agent, auto_public_key means the importer used internally tagged JSON that the host protocol does not accept.

Add a focused serialization test for each auth variant the importer emits:

let value = serde_json::to_value(&record).unwrap();
assert_eq!(value["ssh"]["auth_method"], "auto_public_key");

OpenSSH Sources

Declare platform candidates and fs:read:* permissions for both primary config and fallback discovery:

SourcemacOS/LinuxWindows
OpenSSH config~/.ssh/config%USERPROFILE%/.ssh/config
known hosts fallback~/.ssh/known_hosts%USERPROFILE%/.ssh/known_hosts

Use known_hosts only as host discovery. It rarely contains username or auth metadata, so emit host-only records with empty username, parsed port, and AutoPublicKey.

Parsing rules for known_hosts:

  • Parse plain hosts, comma-separated aliases, and bracketed ports like [example.com]:2222.
  • Skip hashed hosts starting with |, wildcard or negated patterns, and marker lines such as @cert-authority.
  • Ignore key material after the host pattern column.
  • See OpenSSH Sources before extending parser behavior.

Debug Flow

When the UI shows the source as available but OpenSSH returns no rows, trace the full path:

  1. Confirm the installed composite manifest contributes the importer and the current platform.
  2. Confirm each candidate file path expands correctly (~/..., %USERPROFILE%/...) and has matching fs:read:* permission.
  3. Confirm the file exists on the user's machine. ~/.ssh/config may be absent while ~/.ssh/known_hosts exists.
  4. Run importer unit tests for parser behavior and serialized JSON shape.
  5. Check host logs for connection import preview failed. Decode errors mean the source was read and the WASM component returned JSON, but the host rejected the protocol shape.

Treat "可导入" or "available" in the UI as manifest/source visibility only. It does not prove preview records decoded successfully.

Local Packaging

Verify and install the composite extension before host UI testing:

rtk cargo test -p openssh_config_importer_wasm
rtk cargo build --release -p openssh_config_importer_wasm --target wasm32-wasip2
rtk node scripts/release-driver.mjs openssh-config-importer 0.1.0 --target universal --artifact-dir /tmp/onetcli-composite-local/openssh-config

The local install target is:

~/.config/one-hub/extensions/composite/com.onetcli.importer.openssh-config

The installed folder must contain extension.json and wasm/openssh_config_importer_wasm.wasm.

Common Mistakes

MistakeFix
Defining SSH auth as { kind, ... }Serialize exactly like connection-import-protocol::SshImportAuthMethod.
Only scanning ~/.ssh/configAdd known_hosts fallback because many local machines have no config file.
Treating known_hosts aliases as full configsEmit conservative host-only records and skip ambiguous patterns.
Debugging only extension code after a UI zero-row resultInspect host decode logs and candidate file reads.

리뷰

아직 리뷰가 없습니다. 사용해 본 소감을 남겨 주세요.

댓글

로그인 없이 쓸 수 있습니다. 사용 후기, 질문, 작동하지 않은 환경 등을 편하게 남겨 주세요.

아직 댓글이 없습니다. 첫 댓글을 남겨 보세요.

보내면 바로 공개됩니다. 이메일 주소나 전화번호 같은 개인 정보는 쓰지 마세요. URL은 2개까지입니다.

0 / 1,000자

이 양식은 reCAPTCHA로 보호되며 Google 개인정보처리방침 및 서비스 약관이 적용됩니다.

같은 저장소의 스킬

Implement and debug onetcli connection importers packaged as WebAssembly components. The skill covers parsing application settings, manifests and packaging, host integration, local visibility, password handling, and import preview issues.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

  • Adding an importer for a database application
  • Debugging a WASM importer that is not listed
  • Packaging and installing a composite extension
feigeCode/navop1.9천2026년 10월 26일 업데이트

gpui

무료

Use this skill while building or maintaining GPUI applications. It provides focused references for framework APIs and patterns, including keybindings, async tasks, state, events, layout, focus, custom elements, and tests.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

  • Finding the right GPUI API for a feature
  • Implementing keyboard actions and focus navigation
  • Managing entities, events, or global state
feigeCode/navop1.9천2026년 10월 26일 업데이트

Build GPUI interfaces with gpui-component by choosing suitable controls, handling component state and themes, and following its design and coding guides. The references also cover layout, interaction states, interface copy, and application structure.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

  • Choosing a component for a UI need
  • Setting up gpui-component in a GPUI app
  • Handling component state and theming
feigeCode/navop1.9천2026년 10월 26일 업데이트

Design, implement, review, or debug onetcli IPC database drivers. Work from the `driver.json` manifest and JSON-RPC protocol contract through schema metadata, SQL-building methods, import and export, tests, and packaging, with guidance that applies across implementation languages.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

  • Creating or reviewing an onetcli IPC database driver
  • Defining driver.json methods and capabilities
  • Implementing schema metadata and DDL builders
feigeCode/navop1.9천2026년 10월 26일 업데이트

navop

무료

Use the Navop CLI to discover and operate resources exposed by a running Navop desktop app. The skill checks live tools, permissions, and schemas before commands, then follows Navop’s approval decisions for operations.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

  • Checking which Navop tools are currently available
  • Inspecting a tool’s live schema before using it
  • Running a supported read or write operation
feigeCode/navop1.9천2026년 10월 26일 업데이트

Prepare and review bilingual Chinese and English release notes for Navop. Maintain `CHANGELOG.md` as the source of truth, then check that tagged entries provide consistent content for GitHub Releases and the R2 updater manifest when a release is published or synchronized.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

  • Drafting bilingual notes for a Navop version
  • Reviewing a CHANGELOG.md release entry
  • Checking release notes before creating a version tag
feigeCode/navop1.9천2026년 10월 26일 업데이트

feigeCode의 스킬 모두 보기

이 스킬의 문제 신고