cloudstack-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bhais...@apache.org
Subject [3/8] git commit: updated refs/heads/master to 869a83f
Date Fri, 14 Aug 2015 06:54:44 GMT
CLOUDSTACK-8701: Add administrative contact block as per SAML IDP expectations

Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
(cherry picked from commit 1e3e67451489789949e1b50e1f0732bcba0596b5)
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>


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

Branch: refs/heads/master
Commit: da72ba6e1b95ab867c1ee88f7dac3efb0051e10d
Parents: 1ec4d01
Author: Rohit Yadav <rohit.yadav@shapeblue.com>
Authored: Sun Aug 9 00:13:51 2015 +0530
Committer: Rohit Yadav <rohit.yadav@shapeblue.com>
Committed: Fri Aug 14 11:59:16 2015 +0530

----------------------------------------------------------------------
 .../api/command/GetServiceProviderMetaDataCmd.java    | 14 +++++++++++++-
 1 file changed, 13 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cloudstack/blob/da72ba6e/plugins/user-authenticators/saml2/src/org/apache/cloudstack/api/command/GetServiceProviderMetaDataCmd.java
----------------------------------------------------------------------
diff --git a/plugins/user-authenticators/saml2/src/org/apache/cloudstack/api/command/GetServiceProviderMetaDataCmd.java
b/plugins/user-authenticators/saml2/src/org/apache/cloudstack/api/command/GetServiceProviderMetaDataCmd.java
index a6cefb1..89e3f31 100644
--- a/plugins/user-authenticators/saml2/src/org/apache/cloudstack/api/command/GetServiceProviderMetaDataCmd.java
+++ b/plugins/user-authenticators/saml2/src/org/apache/cloudstack/api/command/GetServiceProviderMetaDataCmd.java
@@ -206,16 +206,28 @@ public class GetServiceProviderMetaDataCmd extends BaseCmd implements
APIAuthent
         spSSODescriptor.addSupportedProtocol(SAMLConstants.SAML20P_NS);
         spEntityDescriptor.getRoleDescriptors().add(spSSODescriptor);
 
-        ContactPerson contactPerson = new ContactPersonBuilder().buildObject();
+        // Add technical contact
         GivenName givenName = new GivenNameBuilder().buildObject();
         givenName.setName(spMetadata.getContactPersonName());
         EmailAddress emailAddress = new EmailAddressBuilder().buildObject();
         emailAddress.setAddress(spMetadata.getContactPersonEmail());
+        ContactPerson contactPerson = new ContactPersonBuilder().buildObject();
         contactPerson.setType(ContactPersonTypeEnumeration.TECHNICAL);
         contactPerson.setGivenName(givenName);
         contactPerson.getEmailAddresses().add(emailAddress);
         spEntityDescriptor.getContactPersons().add(contactPerson);
 
+        // Add administrative/support contact
+        GivenName givenNameAdmin = new GivenNameBuilder().buildObject();
+        givenNameAdmin.setName(spMetadata.getContactPersonName());
+        EmailAddress emailAddressAdmin = new EmailAddressBuilder().buildObject();
+        emailAddressAdmin.setAddress(spMetadata.getContactPersonEmail());
+        ContactPerson contactPersonAdmin = new ContactPersonBuilder().buildObject();
+        contactPersonAdmin.setType(ContactPersonTypeEnumeration.ADMINISTRATIVE);
+        contactPersonAdmin.setGivenName(givenNameAdmin);
+        contactPersonAdmin.getEmailAddresses().add(emailAddressAdmin);
+        spEntityDescriptor.getContactPersons().add(contactPersonAdmin);
+
         Organization organization = new OrganizationBuilder().buildObject();
         OrganizationName organizationName = new OrganizationNameBuilder().buildObject();
         organizationName.setName(new LocalizedString(spMetadata.getOrganizationName(), Locale.getDefault().getLanguage()));


Mime
View raw message