toggle menu
openrs2
jvm
switch theme
search in API
openrs2
/
org.openrs2.crypto
/
Rsa
Rsa
object
Rsa
Members
Properties
CLIENT_KEY_LENGTH
Link copied to clipboard
const
val
CLIENT_KEY_LENGTH
:
Int
=
1008
JAR_KEY_LENGTH
Link copied to clipboard
const
val
JAR_KEY_LENGTH
:
Int
=
2048
MAGIC
Link copied to clipboard
const
val
MAGIC
:
Int
=
10
Functions
apply
Link copied to clipboard
fun
apply
(
ciphertext
:
BigInteger
,
key
:
RSAKeyParameters
)
:
BigInteger
generate
Key
Pair
Link copied to clipboard
fun
generateKeyPair
(
length
:
Int
)
:
Pair
<
RSAKeyParameters
,
RSAPrivateCrtKeyParameters
>
read
Private
Key
Link copied to clipboard
fun
readPrivateKey
(
reader
:
Reader
)
:
RSAPrivateCrtKeyParameters
fun
readPrivateKey
(
path
:
Path
)
:
RSAPrivateCrtKeyParameters
read
Public
Key
Link copied to clipboard
fun
readPublicKey
(
reader
:
Reader
)
:
RSAKeyParameters
fun
readPublicKey
(
path
:
Path
)
:
RSAKeyParameters
write
Private
Key
Link copied to clipboard
fun
writePrivateKey
(
path
:
Path
,
key
:
RSAKeyParameters
)
write
Public
Key
Link copied to clipboard
fun
writePublicKey
(
path
:
Path
,
key
:
RSAKeyParameters
)