> For the complete documentation index, see [llms.txt](https://docs.maiagent.ai/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.maiagent.ai/org/security-and-privacy.md).

# 安全與隱私

給 IT 與資安窗口的 MaiAgent 安全與隱私重點：ISO 27001／27701 認證、傳輸加密、憑證加密儲存、角色權限、SSO、活動日誌、Hook 個資遮罩，以及 Agent 監控和活動日誌各自記錄什麼。

本頁整理 MaiAgent 在資訊安全與隱私上提供的機制，給負責導入評估的 IT、資安窗口快速掌握重點，也可以直接轉給貴公司的資安單位參考。每一節都附上手冊中的詳細操作頁。

{% hint style="info" %}
本頁只列出平台已提供的機制。需要資安問卷回覆、認證相關文件、資安事件通報方式或合約條款，請洽 MaiAgent 窗口。
{% endhint %}

## 重點一覽 <a href="#at-a-glance" id="at-a-glance"></a>

| 面向    | MaiAgent 提供的機制                  | 詳細說明                                   |
| ----- | ------------------------------- | -------------------------------------- |
| 認證    | ISO 27001 與 ISO 27701 雙認證       | [認證](#certifications)                  |
| 傳輸    | 全站 HTTPS，並以 HSTS 要求瀏覽器只走加密連線    | [加密](#encryption)                      |
| 憑證保存  | 串接外部系統用的密碼、金鑰與權杖加密後存放           | [加密](#credential-encryption)           |
| 誰能用什麼 | 角色權限、資源分配、模型調用權限                | [權限控管](#access-control)                |
| 登入    | 企業單一登入（SSO）與 LDAP 身分同步          | [登入與帳號](#sign-in-and-accounts)         |
| 稽核    | 活動日誌只能新增、不能刪改                   | [活動日誌](#activity-log)                  |
| 敏感內容  | Hook 遮罩個資、攔截惡意或不當內容             | [Hook](#hook)                          |
| 對話內容  | Agent 監控記錄每一次 AI 回覆，依角色權限決定誰看得到 | [三種紀錄的差別](#monitoring-vs-activity-log) |

## 認證 <a href="#certifications" id="certifications"></a>

MaiAgent 通過 **ISO 27001 資訊安全管理系統**與 **ISO 27701 隱私資訊管理系統**雙認證。需要認證相關文件時，請洽 MaiAgent 窗口。

## 加密 <a href="#encryption" id="encryption"></a>

### 傳輸加密 <a href="#encryption-in-transit" id="encryption-in-transit"></a>

* 與平台之間的連線一律使用 HTTPS；以 HTTP 連入時，平台會轉向 HTTPS。
* 平台以 HSTS 要求瀏覽器之後只用加密連線，避免連線被降級成未加密的 HTTP。

### 儲存加密 <a href="#encryption-at-rest" id="encryption-at-rest"></a>

* SaaS 的資料庫與上傳的檔案在存放時加密，見技術手冊 [AI Gateway 安全性：誰看得到提示詞](https://docs.maiagent.ai/tech/ai-gateway/ai-gateway-security#q3-who-sees-prompts)。
* 私有雲與地端部署的資料庫與檔案存放在貴公司的主機或儲存設備上，存放時的加密由貴公司的磁碟或儲存層負責；平台本身不另外加密檔案。

### 憑證類欄位加密儲存 <a href="#credential-encryption" id="credential-encryption"></a>

串接外部系統時，平台需要保存對方的密碼或金鑰。下列欄位會以 AES-256-GCM 加密後才寫入資料庫：

* [身分同步（LDAP）](/org/identity-sync.md)的服務帳號密碼
* 對話平台串接用的密鑰與存取權杖，例如 LINE、Messenger、Instagram、WhatsApp、Microsoft Teams、LINE WORKS，以及 Email 平台的信箱密碼
* 連接器與 MCP 工具的 OAuth 授權資訊（用戶端密鑰、存取權杖與更新權杖）
* [AI Gateway](/build/ai-gateway.md) 自帶金鑰（BYOK）的供應商憑證

## 權限控管：誰看得到、誰能用 <a href="#access-control" id="access-control"></a>

* **角色**：成員的最終權限是預設角色加上所有自訂角色的聯集。功能權限決定左側選單出現哪些功能；資源分配（Agent、知識庫、對話平台、技能等）加上 <mark style="color:blue;">讀取</mark> 權限，決定成員看得到哪些資源。組織擁有者自動擁有全部權限與資源。詳見 [角色權限管理](/org/roles/role-permission.md) 與 [角色資源可見性控制](/org/roles/group-resource-visibility.md)。
* **組織隔離**：資料以組織為單位隔離，成員只能存取自己所屬組織的資料。
* **模型調用權限**：組織擁有者可以關閉不允許使用的 AI 模型，關閉的模型不會出現在任何模型選單中。詳見 [模型調用權限](/org/model-access.md)。
* **API Key**：每把金鑰綁定一位成員與一個組織，呼叫時的權限和該成員相同，可隨時停用或撤銷。詳見 [API Key 管理](/org/developer/api-keys.md)。

{% hint style="warning" %}
**預設角色會套用到所有成員。** 建議預設角色只給最低限度的權限，其他權限透過自訂角色分配。設了權限卻看不到、或不該看到的人看到了，請依 [逐項檢查表](/org/roles/role-permission.md#faq-member-cannot-see-agent) 排查。
{% endhint %}

## 登入與帳號管理 <a href="#sign-in-and-accounts" id="sign-in-and-accounts"></a>

* **企業單一登入（SSO）**：支援 SAML（含 ADFS）、EIP、Keycloak、Cloudflare Access，員工以公司帳號登入，不必另外記一組 MaiAgent 密碼。詳見 [第三方登入（SSO）](/org/sso.md)。
* **身分同步（LDAP）**：從 AD、JumpCloud、OpenLDAP 等目錄自動同步帳號與群組；在目錄中停用、或離開同步範圍的帳號，下一次同步時會在 MaiAgent 被停用，該成員的 API Key 也會一併刪除。詳見 [身分同步（LDAP）](/org/identity-sync.md#faq-account-keeps-disabled)。

以上兩項為企業版功能。

## 稽核：活動日誌 <a href="#activity-log" id="activity-log"></a>

[活動日誌](/org/activity-log.md) 記錄組織內資料的每一次新增、更新、刪除，以及成員登入，每筆紀錄包含操作時間、操作的成員、來源 IP 與變更內容，可依期間匯出成 Excel 留存。

活動日誌只能新增、不能刪改：後台沒有刪除或編輯紀錄的功能，資料庫層也會阻擋修改與刪除，組織擁有者同樣無法移除任何一筆。詳見 [活動日誌：資料保存](/org/activity-log.md#data-retention)。

## 敏感內容：Hook 訊息攔截 <a href="#hook" id="hook"></a>

[Hook](/build/hook.md) 在內容交給 AI 之前、以及 AI 回覆送出之前自動介入，由系統強制執行，不靠 AI 自律：

* **遮罩個資**：把手機、Email、身分證、信用卡號，以及人名、地址等個資遮罩後才交給模型。
* **攔截內容**：擋下提示注入攻擊、暴力或仇恨等不當內容，以及含禁用字的訊息。
* **涵蓋 AI 讀到的所有內容**：除了使用者打的字，附件、知識庫檢索段落與工具回傳的結果也會經過同一組 Hook。

每一次攔截、改寫、放行都會留在 [Hook 執行紀錄](/build/hook/execution-logs.md)；紀錄預設只保留處置結果，不保留遮罩前的原始內容，見 [控制是否記錄原始訊息](/build/hook/execution-logs.md#log-privacy-toggle)。Hook 為企業版功能。

## Agent 監控、活動日誌與 Hook 執行紀錄的差別 <a href="#monitoring-vs-activity-log" id="monitoring-vs-activity-log"></a>

三種紀錄各管一件事，資安稽核時常需要搭配查看：

|       | 活動日誌                                                                          | Agent 監控（對話紀錄）                                                                                                                            | Hook 執行紀錄                                                                              |
| ----- | ----------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- |
| 記錄什麼  | 資料的新增、更新、刪除與成員登入：誰、何時、從哪個 IP、改了什麼                                             | 每一次 AI 回覆：使用者訊息、AI 回覆、Agent、模型、回應時間、Token 用量、品質評分、發起的成員                                                                                   | 每一次 Hook 的攔截、改寫、放行：哪則訊息、哪個 Hook、做了什麼處置                                                 |
| 不記錄什麼 | 對話內容，以及單純開啟頁面或查看資料                                                            | 設定變更與登入                                                                                                                                   | 沒有掛 Hook 的 Agent 的對話                                                                   |
| 誰看得到  | 具 <mark style="color:blue;">活動日誌權限</mark> 的角色                                 | 組織擁有者看得到全部；其他成員需 <mark style="color:blue;">AI 助理監控權限</mark>，且只看得到分配給所屬角色的 Agent；MaiGPT 預設分配給預設角色，所以成員的 MaiGPT 對話也看得到                      | 具 <mark style="color:blue;">Hook 權限</mark> 的角色                                         |
| 位置    | <mark style="color:blue;">組織設定</mark> → <mark style="color:blue;">活動日誌</mark> | <mark style="color:blue;">AgentOps</mark> → <mark style="color:blue;">AI 助理監控</mark>                                                      | <mark style="color:blue;">AgentOps</mark> → <mark style="color:blue;">Hook 執行紀錄</mark> |
| 詳細說明  | [活動日誌](/org/activity-log.md)                                                  | [Agent 監控](/build/agent-ops/evaluations.md#ai-agent-monitoring)、[查看 MaiGPT 對話](/build/agent-ops/evaluations.md#view-maigpt-conversations) | [Hook 執行紀錄](/build/hook/execution-logs.md)                                             |

透過 API 呼叫 MaiAgent 的請求，另外記錄在 [API 呼叫紀錄](/org/developer/api-logs.md)。

{% hint style="info" %}
**後台有兩個地方看得到對話內容：** <mark style="color:blue;">AI 助理監控</mark>（需 <mark style="color:blue;">AI 助理監控權限</mark>），以及 <mark style="color:blue;">客服對話</mark> → <mark style="color:blue;">所有對話</mark>（需 <mark style="color:blue;">所有對話權限</mark>，範圍是分配給所屬角色、並勾選 <mark style="color:blue;">查看所有對話</mark> 的對話平台，以及指派給自己的對話）；組織擁有者兩處都看得到全部。導入前建議先決定哪些角色需要這兩個權限，並告知成員。成員端的說明可以直接引用 [MaiGPT 安全性與隱私](/work/maigpt/faq/security.md#admin-access-to-chat)。
{% endhint %}

## 目前不提供的機制 <a href="#not-provided" id="not-provided"></a>

資安問卷常問、但平台目前沒有的項目，先列在這裡，避免評估時來回確認：

| 項目                                             | 現況                                                                               | 替代做法                                                                                                                                                |
| ---------------------------------------------- | -------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------- |
| 特權存取管理（PAM）、即時（JIT）授權、特權連線錄影                   | 不提供，也不整合 PAM 產品                                                                  | 以[角色權限](/org/roles/role-permission.md)控制誰能用什麼、以 SSO／LDAP 讓帳號跟著公司目錄開通與停用；管理操作留在[活動日誌](/org/activity-log.md)                                          |
| 外部密鑰庫（例如 HashiCorp Vault、雲端 Secrets Manager）整合 | 不提供。串接外部系統的密碼與金鑰由平台以 AES-256-GCM 加密後存在平台資料庫，見[憑證類欄位加密儲存](#credential-encryption) | —                                                                                                                                                   |
| 每次請求自動輪替 API Key                               | 不提供。API Key 在撤銷前持續有效，可設定到期日                                                      | 定期在 [API Key 管理](/org/developer/api-keys.md)建立新金鑰、更新呼叫端、再撤銷舊金鑰                                                                                      |
| 把活動日誌或對話紀錄即時送到 SIEM                            | 不提供推送或 syslog 輸出                                                                 | 依期間[匯出活動日誌](/org/activity-log.md)為 Excel，再匯入貴公司的系統                                                                                                  |
| 第三方執行期提示注入防護產品（例如 AI 防火牆）整合                    | 不整合                                                                              | 使用 [Hook](/build/hook.md) 的提示注入與不當內容偵測，或把防護產品放在使用者與 MaiAgent 之間的網路層，見技術手冊 [AI 安全防護機制](https://docs.maiagent.ai/tech/advanced-genai-tech/guardrails) |

## 資料使用 <a href="#data-use" id="data-use"></a>

MaiGPT 使用的 AI 模型不會拿對話資料進行訓練，見 [MaiGPT 安全性與隱私](/work/maigpt/faq/security.md#ai-training-on-chat)。各模型供應商的資料處理條款、資料存放與保留等問題，請洽 MaiAgent 窗口。

組織若要求知識庫的索引資料留在自己管理的環境，可以讓知識庫改接組織自有的向量資料庫（企業版功能），見 [如何建立知識庫：向量資料庫](/build/knowledge-base/km-basic-settings.md#vector-database)。

## 導入前的建議設定 <a href="#recommended-setup" id="recommended-setup"></a>

1. 啟用企業單一登入或 LDAP 身分同步，讓帳號跟著公司目錄開通與停用。
2. 把預設角色的權限降到最低，其他權限用自訂角色分配。
3. 決定哪些角色擁有 <mark style="color:blue;">AI 助理監控權限</mark> 與 <mark style="color:blue;">活動日誌權限</mark>，並定期檢視。
4. 對外服務或會處理個資的 Agent（例如辨識證件、發票的[影像視覺應用](/work/image-vision.md)），掛上個資遮罩與提示注入防護的 Hook。
5. 定期依期間匯出活動日誌，作為稽核留存。

## 相關頁面 <a href="#related" id="related"></a>

* [角色與權限](/org/roles.md)
* [第三方登入（SSO）](/org/sso.md)
* [活動日誌](/org/activity-log.md)
* [Hook 訊息攔截](/build/hook.md)
* [自動評估與 Agent 監控](/build/agent-ops/evaluations.md)
* [MaiGPT 安全性與隱私](/work/maigpt/faq/security.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.maiagent.ai/org/security-and-privacy.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.
