tc full packet test
All checks were successful
Build and Deploy MITM Webserver / build (push) Successful in 10s
All checks were successful
Build and Deploy MITM Webserver / build (push) Successful in 10s
This commit is contained in:
@@ -11,9 +11,15 @@ class PacketDBModel(BaseModel):
|
||||
|
||||
id: Union[int, str]
|
||||
timestamp: datetime = Field(..., description="Packet timestamp in ISO format.")
|
||||
packet_uid: str = Field(..., description="Stable packet identity used for upserts/correlation.")
|
||||
updated_at: Optional[datetime] = Field(None, description="Last DB update time for this row.")
|
||||
correlation_key: str = Field(..., description="Primary upsert key for this packet row.")
|
||||
correlation_source: Optional[str] = Field(None, description="How the correlation key was derived.")
|
||||
packet_id: Optional[str] = Field(None, description="Kernel-side packet identifier derived from skb mark.")
|
||||
packet_uid: Optional[str] = Field(None, description="Legacy hash-based packet identity fallback.")
|
||||
skb_mark: Optional[int] = Field(None, description="Raw skb mark observed in telemetry or capture header.")
|
||||
ingress_if: Optional[str] = None
|
||||
egress_if: Optional[str] = None
|
||||
capture_iface: Optional[str] = None
|
||||
src_mac: Optional[str] = None
|
||||
dst_mac: Optional[str] = None
|
||||
eth_type_raw: Optional[int] = Field(None, description="Numeric Ethernet type from the frame header.")
|
||||
@@ -37,6 +43,7 @@ class PacketDBModel(BaseModel):
|
||||
app_is_encrypted: Optional[bool] = Field(None, description="Whether detected protocol appears encrypted.")
|
||||
app_risk_score: Optional[int] = Field(None, description="Count/score of detected nDPI risks.")
|
||||
dpi_metadata: Optional[dict] = Field(None, description="Raw DPI metadata from nDPI.")
|
||||
capture_metadata: Optional[dict] = Field(None, description="Capture-side metadata from the mirrored packet shim.")
|
||||
telemetry_metadata: Optional[dict] = Field(None, description="Kernel telemetry details from eBPF collector.")
|
||||
verdict: Optional[str] = None
|
||||
verdict_reason: Optional[str] = None
|
||||
@@ -51,9 +58,15 @@ class PacketDBModel(BaseModel):
|
||||
"example": {
|
||||
"id": 123,
|
||||
"timestamp": "2026-03-05T12:34:56.789Z",
|
||||
"updated_at": "2026-03-05T12:34:56.900Z",
|
||||
"correlation_key": "pid:123456",
|
||||
"correlation_source": "kernel_mark",
|
||||
"packet_id": "123456",
|
||||
"packet_uid": "9f6d3af0d3c81cb20ee8e7d32df7c56414460542",
|
||||
"skb_mark": 123456,
|
||||
"ingress_if": "eth0",
|
||||
"egress_if": "eth1",
|
||||
"capture_iface": "mitmcap0",
|
||||
"src_mac": "aa:bb:cc:dd:ee:ff",
|
||||
"dst_mac": "11:22:33:44:55:66",
|
||||
"eth_type_raw": 2048,
|
||||
@@ -77,6 +90,7 @@ class PacketDBModel(BaseModel):
|
||||
"app_is_encrypted": False,
|
||||
"app_risk_score": 0,
|
||||
"dpi_metadata": {"method": "GET"},
|
||||
"capture_metadata": {"header_magic": "MTCP", "header_version": 1},
|
||||
"telemetry_metadata": {"event_type": "egress", "iface": "eth1"},
|
||||
"verdict": "accept",
|
||||
"verdict_reason": "egress-observed",
|
||||
|
||||
Reference in New Issue
Block a user