-
Notifications
You must be signed in to change notification settings - Fork 12
Home
- HasherInterface
- EncodeInterface
- HashArray
-
Array of hash bytes
- CryptoApi
-
Main class
- Md2
-
Md2 hasher
-
HasherInterface
- new HasherInterface(name, options)
-
.name :
string -
.message :
Array.<number> -
.length :
number -
.state :
Object -
.unitSize :
number -
.unitOrder :
number -
.blockSize :
number - .processBlock(block)
-
.finalize() ⇒
HashArray -
.getState() ⇒
Object -
.setState(state) ⇒
HasherInterface -
.update(message) ⇒
HasherInterface - .process()
| Param | Type |
|---|---|
| name | string |
| options | Object |
Hasher name
Kind: static property of HasherInterface
Message
Kind: static property of HasherInterface
Length of message
Kind: static property of HasherInterface
All algorithm variables that changed during process
Kind: static property of HasherInterface
Size of unit in bytes (4 = 32 bits)
Kind: static property of HasherInterface
Bytes order in unit 0 - normal 1 - reverse
Kind: static property of HasherInterface
Size of block in units
Kind: static property of HasherInterface
Process ready block
Kind: static method of HasherInterface
| Param | Type |
|---|---|
| block | Array.<number> |
HasherInterface.finalize() ⇒ HashArray
Process last block and return hash
Kind: static method of HasherInterface
Returns: HashArray - hash
Return current state
Kind: static method of HasherInterface
HasherInterface.setState(state) ⇒ HasherInterface
Set state
Kind: static method of HasherInterface
| Param | Type |
|---|---|
| state | Object |
HasherInterface.update(message) ⇒ HasherInterface
Update message
Kind: static method of HasherInterface
| Param | Type |
|---|---|
| message |
string | Array.<number>
|
Process ready blocks
Kind: static method of HasherInterface
Encode HashArray
| Param | Type |
|---|---|
| hash | Array.<number> |
Array of hash bytes
Kind: global class
Instanceof: Array
| Param | Type |
|---|---|
| hash | Array.<number> |
| Encodes | Encodes |
Stringify hash
Kind: static method of HashArray
Main class
Kind: global class
Access: public
Kind: static property of CryptoApi
Instanceof: HasherInterface
CryptoApi.hash(algo, message, options) ⇒ HashArray
Hash message with algo
Kind: static method of CryptoApi
Returns: HashArray - hash
Access: public
| Param | Type |
|---|---|
| algo | string |
| message | string |
| options | Object |
CryptoApi.hasher(algo, options) ⇒ HasherInterface
Get new Hasher object
Kind: static method of CryptoApi
Access: public
| Param | Type |
|---|---|
| algo | string |
| options | Object |
CryptoApi.hashArray(hash) ⇒ HashArray
Get new HashArray
Kind: static method of CryptoApi
Access: public
| Param | Type |
|---|---|
| hash | Array.<number> |
Md2 hasher
Kind: global class
Implements: HasherInterface
Kind: instance method of Md2
Kind: instance method of Md2