tlsutils

package
v0.0.0-...-0c1943d Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 11, 2024 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Overview

Package tlsutils contains the utility functions related to tls communication of the adapter

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetKeyLocations

func GetKeyLocations() (string, string, string)

GetKeyLocations function returns the public key path and private key path

func GetServerCertificate

func GetServerCertificate(tlsCertificate string, tlsCertificateKey string) (tls.Certificate, error)

GetServerCertificate returns the certificate (used for the restAPI server and xds server) created based on configuration values. Move to pkg. remove config and read from a file path

func GetTrustedCertPool

func GetTrustedCertPool(truststoreLocation string) *x509.CertPool

GetTrustedCertPool returns the trusted certificate (used for the restAPI server and xds server) created based on the provided directory/file path. Move to pkg

func InvokeControlPlane

func InvokeControlPlane(req *http.Request, skipSSL bool) (*http.Response, error)

InvokeControlPlane sends request to the control plane and returns the response

func IsPublicCertificate

func IsPublicCertificate(certContent []byte) bool

IsPublicCertificate checks if the file content represents valid public certificate in PEM format. Move to pkg

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL