Class DecorateDelegatedAssertion

    • Field Detail

      • log

        private final org.slf4j.Logger log
        Class logger.
      • libertySSOSEndpointURL

        private String libertySSOSEndpointURL
        The URL at which the IdP will accept Liberty ID-WSF SSOS requests.
      • libertySSOSEndpointURLLookupStrategy

        @Nullable
        private Function<Pair<ProfileRequestContext,​javax.servlet.http.HttpServletRequest>,​String> libertySSOSEndpointURLLookupStrategy
        The strategy used to resolve the URL at which the IdP will accept Liberty ID-WSF SSOS requests.
      • keyInfoGeneratorManager

        @Nonnull
        private NamedKeyInfoGeneratorManager keyInfoGeneratorManager
        The manager used to generate KeyInfo instances from Credentials.
      • delegationContext

        private DelegationContext delegationContext
        The delegation context instance to be populated.
      • assertions

        private List<Assertion> assertions
        The list of assertions on which to operate.
      • relyingPartyContext

        private RelyingPartyContext relyingPartyContext
        The current RelyingPartyContext.
      • responderId

        private String responderId
        The entityID of the local responder entity.
      • relyingPartyId

        private String relyingPartyId
        The entityID of the SAML relying party.
    • Constructor Detail

      • DecorateDelegatedAssertion

        public DecorateDelegatedAssertion()
        Constructor.
    • Method Detail

      • setLibertySSOSEndpointURL

        public void setLibertySSOSEndpointURL​(@Nullable
                                              String url)
        Set the statically-configured URL at which the IdP will accept Liberty ID-WSF SSOS requests.
        Parameters:
        url - the Liberty ID-WSF SSOS endpoint URL, or null
      • setLibertySSOSEndpointURLLookupStrategy

        public void setLibertySSOSEndpointURLLookupStrategy​(@Nullable
                                                            Function<Pair<ProfileRequestContext,​javax.servlet.http.HttpServletRequest>,​String> strategy)
        Set strategy used to resolve the URL at which the IdP will accept Liberty ID-WSF SSOS requests.
        Parameters:
        strategy - the Liberty ID-WSF SSOS endpoint URL lookup strategy, or null
      • doPreExecuteDelegationInfo

        protected boolean doPreExecuteDelegationInfo​(@Nonnull
                                                     ProfileRequestContext profileRequestContext)
        Pre-execute actions on the delegation-specific info.
        Parameters:
        profileRequestContext - the current profile request context
        Returns:
        true iff doExecute(ProfileRequestContext) should proceed
      • doPreExecuteRelyingParty

        protected boolean doPreExecuteRelyingParty​(@Nonnull
                                                   ProfileRequestContext profileRequestContext)
        Pre-execute actions on the relying party context info.
        Parameters:
        profileRequestContext - the current profile request context
        Returns:
        true iff doExecute(ProfileRequestContext) should proceed
      • resolveLibertySSOSEndpointURL

        private void resolveLibertySSOSEndpointURL​(ProfileRequestContext profileRequestContext)
        Resolve and store the effective Liberty SSOS endpoint URL to use.
        Parameters:
        profileRequestContext - the current request context
      • decorateDelegatedAssertion

        private void decorateDelegatedAssertion​(@Nonnull
                                                ProfileRequestContext requestContext)
                                         throws EventException
        Decorate the Assertion to allow use as a delegated security token by the SAML requester.
        Parameters:
        requestContext - the current request context
        Throws:
        EventException - to propagate events
      • addLibertySSOSEPRAttribute

        private void addLibertySSOSEPRAttribute​(@Nonnull
                                                ProfileRequestContext requestContext,
                                                @Nonnull
                                                Assertion assertion)
        Add Liberty SSOS service Endpoint Reference (EPR) attribute to Assertion's AttributeStatement.
        Parameters:
        requestContext - the current request context
        assertion - the delegated assertion being issued
      • buildLibertSSOSEPRAttributeValue

        @Nonnull
        private XMLObject buildLibertSSOSEPRAttributeValue​(@Nonnull
                                                           ProfileRequestContext requestContext,
                                                           @Nonnull
                                                           Assertion assertion)
        Build the Liberty SSOS EPR AttributeValue object.
        Parameters:
        requestContext - the current request context
        assertion - the delegated assertion being issued
        Returns:
        the AttributeValue object containing the EPR
      • addIdPAudienceRestriction

        private void addIdPAudienceRestriction​(@Nonnull
                                               ProfileRequestContext requestContext,
                                               @Nonnull
                                               Assertion assertion)
        An an AudienceRestriction condition indicating the IdP as an acceptable Audience.
        Parameters:
        requestContext - the current request context
        assertion - the assertion being isued
      • addSAMLPeerSubjectConfirmation

        private void addSAMLPeerSubjectConfirmation​(@Nonnull
                                                    ProfileRequestContext requestContext,
                                                    @Nonnull
                                                    Assertion assertion)
                                             throws EventException
        Add SubjectConfirmation to the Assertion Subject to allow confirmation when wielded by the SAML requester.
        Parameters:
        requestContext - the current request context
        assertion - the assertion being issued
        Throws:
        EventException - to propagate event signals