Skip to content

Commit

Permalink
- add spamvertised schema
Browse files Browse the repository at this point in the history
  • Loading branch information
ethanae committed Aug 2, 2024
1 parent 5b178c7 commit 5c219ad
Show file tree
Hide file tree
Showing 3 changed files with 80 additions and 0 deletions.
32 changes: 32 additions & 0 deletions samples/positive/development/spamvertised_sample.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
{
"Version": "development",
"ReporterInfo": {
"ReporterOrg": "ExampleOrg",
"ReporterOrgDomain": "example.com",
"ReporterOrgEmail": "[email protected]",
"ReporterContactEmail": "[email protected]",
"ReporterContactName": "Mr. Example",
"ReporterContactPhone": "+ 01 000 1234567"
},
"Disclosure": true,
"Report": {
"ReportClass": "Activity",
"ReportType": "Spamvertised",
"Date": "2024-08-03T14:17:10Z",
"SourceIp": "192.0.2.55",
"SourcePort": 54321,
"SourceUrl": "http://bad-spamvertised.spam",
"DestinationIp": "198.51.100.33",
"DestinationPort": 25,
"SmtpMailFromAddress": "[email protected]",
"SmtpRcptToAddress": "[email protected]",
"Samples": [
{
"ContentType": "message/rfc822",
"Base64Encoded": true,
"Description": "The spamvertised mail",
"Payload": "bWFpbA=="
}
]
}
}
45 changes: 45 additions & 0 deletions schemas/development/spamvertised.schema.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
{
"$schema": "http://json-schema.org/draft-07/schema#",
"$id": "https://raw.githubusercontent.com/xarf/schema-discussion/master/schemas/development/spamvertised.schema.json",
"title": "XARF SPAMVERTISED",
"description": "A format to report SPAMVERTISED events.",
"allOf": [
{
"$ref": "xarf_shared.schema.json#/properties/XarfBase"
},
{
"type": "object",
"properties": {
"Report": {
"allOf": [
{
"$ref": "xarf_shared.schema.json#/properties/IpAndUrlBasedReport"
},
{
"type": "object",
"properties": {
"ReportClass": {
"type": "string",
"enum": ["Activity"]
},
"ReportType": {
"type": "string",
"enum": ["Spamvertised"]
}
}
},
{
"$ref": "xarf_shared.schema.json#/properties/WithDestination"
},
{
"$ref": "xarf_shared.schema.json#/properties/CommonProps"
},
{
"$ref": "xarf_shared.schema.json#/properties/EMail"
}
]
}
}
}
]
}
3 changes: 3 additions & 0 deletions schemas/development/xarf.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,9 @@
},
{
"$ref": "harassment.schema.json"
},
{
"$ref": "spamvertised.schema.json"
}
]
}

0 comments on commit 5c219ad

Please sign in to comment.