def msg_pkget(args): print "pkGET args: " print args acpkreq = ac_pb2.acPublicKeyMessageRequest() acpkreq.type = ac_pb2.acPublicKeyMessageRequest.PK_GET acpkreq.nick = args[KEY_NICK] return acpkreq.SerializeToString()
def msg_pkdel(args): print "pkDEL args: " print args acpkreq = ac_pb2.acPublicKeyMessageRequest() acpkreq.type = ac_pb2.acPublicKeyMessageRequest.PK_DEL if args and args[KEY_NICK]: acpkreq.nick = args[KEY_NICK] return acpkreq.SerializeToString()
def msg_pklist(args): print "pkLIST args: " print args acpkreq = ac_pb2.acPublicKeyMessageRequest() acpkreq.type = ac_pb2.acPublicKeyMessageRequest.PK_LIST if args and args[KEY_NICK]: print " I M HERE!!!" acpkreq.nick = args[KEY_NICK] return acpkreq.SerializeToString()
def msg_pkadd(args): print "pkADD args: " print args acpkreq = ac_pb2.acPublicKeyMessageRequest() acpkreq.type = ac_pb2.acPublicKeyMessageRequest.PK_ADD acpkreq.nick = args[KEY_NICK] acpkreq.host = args[KEY_HOST] acpkreq.server = args[KEY_SERVER] acpkreq.blob = args[KEY_BLOB] return acpkreq.SerializeToString()