# Entra ID の証明書ベース認証

証明書ベースの認証は、Entra ID リソースにアクセスするための強力なセキュリティ代替手段を提供します。この記事では、証明書管理を簡素化するために証明機関として SCEPman を利用し、この方法を構成する手順を順を追って説明します。

## SCEPman CRL を有効にする

{% content-ref url="/pages/3d7774e878b5919ce290caea39380ee5bf346fbf" %}
[CRL の有効化](/ja/zheng-ming-shu-guan-li/manage-certificates/enabling-crl.md)
{% endcontent-ref %}

Entra ID は、証明書を検証するために CRL を必要とします。CRL を利用可能にするため、アプリサービスで次の環境変数を設定してください:

[AppConfig:CRL:RequestToken](https://docs.scepman.com/scepman-configuration/application-settings/crl#appconfig-crl-requesttoken)

CRL をダウンロードできるように、URL 内で使用されるカスタム文字列をここに設定します。

[AppConfig:CRL:Source](https://docs.scepman.com/scepman-configuration/application-settings/crl#appconfig-crl-source)

これは、SCEPman が CRL を作成する元のソースです。これが次のように設定されていることを確認してください `Storage`

## Entra ID をセットアップする

{% stepper %}
{% step %}

### Entra Security Center に PKI を作成する

Entra ID で、次へ移動します **Protection** > **Security Center** > [**Public Key Infrastructure**](https://entra.microsoft.com/#view/Microsoft_AAD_IAM/SecurityMenuBlade/~/PublicKeyInfrastructure/menuId/SecurityCenter/fromNav/)**,** をクリックします *Create PKI* を選択し、対応する表示名を選択します。
{% endstep %}

{% step %}

### 証明機関を追加する

新しく作成した PKI に移動し、次をクリックします *Add certificate authority* SCEPman インスタンスの CA 証明書をアップロードします。この証明書は、右側のメニューにあるホームページから取得できます (*Get CA Certificate*).

Certificate revocation list URL には、次の形式で URL を入力できます:

```
https://scepman.contoso.com/crl/pem/{YourCrlRequestToken}
```

{% hint style="warning" %}
次を含めるようにしてください `/pem/` 既定の DER 形式を使用すると、Entra に互換性の問題が発生する場合があるため、URL にパスを含めてください。
{% endhint %}

これで、次のような証明機関ができているはずです:

<figure><img src="/files/4534fb394c519d87a20ba3edb185ae7a717c722b" alt=""><figcaption></figcaption></figure>
{% endstep %}

{% step %}

### Authentication Methods で CBA を有効にする

CA の準備ができたので、次に進んで以下で証明書ベースの認証を有効にできます **Protection** > **Authentication methods** > [**Policies**](https://entra.microsoft.com/#view/Microsoft_AAD_IAM/AuthenticationMethodsMenuBlade/~/AdminAuthMethods/fromNav/)

次へ移動します *Certificate-based authentication* ポリシーを開き、有効化して、すべてのユーザーまたは特定のグループがこの方法を使用できるようにします:

![](/files/d2e36e087cabbd7f52788b30eebe4edddf5b8934)
{% endstep %}

{% step %}

### 証明書ベースの認証を構成する

次に切り替えて *Configure* タブを開き、各オプションを確認します:

**CRL 検証を要求する**: ✅

これは、この方法が提供するセキュリティの重要な部分です。CRL によって、Entra ID は失効した証明書を把握できるため、それらを認証に使用できなくなります。

**発行者ヒント** : ✅

発行者ヒントを有効にすると、認証時に、構成された CA によって発行された証明書のみが表示されます。

認証バインドの既定設定はそのままにして、先に作成した証明機関を許可するルールを作成します:

<figure><img src="/files/95576f92a8b382a861b9a65c4250c2520244dbda" alt=""><figcaption></figcaption></figure>

**認証強度**:

これは、この CA を使用した認証の重みを定義します。 *Single-factor authentication*を選択した場合、アクセスするアプリケーションによっては、別の認証方法が必要になることがあります。

**アフィニティ バインド**:

アフィニティ バインドは、証明書に必要な詳細を定義します。認証を許可するには、それがユーザー オブジェクト内の対応するデータと一致している必要があります。SCEPman は現在、ユーザー オブジェクトに証明書情報を追加できないため、これを次のように設定することをお勧めします **Low** 必要な情報を手動で構成しない限り。

{% hint style="warning" %}
認証強度とアフィニティ バインドの設定は、特定のユースケースや、この認証方法で保護したいアカウントの種類に大きく依存します。権限の高いユーザーを保護したい場合は、高いアフィニティを得るために、ユーザー アカウントに証明書情報を手動で追加することを検討してください。
{% endhint %}
{% endstep %}
{% endstepper %}

## 使用方法

構成が完了すると、ユーザーは次を選択できます *証明書またはスマート カードを使用する*:

<figure><img src="/files/11921f025c11c2c2504f7fbac36d84232395b429" alt=""><figcaption></figcaption></figure>

すると、認証に使用する証明書の選択が求められます。

<figure><img src="/files/3fb7dc2f6fb9ab3610c2022229573ef460f474bc" alt=""><figcaption></figcaption></figure>

## 高アフィニティ バインドのために証明書マッピングを手動で追加する

CBA を高アフィニティ バインドのみで有効にしたい場合は、ユーザーの承認済み情報に証明書の詳細を手動で入力できます。

Entra ID でユーザーのプロパティに移動して編集し、次に **証明書ユーザー ID**:

<figure><img src="/files/6e8835c1b48903ea4c77fef3a6412227d4576985" alt=""><figcaption></figcaption></figure>

これらの ID に必要な形式は、認証方法のユーザー バインドで構成したフィールドによって異なります。形式の一覧は、該当する [Microsoft のドキュメント](https://learn.microsoft.com/en-us/entra/identity/authentication/concept-certificate-based-authentication-certificateuserids#supported-patterns-for-certificate-user-ids).

の例 *SHA1PublicKey* バインド:

```
X509:<SHA1-PUKEY>9600e49d740011187e5c734bab4a3d5d18d2a87a
```

これは、証明書のサムプリントを使用してユーザーの ID を強力にマッピングしています。


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.scepman.com/ja/scepman-depuroi/deployment-guides/scenarios/certificate-based-authentication-for-entra-id.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
