Example usage for org.apache.commons.net.smtp SMTPSClient setTrustManager

List of usage examples for org.apache.commons.net.smtp SMTPSClient setTrustManager

Introduction

In this page you can find the example usage for org.apache.commons.net.smtp SMTPSClient setTrustManager.

Prototype

public void setTrustManager(TrustManager newTrustManager) 

Source Link

Document

Override the default TrustManager to use.

Usage

From source file:org.apache.james.protocols.smtp.AbstractSMTPSServerTest.java

@Override
protected SMTPClient createClient() {
    SMTPSClient client = new SMTPSClient(true, BogusSslContextFactory.getClientContext());
    client.setTrustManager(BogusTrustManagerFactory.getTrustManagers()[0]);
    return client;
}

From source file:org.apache.james.protocols.smtp.AbstractStartTlsSMTPServerTest.java

protected SMTPSClient createClient() {
    SMTPSClient client = new SMTPSClient(false, BogusSslContextFactory.getClientContext());
    client.setTrustManager(BogusTrustManagerFactory.getTrustManagers()[0]);
    return client;
}

From source file:org.apache.james.protocols.smtp.netty.NettyStartTlsSMTPServerTest.java

private SMTPSClient createClient() {
    SMTPSClient client = new SMTPSClient(false, BogusSslContextFactory.getClientContext());
    client.setTrustManager(BogusTrustManagerFactory.getTrustManagers()[0]);
    return client;
}