Rsa

object Rsa

Properties

Link copied to clipboard
const val CLIENT_KEY_LENGTH: Int = 1008
Link copied to clipboard
const val JAR_KEY_LENGTH: Int = 2048
Link copied to clipboard
const val MAGIC: Int = 10

Functions

Link copied to clipboard
fun apply(ciphertext: BigInteger, key: RSAKeyParameters): BigInteger
Link copied to clipboard
fun generateKeyPair(length: Int): Pair<RSAKeyParameters, RSAPrivateCrtKeyParameters>
Link copied to clipboard
fun readPrivateKey(reader: Reader): RSAPrivateCrtKeyParameters
fun readPrivateKey(path: Path): RSAPrivateCrtKeyParameters
Link copied to clipboard
fun readPublicKey(reader: Reader): RSAKeyParameters
fun readPublicKey(path: Path): RSAKeyParameters
Link copied to clipboard
fun writePrivateKey(path: Path, key: RSAKeyParameters)
Link copied to clipboard
fun writePublicKey(path: Path, key: RSAKeyParameters)