public interface CombineAlgorithm
Algorithm that is able to combine two inputs into one and vice versa split one input back to two.
These functions are reversible, so splitting combined text must result in original text again.
In formula: split(combine([input1, input])) == [input1, input2].
These algorithms are used for combining an input text and salt before it is processed by hashing algorithm. Also it is used for combining initialization vector and cipher text during encryption so IV is part of final output or splitting back during decryption.
ConcatCombineAlgorithm| Modifier and Type | Method and Description |
|---|---|
byte[] |
combine(byte[] input1,
byte[] input2)
Combines together two byte arrays.
|
byte[][] |
split(byte[] combined)
Splits input (that was combined earlier) back to original.
|
byte[] combine(byte[] input1,
byte[] input2)
input1 - first input to be combinedinput2 - second input to be combinedbyte[][] split(byte[] combined)
combined - previously combined inputCopyright © 2014. All rights reserved.