@@ -74,15 +74,6 @@ functions:
74
74
2. Select Show internal fields
75
75
3. Select Render Whitespace
76
76
4. Internal fields are not passed to the Destination.
77
- - id : eval
78
- filter : " true"
79
- disabled : false
80
- conf :
81
- add :
82
- - name : __raw
83
- value : _raw
84
- description : Set internal __raw field (double underscore).
85
- groupId : 74Mz02
86
77
- id : mask
87
78
filter : " true"
88
79
disabled : false
@@ -93,7 +84,7 @@ functions:
93
84
- matchRegex : /({)([\S\s]+)([}{])gg/gm
94
85
replaceExpr : " `${g1}${g2.replace(/[\\ s\\ r\\ n]+/gm,' ')}${g3}`"
95
86
fields :
96
- - __raw
87
+ - _raw
97
88
groupId : 74Mz02
98
89
description : Event 4104 - Edge Case to handle early curly braces
99
90
- id : mask
@@ -106,7 +97,7 @@ functions:
106
97
- matchRegex : /\n\s+at\s/gm
107
98
replaceExpr : " ' at '"
108
99
fields :
109
- - __raw
100
+ - _raw
110
101
groupId : 74Mz02
111
102
description : Event 1309 - Stack Trace
112
103
- id : mask
@@ -117,7 +108,7 @@ functions:
117
108
- matchRegex : /^/
118
109
replaceExpr : " 'Timestamp='"
119
110
fields :
120
- - __raw
111
+ - _raw
121
112
description : Add Timestamp key name to make it uniform like the rest of the event. The
122
113
Timestamp field is removed (optional) at the end of the pipeline since
123
114
_time is already extracted.
@@ -130,7 +121,7 @@ functions:
130
121
- matchRegex : /^( +)/gm
131
122
replaceExpr : " ''"
132
123
fields :
133
- - __raw
124
+ - _raw
134
125
description : Remove any beginning spaces in the event. Not all events have them, but
135
126
in the test samples I reviewed, I did notice exceptions. Sometimes the
136
127
spaces re-appear.
@@ -143,7 +134,7 @@ functions:
143
134
- matchRegex : /$/
144
135
replaceExpr : " ' \\ r\\ n'"
145
136
fields :
146
- - __raw
137
+ - _raw
147
138
description : Add a \s\r\n to the end of the event to make parsing easier, "Sometimes
148
139
Regex is hard..."
149
140
groupId : 74Mz02
@@ -155,7 +146,7 @@ functions:
155
146
- matchRegex : /^Additional Data.*[\r\n]+/gm
156
147
replaceExpr : " ''"
157
148
fields :
158
- - __raw
149
+ - _raw
159
150
groupId : 74Mz02
160
151
description : Remove Additional Data line since it doesn't add any value
161
152
- id : comment
@@ -206,7 +197,7 @@ functions:
206
197
- matchRegex : /\n"/gm
207
198
replaceExpr : " ''"
208
199
fields :
209
- - __raw
200
+ - _raw
210
201
description : Edge Cases to collapse events to same line when key is on line 1 and value
211
202
is on line 2, etc. See Comment above
212
203
groupId : 74Mz02
@@ -219,7 +210,7 @@ functions:
219
210
- matchRegex : /^(.+?:)(\n)^(.+)/gm
220
211
replaceExpr : " `${g1}${g3}`"
221
212
fields :
222
- - __raw
213
+ - _raw
223
214
groupId : 74Mz02
224
215
description : Event 1644 - Edge Case to collapse remaining events to same line when key
225
216
is on line 1 and value is on line 2, etc.
@@ -236,7 +227,7 @@ functions:
236
227
- matchRegex : / +\r/gm
237
228
replaceExpr : " '\\ r'"
238
229
fields :
239
- - __raw
230
+ - _raw
240
231
description : Remove spaces at the end of each line.
241
232
groupId : 74Mz02
242
233
- id : mask
@@ -247,7 +238,7 @@ functions:
247
238
- matchRegex : /\r+/gm
248
239
replaceExpr : " ''"
249
240
fields :
250
- - __raw
241
+ - _raw
251
242
description : Remove Windows carriage returns characters displayed as␍which is the \r
252
243
groupId : 74Mz02
253
244
- id : mask
@@ -258,7 +249,7 @@ functions:
258
249
- matchRegex : /^\n/gm
259
250
replaceExpr : " ''"
260
251
fields :
261
- - __raw
252
+ - _raw
262
253
description : Remove empty lines. Sometimes these come back as you process events,
263
254
merge event liens and I might repeat this when necessary.
264
255
groupId : 74Mz02
@@ -274,7 +265,7 @@ functions:
274
265
- matchRegex : " /: /gm"
275
266
replaceExpr : " ':'"
276
267
fields :
277
- - __raw
268
+ - _raw
278
269
description : " Remove extra spaces and convert to single space and remove and spaces
279
270
before or after the keys : values since Windows event structure are so
280
271
unpredictable."
@@ -293,7 +284,7 @@ functions:
293
284
- matchRegex : /}\n/gm
294
285
replaceExpr : " '} '"
295
286
fields :
296
- - __raw
287
+ - _raw
297
288
description : Escape required characters that the JSON format requires.
298
289
groupId : 74Mz02
299
290
- id : mask
@@ -306,7 +297,7 @@ functions:
306
297
- matchRegex : /^((?:[\w()-]+ ?){1,4})(?=[:])([:])/gm
307
298
replaceExpr : " `${g1.replace(/[\\ s-]/gm,'_')}${g2}`"
308
299
fields :
309
- - __raw
300
+ - _raw
310
301
description : Remove spaces in any Message Keys and replace with underscore
311
302
groupId : 74Mz02
312
303
- id : mask
@@ -323,7 +314,7 @@ functions:
323
314
- matchRegex : /{\n/
324
315
replaceExpr : " '{'"
325
316
fields :
326
- - __raw
317
+ - _raw
327
318
description : Add Quote and Bracket to parent objects such as "Creator_Subject":{
328
319
groupId : KaPK3t
329
320
- id : mask
@@ -342,7 +333,7 @@ functions:
342
333
- matchRegex : /\t/gm
343
334
replaceExpr : " ''"
344
335
fields :
345
- - __raw
336
+ - _raw
346
337
description : Transform __raw into JSON, handling various event shapes and exceptions.
347
338
groupId : KaPK3t
348
339
- id : mask
@@ -363,7 +354,7 @@ functions:
363
354
- matchRegex : /$/
364
355
replaceExpr : " '\\ n}'"
365
356
fields :
366
- - __raw
357
+ - _raw
367
358
description : Transform __raw into JSON, handling various event shapes and exceptions.
368
359
groupId : KaPK3t
369
360
- id : mask
@@ -378,15 +369,15 @@ functions:
378
369
- matchRegex : /^([^"{}][^=]+)=(.+)/gm
379
370
replaceExpr : ' `"${g1}":"${g2}",`'
380
371
fields :
381
- - __raw
372
+ - _raw
382
373
description : Transform __raw into JSON, handling various event shapes and exceptions.
383
374
groupId : KaPK3t
384
375
- id : eval
385
376
filter : " true"
386
377
disabled : false
387
378
conf :
388
379
add :
389
- - value : __raw .match(/^([^"}{].*)/gm).join('\n')
380
+ - value : _raw .match(/^([^"}{].*)/gm).join('\n')
390
381
name : Message_Text
391
382
description : Extract freeform text from __raw to MessageText for safekeeping.
392
383
groupId : KaPK3t
@@ -402,7 +393,7 @@ functions:
402
393
- matchRegex : /"\n"/
403
394
replaceExpr : " '\" ,\\ n\" '"
404
395
fields :
405
- - __raw
396
+ - _raw
406
397
description : Remove freeform text from __raw because JSON requires a strict format.
407
398
groupId : KaPK3t
408
399
- id : serde
@@ -411,7 +402,7 @@ functions:
411
402
conf :
412
403
mode : extract
413
404
type : json
414
- srcField : __raw
405
+ srcField : _raw
415
406
description : Extract JSON to top level fields where you can manage fields quickly and
416
407
easily.
417
408
groupId : KaPK3t
@@ -429,6 +420,7 @@ functions:
429
420
- " !sourcetype"
430
421
- " !host"
431
422
- " *"
423
+ cleanFields : false
432
424
description : Push all top level fields and Serialize into _raw, exclude default Splunk
433
425
fields first, and include the remaining fields.
434
426
groupId : MHboFX
@@ -692,7 +684,14 @@ functions:
692
684
description : Keep Cribl fields and the default Splunk fields and remove all unnecessary
693
685
top level fields. Feel free to adjust for extracted meta fields.
694
686
groupId : OW2pX5
687
+ - id : serde
688
+ filter : " true"
689
+ disabled : true
690
+ conf :
691
+ mode : extract
692
+ type : json
693
+ srcField : _raw
695
694
- id : drop
696
695
filter : " ['4688','4689'].includes(_raw.EventCode)"
697
- disabled : null
696
+ disabled : true
698
697
conf : {}
0 commit comments