org.mozilla.jss.pkix.primitive

Class PBEParameter

public class PBEParameter extends Object implements ASN1Value

PKCS #5 PBEParameter, and PKCS #12 pkcs-12PbeParams. The only difference between the two is that PKCS #5 dictates that the size of the salt must be 8 bytes, while PKCS #12 leaves the salt length undefined. To work with both standards, this class does not check the length of the salt but rather leaves that to the application.
Nested Class Summary
static classPBEParameter.Template
A template class for decoding a PBEParameter.
Constructor Summary
PBEParameter(byte[] salt, int iterations)
Creates a PBEParameter from a salt and iteration count.
PBEParameter(OCTET_STRING salt, INTEGER iterations)
Creates a PBEParameter from a salt and iteration count.
Method Summary
voidencode(OutputStream ostream)
voidencode(Tag implicitTag, OutputStream ostream)
intgetIterations()
byte[]getSalt()
TaggetTag()
static PBEParameter.TemplategetTemplate()

Constructor Detail

PBEParameter

public PBEParameter(byte[] salt, int iterations)
Creates a PBEParameter from a salt and iteration count. Neither may be null.

PBEParameter

public PBEParameter(OCTET_STRING salt, INTEGER iterations)
Creates a PBEParameter from a salt and iteration count. Neither may be null.

Method Detail

encode

public void encode(OutputStream ostream)

encode

public void encode(Tag implicitTag, OutputStream ostream)

getIterations

public int getIterations()

getSalt

public byte[] getSalt()

getTag

public Tag getTag()

getTemplate

public static PBEParameter.Template getTemplate()