Sun Java System Portal Server Secure Remote Access 7.2 管理指南

了解 platform.conf 檔案

預設情況下,platform.conf 檔案位於:/etc/opt/SUNWportal

platform.conf 檔案包含閘道所需的詳細資訊。本節提供一個範例 platform.conf 檔案,並說明所有的項目。

在配置檔中包含所有機器特定詳細資訊的優點,就是共用的設定檔可以被在多個機器上執行的閘道共享。

以下是 platform.conf 檔案的範例。


Tue May 30 11:51:23 IST 2006
debug.com.sun.portal.rewriter.original.level=INFO
gateway.favicon=
gateway.bindipaddress=10.12.154.236
debug.com.sun.portal.sra.rproxy.toFromServer.handler.java.util.logging.FileHandler.pattern=
/var/opt/SUNWportal/logs/sra/default/Gateway.toFromServer.%u.%g.log
gateway.port=443
rewriterproxy.jvm.flags=-ms64m -mx128m
portal.server.instance=default
debug.com.sun.portal.handler.java.util.logging.FileHandler.filter=
gateway.jdk.dir=/usr/jdk/entsys-j2se
gateway.ignoreURIList=/MSOffice/cltreq.asp,/_vti_bin/owssvr.dll
debug.com.sun.portal.rewriter.rest.level=INFO
gateway.trust_all_server_certs=true
debug.com.sun.portal.handler.java.util.logging.FileHandler.append=true
gateway.cdm.cacheCleanupTime=300000
gateway.httpurl=
debug.com.sun.portal.handler.java.util.logging.FileHandler.count=1
gateway.jvm.classpath=
debug.com.sun.portal.setserverlogs=false
gateway.protocol=https
debug.com.sun.portal.sra.rproxy.toFromServer=java.util.logging.FileHandler
rewriterproxy.jvm.classpath=
gateway.enable.customurl=false
debug.com.sun.portal.sra.rproxy.toFromBrowser=java.util.logging.FileHandler
debug.com.sun.portal.handler.java.util.logging.FileHandler.formatter=com.sun.portal.
log.common.PortalLogFormatter
debug.com.sun.portal.sra.rproxy.toFromBrowser.handler.java.util.logging.FileHandler.pattern=
/var/opt/SUNWportal/logs/sra/default/Gateway.toFromBrowser.%u.%g.log
debug.com.sun.portal.level=INFO
debug.com.sun.portal.rewriter.unaffected.separatefile=true
gateway.enable.accelerator=false
debug.com.sun.portal.rewriter.original.separatefile=true
gateway.virtualhost=nicp236.india.sun.com 10.12.154.236
debug.com.sun.portal.stacktrace=true 
gateway.host=nicp236.india.sun.com
debug.com.sun.portal.handler.java.util.logging.FileHandler.pattern=
/var/opt/SUNWportal/logs/sra/default/%logger.%sraComponentType.%u.%g.log
gateway.certdir=/etc/opt/SUNWportal/cert/default
gateway.sockretries=3
gateway.allow.client.caching=true
debug.com.sun.portal.rewriter.unaffected.level=INFO
debug.com.sun.portal.rewriter.uriinfo.separatefile=true
log.config.check.period=2000
debug.com.sun.portal.rewriter.rewritten.level=INFO
gateway.userProfile.cacheSize=1024
debug.com.sun.portal.rewriter.rulesetinfo.level=INFO
netletproxy.jvm.classpath=
gateway.userProfile.cacheSleepTime=60000
debug.com.sun.portal.rewriter.uriinfo.level=INFO
debug.com.sun.portal.rewriter.rest.separatefile=true
gateway.notification.url=notification
debug.com.sun.portal.rewriter.rulesetinfo.separatefile=true
gateway.logdelimiter=&&
gateway.ignoreServerList=false
gateway.jvm.flags=-ms64m -mx128m
debug.com.sun.portal.handler.java.util.logging.FileHandler.limit=5000000
gateway.dsame.agent=http\://sunone216.india.sun.com\:8080/portal/RemoteConfigServlet
gateway.httpsurl=
gateway.retries=6
gateway.userProfile.cacheCleanupTime=300000
gateway.logging.password=X03MO1qnZdYdgyfeuILPmQ\=\= UX9x0jIua3hx1YOVRG/TLg\=\=
netletproxy.jvm.flags=-ms64m -mx128m
debug.com.sun.portal.rewriter.rewritten.separatefile=true
gateway.user=noaccess
gateway.external.ip=10.12.154.236
debug.com.sun.portal.handler=java.util.logging.FileHandler
gateway.cdm.cacheSleepTime=60000
rewriterproxy.accept.from.gateways=
rewriterproxy.checkacl=false

下列表格列出並說明 platform.conf 檔案中所有的欄位。

表 2–1 檔案特性

項目 

預設值 

描述 

gateway.user

noaccess 

閘道以此使用者執行。 

閘道必須做為超級使用者啟動,並且在初始化後,它會失去超級使用者權限而成為此使用者。 

gateway.jdk.dir

 

這是閘道所使用之 JDK 目錄的位置。 

gateway.dsame.agent

 

當閘道啟動要取得其設定檔時,這是閘道會連絡 Access Manager 的 URL。 

portal.server.protocol

portal.server.host

portal.server.port

 

這是預設 Portal Server 安裝使用的通訊協定、主機和連接埠。 

gateway.protocolgateway. hostgateway.port

 

這是閘道的通訊協定、主機和連接埠。這些值與您在安裝時所指定的模式和連接埠相同。這些值用於建立通知 URL。 

gateway. trust_all_server_certs

true 

這表示閘道必須相信所有的伺服器憑證,或僅相信在閘道憑證資料庫中的伺服器憑證。 

gateway. trust_all_server_cert_domains

false 

當閘道和伺服器之間有 SSL 通訊時,會提供伺服器憑證給閘道。在預設情況下,閘道會檢查伺服器主機名稱是否與伺服器憑證 CN 相同。 

如果屬性值設定為 true,則閘道會停用它收到之伺服器憑證的網域名稱檢查。 

gateway.virtualhost

 

如果閘道機器有配置多個主機名稱,您可以在此欄位指定不同的名稱和識別提供者位址。 

gateway.virtualhost. defaultOrg=org

 

這會指定預設的 Org 給登入的使用者。 

例如,假設虛擬主機欄位項目如下所示: 

gateway.virtualhost=test.com employee.test.com

Managers.test.com

含有預設的 org 項目為: 

test.com.defaultOrg = o=root,dc=test,dc=com

employee.test.com.defaultOrg = o=employee,dc=test,dc=com

Manager.test.com.defaultOrg = o=Manager,dc=test,dc=com

使用者可以使用 https://manager.test.com 而非 https://test.com/o=Manager,dc=test,dc=com 以登入管理員的 org。


備註 –

virtualhost 和 defaultOrg 在 platform.conf 檔案中區分大小寫,但用於 URL 時則沒有區分。


gateway.notification.url

 

閘道主機、通訊協定和連接埠的組合,用於建立通知 URL。用於從 Access Manager 接收階段作業通知。 

請確定通知 URL 和任何組織的名稱不相同。如果通知 URL 和組織名稱相同,則使用者在嘗試連結到該組織時會看到空白頁面而非登入的頁面。 

gateway.retries

 

此數字是在啟動時,閘道嘗試連絡 Portal Server 的次數。 

gateway.debug

error

設定閘道的除錯層級。除錯記錄檔位於 debug-directory/files。除錯檔案的位置在 gateway.debug.dir 項目中指定。

除錯層級為: 

  • error - 只會在除錯檔案中記錄幾個錯誤。在此種錯誤發生時,閘道通常會停止運作。

  • warning - 記錄警告訊息。

  • message - 記錄所有的除錯訊息。

  • on - 在主控台顯示所有的除錯訊息。

除錯檔案為: 

srapGateway.gateway-profile-name - 包含閘道的除錯訊息。

Gateway_to_from_server.gateway-profile-name - 在訊息模式下,此檔案包含閘道和內部伺服器之間所有的需求和回應標頭。

要產生此檔案,請變更 /var/opt/SUNWps/debug 目錄的寫入權限。

Gateway_to_from_browser.gateway-profile-name - 在訊息模式下,此檔案包含閘道和用戶端瀏覽器之間所有的需求和回應標頭。

要產生此檔案,請變更 /var/opt/SUNWps/debug 目錄的寫入權限。

gateway.debug.dir

 

這是所有除錯檔案產生的目錄。 

此目錄必須有足夠的權限以將 gateway.user 中提到的使用者寫入檔案。

gateway.logdelimiter

 

目前沒有使用。 

gateway.external.ip

 

如果是在多址閘道機器上 (使用多重 IP 位址的機器),您需要在此指定外部 IP 位址。此 IP 用於執行 FTP 的 Netlet。 

gateway.certdir

 

它指定憑證資料庫的位置。 

gateway.allow.client.caching

true 

允許或拒絕用戶端快取。 

如果允許,用戶端瀏覽器可以快取靜態頁面和影像以取得較佳的效能 (藉由減低網路流量)。 

如果拒絕,因為沒有任何快取,安全性會更高,但是會因為有較高的網路負載而導致效能落差。 

gateway.userProfile.cacheSize

 

這是在閘道上使用者設定檔項目被快取的數目。如果項目數量超過這個值,常用的項目會清除快取。 

gateway.userProfile. cacheSleepTime

 

以秒為單位設定休息時間,以清除快取。 

gateway.userProfile. cacheCleanupTime

 

超過以秒為單位的最大數字的時間後,會移除設定檔項目。 

gateway.bindipaddress

 

在多址機器上,這是閘道連結其 serversocket 的 IP 位址。要配置閘道偵聽所有介面,請置換 IP 位址以使 gateway.bindipaddress=0.0.0.0

gateway.sockretries

目前沒有使用。 

gateway.enable.accelerator

false 

如果設定為 true,則允許支援外部加速器。 

gateway.enable.customurl

false 

如果設定為 true,則允許管理員指定一個自訂的 URL 讓閘道重新寫入頁面。 

gateway.httpurl

 

自訂 URL 的 HTTP reverse proxy URL 讓閘道重新寫入頁面。啟用 Proxylet 時請使用此項目。 

gateway.httpsurl

 

自訂 URL 的 HTTPS reverse proxy URL 讓閘道重新寫入頁面。如果啟用 Proxylet,請勿使用此項目。 

gateway.favicon

 

閘道將 favicon.icon 檔請求重新導向到的 URL。

此項目用於 Internet Explorer、Netscape 7.0 和更高版本中的「favorite icon」。 

如果此項目保持空白,閘道會傳送一個「404 頁面找不到」的訊息給瀏覽器。 

gateway.logging.password

 

使用者 amService-srapGateway 的 LDAP 密碼,閘道會使用它來建立其應用程式階段作業。

密碼可以是加密文字或一般文字。 

http.proxyHost

 

代理伺服器主機會用於連絡 Portal Server。 

http.proxyPort

 

主機連接埠會用於連絡 Portal Server。 

http.proxySet

 

若需要代理伺服器,則屬性會設定為 true。若特性設定為 false,則會忽略 http.proxyHosthttp.proxyPort

portal.server.instance

 

此特性值對應於 /etc/opt/SUNWam/config/AMConfig -instance-name.properties 檔案。如果值是預設值,則會指向 AMConfig.properties。

gateway.cdm.cacheSleepTime

60000 

快取「用戶端偵測模組」回應的逾時值從 Access Manager 傳送到閘道。 

gateway.cdm.cacheCleanupTime

300000 

快取「用戶端偵測模組」回應的逾時值從 Access Manager 傳送到閘道。 

netletproxy.port

10555 

Netlet 代理伺服器預設程式會偵聽此連接埠上的請求。 

rewriterproxy.port

10555 

Rewriter 代理伺服器預設程式會偵聽此連接埠上的請求。 

gateway.ignoreServerList

false 

如果設定為 true,會使用 AMConfig.properties 檔案中指定的值來建立 Access Manager 伺服器 URL。當 Access Manager 伺服器位於負載平衡器之後時,請將此屬性設定為 true。

rewriterproxy.accept.from.gateways

 

這是 IP 位址的清單,可將 Rewriter 代理伺服器設定為接受來自該清單的請求。此屬性對 HTTP 與 HTTPS 模式均適用。它可加強安全性,僅接受來自此集合的請求,而不會處理所有其他的請求。IP 位址可使用逗點分隔。預設值是空的,被視為舊有模式,亦即會尊重到 Rewriter 代理程式的所有請求。 

rewriterproxy.checkacl=

false 

啟用此特性可讓 Rewriter 代理伺服器檢查 ACL 值,就像閘道一樣。舊有模式值是「false」。當將此值設定為 true 時,Rewriter 代理伺服器會在指定 DN 根據在閘道存取服務中指定的值檢查 URL,且會依據此處設定之清單集合來允許/拒絕請求。此值在 HTTP 與 HTTPS 模式中都有用。