Login Register




The stories and information posted here are artistic works of fiction and falsehood. Only a fool would take anything posted here as fact.


Cryptographic Methods and Principles filter_list
Author
Message
Cryptographic Methods and Principles #1
Cryptography Methods

There are multiple methods that are used to secure data, some are better than others, and some are deprecated entirely.
Shift Ciphers

Shift ciphers are one of the oldest methods of cryptography, it involves an offset factor, which remains constant throughout. This means that it is one of the weakest cryptography methods as using letter substitution, a solution can usually be found quite easily, therefore providing little to no security. One time pads

One-time pads are a security method that has yet to be cracked. For every character in a message, a different “shift” or offset is generated. This means that it is essentially impossible to guess, especially with longer messages. The idea of a one-time pad is that it is generated to encrypt the message, it is then sent to the recipient, and destroyed by the sender. The recipient then must use the pad to decrypt the message, then destroy the pad. Because of the randomised offset factor, the message will be almost impossible to crack, unless the pad is intercepted. It would be wise to send the one time pad in an obfuscated format, or encrypted using other methods. This is the only weakness to using a one-time pad, the pad itself must be sent securely, otherwise the whole encryption is voided.
Hashing

Hashing is the process of taking information and compressing it into a long hexadecimal string, that has a fixed length. The output value of a hash is called the “digest” value. This can be used in order to verify if a file is identical to one that you downloaded. This method of using hashes is called using a “checksum”.

Different hash algorithms will result in different digest values for the same input, and every algorithm has it’s advantages and disadvantages. As time goes on and computing efficiency increases, more algorithms will have to be developed as they will quickly become deprecated, which means that any data stored using them can effectively be cracked. 

Hashes have different types, there are some algorithms that are plain hash algorithms, such as ECOH, FSB, MD2, MD4 and RIPEMD, which are useful however there is the issue of hash collisions. This is where two different files can result in the same checksum when run through the hashing algorithm. This can provide an inherent security flaw as this can allow for malicious file replacement, which means that an important file could be replaced by a malicious or altered copy of the file, which results in the same checksum, therefore the recipient would be unaware that their file was not the original.

In order to combat this, Merkle–Damgård construction is used when developing the algorithm. This is a type of development that ensures the likelyhood of hash collisions is largely reduced. This is why the more secure hash functions use this type of construction nowadays, as it makes it harder to “crack” a hash, and this means that the standard is likely to last a lot longer than otherwise.
Block and Stream Ciphers

Block ciphers and stream ciphers are two different ways of encrypting data in a hash algorithm. Block ciphers use the method of separating data into blocks of various sizes (measured in bits). This length is usually 64-128 bits. Once the data has been organised into blocks, these blocks are encrypted in order to return the digest value. Alternatively, stream ciphers take every bit of the data, and they encrypt each one individually. This is important to use when the length of the data is unknown, as block ciphers can become very slow when trying to encrypt large amounts of data. Block ciphers are better suited to applications when the number of bits that need to be encrypted is known.

Encryption Algorithms

There are two types of keyed algorithms that are used in order to encrypt data. These are “symmetric key algorithms” and “asymmetric key algorithms”. 

The main difference between these two methods is the usage of the keys. In symmetric key algorithms, the same key is used to encrypt and decrypt the data. However in asymmetric key algorithms, two keys are used to encrypt and decrypt the data. One of these keys is used to encrypt the data, and one is used to decrypt it. These keys must be mathematically paired in some way order to allow the decryption process to output the correct value.
Symmetric Key Algorithms

DES

DES stands for Data Encryption Standard, and is now a deprecated symmetric key algorithm, though it was once the primary standard for symmetric key encryption, it was cracked a long time ago. It’s a block cipher, which used a block length of 56 bits, with 8 parity bits (a bit which is used to check binary values, the sum of all the 1’s in the block and the parity bit should return an even number). DES was designed by IBM in the 1970’s, though it held an industry standard for roughly thirty years, and is thought to have been cracked in 1999 in just under 24 hours. 3DES

3DES stands for “triple DES”. The idea of 3DES was to circumvent the vulnerability by using multiple keys generated from the DES algorithm. 3DES uses a key bundle of 3x56bit keys in order to encrypt data. This makes the encryption very secure, if configured correctly, it still has not been cracked to this day. However there are many vulnerabilities that are inherent to DES and this means that it is on the decline for it’s usability. It is grouped as a 128bit encryption as it has a number of bits between 112 and 168, due to the key bundle.



RSA

RSA is an asymmetric public key system that is used for secure transactions on the internet. It is a relatively slow algorithm as it uses two large prime numbers with an auxiliary value in order to calculate the public key key, with the prime numbers being kept secret. Anyone can use this public key in order to encrypt data, but only the person who knows the prime numbers can decrypt the data. 

Cracking RSA is possible, however there are a few problems related to it. The first is the “factoring problem”, and the second is the “RSA problem”. 

The factoring problem is that with no quantum computing levels of processing power, it is incredibly time consuming in order to try to factorise an extremely large number into it’s factors or prime factors.

The RSA problem is that it is incredibly difficult to discern a private key only given an RSA public key. For keys with over 1024 bits, no algorithm is known to attempt this. For keys under 1024 bits in length, there is one method to discern the private key, however if a padding scheme is used then this attack is mitigated. AES

AES (Advanced Encryption Standard) is a block cipher that uses 128 bit length blocks, and is used in symmetric key algorithms. AES was developed specifically to take over when 3DES becomes deprecated as it is much more secure in terms of processing power required to crack it as there can be keys ranging from 128 bits to 256 bits. The more bits in the key, the harder it is to crack. AES is secure, but it is also very efficient in terms of processing power for encrypting and decrypting data.Mathematical Principles

Most cryptographic systems use mathematical principles in order to encrypt data. Cryptographic primitives

The majority of modern cryptography is based on algorithms which are built upon in order to develop specific encryption standards; these are called cryptographic primitives. One way functions and integer factorisation

One way functions are designed specifically to be easy to compute but hard to reverse, an example of these would be hash functions. An algorithm that uses a one way function and the idea of integer factorisation is RSA, which uses two large prime numbers and multiplies them together with an auxiliary value. While this calculation is quick to perform, it results in a large number that is very hard to reverse into it’s prime factors with ease. When there are a large number of bits, something called the “factoring problem” occurs. This is because there is no known algorithm that can quickly factorise hundreds of bit long numbers quickly. Pseudorandom functions

These functions are used to create seemingly random numbers with minimal processing power. A lot of cryptographic methods use these, for generating salts and keys to encrypt data and communications. For a successful and secure pseudorandom number generator, a stream of bits must be produced, and there must be no way of predicting the next bit with a higher likelihood than 50%
Keys and digital certificates

Symmetric key encryption isn’t always the best solution when you want to send data securely to another person as the key must be transmitted along with the data, which means that it can be intercepted and the data could be decoded on the fly, with ease.

This is the reason that the public key encryption system is used, and it’s based on the RSA standard. 

The main idea behind the public key system is having a pair of mathematically similar keys, one being a private key and one being a public key. 

The public key is used to encrypt data, and the private key is used to decrypt it. The public key is shared publicly, but the private key is kept secret.

The most common application for the public key system is for securing website data transfers, using SSL/TLS (both used for HTTPS transmissions - though TLS is more modern and secure). These work by having a digital certificate, provided by an authorised CA (certificate authority). These are used to determine if a connection is trusted.

However, it is possible to either self-sign these certificates, or sometimes provide a fake one. Alternatively, there is the option of using the Encrypt[TRADE MARK SIGN] CA, which is free to use and is sponsored by big technology industries like Google.

Some CA’s like Verisign have a “trusted root certificate” embedded in most browsers. This means that any certificates that are signed under Verisign’s name are automatically trusted by the browser, whether they have been verified or not. Virtual Private Networks (VPNs) and generic routing encapsulation (GRE) tunnels

A VPN is a method of “extending” two LAN networks across a shared network (normally this is across the internet). This means that systems on either LAN can communicate with each other, and share resources.

Given that transmitting private data across a public network is not a secure method, there are a few ways to secure this data transfer. Firstly, the protocol that VPN’s use is one, it normally requires authentication to connect and all the data is encrypted when running through it. A good protocol to use for this is called IPSec, as it both encrypts and encapsulates packets, and has authorisation features for hosts to verify both parties before any data is actually sent. Tunnelling is the main method used to secure VPN traffic. Tunneling protocols vary slightly however they all follow the same general idea of securing the data packets sent by one LAN to the other. GRE (generic routing encapsulation) is a method of encapsulating the encrypted data packets and sending them over the WAN. This is because routers over the WAN network will only ever look at the outside packet, therefore they don’t identify the contents of the inner packet. When the packet has reached the other LAN, the outer IP packet is stripped so the data from the inner packet can be accessed by the VPN software to decrypt the data for use on the other LAN....
Knowledge is free..
Retaining that Knowledge takes work..
[Image: 4aeb044653a17ba3f4588cdf214cdf77.gif]

[+] 2 users Like Byrdonawire's post
Reply

RE: Cryptographic Methods and Principles #2
Did you write this yourself?

Thanks for sharing.

Reply

RE: Cryptographic Methods and Principles #3
Yes And I thought it was a fitting post in light of the current events that are taking place. And thank you[WINKING FACE]
Knowledge is free..
Retaining that Knowledge takes work..
[Image: 4aeb044653a17ba3f4588cdf214cdf77.gif]

[+] 1 user Likes Byrdonawire's post
Reply

RE: Cryptographic Methods and Principles #4
I have been wanting to learn cryptography, I hope this is a well written tut, and thanks for posting! Evil
[Image: ezgif_com_gif_maker.gif]
#yellowheartsforsarah

Reply

RE: Cryptographic Methods and Principles #5
Very interesting tutorial! Thank you for sharing this. Just as a tip, if you'd format it just a little bit better, it will increase readability a lot.
~~ Might be back? ~~

Reply

RE: Cryptographic Methods and Principles #6
Some very Interesting reading.

Quite detailed, yet effective and Informative.
Well done.
[Image: AD83g1A.png]

Reply

RE: Cryptographic Methods and Principles #7
Thanks for writing this, it's an interesting tut

Reply