示例#1
0
 def pack(self):
     dict_ = super().pack()
     if self.signed_root:
         dict_[self.SIGNED_ROOT] = self.signed_root.pack()
     if self.monitor_id is not None:
         dict_[self.MONITOR_ID] = self.monitor_id
     return obj_to_bin(dict_)
示例#2
0
 def pack(self):
     dict_ = super().pack()
     dict_[self.ROOT] = self.root
     dict_[self.TIMESTAMP] = self.timestamp
     dict_[self.ENTRIES_NO] = self.entries_no
     dict_[self.ROOT_IDX] = self.root_idx
     dict_[self.LOG_ID] = self.log_id
     return obj_to_bin(dict_)
示例#3
0
 def pack(self):
     dict_ = super().pack()
     dict_[self.DNAME] = self.domain_name
     dict_[self.MSC_LABEL] = self.msc_label
     dict_[self.APPEND_ROOT] = self.append_root
     if self.eeepki_proof:
         dict_[self.EEPKI_PROOF] = self.eepki_proof.pack()
     else:
         dict_[self.EEPKI_PROOF] = None
     return obj_to_bin(dict_)
示例#4
0
 def pack(self):
     dict_ = super().pack()
     dict_[self.LOG_ID] = self.log_id
     if self.entry_from is None or self.entry_to is None:
         raise EEPKIParseError("Cannot pack")
     dict_[self.ENTRY_FROM] = self.entry_from
     dict_[self.ENTRY_TO] = self.entry_to
     if self.entries:
         dict_[self.ENTRIES] = [entry.pack() for entry in self.entries]
     return obj_to_bin(dict_)
示例#5
0
 def pack(self):
     dict_ = super().pack()
     dict_[self.LOG_ID] = self.log_id
     dict_[self.ROOT_IDX] = self.root_idx
     return obj_to_bin(dict_)
示例#6
0
 def pack(self):
     dict_ = super().pack()
     dict_[self.HASH] = self.hash
     dict_[self.TIMESTAMP] = self.timestamp
     return obj_to_bin(dict_)
示例#7
0
 def pack(self):
     dict_ = super().pack()
     dict_[self.ENTRY] = self.entry.pack()
     return obj_to_bin(dict_)
示例#8
0
 def pack(self):
     dict_ = super().pack()
     if self.description:
         dict_[self.DESCRIPTION] = self.description
     return obj_to_bin(dict_)