[java-identity-provider] branch main updated: IDP-2026 - Address SSO audit flag when MFA flow used

Scott Cantor cantor.2 at osu.edu
Thu Dec 15 21:10:34 UTC 2022


This is an automated email from the git hooks/post-receive script.

scantor pushed a commit to branch main
in repository java-identity-provider.

View the commit online:
http://git.shibboleth.net/view/?p=java-identity-provider.git;a=commit;h=b769db72ec05e1b3af6c87c598145e1af0638233

The following commit(s) were added to refs/heads/main by this push:
     new b769db72e IDP-2026 - Address SSO audit flag when MFA flow used
b769db72e is described below

commit b769db72ec05e1b3af6c87c598145e1af0638233
Author: Scott Cantor <cantor.2 at osu.edu>
AuthorDate: Thu Dec 15 16:07:33 2022 -0500

    IDP-2026 - Address SSO audit flag when MFA flow used
    
    https://shibboleth.atlassian.net/browse/IDP-2026
    
    Adjust merging function to set flag based on underlying results.
---
 .../idp/authn/impl/FinalizeMultiFactorAuthentication.java          | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/idp-authn-impl/src/main/java/net/shibboleth/idp/authn/impl/FinalizeMultiFactorAuthentication.java b/idp-authn-impl/src/main/java/net/shibboleth/idp/authn/impl/FinalizeMultiFactorAuthentication.java
index dc917fa9a..98a4134bc 100644
--- a/idp-authn-impl/src/main/java/net/shibboleth/idp/authn/impl/FinalizeMultiFactorAuthentication.java
+++ b/idp-authn-impl/src/main/java/net/shibboleth/idp/authn/impl/FinalizeMultiFactorAuthentication.java
@@ -242,15 +242,22 @@ public class FinalizeMultiFactorAuthentication extends AbstractAuthenticationAct
                     if (mfaContext != null) {
                         final Collection<AuthenticationResult> results = mfaContext.getActiveResults().values();
                         if (!results.isEmpty()) {
+                            
+                            // Track whether SSO was performed.
+                            boolean allPreviousResults = true;
+                            
                             final Subject subject = new Subject();
                             for (final AuthenticationResult result : results) {
                                 subject.getPrincipals().add(new AuthenticationResultPrincipal(result));
                                 subject.getPrincipals().addAll(result.getSubject().getPrincipals());
                                 subject.getPublicCredentials().addAll(result.getSubject().getPublicCredentials());
                                 subject.getPrivateCredentials().addAll(result.getSubject().getPrivateCredentials());
+                                allPreviousResults = allPreviousResults && result.isPreviousResult();
                             }
+                            
                             final AuthenticationResult merged = new AuthenticationResult(
                                     mfaContext.getAuthenticationFlowDescriptor().getId(), subject);
+                            merged.setPreviousResult(allPreviousResults);
                             return merged;
                         }
                     }

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the commits mailing list