What determines if a site is secure to browsers? - web-services

I'm currently building a web site, and I wanted to know how to ensure that my website appeared as secure in a browser.
Kind of like Facebook:
See how they have that little green secure lock icon (in Chrome)? How can I achieve that on my own website to ensure it's users feel comfortable?

Your browser will display this icon when you navigate to a secured endpoint for the website by using the https scheme instead of http. The browser will connect to port 443 on the server instead of port 80 and will receive one or more certificates from the server.
These certificates form a chain, where one certificate is verified by including the digital signature of a signing authority whose public key is included in another certificate.
Eventually, this chain of trust ends in a certificate that is signed by a signing authority whose public key is included in your browser distribution, so the browser is hardcoded to trust it. If the browser is able to build this chain of trust all the way to a build-in public key, it will display this icon to indicate to the user that the site belongs to whoever the certificate was issued for.
If you click this icon, the browser will display a dialog in which you can find who the certificate was issued to (Subject) and the certificates that build this chain of trust.
See also: https://security.stackexchange.com/questions/20803/how-does-ssl-tls-work and http://en.wikipedia.org/wiki/Transport_Layer_Security

You need to have SSL installed on your server.

You need to use SSL , request to your hosting provider fyi, this is paid services, but few hosting provider give you free SSL services Alpha SSL.

Related

Does HTTPS in Google Cloud Functions support mTLS using PKI?

I'm looking to serve HTTPS downloads which are authenticated in both directions using mTLS, the requests and responses being signed with certificates issued by a private CA. The purpose of this is securing OTA updates of an embedded device (I need to identify and authorize both ends before downloading a FW image and PKI + mTLS is a very workable solution). A human being with a browser will never interact with this.
Google Cloud Functions terminate TLS by serving a public Google-issued HTTPS certificate. I can't seem to figure out how to make GCF serve HTTPS using a custom certificate (or to authorize incoming HTTPS requests only if the client certificate is signed by my private CA). Is that even possible? If yes, can anyone point me down the right document or example?
Client certificates are not supported.

Use https in aws for flask api without purchasing domain name

I have made a flask application to use only as API. I have hosted it on aws using nginx and gunicorn. I intend to use the API to run my android application. There is a part in the application where i have to download something using Android Download Manager, but it only downloads things hosted in https domains. So i want to make my application https instead http. But every tutorial shows me a way with a purchased domain. I dont have much information on it yet, but I cant get an SSL Certificate from amazon without purchased domain name(which is pointless for an API). I just want to know how can I do this? How can I make my nginx server listen to https requests?
I have hosted it on aws using nginx and gunicorn.
I think you need a domain name to get ssl on AWS.
It is not allowed in AWS.
One part of HTTPS is encryption, the other part is identity verification. What you're asking for is impossible since it is required that you have to verify your domain name. Without this no Certificate authority will sign a certificate. You cannot have publicly valid certificate if it's self-signed. ACM (Amazon Certificate Manager) an AWS service, will not allow you to create a certificate without a valid domain name.

Where can I get a public SSL certificate if I don't own a domain?

We built web APIs using Spring Boot. It is currently deployed on AWS Elastic Beanstalk. HTTPS is enabled with a self-signed certificate for development and testing. We plan to go live soon, so probably need to get a public certificate from a Certificate Authority.
Amazon has a certificate manager which is the easiest way to get a certificate for application deployed on Elastic Beanstalk. However, it requires some DNS set up on the server side which means you have to own the domain. I also looked at a popular free CA, Letsencrypt. But it also requires domain validation. We don't own a domain yet. The APIs are still using the long url from Beanstalk environment, something like my-app.us-east-2.elasticbeanstalk.com. I wonder if there is any website to download domain independent certificate which can be used for Beanstalk web applications without a domain?
If somebody could get a certificate for a domain he does not own he would be able to impersonate that domain, for example within a man in the middle attack. This would essentially break the security of HTTPS since encryption will not help to protect your data if you don't do the encryption with the real server but instead with a server owned by the attacker.
That's why there is no such thing as domain independent certificate. And that's why you should not be able to get a certificate for a domain you don't control.

How can I setup SSL support for a naked domain on AWS using the AWS Certificate Manager?

(StackOverflow won't let me use "mydomain.com" as an example so I have to use the real domain--sorry all but I tried to not make this an ad)
So I've generated an SSL certificate for *.fantasyadsnetwork.com through AWS Certificate Manager and created a load balancer that can receive www.fantasyadsnetwork.com traffic (http & https) and that portion works great.
The issue I am running into is handling users who key in "https://fantasyadsnetwork.com" into the browser. Note the lack of www (naked domain.) As it stands they are presented with an error message like:
The exact messaging is browser dependant. If you add an exception, click ignore, etc then the user loads the site (which detects the lack of www & redirects the user to https://www.fantasyadsnetwork.com/) just fine but that is an ugly hurdle for a user to jump through.
Any suggestions on how to work around this? Preferably without having to buy a separate SSL certificate from GoDaddy or someone else.
I found my own answer:
When you are setting up the certificate in AWS Certificate Manager if you enter a single *.fantasyadsnetwork.com domain it will not support the naked domain. However they allow you to enter multiple domains so just include the naked domain as well. The bad news is you can't edit this after you've created the certificate so you'll need to create a new one.

Securing an ASP.NET Web Service using SSL, without dedicated IP address on the Server

I need to secure communication between my application and my Web Service.
I own both the application and the Web Service, and I was wondering if it is possible to use HTTPS to do so.
I don't need a certificate to prove to myself who I really am (!), so I don't want to buy an SSL certificate from a Certificate Authority. I just need to make sure no one can intercept the data I pass as WebMethod parameters; Can I create a free certificate and use that to secure communication?
One other thing: I don't want to be forced to get a dedicated, public IP address for my Web Service since it is hosted on a shared Web server.
Definitely it's doable, but hinges on a few conditions.
Create your own self signed certificate. The lack of a certificate authority won't matter in your case because your app is your own consumer.
The host must allow you to configure your IIS site with an SSL cert. Hopefully the tools they provide are good enough.
The shared IP that your web site has currently cannot have more than one certificate bound to it. You're now at the mercy of your host to not move your site to a different IP. It may or may not have an SSL cert on another site at that time. Basically - the first one wins. An IP cannot have more than one cert-secured website.
There are many articles out there showing how to create and install a self signed certificate in IIS. What you need to remember is that this certificate will not be valid as it is not delivered by a certificate authority. Once you set a certificate on the server side you need to indicate to the client to accept the invalid certificate by using the ServerCertificateValidationCallback property:
ServicePointManager.ServerCertificateValidationCallback =
(sender, certificate, chain, sslPolicyErrors) => true;
You can't use a SSL certificate (self signed or otherwise) without a dedicated IP address. Unless your shared hosting provider provides a shared SSL certificate on your IP, you will need to purchase a dedicated IP.
If you want to go through the trouble of doing it, you can use a self-signed certificate and have a tertiary server (or use the IIS server that is self-signing) to be your own certificate authority. This would allow you to generate your own certificate for free, then since you have control over the servers, you could just add your CA server as a trusted and intermediary root certificate authority.
Creating Certificate Authorities and self-signed SSL certificates