From d41ccb8cd431430741f1fb143e039fe996b354d1 Mon Sep 17 00:00:00 2001 From: Terry Quigley <77437788+terryquigleysas@users.noreply.github.com> Date: Mon, 22 Jan 2024 22:00:17 +0000 Subject: [PATCH] Fix field masking examples (#6193) Updating field masking examples that were out of date and incorrect. Signed-off-by: Terry Quigley <77437788+terryquigleysas@users.noreply.github.com> --- _security/access-control/field-masking.md | 50 +++++++++++------------ 1 file changed, 25 insertions(+), 25 deletions(-) diff --git a/_security/access-control/field-masking.md b/_security/access-control/field-masking.md index 0fc42138..c672e75d 100644 --- a/_security/access-control/field-masking.md +++ b/_security/access-control/field-masking.md @@ -58,14 +58,14 @@ You configure field masking using OpenSearch Dashboards, `roles.yml`, or the RES ```yml someonerole: - cluster: [] - indices: - movies: - _masked_fields_: - - "title" - - "genres" - '*': - - "READ" + index_permissions: + - index_patterns: + - 'movies' + allowed_actions: + - read + masked_fields: + - "title" + - "genres" ``` @@ -82,14 +82,14 @@ To specify a different algorithm, add it after the masked field: ```yml someonerole: - cluster: [] - indices: - movies: - _masked_fields_: - - "title::SHA-512" - - "genres" - '*': - - "READ" + index_permissions: + - index_patterns: + - 'movies' + allowed_actions: + - read + masked_fields: + - "title::SHA-512" + - "genres" ``` @@ -103,19 +103,19 @@ hr_employee: - index_patterns: - 'humanresources' allowed_actions: - - ... + - read masked_fields: - 'lastname::/.*/::*' - '*ip_source::/[0-9]{1,3}$/::XXX::/^[0-9]{1,3}/::***' someonerole: - cluster: [] - indices: - movies: - _masked_fields_: - - "title::/./::*" - - "genres::/^[a-zA-Z]{1,3}/::XXX::/[a-zA-Z]{1,3}$/::YYY" - '*': - - "READ" + index_permissions: + - index_patterns: + - 'movies' + allowed_actions: + - read + masked_fields: + - "title::/./::*" + - "genres::/^[a-zA-Z]{1,3}/::XXX::/[a-zA-Z]{1,3}$/::YYY" ```