-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Closed
Description
NEST/Elasticsearch.Net version: 7.8.1
Elasticsearch version: 7.8.0
Description of the problem including expected versus actual behavior: We're ingesting suricata eve logs with timestamps in the default suricata format: 2020-07-23T14:43:46.129022-0400
. We are getting an exception (see below) when we try to deserialize in NEST.
Steps to reproduce:
- Ingest a suricata log into elasticsearch
- Attempt to deserialize the log. It will throw an exception complaining about the datetime format of the timestamp field.
Exception:
System.InvalidOperationException: invalid datetime format. value:2020-07-23T14:43:46.129022-0400
at Elasticsearch.Net.Utf8Json.Formatters.ISO8601DateTimeFormatter.Deserialize(JsonReader& reader, IJsonFormatterResolver formatterResolver)
Test Document:
{
"_index": "suricata-2020.07.23",
"_type": "_doc",
"_id": "DSpHfXMBvOItDiFCmKJQ",
"_version": 1,
"_seq_no": 3756084,
"_primary_term": 1,
"found": true,
"_source": {
"flow": {
"bytes_toserver": 60,
"bytes_toclient": 0,
"pkts_toclient": 0,
"start": "2020-07-23T16:04:33.400720-0400",
"pkts_toserver": 1
},
"@timestamp": "2020-07-23T20:04:34.363Z",
"input": {
"type": "log"
},
"tags": [
"suricata",
"beats_input_codec_plain_applied"
],
"stream": 0,
"@version": "1",
"timestamp": "2020-07-23T16:04:33.400720-0400",
"payload": "",
"ecs": {
"version": "1.5.0"
},
"event_type": "alert"
}
}
Metadata
Metadata
Assignees
Labels
No labels