Hi all, I just completed the Level 3 Prerequisite exam but I have a question.
One of the questions was as follows:
What would be the result of the Mask function with the following settings Match Regex =`(user_id=) (d+)" Replace Expression = C. Mask. random( ${g2}') on the event host=server. local user_id=12345?
A)host=server. local aeQI9
B) host=server. local user_id=fe8780bd8237b0388df7175034db75d6
C) host=server. local user_id=aeQI9
D) The event would remain unchanged because the Match Regex is invalid.
I chose option D. But apparently this was the wrong answer. But I think it shouldn't be… Here is why.
The event host=server.local user_id=12345….
(user_id=) (d+) matches “user_ID=”
(d+) is incorrect, d is just a literal d and not a digit in this case, it should have been \d+. There is also a space in the regex, but the event itself does not have a space. “user_id=12345”
This is why the event would remain unchanged because the match regex is invalid.
If I am wrong, please explain to me where I am mistaken. Thank you!
Hi all, I just completed the Level 3 Prerequisite exam but I have a question.
One of the questions was as follows:
What would be the result of the Mask function with the following settings Match Regex =`(user_id=) (d+)" Replace Expression = C. Mask. random( ${g2}') on the event host=server. local user_id=12345?
A)host=server. local aeQI9
B) host=server. local user_id=fe8780bd8237b0388df7175034db75d6
C) host=server. local user_id=aeQI9
D) The event would remain unchanged because the Match Regex is invalid.
I chose option D. But apparently this was the wrong answer. But I think it shouldn't be… Here is why.
The event host=server.local user_id=12345….
(user_id=) (d+) matches “user_ID=”
(d+) is incorrect, d is just a literal d and not a digit in this case, it should have been \d+. There is also a space in the regex, but the event itself does not have a space. “user_id=12345”
This is why the event would remain unchanged because the match regex is invalid.
If I am wrong, please explain to me where I am mistaken. Thank you!
You are right. There is a \ missing before the d+. Otherwise the answer should be A.
I’ve some doubt about the replace expression too, because I think that, in the way to paste it, it return always undefined. But we can discuss about that. But you are right about that part. Try to report this issue on Slack, they will fix it for sure.
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.
