maxscale mask half data fill

34 views
Skip to first unread message

Ivan

unread,
Nov 13, 2023, 10:23:01 AM11/13/23
to MaxScale
Hi! how to mask half data fill? 
For example :   fill test = 13123123sd123
Need result masking :  test = 1312312****** 

or
For example :   fill test = te...@example.com
Need result masking :  test = ****@example.com  



Ivan

unread,
Jan 17, 2024, 5:04:41 AM1/17/24
to MaxScale
Markus please help

понедельник, 13 ноября 2023 г. в 18:23:01 UTC+3, Ivan:

Markus Mäkelä

unread,
Jan 17, 2024, 6:42:58 AM1/17/24
to maxs...@googlegroups.com

Hi,

Looking at the documentation, you should be able to do it with the "match" and "fill" rules:

The optional key match makes partial replacement of the original value possible: only the matched part would be replaced with the fill character. The match value must be a valid pcre2 regular expression.

The tricky part is probably getting the regular expression correct. I'd recommend playing around with something like regex101.com and see what each pattern matches.

Markus

--
You received this message because you are subscribed to the Google Groups "MaxScale" group.
To unsubscribe from this group and stop receiving emails from it, send an email to maxscale+u...@googlegroups.com.
To view this discussion on the web, visit https://groups.google.com/d/msgid/maxscale/02f4419f-745b-4c5b-9f85-ee57ad96f23fn%40googlegroups.com.
-- 
Markus Mäkelä, Senior Software Engineer
MariaDB Corporation
Reply all
Reply to author
Forward
0 new messages