[java-identity-provider COMMIT] in /trunk: idp-conf/src/main/resources/system/flows/saml1/sso-abstract-beans.xml idp-...
noreply at shibboleth.net
noreply at shibboleth.net
Sun Mar 9 16:38:47 EDT 2014
Author: scantor
Date: Sun Mar 9 16:38:46 2014
New Revision: 5551
URL: http://svn.shibboleth.net/view/java-identity-provider?rev=5551&view=rev
Log:
Fix a TODO in the flow, fix a late binding issue with function composition
Modified:
trunk/idp-conf/src/main/resources/system/flows/saml1/sso-abstract-beans.xml
trunk/idp-profile-impl/src/main/java/net/shibboleth/idp/profile/impl/FilterAttributes.java
Modified: trunk/idp-conf/src/main/resources/system/flows/saml1/sso-abstract-beans.xml
URL: http://svn.shibboleth.net/view/java-identity-provider/trunk/idp-conf/src/main/resources/system/flows/saml1/sso-abstract-beans.xml?rev=5551&r1=5550&r2=5551&view=diff
==============================================================================
--- trunk/idp-conf/src/main/resources/system/flows/saml1/sso-abstract-beans.xml (original)
+++ trunk/idp-conf/src/main/resources/system/flows/saml1/sso-abstract-beans.xml Sun Mar 9 16:38:46 2014
@@ -152,7 +152,6 @@
class="net.shibboleth.idp.authn.impl.InitializeRequestedPrincipalContext"
scope="prototype" />
- <!-- TODO make constructor arg names consistent for resolution and filtering -->
<bean
id="ResolveAttributes"
class="net.shibboleth.idp.profile.impl.ResolveAttributes"
@@ -163,7 +162,7 @@
id="FilterAttributes"
class="net.shibboleth.idp.profile.impl.FilterAttributes"
scope="prototype"
- c:service-ref="shibboleth.AttributeFilterService" />
+ c:filterService-ref="shibboleth.AttributeFilterService" />
<bean
id="UpdateSessionWithSPSession"
Modified: trunk/idp-profile-impl/src/main/java/net/shibboleth/idp/profile/impl/FilterAttributes.java
URL: http://svn.shibboleth.net/view/java-identity-provider/trunk/idp-profile-impl/src/main/java/net/shibboleth/idp/profile/impl/FilterAttributes.java?rev=5551&r1=5550&r2=5551&view=diff
==============================================================================
--- trunk/idp-profile-impl/src/main/java/net/shibboleth/idp/profile/impl/FilterAttributes.java (original)
+++ trunk/idp-profile-impl/src/main/java/net/shibboleth/idp/profile/impl/FilterAttributes.java Sun Mar 9 16:38:46 2014
@@ -68,7 +68,7 @@
@Nonnull private final Logger log = LoggerFactory.getLogger(FilterAttributes.class);
/** Service used to get the engine used to fetch attributes. */
- @Nonnull private final ReloadableService<AttributeFilter> filterService;
+ @Nonnull private final ReloadableService<AttributeFilter> attributeFilterService;
/**
* Strategy used to locate the {@link RelyingPartyContext} associated with a given {@link ProfileRequestContext}.
@@ -89,7 +89,7 @@
* Strategy used to locate the {@link SAMLMetadataContext} associated with a given {@link ProfileRequestContext}.
*/
@Nonnull private Function<ProfileRequestContext, SAMLMetadataContext> metadataContextLookupStrategy;
-
+
/**
* Strategy used to locate the {@link SAMLMetadataContext} associated with a given {@link AttributeFilterContext}.
*/
@@ -108,13 +108,15 @@
@Nullable private AttributeContext attributeContext;
/**
- * Constructor. Initializes {@link #relyingPartyContextLookupStrategy}, {@link #authnContextLookupStrategy} and
- * {@link #subjectContextLookupStrategy} to {@link ChildContextLookup}.
- *
- * @param service engine used to filter attributes
- */
- public FilterAttributes(@Nonnull final ReloadableService<AttributeFilter> service) {
- filterService = Constraint.isNotNull(service, "Service cannot be null");
+ * Constructor.
+ *
+ * <p>Initializes {@link #relyingPartyContextLookupStrategy}, {@link #authnContextLookupStrategy} and
+ * {@link #subjectContextLookupStrategy} to {@link ChildContextLookup}.</p>
+ *
+ * @param filterService engine used to filter attributes
+ */
+ public FilterAttributes(@Nonnull final ReloadableService<AttributeFilter> filterService) {
+ attributeFilterService = Constraint.isNotNull(filterService, "Service cannot be null");
relyingPartyContextLookupStrategy = new ChildContextLookup<>(RelyingPartyContext.class, false);
subjectContextLookupStrategy = new ChildContextLookup<>(SubjectContext.class, false);
authnContextLookupStrategy = new ChildContextLookup<>(AuthenticationContext.class, false);
@@ -126,7 +128,12 @@
new InboundMessageContextLookup()));
// This is always set to navigate to the root context and then apply the previous function.
- metadataFromFilterLookupStrategy = Functions.compose(metadataContextLookupStrategy,
+ metadataFromFilterLookupStrategy = Functions.compose(
+ new Function<ProfileRequestContext,SAMLMetadataContext>() {
+ public SAMLMetadataContext apply(ProfileRequestContext input) {
+ return metadataContextLookupStrategy.apply(input);
+ }
+ },
new RootContextLookup<AttributeFilterContext,ProfileRequestContext>());
}
[... 10 lines stripped ...]
More information about the commits
mailing list