[jboss-cvs] Picketlink SVN: r398 - in federation/branches/Branch_1_x: picketlink-fed-core/src/main/java/org/picketlink/identity/federation/core/wstrust and 1 other directory.

jboss-cvs-commits at lists.jboss.org jboss-cvs-commits at lists.jboss.org
Wed Sep 15 18:50:04 EDT 2010


Author: sguilhen at redhat.com
Date: 2010-09-15 18:50:04 -0400 (Wed, 15 Sep 2010)
New Revision: 398

Modified:
   federation/branches/Branch_1_x/picketlink-bindings-jboss/src/main/java/org/picketlink/identity/federation/bindings/jboss/auth/SAML2STSIssuingLoginModule.java
   federation/branches/Branch_1_x/picketlink-fed-core/src/main/java/org/picketlink/identity/federation/core/wstrust/SAMLPrincipal.java
Log:
Added missing javadocs

Modified: federation/branches/Branch_1_x/picketlink-bindings-jboss/src/main/java/org/picketlink/identity/federation/bindings/jboss/auth/SAML2STSIssuingLoginModule.java
===================================================================
--- federation/branches/Branch_1_x/picketlink-bindings-jboss/src/main/java/org/picketlink/identity/federation/bindings/jboss/auth/SAML2STSIssuingLoginModule.java	2010-09-15 00:35:42 UTC (rev 397)
+++ federation/branches/Branch_1_x/picketlink-bindings-jboss/src/main/java/org/picketlink/identity/federation/bindings/jboss/auth/SAML2STSIssuingLoginModule.java	2010-09-15 22:50:04 UTC (rev 398)
@@ -163,7 +163,7 @@
             log.trace("Calling STS at " + this.endpointURL);
          Element assertionElement = client.issueToken(SAMLUtil.SAML2_TOKEN_TYPE);
          SamlCredential credential = new SamlCredential(assertionElement);
-         this.principal = new SAMLPrincipal(this.getPrincipalFromAssertion(assertionElement), credential);
+         this.principal = new SAMLPrincipal(this.getAssertionSubjectName(assertionElement), credential);
       }
       catch (WSTrustException we)
       {
@@ -241,7 +241,15 @@
       return new Group[] {callerPrincipal};
    }
 
-   private String getPrincipalFromAssertion(Element assertionElement)
+   /**
+    * <p>
+    * Obtains the subject name of the specified SAML assertion.
+    * </p>
+    * 
+    * @param assertionElement the assertion {@code Element}.
+    * @return the name of the assertion subject.
+    */
+   private String getAssertionSubjectName(Element assertionElement)
    {
       try
       {

Modified: federation/branches/Branch_1_x/picketlink-fed-core/src/main/java/org/picketlink/identity/federation/core/wstrust/SAMLPrincipal.java
===================================================================
--- federation/branches/Branch_1_x/picketlink-fed-core/src/main/java/org/picketlink/identity/federation/core/wstrust/SAMLPrincipal.java	2010-09-15 00:35:42 UTC (rev 397)
+++ federation/branches/Branch_1_x/picketlink-fed-core/src/main/java/org/picketlink/identity/federation/core/wstrust/SAMLPrincipal.java	2010-09-15 22:50:04 UTC (rev 398)
@@ -1,3 +1,20 @@
+/*
+ * JBoss, Home of Professional Open Source. Copyright 2008, Red Hat Middleware LLC, and individual contributors as
+ * indicated by the @author tags. See the copyright.txt file in the distribution for a full listing of individual
+ * contributors.
+ * 
+ * This is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either version 2.1 of the License, or (at your option) any
+ * later version.
+ * 
+ * This software is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied
+ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
+ * details.
+ * 
+ * You should have received a copy of the GNU Lesser General Public License along with this software; if not, write to
+ * the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA, or see the FSF site:
+ * http://www.fsf.org.
+ */
 package org.picketlink.identity.federation.core.wstrust;
 
 import java.io.Serializable;
@@ -3,4 +20,11 @@
 import java.security.Principal;
 
+/**
+ * <p>
+ * A {@code Principal} implementation that encloses a {@code SamlCredential}.
+ * </p> 
+ * 
+ * @author <a href="mailto:sguilhen at redhat.com">Stefan Guilhen</a>
+ */
 public class SAMLPrincipal implements Principal, Serializable
 {



More information about the jboss-cvs-commits mailing list