blob: 83a39795566c3fc9c2f059c3b6a23c124e9b7203 [file] [log] [blame]
package org.eclipse.team.internal.ccvs.ssh;
/*
* (c) Copyright IBM Corp. 2000, 2001.
* All Rights Reserved.
*/
public abstract class Cipher {
public abstract void decipher(byte[] src, int srcPos, byte[] dst, int dstPos, int len);
public abstract void encipher(byte[] src, int srcPos, byte[] dst, int dstPos, int len);
public static Cipher getInstance(String algorithm) {
try {
Class c = Class.forName("org.eclipse.team.internal.ccvs.ssh." + algorithm);
return (Cipher) c.newInstance();
} catch (Exception e) {
return null;
}
}
public abstract void setKey(byte[] key);
}