Sun Java logo     上一頁      目錄      索引      下一頁     

Sun logo
Sun Java System Portal Server Secure Remote Access 6 2005Q1 管理指南 

第 7 章
憑證

本章說明憑證管理並解釋如何安裝自簽的憑證與來自認證機構 (CA) 的憑證。

本章涵蓋下列主題:


SSL 憑證簡介

Sun Java™ System Portal Server Secure Remote Access 軟體提供基於憑證的遠端使用者認證。SRA 使用安全套接層 (SSL) 以啟用安全通訊。此 SSL 通訊協定可實現兩部機器之間的安全通訊。

SSL 憑證使用公開金鑰與私人金鑰對提供加密與解密功能。

有兩種類型的憑證:

依預設,當您安裝閘道時,系統會產生並安裝自簽憑證。

安裝之後,您可以隨時產生、獲得或取代憑證。

SRA 同時支援使用個人數位憑證 (PDC) 的用戶端認證。PDC 是一種機制,可透過 SSL 用戶端認證進行使用者認證。有了 SSL 用戶端認證,SSL 訊號交換模式便會於閘道結束。閘道會擷取使用者的 PDC 並將它傳送到認證伺服器。而此伺服器會使用 PDC 認證使用者。若要配置 PDC 與認證鏈接,請參閱使用認證鏈接

SRA 提供名為 certadmin 的工具,可讓您用來管理 SSL 憑證。請參閱 certadmin 程序檔


備註

憑證快顯式視窗在 SSL 應用程式中很常見。建議使用者接受警告並繼續執行。



憑證檔案

與憑證相關的檔案位於 /etc/opt/SUNWps/cert/gateway-profile-name。此目錄依預設包含 5 個檔案。

表 7-1 列出這些檔案及其說明。

表 7-1  憑證檔案

檔案名稱

類型

描述

cert8.db, key3.db, secmod.db

二進位

包含憑證、密鑰和密碼編譯模組的資料。

可以使用 certadmin 程序檔進行操控。

與 Sun Java System Web Server 使用的資料庫檔案具有相同的格式,其中檔案位於 portal-server-install-root/SUNWwbsvr/alias

如有必要,這些檔案可以在 Portal Server 主機和閘道元件或閘道之間共享使用。

.jsspass

隱藏文字檔

包含用於 SRA 密鑰資料庫的加密密碼。

.nickname

隱藏文字檔

token-name:certificate-name 格式儲存閘道需要使用的記號與憑證的名稱。

若您正在使用預設記號 (預設內部軟體加密模組的記號),請省略記號名稱。在大部分的情形下,.nickname 檔案僅會儲存憑證名稱。

身為管理員,您可以修改此檔案中的憑證名稱。閘道現在將使用您所指定的憑證。


憑證信任屬性

憑證的信任屬性表示以下資訊:

每種憑證有三種可能的信任種類,說明順序為:「SSL、電子郵件、物件簽署」。只有第一種類別可用於取得閘道。在每個種類位置中,可以使用零或其他信任屬性代碼。

種類的屬性代碼由逗號隔開,而整個屬性集則是由引號環繞。例如,閘道安裝期間產生並安裝的自簽憑證標記為「u,u,u」,表示此憑證為伺服器憑證 (使用者憑證),而不是根 CA 憑證。

表 7-2 列出可能的屬性值與每個值的意義。

表 7-2  憑證信任屬性 

屬性

描述

p

有效點

P

可信任點 (暗含 p)

c

有效 CA

T

可信任的 CA 核發用戶端憑證 (暗含 c)

C

可信任的 CA 核發伺服器憑證 (僅限 SSL) (暗含 c)

u

憑證可以用於認證或簽署

w

傳送警告 (在該環境中使用憑證時,與其他屬性一起使用以便包含一個警告)


CA 信任屬性

憑證資料庫中包含眾所皆知的公開 CA。有關修改公開 CA 信任屬性的資訊,請參閱修改憑證的信任屬性

表 7-3 列出眾多共用的認證機構及其信任屬性。

表 7-3  公開認證機構 

認證機構名稱

信任屬性

Verisign/RSA Secure Server CA

CPp,CPp,CPp

VeriSign Class 4 Primary CA

CPp,CPp,CPp

GTE CyberTrust Root CA

CPp,CPp,CPp

GTE CyberTrust Global Root

CPp,CPp,CPp

GTE CyberTrust Root 5

CPp,CPp,CPp

GTE CyberTrust Japan Root CA

CPp,CPp,CPp

GTE CyberTrust Japan Secure Server CA

CPp,CPp,CPp

Thawte Personal Basic CA

CPp,CPp,CPp

Thawte Personal Premium CA

CPp,CPp,CPp

Thawte Personal Freemail CA

CPp,CPp,CPp

Thawte Server CA

CPp,CPp,CPp

Thawte Premium Server CA

CPp,CPp,CPp

American Express CA

CPp,CPp,CPp

American Express Global CA

CPp,CPp,CPp

Equifax Premium CA

CPp,CPp,CPp

Equifax Secure CA

CPp,CPp,CPp

BelSign Object Publishing CA

CPp,CPp,CPp

BelSign Secure Server CA

CPp,CPp,CPp

TC TrustCenter, Germany, Class 0 CA

CPp,CPp,CPp

TC TrustCenter, Germany, Class 1 CA

CPp,CPp,CPp

TC TrustCenter, Germany, Class 2 CA

CPp,CPp,CPp

TC TrustCenter, Germany, Class 3 CA

CPp,CPp,CPp

TC TrustCenter, Germany, Class 4 CA

CPp,CPp,CPp

ABAecom (sub., Am. Bankers Assn.)Root CA

CPp,CPp,CPp

Digital Signature Trust Co. Global CA 1

CPp,CPp,CPp

Digital Signature Trust Co. Global CA 3

CPp,CPp,CPp

Digital Signature Trust Co. Global CA 2

CPp,CPp,CPp

Digital Signature Trust Co. Global CA 4

CPp,CPp,CPp

Deutsche Telekom AG Root CA

CPp,CPp,CPp

Verisign Class 1 Public Primary Certification Authority

CPp,CPp,CPp

Verisign Class 2 Public Primary Certification Authority

CPp,CPp,CPp

Verisign Class 3 Public Primary Certification Authority

CPp,CPp,CPp

Verisign Class 1 Public Primary Certification Authority - G2

CPp,CPp,CPp

Verisign Class 2 Public Primary Certification Authority - G2

CPp,CPp,CPp

Verisign Class 3 Public Primary Certification Authority - G2

CPp,CPp,CPp

Verisign Class 4 Public Primary Certification Authority - G2

CPp,CPp,CPp

GlobalSign Root CA

CPp,CPp,CPp

GlobalSign Partners CA

CPp,CPp,CPp

GlobalSign Primary Class 1 CA

CPp,CPp,CPp

GlobalSign Primary Class 2 CA

CPp,CPp,CPp

GlobalSign Primary Class 3 CA

CPp,CPp,CPp

ValiCert Class 1 VA

CPp,CPp,CPp

ValiCert Class 2 VA

CPp,CPp,CPp

ValiCert Class 3 VA

CPp,CPp,CPp

Thawte Universal CA Root

CPp,CPp,CPp

Verisign Class 1 Public Primary Certification Authority - G3

CPp,CPp,CPp

Verisign Class 2 Public Primary Certification Authority - G3

CPp,CPp,CPp

Verisign Class 3 Public Primary Certification Authority - G3

CPp,CPp,CPp

Verisign Class 4 Public Primary Certification Authority - G3

CPp,CPp,CPp

Entrust.net Secure Server CA

CPp,CPp,CPp

Entrust.net Secure Personal CA

CPp,CPp,CPp

Entrust.net Premium 2048 Secure Server CA

CPp,CPp,CPp

ValiCert OCSP Responder

CPp,CPp,CPp

Baltimore CyberTrust Code Signing Root

CPp,CPp,CPp

Baltimore CyberTrust Root

CPp,CPp,CPp

Baltimore CyberTrust Mobile Commerce Root

CPp,CPp,CPp

Equifax Secure Global eBusiness CA

CPp,CPp,CPp

Equifax Secure eBusiness CA 1

CPp,CPp,CPp

Equifax Secure eBusiness CA 2

CPp,CPp,CPp

Visa International Global Root 1

CPp,CPp,CPp

Visa International Global Root 2

CPp,CPp,CPp

Visa International Global Root 3

CPp,CPp,CPp

Visa International Global Root 4

CPp,CPp,CPp

Visa International Global Root 5

CPp,CPp,CPp

beTRUSTed Root CA

CPp,CPp,CPp

Xcert Root CA

CPp,CPp,CPp

Xcert Root CA 1024

CPp,CPp,CPp

Xcert Root CA v1

CPp,CPp,CPp

Xcert Root CA v1 1024

CPp,CPp,CPp

Xcert EZ

CPp,CPp,CPp

CertEngine CA

CPp,CPp,CPp

BankEngine CA

CPp,CPp,CPp

FortEngine CA

CPp,CPp,CPp

MailEngine CA

CPp,CPp,CPp

TraderEngine CA

CPp,CPp,CPp

USPS Root

CPp,CPp,CPp

USPS Production 1

CPp,CPp,CPp

AddTrust Non-Validated Services Root

CPp,CPp,CPp

AddTrust External Root

CPp,CPp,CPp

AddTrust Public Services Root

CPp,CPp,CPp

AddTrust Qualified Certificates Root

CPp,CPp,CPp

Verisign Class 1 Public Primary OCSP Responder

CPp,CPp,CPp

Verisign Class 2 Public Primary OCSP Responder

CPp,CPp,CPp

Verisign Class 3 Public Primary OCSP Responder

CPp,CPp,CPp

Verisign Secure Server OCSP Responder

CPp,CPp,CPp

Verisign Time Stamping Authority CA

CPp,CPp,CPp

Thawte Time Stamping CA

CPp,CPp,CPp

E-Certify CA

CPp,CPp,CPp

E-Certify RA

CPp,CPp,CPp

Entrust.net Global Secure Server CA

CPp,CPp,CPp

Entrust.net Global Secure Personal CA

CPp,CPp,CPp


certadmin 程序檔

您可以使用 certadmin 程序檔執行下列憑證管理工作:


產生自簽憑證

您需要為每個伺服器和閘道之間的 SSL 通訊產生憑證。

    安裝之後若要產生自簽憑證

  1. 以 root 身份,在您想要產生憑證的閘道機器上執行 certadmin 程序檔:
  2. portal-server-install-root/SUNWps/bin/certadmin -n gateway-profile-name

    系統便會顯示憑證管理功能表。

    1) Generate Self-Signed Certificate

    2) Generate Certificate Signing Request (CSR)

    3) Add Root CA Certificate

    4) Install Certificate From Certificate Authority (CA)

    5) Delete Certificate

    6) Modify Trust Attributes of Certificate (e.g., for PDC)

    7) List Root CA Certificates

    8) List All Certificates

    9) Print Certificate Content

    10) Quit

    choice: [10] 1

  3. 在憑證管理功能表上選擇選項 1
  4. 憑證管理程序檔會詢問您是否想要保留現有的資料庫檔案。

  5. 請輸入機構特定的資訊、記號名稱和憑證名稱。

    備註     

    關於萬用字元憑證,請在主機的完全合格的 DNS 名稱中指定一個 * 號。例如,如果主機的完全合格 DNS 名稱為 abc.sesta.com,請指定為 *.sesta.com。產生的憑證現在對於 sesta.com 網域中的所有主機名稱而言,都有效。


  6. What is the fully-qualified DNS name of this host?[host_name.domain_name]

    What is the name of your organization (ex:Company)? []

    What is the name of your organizational unit (ex:division)? []

    What is the name of your City or Locality? []

    What is the name (no abbreviation please) of your State or Province? []

    What is the two-letter country code for this unit? []

    Token name is needed only if you are not using the default internal (software) cryptographic module, for example, if you want to use a crypto card (Token names could be listed using:modutil -dbdir /etc/opt/SUNWps/cert/gateway-profile-name -list); Otherwise, just hit Return below.

    Please enter the token name. []

    Enter the name you like for this certificate?

    Enter the validity period for the certificate (months) [6]

    A self-signed certificate is generated and the prompt returns.

    記號名稱 (預設空白) 和憑證名稱儲存於 /etc/opt/SUNWps/cert/gateway-profile-name 之下的 .nickname 檔案中。

  7. 重新啟動憑證閘道才會生效:
  8. gateway-install-root/SUNWps/bin/gateway -n new gateway-profile-name start


產生憑證簽署要求 (CSR)

可以從 CA 訂製憑證之前,您需要產生包含 CA 所需要資訊的憑證簽署要求。

    若要產生 CSR
  1. 以超級使用者身份執行 certadmin 程序檔:
  2. portal-server-install-root/SUNWps/bin/certadmin -n gateway-profile-name

    系統便會顯示憑證管理功能表。

    1) Generate Self-Signed Certificate

    2) Generate Certificate Signing Request (CSR)

    3) Add Root CA Certificate

    4) Install Certificate From Certificate Authority (CA)

    5) Delete Certificate

    6) Modify Trust Attributes of Certificate (e.g., for PDC)

    7) List Root CA Certificates

    8) List All Certificates

    9) Print Certificate Content

    10) Quit

    choice: [10] 2

  3. 在憑證管理功能表上選擇選項 2
  4. 程序檔提示您輸入機構特定的資訊、記號名稱和網路管理員電子郵件及電話號碼。

    請指定主機的完整合格 DNS 名稱。

    What is the fully-qualified DNS name of this host?[snape.sesta.com]

    What is the name of your organization (ex:Company)? []

    What is the name of your organizational unit (ex:division)? []

    What is the name of your City or Locality? []

    What is the name (no abbreviation please) of your State or Province? []

    What is the two-letter country code for this unit? []

    Token name is needed only if you are not using the default internal (software) cryptographic module, for example, if you want to use a crypto card (Token names could be listed using:modutil -dbdir /etc/opt/SUNWps/cert -list); Otherwise, just hit Return below.

    Please enter the token name []

    Now input some contact information for the webmaster of the machine that the certificate is to be generated for.

    What is the email address of the admin/webmaster for this server [] ?

    What is the phone number of the admin/webmaster for this server [] ?

  5. 輸入所有需要的資訊。

  6. 備註

    請務必填寫網路管理員電子郵件和電話號碼。為了獲得有效的 CSR,必須填寫這兩項資訊。


CSR 會產生並儲存於 portal-server-install-root/SUNWps/bin/csr.hostname.datetimestamp 檔案中。CSR 同時會顯示於螢幕上。當您從 CA 訂製憑證時,可以直接複製並貼上 CSR。


新增根 CA 憑證

若用戶端站台提交的的憑證由閘道憑證資料庫中不包含的 CA 所簽署,則 SSL 訊號交換模式將會失敗。

若要避免這種情況,您需要新增根 CA 憑證到憑證資料庫。這項動作可以確保 CA 變成閘道所知的 CA。

瀏覽至 CA 的網站並獲得此 CA 的根憑證。當您使用 certadmin 程序檔時,請指定根 CA 憑證的檔案名稱和路徑。

    若要新增根 CA 憑證
  1. 以超級使用者身份執行 certadmin 程序檔。
  2. portal-server-install-root/SUNWps/bin/certadmin -n gateway-profile-name

    系統便會顯示憑證管理功能表。

    1) Generate Self-Signed Certificate

    2) Generate Certificate Signing Request (CSR)

    3) Add Root CA Certificate

    4) Install Certificate From Certificate Authority (CA)

    5) Delete Certificate

    6) Modify Trust Attributes of Certificate (e.g., for PDC)

    7) List Root CA Certificates

    8) List All Certificates

    9) Print Certificate Content

    10) Quit

    choice: [10] 3

  3. 在憑證管理功能表上選擇選項 3
  4. 輸入包含根憑證的檔案名稱並輸入憑證名稱。
  5. 根 CA 憑證將會新增至憑證資料庫。


安裝來自認證機構的 SSL 憑證

閘道安裝期間,依預設系統會建立自簽憑證並安裝。在安裝之後的任何時間,您都可以安裝由供應商或由您公司的 CA 提供簽署的 SSL 憑證,其中這些供應商會提供正式的認證機構 (CA) 服務。

這項工作包含的三個步驟為:

從 CA 訂製憑證

產生憑證簽署要求 (CSR) 之後,您需要使用 CSR 從 CA 訂製憑證。

    若要從 CA 訂製憑證
  1. 請至認證機構的網站並訂製您的憑證。
  2. 提供 CA 所要求的 CSR。若 CA 要求請提供其他資訊。
  3. 您將會收到 CA 簽署的憑證。請將它儲存在檔案中。檔案中憑證內容前後請包含「BEGIN CERTIFICATE」和「END CERTIFICATE」兩行。

    下面的範例省略了實際的憑證資料。

    -----BEGIN CERTIFICATE-----

    The certificate contents...

    ----END CERTIFICATE-----

安裝來自 CA 的憑證

使用 certadmin 程序檔,將您從 CA 獲得的憑證安裝在本機資料庫檔案中,路徑是 /etc/opt/SUNWps/certgateway-profile-name

    若要安裝來自 CA 的憑證
  1. 以超級使用者身份執行 certadmin 程序檔。
  2. portal-server-install-root/SUNWps/bin/certadmin -n gateway-profile-name

    系統便會顯示憑證管理功能表。

    1) Generate Self-Signed Certificate

    2) Generate Certificate Signing Request (CSR)

    3) Add Root CA Certificate

    4) Install Certificate From Certificate Authority (CA)

    5) Delete Certificate

    6) Modify Trust Attributes of Certificate (e.g., for PDC)

    7) List Root CA Certificates

    8) List All Certificates

    9) Print Certificate Content

    10)Quit

    choice: [10] 4

  3. 在憑證管理功能表上選擇選項 4
  4. 程序檔會讓您輸入憑證檔案名稱、憑證名稱和記號名稱。

    What is the name (including path) of file that contains the certificate?

    Please enter the token name you used when creating CSR for this certificate. []

  5. 提供所有需要的資訊。
  6. 憑證將安裝於 /etc/opt/SUNWps/certgateway-profile-name,而且系統會傳回螢幕提示。

  7. 重新啟動憑證閘道才會生效:
  8. gateway-install-root/SUNWps/bin/gateway -n gateway-profile-name start


刪除憑證

您可以使用憑證管理程序檔刪除憑證。

    若要刪除憑證
  1. 以超級使用者身份執行 certadmin 程序檔。
  2. portal-server-install-root/SUNWps/bin/certadmin -n gateway-profile-name

    其中 gateway-profile-name 是閘道實例的名稱。

    系統便會顯示憑證管理功能表。

    1) Generate Self-Signed Certificate

    2) Generate Certificate Signing Request (CSR)

    3) Add Root CA Certificate

    4) Install Certificate From Certificate Authority (CA)

    5) Delete Certificate

    6) Modify Trust Attributes of Certificate (e.g., for PDC)

    7) List Root CA Certificates

    8) List All Certificates

    9) Print Certificate Content

    10)Quit

    choice: [10] 5

  3. 在憑證管理功能表上選擇選項 5
  4. 輸入要刪除的憑證名稱。


修改憑證的信任屬性

若用戶端認證與閘道一起使用,憑證信任屬性則需要修改。其中一個用戶端認證範例為 PDC (個人數位憑證)。核發 PDC 的 CA 必須受閘道所信任,其中 CA 憑證的 SSL 標記必須為「T」。

若閘道設為與 HTTPS 站台通訊,HTTPS 站台伺服器憑證的 CA 必須受閘道所信任,而且 CA 憑證的 SSL 標記 必須為「C」。

    若要修改憑證的信任屬性
  1. 以超級使用者身份執行 certadmin 程序檔。
  2. gateway-install-root/SUNWps/bin/certadmin -n gateway-profile-name

    其中 gateway-profile-name 是閘道實例的名稱。

    系統便會顯示憑證管理功能表。

    1) Generate Self-Signed Certificate

    2) Generate Certificate Signing Request (CSR)

    3) Add Root CA Certificate

    4) Install Certificate From Certificate Authority (CA)

    5) Delete Certificate

    6) Modify Trust Attributes of Certificate (e.g., for PDC)

    7) List Root CA Certificates

    8) List All Certificates

    9) Print Certificate Content

    10)Quit

    choice: [10] 6

  3. 在憑證管理功能表上選擇選項 6
  4. 輸入憑證的名稱。例如:Thawte Personal Freemail C。
  5. Please enter the name of the certificate?

    Thawte Personal Freemail CA

  6. 輸入憑證的信任屬性。
  7. Please enter the trust attribute you want the certificate to have [CT,CT,CT]

系統將會變更憑證信任屬性。


列示根 CA 憑證

您可以使用憑證管理程序檔檢視所有根 CA 憑證。

    若要檢視根 CA 清單
  1. 以超級使用者身份執行 certadmin 程序檔。
  2. portal-server-install-root/SUNWps/bin/certadmin -n gateway-profile-name

    其中 gateway-profile-name 是閘道實例的名稱。

    系統便會顯示憑證管理功能表。

    1) Generate Self-Signed Certificate

    2) Generate Certificate Signing Request (CSR)

    3) Add Root CA Certificate

    4) Install Certificate From Certificate Authority (CA)

    5) Delete Certificate

    6) Modify Trust Attributes of Certificate (e.g., for PDC)

    7) List Root CA Certificates

    8) List All Certificates

    9) Print Certificate Content

    10)Quit

    choice: [10] 7

  3. 在憑證管理功能表上選擇選項 7
  4. 系統會顯示所有根 CA 憑證。


列示所有憑證

您可以使用憑證管理程序檔檢視所有憑證及其對應的信任屬性。

    若要列示所有憑證
  1. 以超級使用者身份執行 certadmin 程序檔。
  2. portal-server-install-root/SUNWps/bin/certadmin -n gateway-profile-name

    其中 gateway-profile-name 是閘道實例的名稱。

    系統便會顯示憑證管理功能表。

    1) Generate Self-Signed Certificate

    2) Generate Certificate Signing Request (CSR)

    3) Add Root CA Certificate

    4) Install Certificate From Certificate Authority (CA)

    5) Delete Certificate

    6) Modify Trust Attributes of Certificate (e.g., for PDC)

    7) List Root CA Certificates

    8) List All Certificates

    9) Print Certificate Content

    10)Quit

    choice: [10] 8

  3. 在憑證管理功能表上選擇選項 8
  4. 系統會顯示所有 CA 憑證。


列印憑證

您可以使用憑證管理程序檔列印憑證。

    若要列印憑證
  1. 以超級使用者身份執行 certadmin 程序檔。
  2. portal-server-install-root/SUNWps/bin/certadmin -n gateway-profile-name

    其中 gateway-profile-name 是閘道實例的名稱。

    系統便會顯示憑證管理功能表。

    1) Generate Self-Signed Certificate

    2) Generate Certificate Signing Request (CSR)

    3) Add Root CA Certificate

    4) Install Certificate From Certificate Authority (CA)

    5) Delete Certificate

    6) Modify Trust Attributes of Certificate (e.g., for PDC)

    7) List Root CA Certificates

    8) List All Certificates

    9) Print Certificate Content

    10)Quit

    choice: [10] 9

  3. 在憑證管理功能表上選擇選項 9
  4. 輸入憑證的名稱。


上一頁      目錄      索引      下一頁     


文件號碼:819-4617。 Copyright 2005 Sun Microsystems, Inc. 版權所有。