IdPのサービス動作状況を確認する
以前構築したIdPにて、以下のURLで 404 Not Found エラーが発生する場合は、まず 貴学にてIdPv3をインストールする場合の構築手順 の virtualhost-localhost80.conf
の設定を確認してください。
1.Tomcat と、httpd サービスを再起動
IdPの設定変更後に各サービスの再起動を行っていない場合は、行ってください。
# systemctl stop tomcat
# systemctl restart httpd # systemctl start tomcat
2.動作状況確認URLにアクセス
IdPサーバ自身から以下のようにアクセスして確認します。
※ホスト名は必ず localhost(もしくは127.0.0.1)として下さい。
# wget -O - http://localhost/idp/status
外部からステータスページにアクセスしたい場合
監視サーバからのアクセスなど、外部からアクセスしたい場合は、アクセス元のIPアドレスを許可する必要があります。
設定を変更した場合は、再度Tomcatの再起動を行ってください。
/opt/shibboleth-idp/conf/access-control.xml ファイルにアクセス元となるIPアドレスを設定してください。
<util:map id="shibboleth.AccessControlPolicies">
<entry key="AccessByIPAddress">
<bean parent="shibboleth.IPRangeAccessControl"
p:allowedRanges="#{ {'127.0.0.1/32', '::1/128', 'xxx.xxx.xxx.xxx/xx'} }" />
← アクセス元のIPアドレス範囲を追加
</entry>
</util:map>
以下のURLにアクセスします。
※ホスト名を構築した環境に置き換えてアクセスしてください。
https://example-idp.nii.ac.jp/idp/status
上記のように変更した場合、同じルールを使用している他の機能(resolvertestとreload-*)へのアクセスも許可されます。
/idp/statusのみのアクセス制御を変更したい場合は、上述の<entry>要素を複製・適宜修正し、key属性にユニークな識別子を割り当てた後、idp.propertiesのidp.status.accessPolicyに当該keyを設定してください。
3.3.0のidp.propertiesにはidp.status.accessPolicyの行がありませんので、以下のような行を追加してください。
idp.status.accessPolicy = AccessByIPAddressXXX
3.結果の確認
各サービスの動作状況が確認できます。以下のようにShibboleth IdPのバージョンを含めて各種情報が表示され、以下と比較して大きな違いがなければ、IdPの機能が正常に動作していることの確認が出来ました。
--2017-09-07 15:48:41-- http://localhost/idp/status
Resolving localhost (localhost)... ::1, 127.0.0.1
Connecting to localhost (localhost)|::1|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 1762 (1.7K) [text/plain]
Saving to: ‘STDOUT’
0% [ ] 0 --.-K/s
### Operating Environment Information
operating_system: Linux
operating_system_version: 3.10.0-514.6.1.el7.x86_64
operating_system_architecture: amd64
jdk_version: 1.8.0_141
available_cores: 1
used_memory: 96 MB
maximum_memory: 1500 MB
### Identity Provider Information
idp_version: 3.2.1
start_time: 2017-09-07T15:34:51+09:00
current_time: 2017-09-07T15:48:41+09:00
uptime: 830594 ms
service: shibboleth.LoggingService
last successful reload attempt: 2017-09-07T06:34:19Z
last reload attempt: 2017-09-07T06:34:19Z
service: shibboleth.ReloadableAccessControlService
last successful reload attempt: 2017-09-07T06:34:26Z
last reload attempt: 2017-09-07T06:34:26Z
service: shibboleth.MetadataResolverService
last successful reload attempt: 2017-09-07T06:34:24Z
last reload attempt: 2017-09-07T06:34:24Z
metadata source: ShibbolethMetadata
last refresh attempt: 2017-09-07T06:34:25Z
last update: 2017-09-07T06:34:25Z
service: shibboleth.RelyingPartyResolverService
last successful reload attempt: 2017-09-07T06:34:24Z
last reload attempt: 2017-09-07T06:34:24Z
service: shibboleth.NameIdentifierGenerationService
last successful reload attempt: 2017-09-07T06:34:23Z
last reload attempt: 2017-09-07T06:34:23Z
service: shibboleth.AttributeResolverService
last successful reload attempt: 2017-09-07T06:34:22Z
last reload attempt: 2017-09-07T06:34:22Z
DataConnector staticJaOrganizationName: has never failed
DataConnector staticOrganizationName: has never failed
DataConnector staticEntitlementCommonLibTerms: has never failed
DataConnector computedID: has never failed
DataConnector myLDAP: has never failed
service: shibboleth.AttributeFilterService
last successful reload attempt: 2017-09-07T06:34:22Z
last reload attempt: 2017-09-07T06:34:22Z
100%[===============================================>] 1,762 --.-K/s in 0s
2017-09-07 15:48:41 (85.1 MB/s) - written to stdout [1762/1762]