Package net.lingala.zip4j.crypto.PBKDF2
Class PBKDF2Engine
- java.lang.Object
-
- net.lingala.zip4j.crypto.PBKDF2.PBKDF2Engine
-
public class PBKDF2Engine extends Object
-
-
Field Summary
Fields Modifier and Type Field Description protected PBKDF2Parameters
parameters
protected net.lingala.zip4j.crypto.PBKDF2.PRF
prf
-
Constructor Summary
Constructors Constructor Description PBKDF2Engine()
PBKDF2Engine(PBKDF2Parameters parameters)
PBKDF2Engine(PBKDF2Parameters parameters, net.lingala.zip4j.crypto.PBKDF2.PRF prf)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
_F(byte[] dest, int offset, net.lingala.zip4j.crypto.PBKDF2.PRF prf, byte[] S, int c, int blockIndex)
protected void
assertPRF(byte[] P)
protected int
ceil(int a, int b)
byte[]
deriveKey(char[] inputPassword)
byte[]
deriveKey(char[] inputPassword, int dkLen)
PBKDF2Parameters
getParameters()
net.lingala.zip4j.crypto.PBKDF2.PRF
getPseudoRandomFunction()
protected void
INT(byte[] dest, int offset, int i)
protected byte[]
PBKDF2(net.lingala.zip4j.crypto.PBKDF2.PRF prf, byte[] S, int c, int dkLen)
void
setParameters(PBKDF2Parameters parameters)
void
setPseudoRandomFunction(net.lingala.zip4j.crypto.PBKDF2.PRF prf)
boolean
verifyKey(char[] inputPassword)
protected void
xor(byte[] dest, byte[] src)
-
-
-
Field Detail
-
parameters
protected PBKDF2Parameters parameters
-
prf
protected net.lingala.zip4j.crypto.PBKDF2.PRF prf
-
-
Constructor Detail
-
PBKDF2Engine
public PBKDF2Engine()
-
PBKDF2Engine
public PBKDF2Engine(PBKDF2Parameters parameters)
-
PBKDF2Engine
public PBKDF2Engine(PBKDF2Parameters parameters, net.lingala.zip4j.crypto.PBKDF2.PRF prf)
-
-
Method Detail
-
deriveKey
public byte[] deriveKey(char[] inputPassword)
-
deriveKey
public byte[] deriveKey(char[] inputPassword, int dkLen)
-
verifyKey
public boolean verifyKey(char[] inputPassword)
-
assertPRF
protected void assertPRF(byte[] P)
-
getPseudoRandomFunction
public net.lingala.zip4j.crypto.PBKDF2.PRF getPseudoRandomFunction()
-
PBKDF2
protected byte[] PBKDF2(net.lingala.zip4j.crypto.PBKDF2.PRF prf, byte[] S, int c, int dkLen)
-
ceil
protected int ceil(int a, int b)
-
_F
protected void _F(byte[] dest, int offset, net.lingala.zip4j.crypto.PBKDF2.PRF prf, byte[] S, int c, int blockIndex)
-
xor
protected void xor(byte[] dest, byte[] src)
-
INT
protected void INT(byte[] dest, int offset, int i)
-
getParameters
public PBKDF2Parameters getParameters()
-
setParameters
public void setParameters(PBKDF2Parameters parameters)
-
setPseudoRandomFunction
public void setPseudoRandomFunction(net.lingala.zip4j.crypto.PBKDF2.PRF prf)
-
-