Questions on expressions
Hi, I have two questions, The first question, is there an expression available in Cribl to generate a random GUID? The second question, is there an expression that will generate a date in this format `Tue, 24 Nov 2023 12:50:11 UTC`
Answers
-
Nice work <@U027B0M9FL4>!!!
0 -
Can I paste this right into Cribl as a value? I am getting an error with the above expression
0 -
Oh I see. It needs to be a global variable
0 -
you can put it in a Code function (eval won't work)
0 -
what If I want to use it as a payload parameter in a collector?
0 -
that particular implementation wouldn't work
0 -
Is there a workaround?
0 -
depends on how strict/safe you want your GUID creation to be. Easy enough to fudge a GUID-like string using a hash of a datetime string for example
0 -
`C.Mask.sha1(Date.now())`
0 -
(trim, format as needed)
0 -
2nd ask `C.Time.strftime(Date.now()/1000,"%a, %d %b %Y %H:%M:%S UTC",true)`
0 -
Thanks for your help Jon!
0 -
I'm trying to set up collectors for mimecast it requires a lot of steps if I were to do it in Cribl. Would you suggest I just do this Something like Lambda and pull them in via S3?
0