How to add HTTPS binding to IIS7 :
1) GO to run -> inetmgr
2) Select Default Web Site -> From right panel options select 'Bindings' -> Add -> select https from select type drop down options
3) Assign SSL certificate for list. You can create your certificate and use here for authentication.
4) Select Default Web Site-> Feature View -> select SSL security -> and set SSL required with accepted value and click on Apply. To change your settings.
How To test :
Select Default Web Site -> You will see Browse:443 in Right pane option
Click on it, it will show IIS page with hppts protocol.
Answers for my questions:
1) If I change the service urls from HTTP to HTTPS will it work?
Yes, but the page from which you are calling service and WCF Service must be under same IIS
2) Is it require to add extra binding settings in config file of service.
Yes, I changed bindings to webHttpBinding.
<bindings>
<webhttpbinding>
<binding name="webHttpBindingClient">
<security mode="Transport" />
</binding>
</webhttpbinding>
</bindings>
<services>
<service behaviorconfiguration="ServiceBehaviour" name="Service">
<endpoint address="" binding="webHttpBinding" behaviorconfiguration="EndpBehaviour" bindingconfiguration="webHttpBindingClient" contract="IService" name="webHttpEndPointBinding" />
</service>
</services>
<system.webserver>
<httpprotocol>
<customheaders>
<add name="Access-Control-Allow-Origin" value="*" />
<add name="Access-Control-Allow-Credentials" value="true" />
<add name="Access-Control-Allow-Methods" value="POST, GET,OPTIONS" />
<add name="Access-Control-Max-Age" value="600000" />
<add name="Access-Control-Allow-Headers" value="content-type" />
<add name="Content-Type" value="application/json;charset=UTF-8" />
</customheaders>
</httpprotocol>
<modules runallmanagedmodulesforallrequests="true" />
</system.webserver>
3) Which things will affect after changing HTTP to HTTPS?
- Both HTTP and HTTPs will work fine
4) I am calling these WCF services by using jquery.ajax(), will it work bye changing only URL of service?
- Yes it will work with only URL change