比較バージョン

キー

  • この行は追加されました。
  • この行は削除されました。
  • 書式設定が変更されました。

...

https://www.eclipse.org/jetty/download.html より最新版のパッケージ(.tgz)をダウンロードしてインストールします。
さらに、Shibboleth Projectが配布している各種設定ファイル群Projectが配布しているJetty向け設定ファイル群(jetty-base)を配置します。

パネル
borderColor#cccccc
bgColor#eeeeee
borderStylesolid

※以下は手順書作成時の最新
# wget https://repo1.maven.org/maven2/org/eclipse/jetty/jetty-distribution/9.4.3244.v20200930v20210927/jetty-distribution-9.4.3244.v20200930v20210927.tar.gz
#

tar

zxv

-C

/opt

-f

jetty-distribution-9.4.*.v????????.tar.gz
#

(

cd

/opt

;

ln

-s

jetty-distribution-9.4.*.v????????

/opt/jetty

)
#

wget

https://build.shibboleth.net/

nexus

maven/

service/local/repositories/releases/content/

snapshots/net/shibboleth/idp/idp-jetty-base/9.4.

0

1-SNAPSHOT/idp-jetty-base-9.4

.0

.1-20220208.135650-767.tar.gz
#

tar

zxv

-C

/opt

-f

idp-jetty-base-9.4.?

.tar

-????????.*.tar.gz


サービス起動には、jetty起動用のユーザを使用することを推奨します。

...

パネル
borderColor#cccccc
bgColor#eeeeee
borderStylesolid

# ---------------------------------------
# Module: idp
# Shibboleth IdP
# ---------------------------------------
--module=idp
--module=http
--module=http-forwarded

## Keystore file path (relative to $jetty.base)
jetty.sslContext.keyStorePath=../credentials/idp-userfacing.p12


(省略)

※末尾に以下を追加

## Connector port to listen on
jetty.ssl.port=443  ※利用されない
jetty.http.host=127.0.0.1
jetty.http.port=8080


/opt/jetty-base/etcstart.d/tweakidp-ssllogging.xmlを以下の内容で作成します。ini を修正します。

パネル
borderColor#cccccc
bgColor#eeeeee
borderStylesolid

(省略)

# Override logback version pinned in jetty-home/modules/logback-impl.mod
logback.version=1.2.10
# Override SLF4J version pinned in jetty-home/modules/slf4j-api.mod
slf4j.version=1.7.32

情報

ここで記載しているバージョンは lib/logback/ および log/slf4j/ 以下に配置されているライブラリのバージョンです。展開したjetty-baseが本技術ガイドに記載のものと異なる場合は、実際に配置されているライブラリのバージョンを logback.version= および slf4j.version= に記述してください。


/opt/jetty-base/etc/tweak-ssl.xmlを以下の内容で作成します。

注意

過去の技術ガイドでは id="shibContextFactory" の部分を誤って id="sslContextFactory" としておりました。本設定が正しく反映されるように、修正をお願いいたします。

パネル
borderColor#cccccc
bgColor#eeeeee
borderStylesolid

<!DOCTYPE Configure PUBLIC "-//Jetty//Configure//EN"
          "http://www.eclipse.<!DOCTYPE Configure PUBLIC "-//Jetty//Configure//EN"
"http://www.eclipse.org/jetty/configure_9_4.dtd">
<Configure id="sslContextFactoryshibContextFactory" class="org.eclipse.jetty.util.ssl.SslContextFactory">
    <Set name="IncludeProtocols">
        <Array type="String">

            <Item>TLSv1.3</Item>

            <Item>TLSv1.2</Item>

        </Array>

    </Set>

    <Set name="ExcludeProtocols">

        <Array type="String">

            <Item>TLSv1.1</Item>

            <Item>TLSv1</Item>

            <Item>SSL</Item>

            <Item>SSLv2</Item>

            <Item>SSLv3</Item>

        </Array>

    </Set>

    <Set name="IncludeCipherSuites">

        <Array type="String">

            <Item>TLS_AES.*</Item>

            <Item>TLS_ECDHECHACHA20.*</Item>

            <Item>TLS_AESECDHE.*</Item>

            <Item>TLS_RSA.*<_EMPTY_RENEGOTIATION_INFO_SCSV</Item>
        </Array>

    </Set>

    <Set name="ExcludeCipherSuites">

        <Array type="String">

            <Item>.*NULL.*</Item>

            <Item>.*RC4.*</Item>

            <Item>^.*_(MD5|SHA|SHA1)$</Item>
            <Item>.*DES.*</Item>

            <Item>.*RC4DSS.*</Item>

<Item>            <Item>^TLS_DHE_.*MD5$</Item>
            <Item>^TLS_RSA_.*$</Item>

        </Item>

<Item>.*DES.*</Item>
<Item>.*DSS.*</Item>
<Item>TLS_DHE.*</Item>
</Array>
</Set>
</Configure>Array>
    </Set>

</Configure>

上記ファイルを参照するように /opt/jetty-base/modules/idp-backchannel.mod に追記します。

パネル
borderColor#cccccc
bgColor#eeeeee
borderStylesolid

(省略)

[xml]
etc/idp-backchannel.xml
etc/tweak-ssl.xml


5.  httpd の設定 

/etc/httpd/conf/httpd.conf の修正

...

パネル
borderColor#cccccc
bgColor#eeeeee
borderStylesolid

(省略)
<VirtualHost _default_:443>
(省略)
#ServerName example-idp.nii.ac.jp:443 ←ホスト名
↑コメントアウト(#)を削除
↓以下を追加
RequestHeader set X-Forwarded-Port 443
RequestHeader set X-Forwarded-Proto https

RequestHeader unset Forwarded
RequestHeader unset X-Forwarded-For
ProxyPass /idp/ http://localhost:8080/idp/ connectiontimeout=5 timeout=15

(省略)

...