-: In this section of the course, we're going to focus
on the concept of the Public Key Infrastructure,
also known as PKI.
Now Public Key Infrastructure is an entire system of
hardware, software, policies, procedures,
and people that is based on asymmetric encryption.
If you have ever connected to a website using a
https connection, you've been part of PKI.
Now, if you want to establish a secure connection
to diontraining.com, you would enter
https://www diontraining.com into your web browser.
Your web browser would go to a trusted third party
called the certificate authority, and they're going to
ask them for a copy of my web server's public key.
Then, your web browser is going to pick a random long number
to use as a shared secret key for use with the
symmetric algorithm, something like ADS that we're
going to use for bulk encryption of the data
between your browser and my web server.
But, you have to get that random shared secret
to my web server securely, and for that,
we're going to use Public Key Encryption,
known as asymmetrical encryption.
Now, using my public key, your computer is going to
encrypt that random shared secret key that you've created.
In the example here, I'm using 51363 as our shared secret.
Now once you encrypt that using my server's public key,
which anyone in the world has access to,
it's then going to be sent over the internet.
Now, because it's encrypted with my public key though,
no-one on the internet can decrypt it
unless they have my private key.
And the only person who has that is me.
So as we go across the internet, no-one can see the fact
that it's 51363 as that secret code.
Now once my web server receives the encrypted cipher text,
it's going to use my server's private key to decrypt it
and get it back to that shared secret key
that you submitted.
And now that I have it in plain text,
I know what that number is, that 51363.
So far, this is just using asymmetrical encryption
like we discussed in the last section.
Now, both you and my server know
this shared secret key though.
So we can create a symmetric tunnel.
We can do that by using something like ADF
to create a secure TLS or SSL tunnel over the internet
and communicate safely and securely
from anybody's prying eyes.
This is going to ensure that we have confidentiality,
because we're both using the same shared secret key.
And because my web server is the only device
in the entire world that had a copy of that private key,
you're also assured that my web server
is who it claims to be.
It's been authenticated; in this case as diontraining.com.
This gives us authentication of the identity of my server,
in this way your web browser knows it can trust it.
Now, if all of that occurs successfully, you're going to get
that little padlock in your browser showing that we can
both communicate securely between each other.
Now all of that sounds a lot like Public Key Cryptography,
doesn't it?
Well, PKI and Public Key Cryptography are closely related,
but they are not the same thing.
When we talk about PKI, this is the system that creates
the asymmetrical key pairs that consist of those
public and private keys that are used in the encryption
and decryption process, as well as managing those key pairs
to make sure they're valid and can be trusted.
When we talk about Public Key Cryptography
on the other hand, we're just talking about the
encryption and decryption process.
So it's a small part of the overall PKI architecture.
For all of this to occur successfully, we need to have a
trusted third party involved though.
This trusted third party is known
as a certificate authority.
These certificate authorities are going to issue
digital certificates, and these certificate authorities
are also going to level trust between all of the
certificate authorities around the world.
In this section of the course, we're going to focus on
all of those other parts of the process that allow
PKI to work, including those certificate authorities.
Remember, PKI uses Public Key Cryptography to do
its function, but PKI is the entire system of things
that are done to be able to create the secure connection
from end to end.
Now when we talk about Public Key Encryption
on the other hand, it's just the asymmetric
encryption and decryption piece.