> 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).

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

## 概要

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

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

RealmJoin の API では、Tenant 内の指定したデバイスに対する「Support Account」（ローカル管理者）を要求できます。参照: [RealmJoin の Swagger 説明](https://customer-api.realmjoin.com/swagger/index.html) 現在どの操作が詳細にサポートされているかを確認してください。RealmJoin で LAPS を使用するには、RealmJoin Windows Client の展開が必要です。

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

## Support Account の要求

エンドポイントを使用して、対象デバイス上にローカル Support Account を作成するよう 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 ではないことに注意してください（別の属性です）！

現在、対象デバイスには Support Account が存在しません。

![Local Accounts - Support Account を要求する前](/files/be886ed7f1d356195cf8c9cd7420c8626d69c52d)

作成してみましょう **リクエスト**:

ヘッダー:

```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 がローカル Support Account を作成するまでのおおよその時間が含まれます。この例では、少なくとも 12 分は待つことを想定してください。クライアントが長い間確認されていない場合は、 `null` 数値の代わりに推定値として返されることがあります。

RealmJoin Windows Client は、既定では 30 分ごとにジョブをポーリングします。API が提供する概算は、Windows Client が最後にチェックインした時刻に基づいています。

## Support Account の資格情報を取得する

エンドポイント `/laps/retrieve` は、Support Account がすでに作成されているかを確認し、Support Account の実際の資格情報を取得するために使用されます。

同じものを問い合わせてみましょう `deviceId` の `9999dab9-f946-40ee-9a17-2500c8d00878` 例と同じように [上記の](#requesting-a-support-account).

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

![Local Accounts - Support Account が正常に作成されました](/files/1456fe0d94b0e0da11e31d05caba6319f2961b4a)

**要求**

ヘッダー:

```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": "見つかりません",
    "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 経由で接続し、ユーザーにサポートを提供できます。

ご覧のとおり、既定では Support Account の有効期間は限られており、有効期限後にアクセスが必要な場合は再作成する必要があります。これは、高権限の資格情報が日々の運用タスクにわたって残り続けないようにするためです。


---

# 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 dynamically by asking a question.

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

```
GET https://docs.realmjoin.com/ja/dev-reference/local-admin-password-management.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
