ソースを参照

Added fields in mapping.xml

Denis Waßmann 7 年 前
コミット
25735dbcbe
1 ファイル変更5 行追加0 行削除
  1. 5 0
      code/ID2TLib/Botnet/MessageMapping.py

+ 5 - 0
code/ID2TLib/Botnet/MessageMapping.py

@@ -30,6 +30,11 @@ class MessageMapping:
             mapping.setAttribute(self.ATTR_ID, str(message.msg_id))
             mapping.setAttribute(self.ATTR_LINENO, str(message.line_no))
 
+            mapping.setAttribute("Src", str(message.src["ID"]))
+            mapping.setAttribute("Dst", str(message.dst["ID"]))
+            mapping.setAttribute("Type", str(message.type.value))
+            mapping.setAttribute("Time", str(message.time))
+
             packet = self.id_to_packet.get(message.msg_id)
             mapping.setAttribute(self.ATTR_HAS_PACKET, "true" if packet is not None else "false")
             if packet: