def METHOD_NAME(cls, term, value):
    if utils.is_string(term) and utils.is_string(value):
        if CidrMatch.ip_compiled.match(term) and CidrMatch.cidr_compiled.match(value):
            # check for an ipv4 cidr
            if value not in cls.__cidr_cache:
                cls.__cidr_cache[value] = CidrMatch.get_callback(None, eql.ast.String(value))
            return cls.__cidr_cache[value](term)
    return term == value