Skip to main content

Class: EncryptionService

api-oauth/encryption.service.EncryptionService

Service to encrypt and decrypt data using the LOGIN_SPECIFIC key pair

Constructors

constructor

new EncryptionService()

Properties

privateKey

Private Readonly privateKey: KeyObject

Defined in

gropius-login-service/backend/src/api-oauth/encryption.service.ts:9


publicKey

Private Readonly publicKey: KeyObject

Defined in

gropius-login-service/backend/src/api-oauth/encryption.service.ts:11

Methods

decrypt

decrypt(data): string

Decrypts the given data using the LOGIN_SPECIFIC private key

Parameters

NameTypeDescription
datastringThe data to decrypt

Returns

string

The decrypted data

Defined in

gropius-login-service/backend/src/api-oauth/encryption.service.ts:29


encrypt

encrypt(data): string

Encrypts the given data using the LOGIN_SPECIFIC public key

Parameters

NameTypeDescription
datastringThe data to encrypt

Returns

string

The encrypted data

Defined in

gropius-login-service/backend/src/api-oauth/encryption.service.ts:19