2
0
mirror of https://github.com/openkmip/pykmip synced 2025-12-25 20:53:23 +00:00

Adding server support for the GetAttributes operation

This change adds server support for the GetAttributes operation.
The user can specify an object ID and an attribute list to get
the values of the attributes listed from the specified object.
The user can also omit either argument; the server will default
to using the ID placeholder and all viable attributes respectively.
Only a subset of the standard attributes are supported right now.
New tests have been added to cover the new feature.

Closes #185
Closes #211
Closes #218
This commit is contained in:
Peter Hamilton
2016-12-01 18:21:07 -05:00
parent c92579d50a
commit c59cfeeef9
7 changed files with 991 additions and 193 deletions

View File

@@ -1146,3 +1146,12 @@ class AttributePolicy(object):
# TODO (peterhamilton) Handle multivalue swap between certificate types
rule_set = self._attribute_rule_sets.get(attribute)
return rule_set.multiple_instances_permitted
def get_all_attribute_names(self):
"""
Get a list of all supported attribute names.
Returns:
list: A list of string attribute names.
"""
return self._attribute_rule_sets.keys()