# Active Directoryを利用したログイン認証

## **Active Directory 認証概要**

Active Directory上にConMas i-Reporter環境を構築することで、AD認証を行っているクライアント端末からは、i-Reporterへのログインは不要になります（シングルサインオン）。\
セッションタイムアウトによる再ログインもなくなります。

### **前提条件**

* 「ConMas Manager」をインストールしているサーバーと、「ConMas i-Reporter」を起動するクライアントPCを同じドメインに参加させます。
* あらかじめ、「ConMas i-Reporter」にドメインユーザーと同じログインIDのユーザーを登録しておきます。

### **対応アプリケーション**

以下のアプリケーションのログインに対応しています。

* i-Reporter For Windows
* ConMas Designer
* ConMas Manager

{% hint style="warning" %}
iOS版 i-Reporter アプリには対応しておりません。

また、Active Directory 認証を有効にした場合、iOS版i-Reporterアプリは利用できなくなります。
{% endhint %}

## **注意事項**

本機能が提供するのは、Active Directory上とConMas Server上でユーザーIDが一致した場合にログインが可能とする機能（シングルサインオン）であり、Active Directoryとのアクセス権限連携などはできません。

{% hint style="warning" %}
i-Reporterを利用するうえでのアクセス権等の権限設定やグループ設定は、別途ConMas Managerから行う必要があります。
{% endhint %}

**Active Directory 認証イメージ**

<div align="left"><figure><img src="/files/8hOb7CQJGMFacONQcETj" alt=""><figcaption></figcaption></figure></div>

## **i-Reporter アプリ（Windows版）／ ConMas Designer の設定方法**

**【手順】**

1. **ConMas Serverの設定を変更する。**\
   IISに登録してある「ConMasWeb」アプリケーションの認証設定を変更します。\
   「ConMasWeb」 ＞ 「認証」 より、

   * 「Windows 認証」を “有効”
   * 「匿名認証」を“無効”&#x20;

   にします。

   <figure><img src="/files/eCyseko7YABgklWBTyDr" alt=""><figcaption></figcaption></figure>

   <br>
2. **ConMas Serverの設定を変更する。**\
   「ConMasWeb」アプリケーションの設定を変更します。\
   \
   Web.config ファイル内の記述を変更します。\
   `<インストールフォルダ>\ConMas\ConMasWeb\Web.config`\
   \
   \
   \
   \
   \
   「AuthType」設定を STD から AD に変更します。\
   &#x20;`<appSettings>`\
   &#x20;  `<!-- ユーザー認証方式設定  STD:標準　AD:ＡＤ　CST:カスタム -->`\
   &#x20;  `<add key="AuthType" value="AD" />`\ <br>
3. **クライアントアプリケーションの設定を変更する。**\
   \
   **i-Reporter アプリ（Windows版）**\
   アプリケーションを起動し、「設定」 ＞ 「サーバー」を選択します。

   * 「ユーザーID」、「パスワード」は設定しません。
   * 「自動ログイン」を“オン”にします。
   * 「AD認証モード」を“オン”にします。

   設定完了後、アプリケーションを閉じて、再度起動してください。

   <figure><img src="/files/fBjqoEao28d29m1B3Vft" alt=""><figcaption></figcaption></figure>

   \
   \
   **ConMas Designer**\
   アプリケーションを起動し、「Designer設定」を選択します。

   * 「AD認証モード」にチェックを入れます。

   設定完了後、アプリケーションを閉じて、再度起動してください。

   <figure><img src="/files/TUAg3YouOqOmuvdaD1nV" alt=""><figcaption></figcaption></figure>

## **ConMas Manager の設定方法**

**【手順】**

1. **ConMas Serverの設定を変更する。**\
   IISに登録してある「ConMasManager」アプリケーションの認証設定を変更します。\
   「ConMasManager」 ＞ 「認証」 より、

   * 「Windows 認証」を “有効”
   * 「匿名認証」を“無効”
   * 「フォーム認証」を“無効”

   にします。

   <figure><img src="/files/J6lF8SC8Sp6L8Ke8xpnj" alt=""><figcaption></figcaption></figure>

   <br>
2. **ConMas Serverの設定を変更する。**\
   「ConMasManager」アプリケーションの設定を変更します。\
   \
   Web.config ファイル内の記述を変更します。\
   `<インストールフォルダ>\ConMas\ConMasManager\Web.config`\
   \
   \
   「AuthType」設定を STD から AD に変更します。\
   ※ AuthType が無い場合は、\<appSetting>配下に追記してください。\
   &#x20;`<appSettings>`\
   &#x20;  `<!-- ユーザー認証方式設定  STD:標準　AD:ＡＤ　CST:カスタム -->`\
   &#x20;  `<add key="AuthType" value="AD" />`\
   \
   「 authentication mode 」設定を Windows に変更します。\
   &#x20;`<authentication mode="Windows">`\
   &#x20;  `<forms loginUrl="~/Account/LogOn" timeout="2880" name=".ASPXFORMSAUTH" />`\
   &#x20;`</authentication>`


---

# 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://manuals.i-reporter.jp/environment-configuration/set-up-users/ad-authentication.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.
