Hello, my source data has the following dates, which i am struggling to create the correct field mapping.
"notBefore": "Jun 9 00:31:02 2020 GMT", "notAfter": "Jun 9 00:31:02 2025 GMT"
i have tried various combinations, but basically looking like this, and i just can't get it right.
"notBefore": {
"type": "date",
"format": "MMM dd hh:mm:ss yyyy ZZZ",
"fields": {
"keyword": {
"type": "keyword",
"ignore_above": 256
}
}
}
The errors are obvious
{"index":{"_index":"sslscan-2020","_type":"_doc","_id":"UHlkLHMBb4m0aeo6mAc9","status":400,"error":{"type":"mapper_parsing_exception","reason":"failed to parse field [certificateChain.notBefore] of type [date] in document with id 'UHlkLHMBb4m0aeo6mAc9'. Preview of field's value: 'Dec 8 00:00:00 2018 GMT'","caused_by":{"type":"illegal_argument_exception","reason":"failed to parse date field [Dec 8 00:00:00 2018 GMT] with format [strict_date_optional_time||epoch_millis]","caused_by":{"type":"date_time_parse_exception","reason":"Failed to parse with all enclosed parsers"}}}}}