I have received the APNS certificate using iOS Enterprise developer account and that is in .pem format.We have download this mdm certificate from the portal https://identity.apple.com/pushcert/
I have referred the 2011_THE iOS MDM Protocol document for MDM server implementation.I am able to get the pushmagic and device token.
I am using the below code which is given in the "2011_THE iOS MDM Protocol" document as server.py file.
class queue_cmd: def GET(self):
global current_command, last_sent global my_DeviceToken, my_PushMagic
i = web.input() cmd = i.command
cmd_data = mdm_commands[cmd]
cmd_data['CommandUUID'] = str(uuid.uuid4())
current_command = cmd_data last_sent = pprint.pformat(current_command)
wrapper = APNSNotificationWrapper('PlainCert.pem', False)
message = APNSNotification()
message.token(my_DeviceToken)
message.appendProperty(APNSProperty('mdm', my_PushMagic))
wrapper.append(message)
wrapper.notify()
Now I want to know should I use the APNS certificate downloaded from portal https://identity.apple.com/pushcert/ by renaming it to "PlainCert.pem" in our server.py code or should I generate "PlainCert.pem" by some other way?