Skip to main content

Self Signed Certificates Vs Signed Certificates (CA Certificates)

Certificates

Certificates basically two categories.
Self Signed Certificates  - will create by self
CA Certificates  - will be  provided by Third party vendor with robust algorithms

Depends on the location of installing the certificate these are two types
1. Public Key Certificates (Client Side)
2. Private Key Certificates (Server Side)

Self Signed Certificates

 
If any one is using self signed certificates in their applications
they have to make sure both server side and client side certificates are in sync.
Other wise we should be ready to face SSLHandShake Exceptions. These will be preferable mostly for lower environments not for production.

CA certificates 


If you install CA certificates on server side, client side certificates are installed automatically whenever they access the server. So in production for CA certificates there is no need to install the client side certificates.

We can generate a Self Signed Certificate using Java Key tool
JAVA_HOME/bin/keytool.exe








Comments

  1. I think openssl also will be useful for generating the certificates. SSL certificates is one of the painful things to configure in dev environment. Need more details..

    ReplyDelete

Post a Comment

Popular posts from this blog

Spring Reactive Stack

Compress a String

package com.sbs.java8.praticse; public class StringCompression { public StringCompression() { // TODO Auto-generated constructor stub } public static void main(String[] args) { System.out.println(compressString("aaaabbbbbccccAAAAccccccccdefg")); } public static String compressString(String str) { //String str = "aaaabbbbbcccc"; char[] charArray = str.toCharArray(); String compressedString = ""; int i = 0; while (i < charArray.length) { int counter = 1; int j = i + 1; while (j < charArray.length && charArray[i] == charArray[j]) { counter++; j++; i++; } compressedString = compressedString + charArray[i] + counter; i++; } //System.out.println(compressedString); String output =(compressedString.length() > charArray.length)? str: compressedString; return output; } }

Basic Sortings (Bubble, Selection and Insertion Sorts)

public class BasicSortings { public static void main(String[] args) { int temp; int iterationCount = 0; int array[] = { 2, 33, 29, 30, 21, 98}; //Bubble sort or Simple sort for (int i = 0; i < array.length - 1; i++) { for (int j = i + 1; j < array.length; j++) { if (array[i] > array[j]) { temp = array[i]; array[i] = array[j]; array[j] = temp; } iterationCount++; } } System.out.println("Bubble Sort Big 0(n) --> " + iterationCount); for (int s = 0; s < array.length; s++) { System.out.print(array[s] + "\t"); } System.out.println("\n"); System.out.println("\n"); //Selection Sort iterationCount =0; int sortPointer=0; for (int i = sortPointer; i < array.length; i++) { for(int j=i+1;j< array.length;j++) { if(array[i] > array[j]) { temp = array[i]; array[i] = array[j]; array[j] = temp;