比較バージョン

キー

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

...

抜粋を含める
画面のカスタマイズ
画面のカスタマイズ
nopaneltrue

...

組み込みのユーザ同意機能について

Shibboleth IdP 3には、uApprove相当のユーザ同意機能があります。uApprove 3には、uApprove相当のユーザ同意機能が組み込まれています。uApprove JPとの違いはShibboleth IdP 3のユーザ同意機能とuApprove JPとの相違点を参照してください。

...

  • StorageRecordsテーブルの作成
    StorageRecordsテーブルを作成します。

    展開
    コード ブロック
    languagesql
    titleMySQL
    CREATE TABLE `StorageRecords` (
      `context` varchar(255) NOT NULL,
      `id` varchar(255) NOT NULL,
      `expires` bigint(20) DEFAULT NULL,
      `value` longtext NOT NULL,
      `version` bigint(20) NOT NULL,
      PRIMARY KEY (`context`,`id`)
    ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
  • conf/global.xml
    shibboleth.JPAStorageServiceを定義します。persistent-idの設定(storedId)が設定済みの場合、最後のMyDataSourceの定義は重複となるため不要です。

    展開
    コード ブロック
    languagexml
    titleconf/global.xml (Tomcat7の場合)
    <!-- Use this file to define any custom beans needed globally. -->
    <bean id="shibboleth.JPAStorageService"
          class="org.opensaml.storage.impl.JPAStorageService"
          p:cleanupInterval="%{idp.storage.cleanupInterval:PT10M}"
          c:factory-ref="shibboleth.JPAStorageService.entityManagerFactory" />
    
    <bean id="shibboleth.JPAStorageService.entityManagerFactory"
          class="org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean">
        <property name="packagesToScan" value="org.opensaml.storage.impl" />
        <property name="dataSource" ref="MyDataSource" />
        <property name="jpaVendorAdapter" ref="shibboleth.JPAStorageService.JPAVendorAdapter" />
        <property name="jpaDialect">
            <bean class="org.springframework.orm.jpa.vendor.HibernateJpaDialect" />
        </property>
    </bean>
    
    <bean id="shibboleth.JPAStorageService.JPAVendorAdapter"
          class="org.springframework.orm.jpa.vendor.HibernateJpaVendorAdapter"
          p:database="MYSQL" />
    
    <!-- A DataSource bean suitable for use in the idp.persistentId.dataSource property. -->
    <bean id="MyDataSource"
          class="org.apache.tomcatcommons.dbcpdbcp2.dbcp.BasicDataSource"
          p:driverClassName="com.mysql.jdbc.Driver"
          p:url="jdbc:mysql://localhost:3306/shibboleth"
          p:username="username"
          p:password="password"
          p:maxActivemaxTotal="10"
          p:maxIdle="5"
          p:maxWaitmaxWaitMillis="15000"
          p:testOnBorrow="true"
          p:validationQuery="select 1"
          p:validationQueryTimeout="5" />
    ヒント
    Tomcat8を使用している場合は、下記のShibbolethIdP3.1の情報を参考にしてください。
  • conf/idp.properties
    idp.consent.StorageServiceconf/global.xmlで定義したshibboleth.JPAStorageServiceに変更します。

    展開
    コード ブロック
    languagexml
    titleconf/idp.properties
    # Set to "shibboleth.StorageService" or custom bean for alternate storage of consent
    idp.consent.StorageService = shibboleth.JPAStorageService
    コード ブロック
    languagediff
    title差分
     # Set to "shibboleth.StorageService" or custom bean for alternate storage of consent
    -#idp.consent.StorageService = shibboleth.ClientPersistentStorageService
    +idp.consent.StorageService = shibboleth.JPAStorageService
Shibboleth IdP 3.1の情報
展開
  • StorageRecordsテーブルの作成
    StorageRecordsテーブルを作成します。

    コード ブロック
    languagesql
    titleMySQL
    CREATE TABLE `StorageRecords` (
      `context` varchar(255) NOT NULL,
      `id` varchar(255) NOT NULL,
      `expires` bigint(20) DEFAULT NULL,
      `value` longtext NOT NULL,
      `version` bigint(20) NOT NULL,
      PRIMARY KEY (`context`,`id`)
    ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
  • conf/global.xml

    shibboleth.JPAStorageServiceを定義します。 persistent-idの設定(storedId)が設定済みの場合、最後のMyDataSourceの定義は重複となるため不要です。

    コード ブロック
    languagexml
    titleconf/global.xml (Tomcat7の場合)
    <!-- Use this file to define any custom beans needed globally. -->
    <bean id="shibboleth.JPAStorageService"
          class="org.opensaml.storage.impl.JPAStorageService"
          p:cleanupInterval="%{idp.storage.cleanupInterval:PT10M}"
          c:factory-ref="shibboleth.JPAStorageService.entityManagerFactory" />
    
    <bean id="shibboleth.JPAStorageService.entityManagerFactory"
          class="org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean">
        <property name="packagesToScan" value="org.opensaml.storage.impl" />
        <property name="dataSource" ref="MyDataSource" />
        <property name="jpaVendorAdapter" ref="shibboleth.JPAStorageService.JPAVendorAdapter" />
        <property name="jpaDialect">
            <bean class="org.springframework.orm.jpa.vendor.HibernateJpaDialect" />
        </property>
    </bean>
    
    <bean id="shibboleth.JPAStorageService.JPAVendorAdapter"
          class="org.springframework.orm.jpa.vendor.HibernateJpaVendorAdapter"
          p:database="MYSQL" />
     
    <bean id="MyDataSource"
          class="org.apache.tomcat.dbcp.dbcp.BasicDataSource"
          p:driverClassName="com.mysql.jdbc.Driver"
          p:url="jdbc:mysql://localhost:3306/shibboleth"
          p:username="username"
          p:password="password"
          p:maxActive="10"
          p:maxIdle="5"
          p:maxWait="15000"
          p:testOnBorrow="true"
          p:validationQuery="select 1"
          p:validationQueryTimeout="5" />
    コード ブロック
    languagexml
    titleconf/global.xml (Tomcat8の場合)
     <!-- Use this file to define any custom beans needed globally. -->
    <bean id="shibboleth.JPAStorageService"
          class="org.opensaml.storage.impl.JPAStorageService"
          p:cleanupInterval="%{idp.storage.cleanupInterval:PT10M}"
          c:factory-ref="shibboleth.JPAStorageService.entityManagerFactory" />
    
    <bean id="shibboleth.JPAStorageService.entityManagerFactory"
          class="org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean">
        <property name="packagesToScan" value="org.opensaml.storage.impl" />
        <property name="dataSource" ref="MyDataSource" />
        <property name="jpaVendorAdapter" ref="shibboleth.JPAStorageService.JPAVendorAdapter" />
        <property name="jpaDialect">
            <bean class="org.springframework.orm.jpa.vendor.HibernateJpaDialect" />
        </property>
    </bean>
    
    <bean id="shibboleth.JPAStorageService.JPAVendorAdapter"
          class="org.springframework.orm.jpa.vendor.HibernateJpaVendorAdapter"
          p:database="MYSQL" />
     
    <bean id="MyDataSource"
          class="org.apache.tomcat.dbcp.dbcp2.BasicDataSource"
          p:driverClassName="com.mysql.jdbc.Driver"
          p:url="jdbc:mysql://localhost:3306/shibboleth"
          p:username="username"
          p:password="password"
          p:maxIdle="5"
          p:maxTotal="10"
          p:maxWaitMillis="15000"
          p:testOnBorrow="true"
          p:validationQuery="select 1"
          p:validationQueryTimeout="5" />
    情報

    Tomcat 8付属のDBCP2から、p:maxActivep:maxTotalに、p:maxWaitp:maxWaitMillisに変更になりました。

  • conf/idp.properties

    コード ブロック
    languagexml
    titleconf/idp.properties
    # Set to "shibboleth.StorageService" or custom bean for alternate storage of consent
    idp.consent.StorageService = shibboleth.JPAStorageService
     
    # Maximum number of consent storage records
    # Set to -1 for unlimited server-side storage
    idp.consent.maxStoredRecords = -1

属性毎に同意を得る設定

属性毎に同意を得る設定

注意

SPの必須属性にもチェックボックスが表示されるため、利用者がSPの必須属性のチェックを外して属性を送信しなかった場合にSPを利用できない可能性があります。これが問題になる場合はuApprove JPの利用をご検討ください。

注意

SPの必須属性にもチェックボックスが表示されるため、利用者がSPの必須属性のチェックを外して属性を送信しなかった場合にSPを利用できない可能性があります。

  • conf/idp.properties
    idp.consent.allowPerAttributetrueに設定することで、属性毎にチェックボックスを付加することができます。

    展開
    コード ブロック
    languagexml
    titleconf/idp.properties
    # Flags controlling how built-in attribute consent feature operates
    #idp.consent.allowDoNotRemember = true
    #idp.consent.allowGlobal = true
    idp.consent.allowPerAttribute = true
    コード ブロック
    languagediff
    title差分
     # Flags controlling how built-in attribute consent feature operates
     #idp.consent.allowDoNotRemember = true
     #idp.consent.allowGlobal = true
    -#idp.consent.allowPerAttribute = false
    +idp.consent.allowPerAttribute = true

...