com.jcraft.jsch
Class KeyExchange

java.lang.Object
  extended by com.jcraft.jsch.KeyExchange
Direct Known Subclasses:
DHECN, DHG1, DHG14, DHGEX

public abstract class KeyExchange
extends Object


Field Summary
protected  int DSS
           
protected  int ECDSA
           
protected  byte[] H
           
protected  byte[] K
           
protected  byte[] K_S
           
protected  int RSA
           
protected  Session session
           
protected  HASH sha
           
static int STATE_END
           
 
Constructor Summary
KeyExchange()
           
 
Method Summary
 String getFingerPrint()
           
 String getKeyAlgorithName()
           
 String getKeyType()
           
abstract  int getState()
           
protected static String[] guess(byte[] I_S, byte[] I_C)
           
abstract  void init(Session session, byte[] V_S, byte[] V_C, byte[] I_S, byte[] I_C)
           
abstract  boolean next(Buffer buf)
           
protected  byte[] normalize(byte[] secret)
           
protected  boolean verify(String alg, byte[] K_S, int index, byte[] sig_of_H)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

STATE_END

public static final int STATE_END
See Also:
Constant Field Values

session

protected Session session

sha

protected HASH sha

K

protected byte[] K

H

protected byte[] H

K_S

protected byte[] K_S

RSA

protected final int RSA
See Also:
Constant Field Values

DSS

protected final int DSS
See Also:
Constant Field Values

ECDSA

protected final int ECDSA
See Also:
Constant Field Values
Constructor Detail

KeyExchange

public KeyExchange()
Method Detail

init

public abstract void init(Session session,
                          byte[] V_S,
                          byte[] V_C,
                          byte[] I_S,
                          byte[] I_C)
                   throws Exception
Throws:
Exception

next

public abstract boolean next(Buffer buf)
                      throws Exception
Throws:
Exception

getState

public abstract int getState()

getKeyType

public String getKeyType()

getKeyAlgorithName

public String getKeyAlgorithName()

guess

protected static String[] guess(byte[] I_S,
                                byte[] I_C)

getFingerPrint

public String getFingerPrint()

normalize

protected byte[] normalize(byte[] secret)

verify

protected boolean verify(String alg,
                         byte[] K_S,
                         int index,
                         byte[] sig_of_H)
                  throws Exception
Throws:
Exception


Copyright © 2015 JCraft,Inc.. All Rights Reserved.