I tried this ,but nothing happens
% public void encrypt(byte[] in,
% int i,
% byte[] out,
% int j,
% java.lang.Object k,
% int bs)
%
%
%
% Encrypts exactly one block of plaintext.
%
% Parameters:
% in - the plaintext.
% i - index of in from which to start considering data.
% out - the ciphertext.
% j - index of out from which to store the result.
% k - the session key to use.
% bs - the block size to use.
%
%
%
% %public java.lang.Object makeKey(byte[] uk,
% int bs)
% throws java.security.InvalidKeyException
clear all
clc
J1=javaObject('gnu.crypto.cipher.Anubis')
in =uint8([zeros(1,16)]) ;
out =uint8([zeros(1,16)]) ;
bs=16;
uk=logical([zeros(1,15),1]);
k=J1.makeKey(uk,bs);
J1.encrypt(in,0,out,0,k,16)
class Anubis
Constructor Summary
Anubis()
Trivial 0-arguments constructor.
Method Summary
java.util.Iterator blockSizes()
Returns an Iterator over the supported block sizes.
java.lang.Object clone()
Returns a clone of this instance.
void decrypt(byte[] in, int i, byte[] out, int j, java.lang.Object k, int bs)
Decrypts exactly one block of ciphertext.
void encrypt(byte[] in, int i, byte[] out, int j, java.lang.Object k, int bs)
Encrypts exactly one block of plaintext.
java.util.Iterator keySizes()
Returns an Iterator over the supported key sizes.
java.lang.Object makeKey(byte[] uk, int bs)
Expands a user-supplied key material into a session key for a designated block size.
boolean selfTest()
A correctness test that consists of basic symmetric encryption / decryption test(s) for all supported block and key sizes, as well as one (1) variable key Known Answer Test (KAT).