Looks like no one added any tags here yet for you.
Symmetric Key Encryption
It uses the same key for both encryption and decryption. This method is fast and efficient but requires a secure way of sharing the key with the intended recipient.
Public Key Encryption (Asymmetric Encryption)
It uses two keys, a public key and a private key, which are mathematically related but not identical. The public key can be used to encrypt data, but only the private key can decrypt it. This makes it more secure and flexible, but also more resource-intensive.
RSA
One party generates a key pair, both the public key and the secret key. Then the other party uses the public key to encrypt the communication. The private key is used to decrypt.
Diffie-Hellman
Both parties exchange public key information and then arrive at a shared secret key.
Elliptic Curve Cryptography (ECC)
is an approach to public-key cryptography based on the algebraic structure of elliptic curves over finite fields. ECC allows smaller keys to provide equivalent security, compared to cryptosystems based on modular exponentiation in Galois fields, such as the RSA cryptosystem and ElGamal cryptosystem.
Hash functions
are used in data storage and retrieval applications to access data in a small and nearly constant time per retrieval. They require an amount of storage space only fractionally greater than the total space required for the data or records themselves. They are also used to ensure the integrity of data by generating checksums, and in cryptographic applications to create secure hash algorithms.
A cryptographic hash function
a transformation that takes an input (or āmessageā) and returns a fixed-size string of bytes123. The output should be unique to each unique input; a small change in the input should produce such drastic change in output that the new hash value appears uncorrelated with the old hash value
A good cryptographic hash function should have the following properties:
Preimage resistance: For a given hash output, it should be computationally infeasible to find the input that generated that output.
Second preimage resistance: Given an input and its hash, it should be computationally infeasible to find a different input with the same hash.
Collision resistance: It should be computationally infeasible to find two different inputs that hash to the same output.
A hash function collision
occurs when two different inputs result in the same output
Poor hash functions
do not have good collision resistance, meaning itās easier to find two inputs that result in the same output.
Preimage resistance
is a property where, given a hash output, itās computationally infeasible to find the input that generated that output. Poor hash functions lack this property.
Good hashing algorithms include
SHA-256, SHA-3, and others
good hashing algorithms
These algorithms are designed to be secure against various cryptographic attacks and have good collision resistance.
A Message Authentication Code (MAC)
is used to authenticate the origin and nature of a message.
MACs use authentication cryptography
to verify the legitimacy of data sent through a network or transferred from one person to another.
Message Authentication Codes (MACs)
ensure that the message is coming from the correct sender, has not been changed, and that the data transferred over a network or stored in or outside a system is legitimate and does not contain harmful code.
A brute force attack
is when an attacker tries to guess an accountās password by making a bunch of different attempts.
A brute-force attack on a MAC
requires known message-MAC pairs
If the data is altered between the time the sender initiates the transfer and when the recipient receives it
the MAC information will also be affected. Therefore, when the recipient attempts to verify the authenticity of the data, the key will not work, and the end result will not match that of the sender.