org.apache.sshd.common.mac
Class BaseMac

java.lang.Object
  extended by org.apache.sshd.common.mac.BaseMac
All Implemented Interfaces:
Mac
Direct Known Subclasses:
HMACMD5, HMACMD596, HMACSHA1, HMACSHA196

public class BaseMac
extends Object
implements Mac

Base class for Mac implementations based on the JCE provider.

Author:
Apache MINA SSHD Project

Constructor Summary
BaseMac(String algorithm, int bsize, int defbsize)
           
 
Method Summary
 void doFinal(byte[] buf, int offset)
           
 int getBlockSize()
           
 void init(byte[] key)
           
 void update(byte[] foo, int s, int l)
           
 void updateUInt(long i)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BaseMac

public BaseMac(String algorithm,
               int bsize,
               int defbsize)
Method Detail

getBlockSize

public int getBlockSize()
Specified by:
getBlockSize in interface Mac

init

public void init(byte[] key)
          throws Exception
Specified by:
init in interface Mac
Throws:
Exception

updateUInt

public void updateUInt(long i)
Specified by:
updateUInt in interface Mac

update

public void update(byte[] foo,
                   int s,
                   int l)
Specified by:
update in interface Mac

doFinal

public void doFinal(byte[] buf,
                    int offset)
             throws Exception
Specified by:
doFinal in interface Mac
Throws:
Exception


Copyright © 2008-2012 Apache Software Foundation. All Rights Reserved.