> For the complete documentation index, see [llms.txt](https://docs.realmjoin.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.realmjoin.com/ja/zi-dong-hua/runbooks/runbook-references/user/security/revoke-or-restore-access.md).

# アクセスを取り消すか復元

このユーザーのサインインとセッションをブロックするか、アクセスを復元します

### 説明

このユーザーのサインインをブロックし、現在のセッションを終了します。たとえばインシデント発生時に使用します。すでに発行されているアクセス トークンは、有効期限が切れるまで有効なままで、通常は1時間以内です。Exchange Online、SharePoint、Teams など、継続的アクセス評価を使用するアプリは数分以内に反応します。ユーザーを再度有効にするとブロックは解除されますが、終了したセッションは復元されません。

### 管理者ロールを持つユーザー

Entra ID は、管理者ロールを持つユーザーを、権限の低い管理者による変更から保護します。User Administrator ロールでは、RealmJoin のマネージド ID は、管理者ロールを持たないユーザーと、Helpdesk Administrator、Password Administrator、Groups Administrator、User Administrator などの一部のロールを持つユーザーに対して、サインインのブロックまたは復元、およびセッションの失効を実行できます。

Power Platform Administrator、Exchange Administrator、Global Administrator などのその他のロールを持つユーザー、およびロールを割り当て可能なグループのメンバーと所有者については、Entra ID は Privileged Authentication Administrator または Global Administrator を必要とします。その後、実行は「権限が不足しています」で停止し、ユーザーのロール名が表示されます。Entra 管理センターで、Privileged Authentication Administrator または Global Administrator アカウントを使用して、そのようなユーザーに対する変更を行ってください。

RealmJoin のマネージド ID にこれら 2 つのロールのいずれかを付与することは推奨されません。どちらも Global Administrator の資格情報をリセットできるためです。Microsoft は、どのロールがどの管理者を変更できるかを [機密性の高い操作を実行できるのは誰か](https://learn.microsoft.com/en-us/entra/identity/role-based-access-control/privileged-roles-permissions#who-can-perform-sensitive-actions).

#### ジョブ出力内のロール

何かが変更される前に、ジョブ出力にはユーザーに直接割り当てられている Entra ID ロールが一覧表示されます。これには、管理者ロール チェック用のオプション権限が必要です。それがない場合、出力には「読み取れませんでした」と表示され、実行は続行されます。

### 場所

ユーザー → セキュリティ → アクセスの取り消しまたは復元

**完全な Runbook 名**

rjgit-user\_security\_revoke-or-restore-access

### 詳細

| プロパティ    | 値                                                                                        |
| -------- | ---------------------------------------------------------------------------------------- |
| バージョン    | 1.1.0                                                                                    |
| 必須モジュール  | <p>RealmJoin.RunbookHelper (>= 0.8.10)<br>Microsoft.Graph.Authentication (>= 2.41.2)</p> |
| スケジュール可能 | いいえ                                                                                      |

### アクセス許可

#### アプリケーションのアクセス許可

* **型**: Microsoft Graph
  * User.ReadWrite.All
    * *accountEnabled を設定し、ユーザーのサインイン セッションを取り消します*
  * RoleManagement.Read.Directory *(省略可能 — 機能: 管理者ロール チェック)*
    * *ユーザーの Entra ID ロールを読み取り、それらを表示し、Entra ID が管理者アカウントに対する変更を拒否した場合に、そのロール名を示します*

#### RBAC ロール

* ユーザー管理者
  * *管理者ロールを持たないユーザー、および Helpdesk Administrator などの一部のロールを持つユーザーに対して、サインインのブロックまたは復元とセッションの取り消しを行うために必要です。その他の管理者には Privileged Authentication Administrator または Global Administrator が必要です*

### パラメーター

#### ユーザー名

Runbook が操作対象とするユーザーのユーザー プリンシパル名です。ポータルで選択したユーザーから設定されます。

| プロパティ    | 値                        |
| -------- | ------------------------ |
| 必須       | true                     |
| 既定値      |                          |
| 型        | 文字列                      |
| ポータルで非表示 | はい（runbook のカスタマイズで事前設定） |

#### 取り消す

アクセスの取り消しはサインインをブロックし、セッションを終了します。ユーザーを再度有効にすると、ユーザーは再びサインインできます。

| プロパティ    | 値     |
| -------- | ----- |
| 必須       | false |
| 既定値      | True  |
| 型        | ブール値  |
| ポータルの表示名 | アクション |

**ポータル オプション**

| ポータル オプション   | 値     |
| ------------ | ----- |
| ユーザーを再度有効にする | false |
| アクセスの取り消し    | true  |

[Runbook リファレンスの概要に戻る](https://docs.realmjoin.com/ja/zi-dong-hua/runbooks/runbook-references.md)


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

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

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.realmjoin.com/ja/zi-dong-hua/runbooks/runbook-references/user/security/revoke-or-restore-access.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

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.
