Overview | Package | Class | Tree | Deprecated | Index | Help
| JSS 3.3
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.mozilla.jss.crypto
Interface KeyGenerator.CharToByteConverter

All Known Implementing Classes:
  PasswordConverter

Enclosing interface:
  KeyGenerator

public static interface KeyGenerator.CharToByteConverter

An interface for converting a password of Java characters into an array of bytes. This conversion must be performed to provide a byte array to the low-level crypto engine. The default conversion is UTF8. Null-termination is not necessary, and indeed is usually incorrect, since the password is passed to the crypto engine as a byte array, not a C string.

Method Summary
`byte[]` | `convert(char[] chars)` Converts a password of Java characters into a password of bytes, using some encoding scheme.

Method Detail

### convert

    public byte[] convert(char[] chars)
                   throws java.io.CharConversionException

  Converts a password of Java characters into a password of bytes, using some encoding scheme. The input char array must not be modified.

    `java.io.CharConversionException`

Overview | Package | Class | Tree | Deprecated | Index | Help
| JSS 3.3
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD