implement optimizations

This commit is contained in:
2026-01-15 22:06:28 +01:00
parent ab036f4f9f
commit d40df04e2e
26 changed files with 463 additions and 855 deletions

View File

@@ -11,15 +11,6 @@ Supported algorithms:
- Blake (Blake-224, Blake-256, Blake-384, Blake-512)
- Blake2 (Blake2s, Blake2b)
## Targets
| Target | Status |
|------------------|---------------|
| JVM | Supported |
| JavaScript | Supported |
| Native (Linux) | Supported |
| Native (Windows) | Not Supported |
## Installation
Add the following to your `build.gradle.kts`.
@@ -30,19 +21,16 @@ repositories {
}
dependencies {
implementation("com.infendro:hash:1.3.2")
implementation("com.infendro:hash:1.5.0")
}
```
## Usage
```kotlin
import com.infendro.hash.sha2.`SHA-256`
fun main() {
// hash some value using SHA-256
val value = "Hello World!"
.encodeToByteArray().asUByteArray()
val value = "Hello World!".encodeToByteArray()
val hash = `SHA-256`.hash(value)
}
```