FirebirdSQL logo

RSA_PUBLIC()

Generates an RSA public key

Result type

VARBINARY

Syntax
RSA_PUBLIC (private_key)
Table 1. RSA_PUBLIC Function Parameters
Parameter Description

private_key

RSA private key in PKCS#1 format

RSA_PUBLIC returns the RSA public key in PKCS#1 format for the provided RSA private key (also PKCS#1 format).

RSA_PUBLIC Examples

Tip

Run the example of the RSA_PRIVATE function first.

select rdb$set_context('USER_SESSION', 'public_key',
  rsa_public(rdb$get_context('USER_SESSION', 'private_key'))) from rdb$database;