summaryrefslogtreecommitdiffstats
path: root/jrt/src/com/yahoo/jrt/XorCryptoEngine.java
blob: 6912a58e39404842a3842018d81ab082d8ea77c2 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
// Copyright 2018 Yahoo Holdings. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
package com.yahoo.jrt;


import java.nio.channels.SocketChannel;


/**
 * Very simple crypto engine that requires connection handshaking and
 * data transformation. Used to test encryption integration separate
 * from TLS.
 **/
public class XorCryptoEngine implements CryptoEngine {
    @Override public CryptoSocket createCryptoSocket(TransportMetrics metrics, SocketChannel channel, boolean isServer) {
        return new XorCryptoSocket(channel, isServer);
    }
}