# Asymmetric Cryptography (Public Key Cryptography) – Part I

Asymmetric cryptography, also known as public key cryptography, it uses two distinct, yet related keys. One key, the Public Key, is used for encryption and the other, the Private Key, is for decryption. Let say Mahesh wants to send an encrypted message to Shalini, Mahesh will look for Shalini Public key and use it for encrypt the message before sending it. Then Shalini Can decrypt … Continue reading Asymmetric Cryptography (Public Key Cryptography) – Part I

# Basic of Cryptography (Type of Cryptography)- Part II

Cryptography categorized based on number of keys used for encryption and decryption; Below are list of cryptography catgories  Secret Key Cryptography – It is also call symmetric encryption where for both encryption and decryption uses same key. This is mainly used for confidentiality. Public Key Cryptography – It is also called asymmetric encryption; this algorithm uses two key’s one for encryption and one for decryption. … Continue reading Basic of Cryptography (Type of Cryptography)- Part II

# Caesar Cipher (Cracking Caesar Cipher with the Brute-Force Technique) – Part II

In Part I, I have written code to encrypt the plain text for demonstration purpose . In this article we will use Brute Force technique to decrypt the encrypted message. Note: please make sure to read articles Brute force and Caesar Cipher before this article. Here is C# Code snippet for the same Above code produce below  result, the above code took 17 iteration  to get the actual … Continue reading Caesar Cipher (Cracking Caesar Cipher with the Brute-Force Technique) – Part II

# Caesar Cipher Source Code – Part I

The Caesar cipher is one of the earliest known and simplest ciphers; Created and used in 44 BC by Julius Caesar. It is a type of substitution cipher in which each letter in the plain text is ‘shifted’ with certain number of places in the alphabet. For example, if we right shift the alphabets by 3 char then we get the below text;     … Continue reading Caesar Cipher Source Code – Part I

# Brute Force – Part I

Brute force is a straight forward strategy to solving a problem, it’s also called as ‘Exhaustive Search’ in which you try all possibilities to reach solution of a problem. In Brute force attack, attacker systematically checks all possible passwords and passphrases until the correct one is found. Alternatively, the attacker can attempt to guess the key, which is typically created from the password using a key … Continue reading Brute Force – Part I

# SHA-256(Source Code in C# using .Net in-built Cryptography library) – Part II

.Net Framework provides in built support for various hash functions like MD-5, SHA-1, SHA-256 etc…   ComputeHash method Computes the hash value to the specified byte array.   Below are the overloaded methods to Compute Hash using SHA-256 class in System.Security.Cryptography  library     Here is C# source code using .Net In-build library Continue reading SHA-256(Source Code in C# using .Net in-built Cryptography library) – Part II

# SHA-256(Source Code in C#) – Part I

SHA-256 (Secure Hash Algorithm), is one of the cryptographic hash function, commonly used in Blockchain. It generates an almost-unique 256-bit (32-byte) signature for a text.  SHA-256 is successor hash functions to SHA-1. it is one of the strongest hash functions available and has not yet been compromised in any way.   Here is source code written in C#. I will try to give more details in next … Continue reading SHA-256(Source Code in C#) – Part I

# What do you mean by Hashing?

Hashing is process of converting any size of data into fix size of data by performing mathematical operations. A message to be hashed is called input; the Algorithm is used to do so is called hash function; the output is called hash value.   There are many algorithm which used to generate hash value like MD5, SHA-1, SHA-256, Tiger etc.    Hash function generates a … Continue reading What do you mean by Hashing?

# Basic of Cryptography – Part I

Cryptograph means secret writing, in order to make information secret we use cipher, an algorithm that converts plain text to cipher-text. Cipher has been used long before computer existance. In 44 BC Julius Caesar uses the technique now called Caeser Cipher to send message. He used to shfit the letter by 3 character.  Another great example from history, Nazis Enigma Machine used during war to translate message. … Continue reading Basic of Cryptography – Part I