diff --git a/src/main/resources/mappers/WhiteListMapper.xml b/src/main/resources/mappers/WhiteListMapper.xml index 2e62eda..557e773 100644 --- a/src/main/resources/mappers/WhiteListMapper.xml +++ b/src/main/resources/mappers/WhiteListMapper.xml @@ -424,9 +424,9 @@ from t_white_list - + false - (white_list_ip = INET_ATON(#{command.fiveTupleWithMask.sourceIP}) + or (white_list_ip = INET_ATON(#{command.fiveTupleWithMask.sourceIP}) and white_list_port = CAST(#{command.fiveTupleWithMask.sourcePort} AS UNSIGNED) @@ -436,7 +436,7 @@ ) - (( white_list_ip & INET_ATON(#{command.fiveTupleWithMask.maskSourceIP})) = + or (( white_list_ip & INET_ATON(#{command.fiveTupleWithMask.maskSourceIP})) = (INET_ATON(#{command.fiveTupleWithMask.sourceIP}) & INET_ATON(#{command.fiveTupleWithMask.maskSourceIP})) and white_list_port = CAST(#{command.fiveTupleWithMask.sourcePort} AS UNSIGNED) @@ -479,9 +479,11 @@ select *, INET_NTOA(white_list_ip) as white_list_ip_d from t_white_list + + false - (white_list_ip = INET_ATON(#{staticRule.staticRuleSip}) + or(white_list_ip = INET_ATON(#{staticRule.staticRuleSip}) and white_list_port = #{staticRule.staticRuleSport} @@ -491,7 +493,7 @@ ) - (( white_list_ip & INET_ATON(#{staticRule.staticRuleSip})) = + or(( white_list_ip & INET_ATON(#{staticRule.staticRuleSip})) = (INET_ATON(#{staticRule.staticRuleSip}) & INET_ATON(#{staticRule.staticRuleMsip})) and white_list_port = #{staticRule.staticRuleSport}