Appendix-A

ONES TLS Certificate

This has been added to the architecture to work using the TLS certificates for authentication. The mode of communication in the ONES architecture is as follows

TLS authentication have been added to data collection points from the agent. This means that gateway and collector connection pipes with agent will be authenticated using the TLS certificates. This page explains the methods to generate the certificates. For our lab testing, self signed certificates will be used. To run this script openssl needs to be installed.

Generating TLS Certificates

The following script will generate the necessary certificates.

  1. Generate CA's private key and self-signed certificate

chevron-rightLogshashtag
  1. Generate web server's private key and certificate signing request (CSR)

  1. Use CA's private key to sign web server's CSR and get back the signed certificate

chevron-rightLogshashtag
  1. Generate client's private key and certificate signing request (CSR)

  1. Use CA's private key to sign client's CSR and get back the signed certificate

chevron-rightLogshashtag

Most of the commands are self-explanatory. It will be noted that it uses two files for generating the certificates for server and client. First server-ext.cnf is explained here

circle-info

The main feature to note is the alt_names. For the ONES architecture, the collector follows one to many communication model. This alt_names need to be populated with the set of agents it needs to communicate. The agents act as server in the model. So when there are n number of agents, all these IP Addresses needs to be populated here to avoid certificates not getting validated correctly

client-ext.cnf

This will generate the output files out of which, the following are useful across agent and collector

  1. client-cert.pem

  2. client-key.pem

  3. ca-cert.pem

  4. server-cert.pem

  5. server-key.pem

circle-info

server-key.pem, server-cert.pem & ca-cert.pem needs to be placed at agent. Similarly client-cert.pem, client-key.pem & ca-cert.pem needs to be used in client side. For example, we can use gnmic with these certificates to validate the same

GNMIC with Certificates

It can also be verified that without certificates, the access does not work

Verifying Certificates

It would be desired to simulate failures and validate. For that we can verify locally if certificates are valid or not. For the same, use the following command

Installation Logs

Agent with TLS Mode

To verify agent is running in Tls mode, the following command should be used in the switch