Cifers.
Cifers are the encryption algorithm.
The crypto variable is the key.
The cifer is a set of mathematical rules
for processing data, putting it into an unreadable format.
So classical cifers, substitution ciphers, will substitute out one bit for another.
A block of plain text is replaced with cyber text.
In a transposition cifer, the letters of
the plain text are shifted about to form the cryptogram.
So sometimes this is a little bit confusing.
For example, if I took my name Eric Reed,
and I did a single transubstitutional
shift, one character for the alphabet, an ROT 1 encryption.
E becomes F, R becomes C, I becomes J, C
becomes D, R becomes S, E becomes F, E becomes F, D becomes E.
So I'm substituting one character at a time.
The problem with that is in a single
monalfabetic replacement set, you can use something called frequency analysis.
And frequency analysis can be used to
determine the most frequently occurring characters in the language.
So a polyalphabetic set is a better option for that.
So in substitution, you swap out one character one bit for another.
In transposition, you scramble it up.
So for example, Eric Reed,
instead of being swapped out one at a time, you might have E here, R here,
R here, I here, C here, E here, D here, E here.
You scramble it up.
You scramble, you substitute, you scramble, you substitute.
Transposition is scrambling, substitution
is swapping, and most encryption algorithms use a combination of both.
Based on the type of key used, we've already established public or private key.
Then based on the type of input data, a block cifer or a stream cifer, block
cifers encrypt blocks of data of fixed size.
Stream cifers will encrypt continuous streams of data.
The RC4 diagram we did under Web, that's an example of a stream c ypher.
You encrypt one bit at a time.
Rc5 and 6, for example, on the other hand, are block c yphers.
They actually work on blocks at the same time.
Blocks, you dump multiple bits in the algorithm, you transpose and substitute
multiple times in multiple rounds of encryption.
In a stream c ypher, you generate a key stream.
The data encryption standard is just that.
It's a standard.
This was actually originally the Lucifer algorithm from IBM.
It was originally 128 bits, which was way too secure back then.
It was cut in half to 64 bits with eight
bits of parity, which left us with a 56 bit key.
So 64 bits under the control of a 56 bit key.
The block sizes are 64 bits.
Des by today's standards is considered to be relatively insecure.
We have something called Moore's Law.
Moore's Law states that the processing power of a given computer chip doubles
approximately every two years, 18 months and so forth.
What was secure 10 years ago, by today's standards, not so secure.
The idea is time goes on, technology becomes more advanced, processing power
increases, shorter key lengths become insecure.
Really, what it boils down to, at least
currently, quantum is going to change everything, but currently it just boils
down to how long it takes to exhaust all the possible combinations of the key,
which is two to the power of whatever number of bits in the key.
By today's standards, 56 bits is considered to be insecure.
Now, due to the weakness of a 56 bit key, we actually have a three peat DES called
Triple DES, where you DES the data multiple times, three times versus two.
Double DES, oddly enough, had about the same work factor as single DES, and you
could crack it, cut it in half, do a meet in the middle attack on it, and actually
crack it at about the same time as single DES.
But triple DES definitely improved the security, gives you the
effective key length of just call it 168 bits.
All right, so DES is on its way out.
It's been replaced by the Advanced
Encryption Standard or AES, which is actually the Rindel C ypher.
Aes is a hundred and twenty eight bit
block size with key sizes of one one, twenty eight, one one, one nine, two, and
two, fifty six for the different flavors of AES, one, twenty eight, one, one,
two, 28, one, nine, two, and two, fifty six.
Our RC 4, 5, and 6 algorithms.
Okay, these are all actually Ron Rivist's ciphers.
Big shout out to Ron Rivist.
Big brain on Ron.
He's responsible for RC 4, RC 5, RC
6, MD2, MD 4, MD 5, and I'm pretty sure MD 6.
I don't see why it wouldn't be.
Then you've got RSA.
I've just never seen that.
The credit noted somewhere, but I'm pretty sure he does.
Then the R&RSA for Rivis Shemir Adelman,
Officer Ron Rivis, so pretty prominent guy in the field of cryptography.
Rc 4 is a symmetric stream cifer.
Rc 5 and 6 are both symmetric block cifers.
You don't really need to differentiate much between 5 and 6.
6 is essentially a faster RC 5.
Digital Signature Algorithmic or DSA and Rivis Shemir Adelman RSA.
Both are examples of asymmetric.
Asymetric means public and private keys.
Rsa works on creating products of very large prime numbers.
Then the reversal of the process is called factorization.
It's easy to do in one direction.
It's difficult or impossible to do in reverse without some additional help.
Dsa and RSA are both asymmetric in nature.
Both of them can be used for digital signatures.
Other encryption techniques and technologies, Elliptic Curve.
Elloptic Curve was originally developed
for low processing power devices, cell phones, for example.
Well, a cell phone today is by no means a low processing powered device.
My phone is probably as powerful as a laptop from three, four, five years ago.
So it's not necessarily confined to mobile devices.
But with the elliptic curve, you get the
same security with less math and smaller key sizes.
And it's about one tenth, roughly.
It's not a straight ratio.
But with Elloptic curve, it avoids larger cryptographic key usage, uses
number theory, mathematical elliptic curves, which is algebraic structure.
You don't really need to give that too
much, proposes replacement for RSA to reduce the usage of the key size.
Quantum cryptography. Yeah.
Based on quantum mechanics, like quantum
key distribution, the data is encrypted by a sequence of photons with a spinning
trait while traveling from one end of the other.
Attackers can eavesdrop but can't
manipulate the data because the photons are transferred through arbitrary filters.
Quantum, the state of observation can
actually affect the outcome of the experiment.
There's one aspect, the ability to detect
eavesdropping, which is what that boils down to.
Then you've also got quantum computing, which quantum
computing, all of our current cryptography, is going to go right out the
window with quantum computers just based on the processing power.
Homomorphic encryption allows users to
secure their data encrypted format even while it's being processed or manipulated.
Encryption and decryption are done by the same key holder.
You can encrypt confidential data and
outsource it to the enterprise to process given data.
All right, so ther encryption techniques and technologies
create the hardware based anything gives you better performance.
Also, it can allow for accommodates portability.
Trusted platform modular TPM is a crypto processor chip on the mother board that
securely stores encryption keys, can perform cryptographic operations.
Bit locker keys, things like that, can be
managed through trusted platform management.
A hardware security module, external security device used for managing
cryptographic keys, and that could be like a USB stick or dongle device.
Okay, USB Encryption, additional feature for USB storage
devices, offering onboard encryption services.
Some of that's built into the application that comes with the drive.
You can also use BitLocker for that.
Then hard drive encryption, which we've mentioned.
Data stored in the hardware can be
encrypted using a wide range of encryption options.
And you've got BitLocker, you've got EFS, you've got third party utilities for that.
In Windows, typically you're thinking of BitLocker and an encrypted file system.
Other encryption techniques and technology is post quantum.
Advanced cryptographic algorithm, which
can secure different tanks, initiated on both conventional and quantum computers.
Done absolutely nothing with this at this
point, but it's going to be a game changer, no doubt about it.
Intended to provide secure wide range communication, secure key
processing, signatures and public key based encryption.
All right, lightweight cryptography.
Again, low horsepower devices, low
processing power, need to use algorithms that are more suitable.
So again, one example of that would be lift the curve.
Low complexity RFID tags, sensor based application design on team.
All right, cipher modes of operation.
In a symmetric block c ypher, the same
plain text could produce the same c ypher text.
And if you start seeing patterns in plain
text to c ypher text, you can start drawing conclusions.
You can start determining how the encryption is taking place.
You might be able to crack the encryption.
So in electronic code book mode, there is
no cascading of data into the next operation.
Same plain text produces the same cipher text every time.
In a cipher block chaining mode, you're starting with an initialization vector or
a seed value, and you're adding randomness into the process.
Plain text is X ord with an initialization vector.
That creates the block c ypher encryption.
That c ypher text is then used as the X or for the next block of plain text, etc.
Long story short, the same plain text does
not produce the same c ypher text every time.
That's really important.
It cascades, but part of the problem with that is on the receiving end, reversing
it, if there are any errors in the output, it could actually cascade through the
decryption process and completely screw up the decryption process.
Noisy communication lines can be a problem.
Sorry for feedback.
The initialization vector is added before the initial encryption.
It's the same concept, but it's a little bit different on how it's laid out.
In counter mode, instead of random values, there are sequentially created counters.
This allows you to decrypt things in parallel.
Now, there's another one that is called
output feedback, where the c ypher text is not fed into the next block.
It's done before the c ypher text is output.
It was primarily designed for satellite
communications when you just think outer space satellites for any transmission
errors, so they don't cascade through the decryption process.
Everything else is assuming a reliable communication mechanism or medium.
Satellites are a little bit more dicey, at least in theory.
All right, so c ypher feedback encounter mode.
All four of these are versions of symmetric block ciphers.
Ecb doesn't add any randomness into the process.
Key stretching.
Key stretching refers to strengthening a
key that might be slightly too weak just by making it longer.
You're extending the key, which in key cracking, brute forcing, it's just a
matter of trying every possible combination.
For example, a single bit or one bit key has two possibilities, a 1 or a 0.
It takes you two tries to crack a one bit key.
In a two bit key, you have four combinations, okay?
1, 1, 1, 0, 0, 1, 0, 0.
In a three bit, you have eight
combinations and it doubles every time you add a bit.
The longer the key, every time you add a
bit, you double the number possible combinations.
You double the security with every bit you add.
Key stretching is just extending the key size.
Common uses of cryptography.
Low power devices, we've already talked about.
Lipid curve was intended for low power devices.
Low latencies, applications require low latency.
You should use symmetric cryptography with small keys to keep the process efficient.
Confidentiality.
File level, disk level, email based encryption to achieve confidentiality.
That's probably the widest use, widest use that works for cryptography.
Confidentiality.
Integrity and resiliency.
Again, hash functions give us integrity and digital signatures give us
authenticity and non repudiation. right, obfuscation.
Cryptography also helps in hiding the
contents of data using obfuscation techniques.
O bfuscation in general is, a lot of times, obfuscation is just reversible.
You've got reversible, nonreversible.
When you start talking about obfuscation, types of attacks, or evasion
attacks, you're putting the data into an alternative format, but it usually is
still interpreted correctly on the receiving system.
One of the ways to evade IDS firewalls and so forth is to use alternative coding.
But obfuscation in general is hiding the true meaning of something.
By altering it, oftentimes that's reversible.
Obfuscated passwords are easily reversible, hashed passwords are not.
Clear text passwords and you'll see
obfuscation used in a couple of different contexts.
Real time authentication can also be used
for authentication, storing passwords in the form of hashes, validating user hashes
later in the user attempts to log in or access resources.
We've talked about that in password text.
Again, nonrepeatiation, guarantee the send
of a message cannot later have to deny sending the message or deny
receiving if it's been digitally signed as receive or sent.