Whenever we receive a certificate, it is for a certain period, in our case, it was for 90 days.
So how to renew the certificate and then how to use the renew certificate?
That is the purpose of this video.
So in our case, we have already seen how to create the certificate and how to implement the secure
web server.
Now just we want to see how to renew the certificate and then how to use that renewed certificate.
And we are showing this by using the screenshot that we have already taken.
So in our case, whenever your certificate is going to expire, that you will get the mail from
this zeroSSL, from where we got that certificate that your certificate is going to expire.
In our case, we started getting the mail like in this mail it is saying that your ocloud.in will expire
in seven days.
So that means you will get the warning message.
And even when you are going to visit on your websites, like in our case, our website was www.ocloud.in
and when you are going to type https.
And then when we are going to click on this button on this lock button, what will we?
It is going to show you that it is going to expire on September 18, 21.
So that means warning message regarding certificate expiring.
Will checking website you are going to get.
And then how to renew the certificate, we will log in from our account, that account, which we use
for creating the certificate.
In our case, we use the website www.sslforfree.com for getting the certificate.
Now again, same site for the certificate renewal.
So when you are going to go to that, you will get this on the screen.
You will find that it is saying that ocloud.in is expiring soon and it is going to give you
the date also, plus what it is showing, it is showing you the reniew also.
So what we are going to do, we are going to click.
We have already performed this step and during performing those steps, we have taken the screenshots.
So we are going to click on the renew.
Then when we are going to click on that renew, what will happen, it will show us.
this menu that whether you need a wildcard certificate or not.
And we are going to uncheck that mean we will move this to this place because we do not need the wildcard
certificate, wildcard is paid Certificate.
So in our case, we will move this to this place and then we will click.
Then when we are going to click on this, then we are going to specify the domain.
In our case, that domain was ocloud.in, which is owned by me.
So here when we are going to enter it, it is going to create the certificate for ocloud.in
also for www.ocloud.in also.
And then we are going to click on next.
Then what it is going to show you, whether you want the certificate for 90 days or one year, if you're
going to get it for one year, then this is paid.
So in our case again, we are going to select the 90 day.
That means when we are renewing the certificate again, we will choose this option for 90 day.
Then what it is going to say?
It is going to say whether you want to generate a CSR, then we are going to choose the default option
that mean auto generate CSR.
We are not going to validate it because we are already discuss all of these things in the previous videos.
So we are going to select the default setting to generate CSR.
Then it is going to show which scheme you want.
So in our case, we are going to use the free that is, no money will be charged, but the only problem
is it is valid for 90 a day.
No issue regarding that.
Then we have to use that domain verification, whether actually this ocloud.in belong
to us or not.
So we have to make one cname entry.
So in our case, we are going to make entry into our because this domain, I have registered on GoDaddy.
com.
So we are going to make entry regarding cname.
And now we are not going to repeat how to create this cname record entries because that.
Also, we have covered in earlier videos.
So we are going to make entries in DNS by using DNS manager.
That mean modify cname because already when we were issued the certificate already the cname record was
there so now we have to modify that record and make entry according to this.
According to the instructions, now then we have to click on Verify Domain.
Now it will say congratulations.
Congratulations.
Your SSL certificate is on route.
that mean they are going to issue us
Then it is going to say that please download the congratulations.
Your domain has been verified.
This means our system issuing your certificate at the moment.
Now what we will do, we will download the certificate and we will save it somewhere.
Now what we need to do after the certificate has been issued, you will get this type of screen on your
sslforfree.com.
So this screen will be like a 90 day SSL issued that mean certificate that has
been issued.
It is valid up to December 13, 2021 and earlier, which is expiring on 17th.
Then after the expiry date.
now this screenshot we have taken today that mean 21st October.
So already that has expired.
So what is?
Now, it is not showing only showing the issue certificate that mean issue certificate.
If we want to see that a earlier certificate, we have to click on the expired.
So it is showing the expired and after the expiry, if you are going to visit the site, what will
happen?
It is going to show you this type of Warning potential security risk ahead.
So when we are going to click on Advanced, it is going to show you that the website prove their identity via
certificates, which are valid for a set time period. The certificate for www.ocloud.in expired on September 18,
it got expired.
So that is why it is giving error.
And if you are going to click on further details to view certificate, you will get that type of detail.
When it was issue, when you cannot use after this date.
And here we are showing you that we if you are going to click on this our website, if you are going
to click on that Lock button and you will get this information that it was to expire 18 September
2021.
And here we have taken the screenshot of Today and we are either doing this thing at
around the 4:16pm on 21st oct.
Already expire that mean after the expiry of certificate, you will get this type of message, so be careful
that mean your certificate had expired.
Now what we are going to do now we want to already downloaded.
So what we will do, we will log into our ec2 instance that is running, that is the address
of our instance that we have already covered.
So we are going to put the address of our Apache web server, then for coloring scheme use your system
color.
Then by default on that instance, the user is ec2-user and I am using my private key.
vipingupta.ppk for accessing that service.
So when we are going to end because by default, when we are using the putty, the font size is very
small, so we can change by the font size by clicking on this icon.
So in our case, we have made it 18.
Now you will get this type of screen, and when we are going to run the pwd command, it is
going to show you /home/ec2-user logging and it is showing you the earlier certificate.
So what we are going to do, we will remove this by using rm -f earlier file
nothing is there.
Now we are going to do.
Then we are going to copy by using secure copy.
So in our case, we will put the address, then ec2 username, then we will click on advanced and
we will use our certificate.
So we are going to use winscp to upload the certificate that we have already covered how
to use this.
So here also what we are going to do.
We are going to renew the certificate.
We are going to upload on our ec2 instance.
So this is the screen when it is connecting to our ec2 instance.
Then what will we do, in our case when we renew the certificate, we copied it into one Apache web server
directory and one domain verification directory was there, here we copied this file
Now we will click on this?
then we will drag and drop it here.
Then what will happen?
The certificate will be here.
Then what we will do again, we will go to our ec2 instance.
now we will unzip this file.
And it is going to unzip the file then Certificate.crt file will be there to ca_bundle.crt
file will be there.
Now what we are going to do.
We are going to move these files.
But before moving these files, we have to log in as a root user, therefore, that we are going to run sudo
-s.
So when we are going to run this sudo -s, this will change from ec2 to user root, then
we are going to move this mv.
ca_bundle.crt certificate.crt in which directory /etc/pki/tls/certs because already
these files are there, so it is going to give you the message, whether you want to overwrite.
We are going to say yes yy, then we are going to move the private file into this directory,
then what we are going to do.
We are going to restart our Apache.
Then we will go to our website and we will check whether everything is OK or not.
So let us go to the website and show you that now again, our web server is working properly, so we
will say https://www.ocloud.in.
So it will open the page when we are going to click on this.
So when we are going to more information, it is showing that now it is valid for up to December 14.
again, what we can do, we can use the other also as https://ocloud.in.
So again, it is showing it is running when we are going to click on this.
It is going to.
So in our case, the purpose was to show you how to renew the certificate rest of the steps are same that mean
you have to download that certificate.
You have to upload into the ec2 instance because already we have made the entries in the file, we
have to just replace the earlier certificate.
Again, your site will be now again, it will be valid.
Now it is sporting the.
https.
So that was the renewal of your certificate, how to renew the certificate and again, use this certificate.