cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From cohei...@apache.org
Subject cxf git commit: Make it easier to change the name Id Format
Date Mon, 25 Jan 2016 16:47:54 GMT
Repository: cxf
Updated Branches:
  refs/heads/3.0.x-fixes e61467c87 -> a43da7591


Make it easier to change the name Id Format


Project: http://git-wip-us.apache.org/repos/asf/cxf/repo
Commit: http://git-wip-us.apache.org/repos/asf/cxf/commit/a43da759
Tree: http://git-wip-us.apache.org/repos/asf/cxf/tree/a43da759
Diff: http://git-wip-us.apache.org/repos/asf/cxf/diff/a43da759

Branch: refs/heads/3.0.x-fixes
Commit: a43da7591d44d93f368e878aca5861e1fb61e8c7
Parents: e61467c
Author: Colm O hEigeartaigh <coheigea@apache.org>
Authored: Mon Jan 25 16:40:03 2016 +0000
Committer: Colm O hEigeartaigh <coheigea@apache.org>
Committed: Mon Jan 25 16:45:42 2016 +0000

----------------------------------------------------------------------
 .../security/saml/sso/DefaultAuthnRequestBuilder.java  | 13 ++++++++++---
 1 file changed, 10 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cxf/blob/a43da759/rt/rs/security/sso/saml/src/main/java/org/apache/cxf/rs/security/saml/sso/DefaultAuthnRequestBuilder.java
----------------------------------------------------------------------
diff --git a/rt/rs/security/sso/saml/src/main/java/org/apache/cxf/rs/security/saml/sso/DefaultAuthnRequestBuilder.java
b/rt/rs/security/sso/saml/src/main/java/org/apache/cxf/rs/security/saml/sso/DefaultAuthnRequestBuilder.java
index 9fdde89..6e0ed5e 100644
--- a/rt/rs/security/sso/saml/src/main/java/org/apache/cxf/rs/security/saml/sso/DefaultAuthnRequestBuilder.java
+++ b/rt/rs/security/sso/saml/src/main/java/org/apache/cxf/rs/security/saml/sso/DefaultAuthnRequestBuilder.java
@@ -39,6 +39,7 @@ public class DefaultAuthnRequestBuilder implements AuthnRequestBuilder {
     private boolean forceAuthn;
     private boolean isPassive;
     private String protocolBinding = "urn:oasis:names:tc:SAML:2.0:bindings:HTTP-POST";
+    private String nameIDFormat = "urn:oasis:names:tc:SAML:2.0:nameid-format:persistent";
     
     /**
      * Create a SAML 2.0 Protocol AuthnRequest
@@ -52,9 +53,7 @@ public class DefaultAuthnRequestBuilder implements AuthnRequestBuilder {
             SamlpRequestComponentBuilder.createIssuer(issuerId);
         
         NameIDPolicy nameIDPolicy =
-            SamlpRequestComponentBuilder.createNameIDPolicy(
-                true, "urn:oasis:names:tc:SAML:2.0:nameid-format:persistent", issuerId
-            );
+            SamlpRequestComponentBuilder.createNameIDPolicy(true, nameIDFormat, issuerId);
         
         AuthnContextClassRef authnCtxClassRef =
             SamlpRequestComponentBuilder.createAuthnCtxClassRef(
@@ -103,5 +102,13 @@ public class DefaultAuthnRequestBuilder implements AuthnRequestBuilder
{
     public void setProtocolBinding(String protocolBinding) {
         this.protocolBinding = protocolBinding;
     }
+
+    public String getNameIDFormat() {
+        return nameIDFormat;
+    }
+
+    public void setNameIDFormat(String nameIDFormat) {
+        this.nameIDFormat = nameIDFormat;
+    }
     
 }


Mime
View raw message