> 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/dev-reference/local-admin-password-management.md).

# ローカル管理者パスワード管理

RealmJoin は、API を通じて個別のローカル管理者 (LAPS) アカウントを管理し、パスワードは Azure Key Vault に暗号化して保存されます。

## 概要

Local Administrator Password Solution (LAPS) は、サポートおよび緊急時の目的で、すべての Windows コンピューターで同一の管理者資格情報を使用する問題を解決します。単体では、LAPS はローカル管理者アカウント用のランダム生成パスワードを作成します。

RealmJoin では、ローカルサポートまたは大規模なリモートサポートのいずれにも、安全で個別化された管理アカウントを管理することが可能です。RealmJoin は、顧客の Tenant 内の Azure Key Vault に暗号化されたパスワードを保存し、これらの資格情報へのすべてのアクセスの監査ログを保存します。

RealmJoin の API では、Tenant 内の特定デバイスに対して「サポート アカウント」（ローカル管理者）を要求できます。参照してください [RealmJoin の API リファレンス](https://customer-api.realmjoin.com/scalar/v1) 現在どの操作がサポートされているかの詳細は、こちらをご覧ください。RealmJoin で LAPS を使用するには、RealmJoin Windows Client の展開が必要です。

お使いの環境で LAPS が正しく設定され、デバイスに RealmJoin Windows Client が展開されていることを前提としています。また、必ず [認証する ](/ja/dev-reference/realmjoin-api/authentication.md)適切な HTTP Authorization ヘッダーを使用して、RealmJoin の API に対するすべてのリクエストを認証してください。

## サポート アカウントの要求

次のエンドポイントを使用して、対象デバイスにローカルなサポート アカウントを作成するよう RealmJoin に指示します `/laps/request`. リクエストは Application Insights を使用してキューに入れられ、可能な限り早く RealmJoin Backend と RealmJoin Windows Client によって処理されます。アカウントが作成済み／使用可能になったら。

このエンドポイントは、アカウントの作成にどのくらい時間がかかるかの見積もりを返します。アカウントの準備ができたら、 [こちら](#retrieve-support-account-credentials) 資格情報を取得する方法については、

### 例

次の状況を想定しましょう:

* RealmJoin API の資格情報を取得し、次のようにエンコードしました `dC0xMjM0MTIzNDpteVMzY3JldCE=` (Base64)
* 対象デバイスの Entra `deviceId` は `9999dab9-f946-40ee-9a17-2500c8d00878`. これは Entra の object id ではないことに注意してください（別の属性です）！

現在、対象デバイスにはサポート アカウントが存在しません。

![ローカル アカウント - サポート アカウントを要求する前に](https://3438325150-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MkrcM7cKOpXKri1kVrh%2Fuploads%2FFlbUzySBT9dqV4nrm6kx%2FLaps-before.png?alt=media\&token=e5e95f49-1293-4696-ad1f-a245bb6b42e6)

では、次のものを作成しましょう **リクエスト**:

ヘッダー:

```http
Authorization: Basic dC0xMjM0MTIzNDpteVMzY3JldCE=
Content-Type: application/json
```

リクエスト / URI:

```http
POST https://customer-api.realmjoin.com/laps/request?deviceID=9999dab9-f946-40ee-9a17-2500c8d00878
```

このエンドポイントはリクエスト本文を必要としません。

**応答**

HTTP ステータス: `200` (OK)

本文（JSON表記）:

```json
{
    "estimatedWaitTime": "00:12:31.8215813"
}
```

この応答には、RealmJoin Windows Client がローカル サポート アカウントを作成するまでのおおよその時間が含まれます。この例では、少なくとも 12 分待つことを想定してください。クライアントが長い間確認されていない場合は、 `null` 数値の代わりに見積もりとして受け取る場合があります。

RealmJoin Windows Client は、既定で 30 分ごとにジョブをポーリングします。API が提示する見積もりは、Windows Client の最終チェックイン時刻に基づいています。

## サポート アカウントの資格情報を取得する

このエンドポイント `/laps/retrieve` は、サポート アカウントがすでに作成されているかを照会し、サポート アカウントの実際の資格情報を取得するために使用されます。

同じ `deviceId` の `9999dab9-f946-40ee-9a17-2500c8d00878` を、例と同じように [上記](#requesting-a-support-account).

この例では、RealmJoin Windows Client によって対象デバイス上にサポート アカウント（フルネーム: "Local Support Admin Account"）が作成されています:

![ローカル アカウント - サポート アカウントが正常に作成されました](https://3438325150-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MkrcM7cKOpXKri1kVrh%2Fuploads%2F8ePPJ2SxA29zcJsmGKX7%2FLaps-after.png?alt=media\&token=2d24e9ce-fa68-4499-a597-f0789f0a6115)

**リクエスト**

ヘッダー:

```http
Authorization: Basic dC0xMjM0MTIzNDpteVMzY3JldCE=
Content-Type: application/json
```

リクエスト / URI:

```http
POST https://customer-api.realmjoin.com/laps/retrieve?deviceID=9999dab9-f946-40ee-9a17-2500c8d00878
```

このエンドポイントはリクエスト本文を必要としません。

**応答**

まだ資格情報が利用できない場合、このエンドポイントは HTTP ステータスを返します: `404` （Not Found）と、本文にいくつかの技術的詳細を返します:

本文（JSON）

```json
{
    "type": "https://tools.ietf.org/html/rfc7231#section-6.5.4",
    "title": "Not Found",
    "status": 404,
    "traceId": "00-4c56c3cb0f9b394abf934b107b148613-1234b2497e261649-00"
}
```

資格情報の準備ができるまで、照会を続けることができます。

資格情報の準備ができている場合、このエンドポイントは HTTP ステータスを返します: `200` （OK）と資格情報を返します:

本文（JSON）

```json
{
    "password": "Upji1234",
    "username": "ADM-5A2F2169",
    "accountExpirationDate": "2021-12-21T02:14:07+00:00"
}
```

これらの資格情報を使用してユーザーをサポートできます。たとえば、AnyDesk Supporter Client 経由で接続します。

ご覧のとおり、既定ではサポート アカウントには有効期限があり、有効期限後にアクセスが必要な場合は再作成する必要があります。これは、高権限の資格情報が日々の運用タスクをまたいで残存しないようにするためです。


---

# 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/dev-reference/local-admin-password-management.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.
