mTLS Authentication

Table of contents

  1. Description
  2. Constructor properties
  3. Methods
  4. @Example

Description

CertificateAuthentication is a class in the context of Alert Notification service node client. It is used to trigger the mTLS based authentication, you just need to provide the certificate and private key generated from your Alert Notification service instance (e.g. from a Service Key or Service Binding). For further information go to Credential Management and select Mutual TLS Authentication option.

Constructor properties

Field Type Description
certificate string x509 certificate chain generated by Alert Notification service
privateKey string Private key related to the generated certificate

Methods

Name Returns Description
getCertificate() string Get the certificate.
getPrivateKey() string Get the privateKey.

@Example

import { CertificateAuthentication } from '@sap_oss/alert-notification-client';

const certificateAuthentication = new CertificateAuthentication({
    certificate: 'test-certificate',
    privateKey: 'test-privateKey',
});

console.log(certificateAuthentication.getCertificate());
console.log(certificateAuthentication.getPrivateKey());