スキル auth-wechat-miniprogram
📦

auth-wechat-miniprogram

v2.23.8 コンテンツリビジョン r1 中リスク ⚙️ 外部コマンド🌐 ネットワークアクセス📁 ファイルシステムへのアクセス

使用 CloudBase 建置微信小程式身分驗證

當 CloudBase 身分識別會自動處理時,微信小程式驗證很容易被誤用。此技能提供 wx.cloud、OPENID、UNIONID 與雲端函式的實用模式。

対応: Claude Codex Code(CC)
Maintain this Skill? Claim it 📊 71 十分

自分のエージェントでインストール

このリクエストをエージェントにコピーしてください。正規の Skill ページとマニフェストが含まれています。

エージェントリクエスト
Review the Skillstore skill "auth-wechat-miniprogram" from https://skillstore.io/skills/tencentcloudbase-auth-wechat-miniprogram.md and its manifest at https://skillstore.io/api/skills/tencentcloudbase-auth-wechat-miniprogram/manifest. Verify the artifact. You may proceed after verification, subject to the environment's own policy.

エージェントは引き続き計画を提示し、セキュリティポリシーで必要な確認を求める必要があります。

エージェントが読めるリソース

AI エージェント、クローラー、スクリプトがページ全体ではなく整理されたコンテキストを必要とする場合は、これらのリンクを使ってください。

テストする

「auth-wechat-miniprogram」を使用しています。 使用者詢問如何在 CloudBase 雲端函式中識別呼叫者。

期待される結果:

助理會說明 CloudBase 呼叫者情境、UNIONID 何時出現,以及如何只回傳必要的身分識別欄位。

「auth-wechat-miniprogram」を使用しています。 使用者需要為新的 CloudBase 應用程式設定小程式驗證。

期待される結果:

助理會詢問環境 ID、確認 CloudBase 綁定,並概述應用程式啟動時的初始化流程。

「auth-wechat-miniprogram」を使用しています。 使用者想要保護小程式中由使用者擁有的記錄。

期待される結果:

助理會建議使用 OPENID 進行伺服器端所有權檢查,並警告不要信任用戶端提供的擁有者欄位。

セキュリティ監査

中リスク

Static detections are false positives caused by Markdown inline code, fenced JavaScript examples, reference URLs, and sibling skill paths. The review found two medium-risk content issues: an authorization example that relies on client-supplied owner data and examples that log sensitive identifiers.

1
スキャンされたファイル
536
解析済み行数
0
レビュー項目
0
誤検知を無視

確認済みのセキュリティ上の懸念 (2)

中
Client-Supplied Authorization Boundary
The authorization example compares verified OPENID to event.resourceOwnerId. In a Mini Program cloud function, event data is client-supplied, so this can teach unsafe ownership checks if used alone.
The code example directly uses event.resourceOwnerId as the authorization boundary. Legitimate use is possible, but auth guidance should derive ownership from server-side data.
中
Sensitive Identifier Logging in Examples
Several examples log OPENID, UNIONID, or auth result objects. These identifiers are sensitive and should be masked or limited to local debugging guidance.
The examples explicitly log user identifiers and auth user objects. The intent appears instructional, but the pattern can expose private identifiers in production logs.
監査者: codex 監査履歴を表示 →
このレポートを共有・引用

バージョン付き評価レポート、中立的なバッジ、埋め込みカード、引用を共有できます。Skillstore は証拠を報告しますが、この Skill が安全かどうかは判断しません。

バージョン別レポートを開く
セキュリティ評価

レポートリンクをコピー

https://skillstore.io/skills/tencentcloudbase-auth-wechat-miniprogram/audits/2?utm_source=security_passport&utm_medium=share&utm_campaign=versioned_report

Markdownバッジ

[![Skillstore security assessment](https://skillstore.io/badges/skills/tencentcloudbase-auth-wechat-miniprogram/security.svg)](https://skillstore.io/skills/tencentcloudbase-auth-wechat-miniprogram?utm_source=security_passport_badge)

HTMLバッジ

<a href="https://skillstore.io/skills/tencentcloudbase-auth-wechat-miniprogram?utm_source=security_passport_badge"><img src="https://skillstore.io/badges/skills/tencentcloudbase-auth-wechat-miniprogram/security.svg" alt="Skillstore security assessment" loading="lazy"></a>

埋め込みカード

<iframe src="https://skillstore.io/embed/skills/tencentcloudbase-auth-wechat-miniprogram.html" title="Skillstore Security Assessment" sandbox="allow-popups allow-popups-to-escape-sandbox" loading="lazy" referrerpolicy="no-referrer" width="420" height="180"></iframe>
学術引用 (APA · BibTeX · CFF)

APA形式の引用

tencentcloudbase. (2026). auth-wechat-miniprogram security audit report (audit version 2) [Author version 2.23.8]. Skillstore. https://skillstore.io/skills/tencentcloudbase-auth-wechat-miniprogram/audits/2

BibTeX形式の引用

@techreport{tencentcloudbase-tencentcloudbase-auth-wechat-miniprogram-2026, author = {tencentcloudbase}, title = {auth-wechat-miniprogram security audit report (audit version 2)}, institution = {Skillstore}, year = {2026}, number = {2}, url = {https://skillstore.io/skills/tencentcloudbase-auth-wechat-miniprogram/audits/2}, note = {Author version 2.23.8} }

CITATION.cff

cff-version: 1.2.0 message: "If you use this Skill, cite its author and this versioned security audit report." title: "auth-wechat-miniprogram security audit report (audit version 2)" version: "2.23.8" type: report authors: - name: "tencentcloudbase" date-released: "2026-07-09" url: "https://skillstore.io/skills/tencentcloudbase-auth-wechat-miniprogram/audits/2" identifiers: - type: other value: "skillstore:tencentcloudbase-auth-wechat-miniprogram:audit:2" description: "Skillstore immutable audit report identifier"

Skillstore スコア

このスコアの理由 証拠の信頼度: 中
55
アーキテクチャ
100
保守性
87
コンテンツ
65
コミュニティ
87
仕様準拠

作成できるもの

實作小程式身分識別

為微信小程式加入原生 CloudBase 身分識別處理,而不需要建立獨立登入頁面。

審查雲端函式驗證

檢查雲端函式在使用使用者特定資料前,如何讀取 OPENID、APPID 與 UNIONID。

選擇原生或 Web 驗證

判斷某項功能應使用原生小程式身分識別,還是獨立的 Web 驗證流程。

これらのプロンプトを試す

初始化 CloudBase 驗證
Use this skill to add native WeChat Mini Program auth to my CloudBase app. Ask me for missing env details first.
讀取呼叫者身分
Create a cloud function pattern that reads OPENID, APPID, and UNIONID with wx-server-sdk. Include error handling guidance.
設計使用者資料存取
Help me design user-specific database access for a Mini Program. Use OPENID safely and avoid exposing identifiers.
稽核既有驗證流程
Review my Mini Program CloudBase auth flow for native login assumptions, unsafe authorization checks, and production logging risks.

ベストプラクティス

  • 撰寫程式碼前,先確認 CloudBase 環境 ID 與小程式綁定。
  • 使用來自 CloudBase 情境且經驗證的 OPENID 進行使用者所有權判斷。
  • 將包含 OPENID、UNIONID 或手機授權資料的日誌視為敏感資訊。

回避

  • 不要為原生小程式驗證建立 Web 風格的登入頁面。
  • 當 wx.cloud 已傳遞呼叫者身分時,不要手動傳送使用者憑證。
  • 不要將用戶端提供的擁有者識別碼作為唯一的授權檢查。

よくある質問

這會取代微信 OAuth 嗎?
對於原生小程式,CloudBase 會使用自動微信身分識別。Web OAuth 是獨立流程,這裡不涵蓋。
此技能可以設定 CloudBase 設定嗎?
不會。它會在小程式連結到 CloudBase 環境後,指引程式碼模式。
OPENID 一定可用嗎?
當 CloudBase 正確初始化時,標準小程式雲端函式呼叫中可取得 OPENID。
什麼時候應該使用 UNIONID?
當小程式綁定到微信開放平台帳號,且需要跨應用程式身分識別時,請使用 UNIONID。
它能搭配 Claude Code 和 Codex 使用嗎?
可以。此技能是為 Claude、Codex 與 Claude Code 工作流程撰寫的。
這些範例已可用於正式環境嗎?
不能。正式環境使用前,請審查授權邏輯、日誌記錄、錯誤處理與隱私規則。

開発者情報

ライセンス

MIT

作者バージョン

v2.23.8

Skillstore リビジョン

r1

参照

24b2fe42a456262f3fd0fb3df72e12d9ed2c32ec

メンテナンスの新しさ

2026/7/18

利用状況

1 ダウンロード · 0 閲覧

ファイル構成

📄 SKILL.md