@Override
    public boolean isTrusted(Address address) {
        if (address == null) {
            return false;
        }
        if (trustedInterfaces.isEmpty()) {
            return true;
        }

        String host = address.getHost();
        if (matchAnyInterface(host, trustedInterfaces)) {
            return true;
        } else {
            if (logger.isFineEnabled()) {
                logger.fine(
                        "Address %s doesn't match any trusted interface", host);
            }
            return false;
        }
    }
@Test
    public void givenInterfaceRangeIsConfigured_whenMessageWithMatchingHost_thenTrust() throws UnknownHostException {
        AddressCheckerImpl joinMessageTrustChecker = new AddressCheckerImpl(singleton("127.0.0.1-100"), logger);
        Address address = createAddress("127.0.0.2");
        assertTrue(joinMessageTrustChecker.isTrusted(address));
    }