---
schema_version: "1"
id: f88ae38abd626e86fb35702f4549ddfae8db53f950c7dc3d467218b9d9a1fc0c
title: 使用 OAuth 2.0 信任設定已連線應用程式
collection: tableau
version: current
locale: zh-tw
portal_url: https://docs.salesforce.com/tableau/current/zh-tw/server-linux/connected_apps_eas.md
canonical_url: https://help.tableau.com/current/server-linux/zh-tw/connected_apps_eas.htm
source_site: help.tableau.com
content_type: documentation
content_hash: e621c4645c9ac494f654771e095b9c80ff9359deb2599f6df8bbced8a1e88f75
description: Configure connected apps with OAuth 2.0 trust by registering an external authorization server.
---
[跳至主要內容](#main-content)

# 使用 OAuth 2.0 信任設定已連線應用程式

作為 Tableau Server 管理員，您可以註冊一個或多個外部授權伺服器 (EAS)，以使用 OAuth 2.0 標準通訊協定在您的 Tableau Server 和 EAS 之間建立信任關係。

**重要資訊：**

- 本主題中的某些程序需要使用協力廠商軟體和服務進行設定。我們已盡最大努力驗證該程序，並啟用 Tableau Server 的 EAS 功能。但是，第三方軟體和服務可能會發生變化，或者您的組織可能會有所不同。若遇到問題，權威設定細節和支援請參考第三方文件。
- 若要透過 EAS 啟用內嵌，必須將 Tableau Server 設定為使用 SSL 處理 HTTP 流量。
- 為了讓工作階段權杖有效，外部應用程式和託管外部應用程式的伺服器的時鐘必須設定為國際標準時間 (UTC)。若任一時鐘使用不同的標準，則已連線應用程式將不受信任。

## Tableau 已連線應用程式如何使用 OAuth 2.0 信任

您的 Tableau Server 站台和外部應用程式之間的信任關係透過 JSON Web 權杖 (JWT) 標準中的驗證權杖建立和進行驗證。

在外部應用程式中載入內嵌 Tableau 內容時，會使用授權碼流程、OAuth 流程。使用者成功登入 IdP 後，會自動登入 Tableau Server。請按照下述步驟在Tableau Server 上註冊 EAS。

### 已連線應用程式的關鍵元件

已連線應用程式的以下元件與外部應用程式中的 JWT 共同作業，以驗證使用者並顯示內嵌的內容。

- **外部授權伺服器 (EAS)：**伺服器（通常是您的 IdP），可作為使用者和外部應用程式之間的介面。伺服器對使用者進行驗證，並授權其存取受保護的 Tableau 內容。
- **簽發者 URL：**唯一識別 EAS 執行個體的 URL。

### 已連線應用程式的工作流程

#### 內嵌工作流程

下圖說明了外部授權伺服器 (EAS)、外部應用程式（Web 伺服器和網頁）和 Tableau 已連線應用程式之間如何進行驗證。

![](/tableau/current/zh-tw/server-linux/zh-tw/Img/connectedapp_how_EAS.png)

1. **使用者造訪網頁：**使用者造訪網頁上的內嵌內容時，網頁會向外部應用程式傳送 GET 請求。
2. **外部應用程式將請求重新導向到 EAS：**外部應用程式透過重新導向到外部授權伺服器 (EAS) 的網頁進行回應。
3. **使用者透過 EAS 進行驗證：**使用者透過 EAS 進行驗證和授權。
4. **EAS 透過授權碼回應網頁：**EAS 透過授權碼回應頁面，並重新導向回網頁。
5. **EAS 將授權碼轉換為 JWT：**網頁呼叫 EAS 將授權碼轉換為 JWT，然後網頁將其放入內嵌內容的 URL 中。
6. **網頁從 Tableau 請求內容：**網頁載入 iFrame，並向 Tableau 傳送 GET 請求。
7. **Tableau 驗證權杖：**Tableau 使用簽章驗證 URL 中的 JWT，回應內容並遵守 JWT 中定義的內嵌範圍。

## 建立已連線應用程式

### 第 1 步：開始之前

要將 EAS 註冊到 Tableau Server，必須已設定 EAS。此外，EAS 必須傳送包含下表中列出的已註冊宣告和標頭的有效 JSON Web 權杖 (JWT)。

<table style="width: 90%;mc-table-style: url('Resources/TableStyles/Basic-Border-Light.css');margin-left: 0;margin-right: auto;" class="TableStyle-Basic-Border" cellspacing="0"><colgroup><col class="TableStyle-Basic-Border-Column-Column1"><col class="TableStyle-Basic-Border-Column-Column1"><col class="TableStyle-Basic-Border-Column-Column1"></colgroup><tbody><tr class="TableStyle-Basic-Border-Body-Body1"><td class="TableStyle-Basic-Border-BodyE-Column1-Body1" style="font-weight: bold;">宣告</td><td class="TableStyle-Basic-Border-BodyE-Column1-Body1" style="font-weight: bold;">名稱</td><td class="TableStyle-Basic-Border-BodyD-Column1-Body1" style="font-weight: bold;">描述或所需值</td></tr><tr class="TableStyle-Basic-Border-Body-Body1"><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">「<code>kid</code>」</td><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">主要識別碼</td><td class="TableStyle-Basic-Border-BodyD-Column1-Body1">必需（在標頭中）。來自身分提供者的唯一金鑰識別碼。</td></tr><tr class="TableStyle-Basic-Border-Body-Body1"><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">「<code>iss</code>」</td><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">簽發者</td><td class="TableStyle-Basic-Border-BodyD-Column1-Body1">必需（在標頭或作為聲明）。唯一簽發者 URI 會標識受信任的已連線應用程式及其簽署金鑰。</td></tr><tr class="TableStyle-Basic-Border-Body-Body1"><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">「<code>alg</code>」</td><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">演算法</td><td class="TableStyle-Basic-Border-BodyD-Column1-Body1">必需（在標頭中）。JWT 簽署演算法。javadoc.io 文件中 <a href="https://www.javadoc.io/doc/com.nimbusds/nimbus-jose-jwt/2.21/com/nimbusds/jose/JWSAlgorithm.html" target="_blank">Class JWSAlgorithm</a> 頁面中列出了支援的演算法名稱。可以使用 <a href="https://help.tableau.com/current/server-linux/zh-tw/cli_configuration-set_tsm.htm#eas_algorithms" class="xref">vizportal.oauth.external_authorization_server.blocklisted_jws_algorithms</a>設定簽章演算法。</td></tr><tr class="TableStyle-Basic-Border-Body-Body1"><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">「<code>sub</code>」</td><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">主體</td><td class="TableStyle-Basic-Border-BodyD-Column1-Body1">經過驗證的 <span class="mc-variable Variables.ProductName variable">Tableau Server</span> 使用者的使用者名稱。</td></tr><tr class="TableStyle-Basic-Border-Body-Body1"><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">「<code>aud</code>」</td><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">受眾</td><td class="TableStyle-Basic-Border-BodyD-Column1-Body1"><p>值必須是：「<code>tableau</code>」</p></td></tr><tr class="TableStyle-Basic-Border-Body-Body1"><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">「<code>exp</code>」</td><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">到期時間</td><td class="TableStyle-Basic-Border-BodyD-Column1-Body1">有效的 JWT 不得到期。JWT 的過期時間（UTC 時間）必須在設定的最長有效期內。可以使用 <a href="https://help.tableau.com/current/server-linux/zh-tw/cli_configuration-set_tsm.htm#eas_max_expiration_period" class="xref">vizportal.oauth.external_authorization_server.max_expiration_period_in_minutes</a>命令配置最大有效期限。</td></tr><tr class="TableStyle-Basic-Border-Body-Body1"><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">「<code>jti</code>」</td><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">JWT ID</td><td class="TableStyle-Basic-Border-BodyD-Column1-Body1">JWT ID 宣告為 JWT 提供唯一識別碼，並且區分大小寫。</td></tr><tr class="TableStyle-Basic-Border-Body-Body1"><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">「<code>scp</code>」</td><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">範圍</td><td class="TableStyle-Basic-Border-BodyD-Column1-Body1"><p>如果是<i>嵌入工作流程</i>，支援的值包括：</p><p>「<code>tableau:views:embed</code>」<br>「<code>tableau:views:embed_authoring</code>」（在 Tableau Server 2022.3 中新增）<br>「<code>tableau:metrics:embed</code>」（在 Tableau Server 2023.3 中已淘汰）<br>「<code>tableau:ask_data:embed</code>」（於 Tableau Server 2023.1 新增。於 Tableau Server 2024.2 已淘汰）</p><p><b>附註：</b></p><ul><li>值必須作為清單類型傳遞。</li><li>對於 <code>tableau:views:embed</code>，範圍尊重已在 <span class="mc-variable Variables.ProductName variable">Tableau Server</span> 中設定的使用者權限，並允許使用者與內嵌檢視中的工具互動（若工具在原始檢視中可用）。</li><li>建議內嵌程式碼排除工具列參數。有關更多資訊，請參閱下面的<a href="#known_issues" class="xref">已知問題（僅限嵌入工作流程）</a>。</li></ul><p>有關 <i>REST API 授權工作流程</i>，請參閱<a href="https://help.tableau.com/current/server-linux/zh-tw/connected_apps_scopes.htm#scopes" class="xref">支援 JWT 授權的 REST API 方法</a>。</p><p>如果是 <i>使用 REST API 進行驗證的中繼資料 API 工作流程</i>，唯一支援的範圍是 <code>tableau:content:read</code>。</p><p>對於<i>使用 REST API 進行驗證的 VizQL 資料服務工作流程</i>，唯一支援的範圍是 <code>tableau:viz_data_service:read</code>。</p></td></tr><tr class="TableStyle-Basic-Border-Body-Body1"><td class="TableStyle-Basic-Border-BodyE-Column1-Body1"><code>https://tableau.com/groups</code></td><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">動態群組成員資格</td><td class="TableStyle-Basic-Border-BodyD-Column1-Body1">僅用於<i>內嵌工作流程</i>。<p>值必須與 Tableau Serve 中的一個或多個群組的名稱相符。有關詳情，請參閱<a href="https://help.tableau.com/current/server-linux/zh-tw/groups_create_local.htm#assertions" class="xref">使用聲明的動態群組成員資格</a>。</p></td></tr><tr class="TableStyle-Basic-Border-Body-Body1"><td class="TableStyle-Basic-Border-BodyB-Column1-Body1">（使用者屬性）</td><td class="TableStyle-Basic-Border-BodyB-Column1-Body1">（使用者屬性值）</td><td class="TableStyle-Basic-Border-BodyA-Column1-Body1"><p>僅用於<i>內嵌工作流程</i>。</p><p>從 Tableau Server 2025.1 開始，您可以在 JWT 中包含使用者屬性。然後，在內嵌內容中使用使用者屬性函數時，Tableau 會檢查經過驗證的使用者的內容，並決定哪些資料可以在執行時顯示。</p><p><b>附註：</b></p><ul><li><p>請查看 <a href="https://help.tableau.com/current/api/embedding_api/zh-tw/docs/embedding_api_user_attributes.html#known-issues" target="_blank">Tableau 內嵌 API v3</a> 說明，以瞭解可能影響工作流程的<i>已知問題</i>和<i>限制</i>。</p></li><li>要讓使用者屬性可用，1) 必須使用 Tableau REST API 透過<a href="https://help.tableau.com/current/api/rest_api/zh-tw/REST/rest_api_ref_site.htm#update_embedding_settings_for_site" target="_blank">為站台更新內嵌設定</a>方法啟用使用者屬性功能，並選擇性地啟用 <a href="https://help.tableau.com/current/server/zh-tw/cli_configuration-set_tsm.htm#uaf" target="_blank">features.VizDataServiceClientEnable</a> TSM 選項；2) 內容作者必須建立<a href="https://help.tableau.com/current/pro/desktop/zh-tw/functions_functions_user.htm#user_attributes" target="_blank">使用者屬性函數</a>。</li><li>使用者屬性區分大小寫。</li></ul></td></tr></tbody></table>

**附註：**上述 JWT 宣告記錄在網際網路工程任務推動小組 (IETF) 組織發佈的文件中[已註冊宣告名稱](https://datatracker.ietf.org/doc/html/rfc7519#section-4.1)區段。

### 第 2 步：將 EAS 註冊到 Tableau Server

透過將 EAS 註冊到 Tableau Server，可以在 EAS 和 Tableau Server 之間建立信任關係。這代表使用者存取內嵌在外部應用程式中的 Tableau 內容時，他們將被重新導向至使用 IdP 進行身份驗證。EAS 產生身份驗證權杖，該權杖會傳遞給 Tableau Server 進行驗證。在驗證信任關係後，授予使用者對內嵌內容的存取權限。

**附註：**某些 EAS 支援顯示同意對話方塊的選項，該對話方塊要求使用者核准應用程式存取 Tableau 內容。為確保使用者獲得最佳體驗，我們建議將 EAS 配置為代表使用者自動同意外部應用程式的請求。

#### 關於站台層級 EAS

從 Tableau Server 2024.2 開始，可以設定站台層級 EAS。若要在站台層級註冊 EAS，必須在 Tableau Server 管理員 (TSM) 中啟用已連線應用程式。

可以透過兩種方式註冊伺服器範圍的 EAS：使用 TSM Web UI 或使用 TSM CLI。

註冊 EAS 後，建立的信任關係適用於 Tableau Server 上的所有站台。

### 選項 1：使用 TSM Web UI

1. 若是 Tableau Server 管理員，請登入到 Tableau 服務管理員 (TSM) Web UI。有關詳情，請參閱[登入到 Tableau 服務管理員 Web UI](https://help.tableau.com/current/server-linux/zh-tw/sign_in_tsm.htm#sign-in-to-the-tsm-web-ui)。
2. 執行以下_其中一項_動作：
    
    - 在 Tableau Server 2024.2 及更高版本中，巡覽至「使用者身分和存取」頁面 > 「已連線應用程式」索引標籤。
    - 在 Tableau Server 2023.3 及更早版本中，巡覽至「使用者身分和存取」頁面 > 「授權伺服器」索引標籤。
3. 執行以下_其中一項_動作：
    - 在 Tableau Server 2024.2 及更高版本中：
        
        1. 選取啟用已連線應用程式核取方塊。
        2. 選取第二個選項按鈕「允許已連線應用程式（在站台層級設定）和伺服器範圍的 OAuth 2.0 信任（設定如下）」。
        3. 在簽發者 URL文字方塊中，貼上 EAS 的簽發者 URL。
        4. 按一下「儲存暫止的變更」按鈕。
            
            ![](/tableau/current/zh-tw/server-linux/zh-tw/Img/connectedapp_eas_register_new.png)
    - 在 Tableau Server 2023.3 及更早版本中：
        
        1. 選取啟用內嵌內容的 OAuth 存取核取方塊。
        2. 在簽發者 URL文字方塊中，貼上 EAS 的簽發者 URL。
        3. 按一下「儲存暫止的變更」按鈕。
            
            ![註冊外部授權伺服器表單。](/tableau/current/zh-tw/server-linux/zh-tw/Img/connectedapp_eas_register.png)
4. 完成後，請執行以下操作：
    1. 在頁面右上角，按一下暫止的變更按鈕。
    2. 在頁面右下角，按一下套用變更並重新啟動按鈕以停止並重新啟動 Tableau Server。
        
        ![待授權的外部設定變更清單，其中包含「套用」或「捨棄」變更的選項。](/tableau/current/zh-tw/server-linux/zh-tw/Img/connectedapp_eas_save.png)

### 選項 2：使用 TSM CLI

1. 在叢集中的初始節點（安裝 TSM）上以管理員身分開啟命令提示字元。
2. 執行以下命令：
    
    tsm configuration set -k vizportal.oauth.external\_authorization.enabled -v true
    tsm configuration set -k vizportal.oauth.external\_authorization\_server.issuer -v "<issuer\_url\_of\_EAS>"
    tsm restart

從 Tableau Server 2024.2 開始，可以為站台註冊一個或多個 EAS。在站台層級註冊 EAS 後，建立的信任關係僅適用於站台。

**附註：** 設定站台層級 EAS 的先決條件是在 TSM 中啟用已連線應用程式。

### 步驟 1：啟用已連線應用程式

1. 若是 Tableau Server 管理員，請登入到 Tableau 服務管理員 (TSM) Web UI。有關詳情，請參閱[登入到 Tableau 服務管理員 Web UI](https://help.tableau.com/current/server-linux/zh-tw/sign_in_tsm.htm#sign-in-to-the-tsm-web-ui)。
2. 巡覽至「使用者身分和存取」頁面 > 「已連線應用程式」索引標籤。
3. 選取啟用已連線應用程式核取方塊。
4. 執行以下_其中一項_動作：
    
    - 選取第一個選項按鈕「允許已連線應用程式（在站台層級設定）」，以啟用僅在站台層級註冊 EAS。
        
        ![](/tableau/current/zh-tw/server-linux/zh-tw/Img/connectedapp_eas_register_radio.png)
    - （預設）選取第二個選項按鈕「允許已連線應用程式（在站台層級設定）和伺服器範圍的 OAuth 2.0 信任（設定如下）」，以啟用在站台層級和伺服器範圍註冊 EAS。若選擇此選項，請確保在站台層級指定的簽發者 URL 與伺服器範圍的簽發者 URL 不同。
        
        ![](/tableau/current/zh-tw/server-linux/zh-tw/Img/connectedapp_eas_register_radio_default.png)
5. 按一下「儲存暫止的變更」按鈕。
6. 完成後，請執行以下操作：
    1. 在頁面右上角，按一下暫止的變更按鈕。
    2. 在頁面右下角，按一下套用變更並重新啟動按鈕以停止並重新啟動 Tableau Server。

### 步驟 2：註冊 EAS

1. 作為 Tableau Server 管理員，登入 Tableau Server。
2. 從左窗格中，選取設定 > 已連線應用程式。
3. 按一下「新建已連線應用程式」按鈕下拉箭頭，並選取 OAuth 2.0 信任。
4. 在「建立已連線應用程式」對話方塊中，執行以下動作：  
    1. 在「名稱」文字方塊中，輸入已連線應用程式的名稱。
    2. 在簽發者 URL文字方塊中，貼上 EAS 的簽發者 URL。
    3. 選取啟用已連線應用程式。出於安全考慮，預設情況下，已連線應用程式在建立時會設定為停用。
    4. 完成後，按一下建立按鈕。
    ![](/tableau/current/zh-tw/server-linux/zh-tw/Img/connectedapp_create_eas.png)
5. 建立連線的應用程式後，複製已連線應用程式的站台 ID。該站台 ID 用於上述第 1 步中描述的 JWT 的“aud”（受眾）聲明。
    
    ![外部授權伺服器的詳細資料，其中包含複製站台 ID 的按鈕。](/tableau/current/zh-tw/server-linux/zh-tw/Img/connectedapp_eas_button_luid.png)

### 步驟 3：後續步驟

#### 對於內嵌工作流程

將 Tableau Server 設定為使用 EAS 後，必須將內嵌程式碼新增到外部應用程式中。確保在外部應用程式呼叫的 Web 元件中包含 EAS 產生的有效 JWT，如步驟 1 中所述。

有關內嵌 Tableau 內容的詳情，請參閱以下內容：

- 使用 [Tableau 內嵌 API v3](https://help.tableau.com/current/api/embedding_api/zh-tw/index.html) 內嵌 Tableau 內容。
- 有關基於屬性的存取控制 (ABAC)、按需存取和動態群組成員資格的使用者屬性，請參閱 Tableau 內嵌 API v3 中的[自訂和控制資料存取](https://help.tableau.com/current/api/embedding_api/zh-tw/docs/embedding_api_user_attributes.html) 。
- 內嵌指標，請參閱 Tableau 說明中的主題[將指標內嵌到網頁中](https://help.tableau.com/current/pro/desktop/zh-tw/embed_metrics.htm)。（在 Tableau Server 2023.3，Tableau 已淘汰內嵌指標功能。）

**附註：**為了讓使用者在存取內嵌內容時成功進行驗證，必須將瀏覽器設定為允許協力廠商 Cookie。

##### 使用內嵌網域允許清單控制內容的內嵌位置

從 Tableau Server 2023.3， 您和您的使用者可以使用 Tableau REST API 中的「更新站台內嵌設定」方法來控制是否可以不受限制地內嵌 Tableau 內容或限制為某些網域。

預設情況下，`unrestrictedEmbedding` 內嵌的站台設定設定為 `true` 以允許不受限制的內嵌。或者，您和您的使用者可以將設定設定為 `false` 並使用以下命令指定可以內嵌外部應用程式中的 Tableau 內容網域 `allowList` 範圍。

有關詳情，請參閱以下內容（之一）：

- 在 Tableau REST API 說明中[更新站台的內嵌設定](https://help.tableau.com/current/api/rest_api/zh-tw/REST/rest_api_ref_site.htm#update_embedding_settings_for_site)
- 在 Tableau Embedding API v3 說明中[用於內嵌的 Tableau 站台設定](https://help.tableau.com/current/api/embedding_api/en-us/docs/embedding_api_site.html#about-tableau-site-settings-for-embedding)。

#### 對於 REST API 授權工作流程

設定 JWT 後，必須將有效的 JWT 新增到 REST API 登入請求以進行授權存取。有關詳細資訊，請參閱[已連線應用程式的存取範圍](https://help.tableau.com/current/server-linux/zh-tw/connected_apps_scopes.htm)。

#### 對於中繼資料 API 工作流程

設定 JWT 後，必須將有效的 JWT 新增至 REST API 登入請求。有關詳細資訊，請參閱[已連線應用程式的存取範圍](https://help.tableau.com/current/server-linux/zh-tw/connected_apps_scopes.htm)。

#### SCIM 外部權杖工作量流程

JWT 設定完成後，必須啟用 SCIM 功能。有關更多資訊，請參閱 [使用 OAuth 2.0 信任設定已連線應用程式](#scim)。

### 已知問題（僅限嵌入工作流程）

使用已連線應用程式時存在一些已知問題，這些問題將在未來版本中解決。

- **工具列功能：**內嵌內容定義工具列參數時，並非所有工具列功能都可以使用。要解決此問題，我們建議如下方範例一樣隱藏工具列參數。
    
    <tableau-viz id='tab-viz' src='https://<your\_server>/t/<your\_site>/...'
    	toolbar='hidden'>
    </tableau-viz>

- **已發佈資料來源：**將不會顯示設定為提示使用者提供資料庫認證的已發佈資料來源。要盡可能解決此問題，我們建議資料來源所有者改為內嵌齊資料庫認證。
- **多個站台上的內嵌檢視：** 在 Tableau Server 2023.1 及更早版本中，在同一瀏覽器中不同站台上的檢視之間切換會導致錯誤 1008：無法取得連線應用程式的密碼。若要解決此問題，請升級至 Tableau Server 2023.3 或更高版本。

### 疑難排解

內嵌內容無法在外部應用程式中顯示或 Tableau REST API 授權失敗時，可以使用瀏覽器的開發人員工具來檢查和識別可能與 Tableau Server 上啟用的 EAS 功能相關的錯誤代碼。

請參閱下表，查看錯誤代碼和潛在解決方案的說明。

<table style="width: 90%;margin-left: 0;margin-right: auto;mc-table-style: url('Resources/TableStyles/Basic-Border-Light.css');" class="TableStyle-Basic-Border" cellspacing="0"><colgroup><col class="TableStyle-Basic-Border-Column-Column1"><col class="TableStyle-Basic-Border-Column-Column1"><col class="TableStyle-Basic-Border-Column-Column1"><col class="TableStyle-Basic-Border-Column-Column1"></colgroup><tbody><tr class="TableStyle-Basic-Border-Body-Body1"><td class="TableStyle-Basic-Border-BodyE-Column1-Body1" style="font-weight: bold;">錯誤程式碼</td><td class="TableStyle-Basic-Border-BodyE-Column1-Body1" style="font-weight: bold;">彙總</td><td class="TableStyle-Basic-Border-BodyE-Column1-Body1" style="font-weight: bold;">描述</td><td class="TableStyle-Basic-Border-BodyD-Column1-Body1" style="font-weight: bold;">潛在的解決方案或解釋</td></tr><tr class="TableStyle-Basic-Border-Body-Body1"><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">5</td><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">SYSTEM_USER_NOT_FOUND</td><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">找不到 Tableau 使用者</td><td class="TableStyle-Basic-Border-BodyD-Column1-Body1"><br>要解決此問題，請驗證 JWT 中的「<code>sub</code>」（主題）宣告值為經過驗證的 Tableau Server 的「使用者名稱」。此值區分大小寫。</td></tr><tr class="TableStyle-Basic-Border-Body-Body1"><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">16</td><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">LOGIN_FAILED</td><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">登入失敗</td><td class="TableStyle-Basic-Border-BodyD-Column1-Body1">此錯誤通常是由 JWT 中的以下宣告問題之一引起的：<ul><li>「<code>exp</code>」（到期時間）超過預設的最大有效期限。要解決此問題，請查看有效 JWT 所需的<a href="https://help.tableau.com/current/server/zh-tw/connected_apps_eas.htm#jwt" target="_blank">已註冊宣告</a>並確保使用正確的值。要更改最長有效期限，可以使用 <a href="https://help.tableau.com/current/server-linux/zh-tw/cli_configuration-set_tsm.htm#eas_max_expiration_period" class="xref">vizportal.oauth.external_authorization_server.max_expiration_period_in_minutes</a>命令。</li><li>「<code>sub</code>」（主題）正在呼叫未知使用者。要解決此問題，請驗證「<code>sub</code>」宣告為「使用者名稱」。此值區分大小寫。</li></ul></td></tr><tr class="TableStyle-Basic-Border-Body-Body1"><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">67</td><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">FEATURE_NOT_ENABLED</td><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">不支援隨需存取</td><td class="TableStyle-Basic-Border-BodyD-Column1-Body1">僅可透過獲得授權的 Tableau Cloud 站台進行隨需存取。</td></tr><tr class="TableStyle-Basic-Border-Body-Body1"><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">10081</td><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">COULD_NOT_RETRIEVE_IDP_METADATA</td><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">缺少 EAS 元中繼資料端點</td><td class="TableStyle-Basic-Border-BodyD-Column1-Body1">要解決此問題，請驗證 EAS 配置正確並且呼叫正確的簽發者。</td></tr><tr class="TableStyle-Basic-Border-Body-Body1"><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">10082</td><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">AUTHORIZATION_SERVER_ISSUER_NOT_SPECIFIED</td><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">缺少簽發者</td><td class="TableStyle-Basic-Border-BodyD-Column1-Body1">要解決此問題，請驗證呼叫的是正確的簽發者。要變更簽發者 URL，可以使用 <a href="https://help.tableau.com/current/server-linux/zh-tw/cli_configuration-set_tsm.htm#eas_issuer" class="xref">vizportal.oauth.external_authorization_server.issuer</a>命令。</td></tr><tr class="TableStyle-Basic-Border-Body-Body1"><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">10083</td><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">BAD_JWT</td><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">JWT 標頭含有問題</td><td class="TableStyle-Basic-Border-BodyD-Column1-Body1">JWT 標頭中缺少「<code>kid</code>」（密碼 ID）或「<code>clientId</code>」（簽發者）宣告。要解決此問題，請確保包含此資訊。</td></tr><tr class="TableStyle-Basic-Border-Body-Body1"><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">10084</td><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">JWT_PARSE_ERROR</td><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">JWT 含有問題</td><td class="TableStyle-Basic-Border-BodyD-Column1-Body1">要解決此問題，請驗證以下內容：<ul><li>JWT 中引用的「<code>aud</code>」（受眾）值使用「tableau」值。此值區分大小寫。</li><li>JWT 中包含「<code>aud</code>」（受眾）和「<code>sub</code>」（主題）。</li></ul></td></tr><tr class="TableStyle-Basic-Border-Body-Body1"><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">10085</td><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">COULD_NOT_FETCH_JWT_KEYS</td><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">JWT 找不到金鑰</td><td class="TableStyle-Basic-Border-BodyD-Column1-Body1">找不到密碼。<p>要解決此問題，請驗證呼叫的是正確的簽發者。要變更簽發者 URL，可以使用 <a href="https://help.tableau.com/current/server-linux/zh-tw/cli_configuration-set_tsm.htm#eas_issuer" class="xref">vizportal.oauth.external_authorization_server.issuer</a>命令。</p></td></tr><tr class="TableStyle-Basic-Border-Body-Body1"><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">10087</td><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">BLOCKLISTED_JWS_ALGORITHM_USED_TO_SIGN</td><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">JWT 簽章演算法的問題</td><td class="TableStyle-Basic-Border-BodyD-Column1-Body1">要解決此問題，可以移除簽章演算法。有關詳情，請參閱 <a href="https://help.tableau.com/current/server-linux/zh-tw/cli_configuration-set_tsm.htm#eas_algorithms" class="xref">vizportal.oauth.external_authorization_server.blocklisted_jws_algorithms</a>。</td></tr><tr class="TableStyle-Basic-Border-Body-Body1"><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">10088</td><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">RSA_KEY_SIZE_INVALID</td><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">JWT 簽章要求問題</td><td class="TableStyle-Basic-Border-BodyD-Column1-Body1">要解決此問題，請使用 EAS 或 IdP 驗證 JWT 是否使用大小為 2048 的 RSA 金鑰進行簽章。</td></tr><tr class="TableStyle-Basic-Border-Body-Body1"><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">10091</td><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">JTI_ALREADY_USED</td><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">需要唯一的 JWT</td><td class="TableStyle-Basic-Border-BodyD-Column1-Body1">JWT 已經用於身份驗證過程。要解決此問題，EAS 或 IdP 必須產生新的 JWT。</td></tr><tr class="TableStyle-Basic-Border-Body-Body1"><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">10092</td><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">NOT_IN_DOMAIN_ALLOW_LIST</td><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">未指定內嵌內容的網域</td><td class="TableStyle-Basic-Border-BodyD-Column1-Body1">要解決此問題，請確保將 <code>unrestrictedEmbedding</code> 設定設定為 <code>true</code>，或者讓 <code>domainAllowlist</code> 參數包括使用 Tableau REST API 中<a href="https://help.tableau.com/current/api/rest_api/en-us/REST/rest_api_ref_site.htm#embedding_settings_for_site" target="_blank">更新站台的內嵌設定</a>的方法內嵌 Tableau 內容的網域。</td></tr><tr class="TableStyle-Basic-Border-Body-Body1"><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">10094</td><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">MISSING_REQUIRED_JTI</td><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">缺少 JWT ID</td><td class="TableStyle-Basic-Border-BodyD-Column1-Body1">要解決此問題，請驗證 JWT 中包含「<code>jti</code>」（JWT ID）。</td></tr><tr class="TableStyle-Basic-Border-Body-Body1"><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">10096</td><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">JWT_EXPIRATION_EXCEEDS_CONFIGURED_EXPIRATION_PERIOD</td><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">&nbsp;</td><td class="TableStyle-Basic-Border-BodyD-Column1-Body1">「<code>exp</code>」（到期時間）超過預設的最大有效期限。要解決此問題，請查看有效 JWT 所需的<a href="https://help.tableau.com/current/server/zh-tw/connected_apps_eas.htm#jwt" target="_blank">已註冊宣告</a>並確保使用正確的值。要更改最長有效期限，可以使用 <a href="https://help.tableau.com/current/server-linux/zh-tw/cli_configuration-set_tsm.htm#eas_max_expiration_period" class="xref">vizportal.oauth.external_authorization_server.max_expiration_period_in_minutes</a>命令。</td></tr><tr class="TableStyle-Basic-Border-Body-Body1"><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">10097</td><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">SCOPES_MALFORMED</td><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">範圍宣告問題</td><td class="TableStyle-Basic-Border-BodyD-Column1-Body1">如果 JWT 中缺少「<code>scp</code>」(Scope) 宣告，或未作為清單類型傳遞，則會出現此錯誤。要解決此問題，請驗證 JWT 中包含「<code>scp</code>」，並作為清單類型傳遞。有關 JWT 的疑難排解說明，請參閱 auth0 站台上的<a href="https://jwt.io/" target="_blank">偵錯工具</a>。</td></tr><tr class="TableStyle-Basic-Border-Body-Body1"><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">10098</td><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">JWT_UNSIGNED_OR_ENCRYPTED</td><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">JWT 未簽章或加密</td><td class="TableStyle-Basic-Border-BodyD-Column1-Body1">Tableau 不支援未簽章或加密的 JWT。</td></tr><tr class="TableStyle-Basic-Border-Body-Body1"><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">10099</td><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">SCOPES_MISSING_IN_JWT</td><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">缺少範圍宣告</td><td class="TableStyle-Basic-Border-BodyD-Column1-Body1">JWT 缺少所需的「<code>scp</code>」（範圍）宣告。要解決此問題，請驗證 JWT 中包含「<code>scp</code>」。有關 JWT 的疑難排解說明，請參閱 auth0 站台上的<a href="https://jwt.io/" target="_blank">偵錯工具</a>。</td></tr><tr class="TableStyle-Basic-Border-Body-Body1"><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">10100</td><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">JTI_PERSISTENCE_FAILED</td><td class="TableStyle-Basic-Border-BodyE-Column1-Body1">意外的 JWT ID 錯誤</td><td class="TableStyle-Basic-Border-BodyD-Column1-Body1">出現「<code>jti</code>」（JWT 識別碼）意外錯誤。要解決此問題，必須產生具有新的「<code>jti</code>」的新 JWT。</td></tr><tr class="TableStyle-Basic-Border-Body-Body1"><td class="TableStyle-Basic-Border-BodyB-Column1-Body1">10103</td><td class="TableStyle-Basic-Border-BodyB-Column1-Body1">JWT_MAX_SIZE_EXCEEDED</td><td class="TableStyle-Basic-Border-BodyB-Column1-Body1">JWT 超出最大大小</td><td class="TableStyle-Basic-Border-BodyA-Column1-Body1">當 JWT 大小超過 8000 位元時，可能會發生此錯誤。要解決此問題，請確保僅將必要的宣告傳遞給 <span class="mc-variable Variables.ProductName variable">Tableau Server</span>。</td></tr></tbody></table>