javax.crypto.spec.SecretKeySpec.scala Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of scala-native-crypto_native0.5_2.12 Show documentation
Show all versions of scala-native-crypto_native0.5_2.12 Show documentation
Scala Native java.security implementation based on OpenSSL
The newest version!
package javax.crypto.spec
import java.security.spec.KeySpec
import javax.crypto.SecretKey
class SecretKeySpec(key: Array[Byte], algorithm: String)
extends KeySpec
with SecretKey {
if (key == null || algorithm == null) {
throw new IllegalArgumentException("Missing argument")
}
if (key.isEmpty) {
throw new IllegalArgumentException("Empty key")
}
def getAlgorithm(): String = algorithm
def getEncoded(): Array[Byte] = key
def getFormat(): String = ???
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy