Commit aafb86eb authored by Łukasz Nowak's avatar Łukasz Nowak

Expose bindings for certificate manipulation.

parent 3cb292c5
...@@ -286,6 +286,12 @@ class Computer(SlapDocument): ...@@ -286,6 +286,12 @@ class Computer(SlapDocument):
'computer_id': self._computer_id, 'computer_id': self._computer_id,
'message': message}) 'message': message})
def getCertificateDict(self):
return {
'key': getattr(self, '_key', None),
'certificate': getattr(self, '_certificate', None)
}
def _syncComputerPartitionInformation(func): def _syncComputerPartitionInformation(func):
""" """
Synchronize computer partition object with server information Synchronize computer partition object with server information
...@@ -681,6 +687,17 @@ class slap: ...@@ -681,6 +687,17 @@ class slap:
computer = xml_marshaller.loads(xml) computer = xml_marshaller.loads(xml)
return computer return computer
def revokeComputerCertificate(self, computer_id):
self._connection_helper.POST('/revokeComputerCertificate', {
'computer_id': computer_id})
def getComputerCertificate(self, computer_id):
self._connection_helper.POST('/getComputerCertificate', {
'computer_id': computer_id})
xml = self._connection_helper.response.read()
computer = xml_marshaller.loads(xml)
return computer
def registerComputer(self, computer_guid): def registerComputer(self, computer_guid):
""" """
Registers connected representation of computer and Registers connected representation of computer and
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment