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

identity-public-keys

Maintain user-owned GPG and SSH public-key parsing, profile API registration, identity database persistence, format compatibility, and maintained OpenPGP dependencies. Excludes portal signing-key publication and admin private-key export.

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

설치 방법 보기

포함된 파일(2)

  • SKILL.md4.5 KB
  • agents/openai.yaml332 B

SKILL.md(원문)

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

Identity Public Keys

Ownership and Input Boundary

pkg/identity/public_key.go owns NewPublicKey and format parsing. User.AddPublicKey rejects duplicate keys; Database.AddPublicKey checks the username/email identity pair under its lock and commits the identity data. pkg/ids/local/store.go and authenticator.go dispatch AddKeyGPG/AddKeySSH. These user-owned public keys are distinct from JWT signing keys in pkg/kms.

The portal profile API calls AddUserGPGKey in pkg/authn/api_add_user_gpg_key.go. handle_api_profile.go requires a valid authenticated session, an allowed user/admin role, and a local identity store before dispatching a parsed operation. Its request body limit is one MiB. The backend identity comes from the authenticated session; request fields must not choose another user's inventory. Direct Go callers of the identity database own authorization and input-size limits; the database itself is not an HTTP authorization boundary.

OpenPGP Compatibility

Use the maintained github.com/ProtonMail/go-crypto/openpgp package pinned by go.mod; do not reintroduce golang.org/x/crypto/openpgp. The latter import predates v1.1.41 and is covered by GO-2026-5932, which lists no fixed version of that unmaintained package. Other x/crypto packages remain dependencies. Review the current advisory and maintained package guidance for future changes. Check the replacement's transitive dependencies too: ProtonMail v1.4.1 selects CIRCL v1.6.2, so this repository pins CIRCL v1.6.3 to include the fix for GO-2026-4550. A maintained direct dependency alone does not establish that its selected dependency graph is current.

The repository uses ReadArmoredKeyRing to inspect public-key metadata. It does not call OpenPGP message decryption, encryption, signing, or detached signature verification. A broad advisory or interface-based scan trace does not establish an authentication bypass or an exploitable cryptographic operation. An authenticated user can supply parsing input through the profile API, and library callers may supply it directly; retain strict errors and bounded HTTP input. Package maintenance is necessary without claiming an exploit.

Preserve the actual public format contract:

  • Accepted dispatches are RSA public PEM, ssh-rsa authorized-key text, and ASCII-armored PGP PUBLIC KEY BLOCK data with matching boundaries.
  • OpenPGP parsing requires one entity, a primary public key, and identities. Keep the existing RSA/DSA/ECDH/ECDSA algorithm policy, key ID, lowercase fingerprint, comment, normalized payload, and persisted fields stable.
  • Raw binary OpenPGP and private-key armor are not accepted by NewPublicKey. Do not describe a dependency's broader API as existing repository support.
  • This path records a public key; it does not establish external trust, ownership, revocation status, or suitability for a new cryptographic use. Preserve historical fixture import behavior, including older public keys.

Persisted PublicKey data is an identity record, not directive configuration; the migration adds no new configuration fields or parser grammar. Existing parser-package requirements apply if configurable policy is introduced later.

Validation

pkg/identity/public_key_pgp_test.go checks the legacy armored fixture's exact metadata and rejects malformed armor, invalid packets, multiple entities, private armor, and unsupported binary input. Retain existing RSA/SSH tests. server_public_key_e2e_test.go uses the public root server and real TLS login for profile upload/list, duplicate rejection, database reopen, runtime reload, and another user's empty inventory. Do not inject an authenticated user into that fixture or replace it with an in-memory parser-only test.

make test TEST_DIR='./pkg/identity .' TEST='PublicKey|PGP' COVERAGE_DIR=.coverage/identity-public-keys
make ci-check

Run a versioned vulnerability scan after dependency changes, using the selected patched Go build toolchain. Separate inherited dependency findings from newly introduced code defects, and retain the scanner output and format compatibility evidence. Never log uploaded key payloads or unrelated identity credentials.

리뷰

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

댓글

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

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

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

0 / 1,000자

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

같은 저장소의 스킬

authdb

무료

Maintain the standalone cmd/authdb server, pkg/httpserver listener and portal routing, HTTP configuration parser, TLS, shutdown, executable tests, and deployment guidance. Use authdbctl for the management client.

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

greenpau/go-authcrunch602026년 10월 20일 업데이트

authdbctl

무료

Maintain cmd/authdbctl commands, flags, configuration, terminal input, management retries, output, and executable E2E tests. Use authentication-client for the reusable portal login protocol.

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

greenpau/go-authcrunch602026년 10월 20일 업데이트

Maintain or embed pkg/authclient for portal login, password/TOTP and API-key authentication, native credential transport, configuration parsing, and credential files. Covers authdbctl login wiring; management commands and the admin API have separate owners.

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

greenpau/go-authcrunch602026년 10월 20일 업데이트

Maintain conditional authentication challenge policies, reusable authchal and user-transform FromDirectives parsers, safe claim substitution, GitHub ID/organization transforms, registered-factor inventory, passwordless WebAuthn selection, verified AMR access claims, and policy revalidation across portal login, refresh, OIDC, and direct authentication.

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

greenpau/go-authcrunch602026년 10월 20일 업데이트

Maintain portal cookie configuration, reusable cookie directive parsing, common prefixes and explicit names, domain attributes, factory issuance/deletion, and cookie interoperability with OIDC, refresh, OAuth, and gatekeepers.

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

greenpau/go-authcrunch602026년 10월 20일 업데이트

Maintain optional cross-device portal login, its directive parser, QR and polling UI, approving-browser binding, single-use transfers, MFA and provider evidence, logout invalidation, and TLS/browser tests.

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

greenpau/go-authcrunch602026년 10월 20일 업데이트

greenpau의 스킬 모두 보기

이 스킬의 문제 신고