From c9e2e562b2dbedaa554b51a78ef81ba48151b76a Mon Sep 17 00:00:00 2001 From: axzsd Date: Sat, 11 Mar 2023 23:16:40 +0800 Subject: [PATCH] first --- .../desensitize/executor/JsonPathDesensitizeExecutor.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/java/org/applesline/desensitize/executor/JsonPathDesensitizeExecutor.java b/src/main/java/org/applesline/desensitize/executor/JsonPathDesensitizeExecutor.java index 3b7cd7c..0f9262f 100644 --- a/src/main/java/org/applesline/desensitize/executor/JsonPathDesensitizeExecutor.java +++ b/src/main/java/org/applesline/desensitize/executor/JsonPathDesensitizeExecutor.java @@ -29,7 +29,7 @@ public class JsonPathDesensitizeExecutor extends DesensitizeExecutorAdapter { return gson.fromJson(jsonTree.toString(),obj.getClass()); } - private void maskSensitiveWords(JsonElement originElement,Collection ignoreMaskWords) { + protected void maskSensitiveWords(JsonElement originElement,Collection ignoreMaskWords) { Set needMaskWords = maskWordsMap.keySet(); if (originElement.isJsonArray()) { JsonArray jsonArray = originElement.getAsJsonArray(); @@ -57,7 +57,7 @@ public class JsonPathDesensitizeExecutor extends DesensitizeExecutorAdapter { } } - private Collection matchIgnoreFields(Object obj) { + protected Collection matchIgnoreFields(Object obj) { Collection ignoreMaskFields = new HashSet<>(); for (String ignoreJpe : ignoreJsonPathExpression) { Object field = JsonPath.read(gson.toJsonTree(obj).toString(),ignoreJpe);