クラス OpenSamlRelyingPartyRegistrationBuilderHttpMessageConverter

java.lang.ObjectSE
org.springframework.security.saml2.provider.service.registration.OpenSamlRelyingPartyRegistrationBuilderHttpMessageConverter
実装されたすべてのインターフェース:
org.springframework.http.converter.HttpMessageConverter<RelyingPartyRegistration.Builder>

public class OpenSamlRelyingPartyRegistrationBuilderHttpMessageConverter extends ObjectSE implements org.springframework.http.converter.HttpMessageConverter<RelyingPartyRegistration.Builder>
HTTP レスポンスで IDPSSODescriptor を受け取り、それを RelyingPartyRegistration.Builder に変換する HttpMessageConverter。これの主な使用例は、RelyingPartyRegistrationRepository に含めるための RelyingPartyRegistration を構築することです。これを行うには、次のように、このコンバーターのインスタンスを RestOperations に含めることができます。
                RestOperations rest = new RestTemplate(Collections.singletonList(
                        new RelyingPartyRegistrationsBuilderHttpMessageConverter()));
                RelyingPartyRegistration.Builder builder = rest.getForObject
                                ("https://idp.example.org/metadata", RelyingPartyRegistration.Builder.class);
                RelyingPartyRegistration registration = builder.registrationId("registration-id").build();
 
これは、RelyingPartyRegistration の半分のアサーションパーティ(IDP)のみを構成することに注意してください。つまり、AuthnRequests の送信先と送信方法、アサーションの検証方法などです。証明書利用者(SP)情報を使用して RelyingPartyRegistration をさらに構成するには、適切なビルダーのメソッド。
導入:
5.4
  • コンストラクターの詳細

  • メソッドの詳細

    • canRead

      public boolean canRead(ClassSE<?> clazz, org.springframework.http.MediaType mediaType)
      次で指定:
      インターフェース org.springframework.http.converter.HttpMessageConverter<RelyingPartyRegistration.Builder>canRead 
    • canWrite

      public boolean canWrite(ClassSE<?> clazz, org.springframework.http.MediaType mediaType)
      次で指定:
      インターフェース org.springframework.http.converter.HttpMessageConverter<RelyingPartyRegistration.Builder>canWrite 
    • getSupportedMediaTypes

      public ListSE<org.springframework.http.MediaType> getSupportedMediaTypes()
      次で指定:
      インターフェース org.springframework.http.converter.HttpMessageConverter<RelyingPartyRegistration.Builder>getSupportedMediaTypes 
    • read

      public RelyingPartyRegistration.Builder read(ClassSE<? extends RelyingPartyRegistration.Builder> clazz, org.springframework.http.HttpInputMessage inputMessage) throws IOExceptionSE, org.springframework.http.converter.HttpMessageNotReadableException
      次で指定:
      インターフェース org.springframework.http.converter.HttpMessageConverter<RelyingPartyRegistration.Builder>read 
      例外:
      IOExceptionSE
      org.springframework.http.converter.HttpMessageNotReadableException
    • write

      public void write(RelyingPartyRegistration.Builder builder, org.springframework.http.MediaType contentType, org.springframework.http.HttpOutputMessage outputMessage) throws org.springframework.http.converter.HttpMessageNotWritableException
      次で指定:
      インターフェース org.springframework.http.converter.HttpMessageConverter<RelyingPartyRegistration.Builder>write 
      例外:
      org.springframework.http.converter.HttpMessageNotWritableException