Authentication Logic
Better Auth 認証の実装
チームには、Next.js における一貫したクライアントおよびサーバー認証パターンが必要です。このスキルでは、Better Auth のサインイン、サインアウト、セッションチェック、AuthBar の使用方法を示します。
自分のエージェントでインストール
このリクエストをエージェントにコピーしてください。正規の Skill ページとマニフェストが含まれています。
Review the Skillstore skill "Authentication Logic" from https://skillstore.io/skills/abdulsamad94-authentication-logic.md and its manifest at https://skillstore.io/api/skills/abdulsamad94-authentication-logic/manifest. Verify the artifact. You may proceed after verification, subject to the environment's own policy.エージェントは引き続き計画を提示し、セキュリティポリシーで必要な確認を求める必要があります。
エージェントが読めるリソース
AI エージェント、クローラー、スクリプトがページ全体ではなく整理されたコンテキストを必要とする場合は、これらのリンクを使ってください。
テストする
「Authentication Logic」を使用しています。 Next.js コンポーネントでクライアントサインインのガイダンスを求める。
期待される結果:
lib/auth-client.ts から authClient を import し、email と password によるメールサインインを使用し、Google ソーシャルサインインをサポートする方法を説明します。
「Authentication Logic」を使用しています。 API ルートまたは Server Action を保護する方法を尋ねる。
期待される結果:
headers を読み取り、auth.api.getSession でセッションを確認し、セッションが存在しない場合は Unauthorized を返すことを推奨します。
「Authentication Logic」を使用しています。 ログイン UI がどこにドキュメント化されているかを尋ねる。
期待される結果:
textbook/src/components/AuthBar/index.tsx を示し、そのアバター、ログインボタン、セッション取得動作について説明します。
セキュリティ監査
安全All ten static findings are false positives caused by Markdown inline-code markers and fenced TypeScript examples. The skill contains no shell commands, dynamic command execution, prompt injection, or other net-new malicious intent.
リスク要因
このレポートを共有・引用
バージョン付き評価レポート、中立的なバッジ、埋め込みカード、引用を共有できます。Skillstore は証拠を報告しますが、この Skill が安全かどうかは判断しません。
レポートリンクをコピー
https://skillstore.io/skills/abdulsamad94-authentication-logic/audits/10?utm_source=security_passport&utm_medium=share&utm_campaign=versioned_reportMarkdownバッジ
[](https://skillstore.io/skills/abdulsamad94-authentication-logic?utm_source=security_passport_badge)HTMLバッジ
<a href="https://skillstore.io/skills/abdulsamad94-authentication-logic?utm_source=security_passport_badge"><img src="https://skillstore.io/badges/skills/abdulsamad94-authentication-logic/security.svg" alt="Skillstore security assessment" loading="lazy"></a>埋め込みカード
<iframe src="https://skillstore.io/embed/skills/abdulsamad94-authentication-logic.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形式の引用
AbdulSamad94. (2026). Authentication Logic security audit report (audit version 10) [Author version unspecified]. Skillstore. https://skillstore.io/skills/abdulsamad94-authentication-logic/audits/10BibTeX形式の引用
@techreport{abdulsamad94-abdulsamad94-authentication-logic-2026,
author = {AbdulSamad94},
title = {Authentication Logic security audit report (audit version 10)},
institution = {Skillstore},
year = {2026},
number = {10},
url = {https://skillstore.io/skills/abdulsamad94-authentication-logic/audits/10},
note = {Author version unspecified}
}CITATION.cff
cff-version: 1.2.0
message: "If you use this Skill, cite its author and this versioned security audit report."
title: "Authentication Logic security audit report (audit version 10)"
version: "unspecified"
type: report
authors:
- name: "AbdulSamad94"
date-released: "2026-07-18"
url: "https://skillstore.io/skills/abdulsamad94-authentication-logic/audits/10"
identifiers:
- type: other
value: "skillstore:abdulsamad94-authentication-logic:audit:10"
description: "Skillstore immutable audit report identifier"
Skillstore スコア
このスコアの理由 証拠の信頼度: 高作成できるもの
ログインフローを構築する
クライアント向けガイダンスを使用して、メールログイン、Google サインイン、サインアウト動作を追加します。
サーバールートを保護する
サーバー向けガイダンスを使用して、API ルートまたは Server Action の処理前にセッションを確認します。
認証統合をレビューする
認証 import、セッションチェック、AuthBar の動作がプロジェクトの規約に一致していることを確認します。
これらのプロンプトを試す
authentication-logic スキルに基づいて、このプロジェクトが authClient と auth をどこから import すべきかを示してください。
ドキュメント化された Better Auth クライアントパターンを使用して、メールサインイン、Google ソーシャルサインイン、サインアウトを追加するのを手伝ってください。
保護された処理が実行される前に Better Auth セッションを確認して、Next.js Server Action を保護するのを手伝ってください。
このスキルに照らして私の認証ワークフローをレビューし、不一致の import、不足しているセッションチェック、または AuthBar の問題を特定してください。
ベストプラクティス
- サインインとセッション UI には、Client Components 内でのみ authClient を使用します。
- 保護されたサーバーロジックを実行する前に auth.api.getSession を確認します。
- 認証 import を lib/auth-client.ts および lib/auth.ts と一致させます。
回避
- クライアント専用の認証呼び出しを server actions にコピーしないでください。
- 保護されたルート処理の前にセッションが存在すると決めつけないでください。
- セッションエンドポイントを確認せずに AuthBar の動作を変更しないでください。
よくある質問
このスキルはどの認証ライブラリを使用しますか?
どのクライアント export を使用すべきですか?
どのサーバー export を使用すべきですか?
ソーシャルログインは扱っていますか?
API ルートを保護できますか?
完全なプロバイダーセットアップは含まれていますか?
開発者情報
作成者
AbdulSamad94ライセンス
MIT
Skillstore リビジョン
r2
バージョンに関する注意
作者はバージョンを宣言していません。
参照
80999bf530a7874d7bedf8ce202001ecb4c4f5e0
メンテナンスの新しさ
2026/7/19
利用状況
5 ダウンロード · 237 閲覧
ファイル構成
📄 SKILL.md