diff options
author | Derick Montague <derick.montague@ibm.com> | 2019-12-03 12:52:42 -0600 |
---|---|---|
committer | Gunnar Mills <gmills@us.ibm.com> | 2019-12-04 18:00:25 +0000 |
commit | b42b93d8adcf463dc7cc4422cf6718d698c95236 (patch) | |
tree | 0521a456cdb9c949f5146f50589dc7e298a06ee3 | |
parent | ca7e093bd789f34c35e714dc5bce1ae4e9ce4205 (diff) | |
download | phosphor-webui-b42b93d8adcf463dc7cc4422cf6718d698c95236.tar.gz phosphor-webui-b42b93d8adcf463dc7cc4422cf6718d698c95236.zip |
Fix LDAP request resulting in 400 response
- Remove all references to the AuthenticationType property since our
request is a PATCH and we are not changing the value.
Resolves: https://github.com/openbmc/phosphor-webui/issues/102
Signed-off-by: Derick Montague <derick.montague@ibm.com>
Change-Id: I911ac41bf61250847e4c308f09df8fd59dd27fa7
-rw-r--r-- | app/access-control/controllers/ldap-controller.js | 21 |
1 files changed, 1 insertions, 20 deletions
diff --git a/app/access-control/controllers/ldap-controller.js b/app/access-control/controllers/ldap-controller.js index 16992ec..e77bf86 100644 --- a/app/access-control/controllers/ldap-controller.js +++ b/app/access-control/controllers/ldap-controller.js @@ -44,7 +44,6 @@ window.angular && (function(angular) { getBaseDistinguishedNames(data); const groupsAttribute = getGroupsAttribute(data); const usernameAttribute = getUsernameAttribute(data); - const authenticationType = getAuthenticationType(data); const roleGroups = getRoleGroups(data); @@ -60,7 +59,6 @@ window.angular && (function(angular) { 'BaseDistinguishedNames': baseDistinguishedNames, 'GroupsAttribute': groupsAttribute, 'UsernameAttribute': usernameAttribute, - 'AuthenticationType': authenticationType, 'RoleGroups': roleGroups }; }, @@ -268,7 +266,6 @@ window.angular && (function(angular) { return groupsAttribute; } - /** * * @param {Object} ldapProperties @@ -287,21 +284,6 @@ window.angular && (function(angular) { /** * * @param {Object} ldapProperties - * @returns {null | string} - */ - function getAuthenticationType(ldapProperties) { - let authenticationType = null; - let serviceType = getEnabledServiceType(ldapProperties); - if (serviceType) { - authenticationType = - ldapProperties[serviceType]['Authentication']['AuthenticationType']; - } - return authenticationType; - } - - /** - * - * @param {Object} ldapProperties * @returns {Array} A list of role groups */ function getRoleGroups(ldapProperties) { @@ -323,8 +305,7 @@ window.angular && (function(angular) { const ServiceEnabled = true; const Authentication = { Username: ldapProperties.Username, - Password: ldapProperties.Password, - AuthenticationType: ldapProperties.AuthenticationType + Password: ldapProperties.Password }; const LDAPService = { SearchSettings: { |