[java-identity-provider] branch main updated: IDP-1894 - Log final msg with principal when authentication completes
Scott Cantor
cantor.2 at osu.edu
Wed Mar 2 21:42:31 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=7c1b3983ba9517db262a2d727d085c70c7221c7d
The following commit(s) were added to refs/heads/main by this push:
new 7c1b3983b IDP-1894 - Log final msg with principal when authentication completes
7c1b3983b is described below
commit 7c1b3983ba9517db262a2d727d085c70c7221c7d
Author: Scott Cantor <cantor.2 at osu.edu>
AuthorDate: Wed Mar 2 16:42:27 2022 -0500
IDP-1894 - Log final msg with principal when authentication completes
https://shibboleth.atlassian.net/browse/IDP-1894
---
.../net/shibboleth/idp/authn/impl/FinalizeAuthentication.java | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/idp-authn-impl/src/main/java/net/shibboleth/idp/authn/impl/FinalizeAuthentication.java b/idp-authn-impl/src/main/java/net/shibboleth/idp/authn/impl/FinalizeAuthentication.java
index 89fc53388..1a462a4bb 100644
--- a/idp-authn-impl/src/main/java/net/shibboleth/idp/authn/impl/FinalizeAuthentication.java
+++ b/idp-authn-impl/src/main/java/net/shibboleth/idp/authn/impl/FinalizeAuthentication.java
@@ -110,13 +110,11 @@ public class FinalizeAuthentication extends AbstractAuthenticationAction {
final SubjectCanonicalizationContext c14nCtx =
profileRequestContext.getSubcontext(SubjectCanonicalizationContext.class);
- if (c14nCtx != null) {
+ if (c14nCtx != null && c14nCtx.getPrincipalName() != null) {
canonicalPrincipalName = c14nCtx.getPrincipalName();
profileRequestContext.removeSubcontext(c14nCtx);
log.debug("{} Canonical principal name was established as '{}'", getLogPrefix(), canonicalPrincipalName);
- }
-
- if (canonicalPrincipalName == null) {
+ } else if (canonicalPrincipalName == null) {
final SessionContext sessionCtx = profileRequestContext.getSubcontext(SessionContext.class);
if (sessionCtx != null && sessionCtx.getIdPSession() != null) {
canonicalPrincipalName = sessionCtx.getIdPSession().getPrincipalName();
@@ -194,6 +192,8 @@ public class FinalizeAuthentication extends AbstractAuthenticationAction {
final SubjectContext sc = profileRequestContext.getSubcontext(SubjectContext.class, true);
sc.setPrincipalName(canonicalPrincipalName);
+
+ log.info("{} Principal {} authenticated", getLogPrefix(), canonicalPrincipalName);
final Map<String,AuthenticationResult> scResults = sc.getAuthenticationResults();
scResults.putAll(authenticationContext.getActiveResults());
--
To stop receiving notification emails like this one, please contact
the administrator of this repository.
More information about the commits
mailing list