Fixed the bug that dropped the last char.
authordousti <dousti@ab3bd59b-922f-494d-bb5f-6f0a3c29deca>
Thu, 20 Jun 2002 19:55:07 +0000 (19:55 +0000)
committerdousti <dousti@ab3bd59b-922f-494d-bb5f-6f0a3c29deca>
Thu, 20 Jun 2002 19:55:07 +0000 (19:55 +0000)
git-svn-id: https://subversion.switch.ch/svn/shibboleth/java-idp/trunk@160 ab3bd59b-922f-494d-bb5f-6f0a3c29deca

src/edu/internet2/middleware/shibboleth/aaLocal/attributes/eduPersonPrincipalName.java

index 5d4dc46..23cb65c 100644 (file)
@@ -16,12 +16,15 @@ public class eduPersonPrincipalName implements ShibAttribute{
        int x = eppn.indexOf("@") ;
        System.out.println("EPPN: "+eppn+"    @ at "+x);
        if(x > 0){
-           vals[0] = eppn.substring(0,x-1);
+           vals[0] = eppn.substring(0,x);
            scopes[0] = eppn.substring(x+1);
        }else{
            vals[0] = eppn;
            scopes[0] = defaultScope;
        }
+
+       System.out.println("AA debug: sending value="+vals[0]+"  scope="+scopes[0]);
+               
        return new ScopedAttribute("urn:mace:eduPerson:1.0:eduPersonPrincipalName",
                                 Constants.SHIB_ATTRIBUTE_NAMESPACE_URI, 
                                 new QName("urn:mace:eduPerson:1.0",