From 4f4651e360edf2916a648356db2e16ef1d560f7c Mon Sep 17 00:00:00 2001 From: Philippe Antoine Date: Fri, 16 Jun 2023 16:22:29 +0200 Subject: [PATCH] output/file: http2 metdata is logged in http object as is done for http2 events and alerts. The http.version integer can help to determine if this is HTTP2 Ticket: #6165 --- etc/schema.json | 89 ------------------------------------------ src/output-json-file.c | 2 +- 2 files changed, 1 insertion(+), 90 deletions(-) diff --git a/etc/schema.json b/etc/schema.json index 3fa763603a..32510a6198 100644 --- a/etc/schema.json +++ b/etc/schema.json @@ -1791,95 +1791,6 @@ }, "additionalProperties": false }, - "http2": { - "type": "object", - "properties": { - "http_method": { - "type": "string" - }, - "http_user_agent": { - "type": "string" - }, - "length": { - "type": "integer" - }, - "status": { - "type": "integer" - }, - "url": { - "type": "string" - }, - "version": { - "type": "string" - }, - "request_headers": { - "type": "array", - "minItems": 1, - "items": { - "type": "object", - "properties": { - "name": { - "type": "string" - }, - "table_size_update": { - "type": "integer" - }, - "value": { - "type": "string" - } - }, - "additionalProperties": false - } - }, - "response_headers": { - "type": "array", - "minItems": 1, - "items": { - "type": "object", - "properties": { - "name": { - "type": "string" - }, - "table_size_update": { - "type": "integer" - }, - "value": { - "type": "string" - } - }, - "additionalProperties": false - } - }, - "http2": { - "type": "object", - "properties": { - "stream_id": { - "type": "integer" - }, - "request": { - "type": "object", - "properties": { - "priority": { - "type": "integer" - } - }, - "additionalProperties": false - }, - "response": { - "type": "object", - "properties": { - "error_code": { - "type": "string" - } - }, - "additionalProperties": false - } - }, - "additionalProperties": false - } - }, - "additionalProperties": false - }, "ike": { "type": "object", "optional": true, diff --git a/src/output-json-file.c b/src/output-json-file.c index 540e1be001..a0ce76d71f 100644 --- a/src/output-json-file.c +++ b/src/output-json-file.c @@ -174,7 +174,7 @@ JsonBuilder *JsonBuildFileInfoRecord(const Packet *p, const File *ff, void *tx, break; case ALPROTO_HTTP2: jb_get_mark(js, &mark); - jb_open_object(js, "http2"); + jb_open_object(js, "http"); if (EveHTTP2AddMetadata(p->flow, tx_id, js)) { jb_close(js); } else {