|
Spec-Zone .ru
спецификации, руководства, описания, API
|
public class RC5ParameterSpec extends Object implements AlgorithmParameterSpec
Параметры состоят из номера версии, количества раундов, размера слова, и дополнительно вектора инициализации (IV) (только в режиме обратной связи).
Этот class может использоваться, чтобы инициализировать a Cipher возразите, что реализует алгоритм RC5 как предоставлено , или любыми сторонами, авторизованными Безопасностью RSA.
| Конструктор и Описание |
|---|
RC5ParameterSpec(int version, int rounds, int wordSize)
Создает набор параметра для RC5 от данной версии, числа раундов и размера слова (в битах).
|
RC5ParameterSpec(int version, int rounds, int wordSize, byte[] iv)
Создает набор параметра для RC5 от данной версии, числа раундов, размер слова (в битах), и IV.
|
RC5ParameterSpec(int version, int rounds, int wordSize, byte[] iv, int offset)
Создает набор параметра для RC5 от данной версии, числа раундов, размер слова (в битах), и IV.
|
| Модификатор и Тип | Метод и Описание |
|---|---|
boolean |
equals(Object obj)
Тесты для равенства между указанным объектом и этим объектом.
|
byte[] |
getIV()
Возвращает IV или нуль, если этот набор параметра не содержит IV.
|
int |
getRounds()
Возвращает число раундов.
|
int |
getVersion()
Возвращает версию.
|
int |
getWordSize()
Возвращает размер слова в битах.
|
int |
hashCode()
Вычисляет значение хэш-кода для объекта.
|
public RC5ParameterSpec(int version,
int rounds,
int wordSize)
version - версия.rounds - число раундов.wordSize - размер слова в битах.public RC5ParameterSpec(int version,
int rounds,
int wordSize,
byte[] iv)
Отметьте, что размер IV (размер блока) должен быть дважды размером слова. Байты, которые составляют IV, являются теми между iv[0] и iv[2*(wordSize/8)-1] включительно.
version - версия.rounds - число раундов.wordSize - размер слова в битах.iv - буфер с IV. Первое 2*(wordSize/8) байты буфера копируются, чтобы защитить от последующей модификации.IllegalArgumentException - если iv null или (iv.length < 2 * (wordSize / 8))public RC5ParameterSpec(int version,
int rounds,
int wordSize,
byte[] iv,
int offset)
The IV is taken from iv, starting at offset inclusive. Note that the size of the IV (block size), starting at offset inclusive, must be twice the word size. The bytes that constitute the IV are those between iv[offset] and iv[offset+2*(wordSize/8)-1] inclusive.
version - the version.rounds - the number of rounds.wordSize - the word size in bits.iv - the buffer with the IV. The first 2*(wordSize/8) bytes of the buffer beginning at offset inclusive are copied to protect against subsequent modification.offset - the offset in iv where the IV starts.IllegalArgumentException - if iv is null or (iv.length - offset < 2 * (wordSize / 8))public int getVersion()
public int getRounds()
public int getWordSize()
public byte[] getIV()
public boolean equals(Object obj)
equals in class Objectobj - the object to test for equality with this object.obj is null or otherwise.Object.hashCode(), HashMappublic int hashCode()
hashCode in class ObjectObject.equals(java.lang.Object), System.identityHashCode(java.lang.Object)
For further API reference and developer documentation, see Java SE Documentation. That documentation contains more detailed, developer-targeted descriptions, with conceptual overviews, definitions of terms, workarounds, and working code examples.
Copyright © 1993, 2013, Oracle and/or its affiliates. All rights reserved.
DRAFT ea-b92