SSL SECURITY

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.
13 years ago
I'm using my own server. I installed a ssl certificate succesfully. When I browse my site , its coming with no problem. But when I click any of product on my site , then redirect me to HTTP site. I also write "HTTPS" manually, then redirect me to HTTP site again. Here is the my problem as a sample.

Browse "HTTPS://www.mysite.com" , THERE IS NO PROBLEM.

Then I Click on "HTTPS://www.mysite.com/recentlyaddedproducts.aspx" , then redirect me to "HTTP://www.mysite.com/recentlyaddedproducts.aspx"

Browse "HTTPS://www.mysite.com/recentlyaddedproducts.aspx" manually , then redirect me to "HTTP://www.mysite.com/recentlyaddedproducts.aspx"

and also

Browse "HTTPS://www.mysite.com" , THERE IS NO PROBLEM.

Then I Click on "HTTPS://www.mysite.com/shoppingcart.aspx" , THERE IS NO PROBLEM :)

please help me to solve this problem.

Thanks all.
13 years ago
The reason you're getting http on pages like 'Recently added products" is that, they don't use / require SSL certificate.

SSL Certification "https" is only required where sensitive information (like payment, checkout, shipping cart etc) are involved.

Some pages require SSL, some of them don't. For example, if you want Category page to require SSl, open Category.aspx.cs file and replace

public override PageSslProtectionEnum SslProtected
        {
            get
            {
                return PageSslProtectionEnum.No;
            }
        }


with

public override PageSslProtectionEnum SslProtected
        {
            get
            {
                return PageSslProtectionEnum.Yes;
            }
        }


Then recompile the solution.

Same with other pages, if you want other pages to use SSL cetification "https" then add this in the .cs page

public override PageSslProtectionEnum SslProtected
        {
            get
            {
                return PageSslProtectionEnum.Yes;
            }
        }




P.S. Adding SSL certificate on all pages might make your website slower that is the reason SSL is used only for those pages which involves sensitive information, rest it's totally your choice.
13 years ago
Thank you,

How can I do when my customers click on their shoppingcart then they will be redirected to HTTPS shoppingcart.
13 years ago
Your welcome.

shoppingcart.aspx page is already using ssl certificate - if you click on shopping cart you will see "https" - like you mentioned above "Then I Click on "HTTPS://www.mysite.com/shoppingcart.aspx" , THERE IS NO PROBLEM :)"
13 years ago
Ok. But I want to say to you that ; the customers enter the HTTP site , then click to CART , then they going HTTP CART.

if My request is they enger the HTTP site , then click to CART and will go to HTTPS CART.

I dont know I can explain to you .

Thanks again.
13 years ago
If you want to show your customers that they are on a secured website that is using "https" then just add SSL certificate on your homepage (default.aspx)

by adding this code in default.aspx.cs

public override PageSslProtectionEnum SslProtected
        {
            get
            {
                return PageSslProtectionEnum.Yes;
            }
        }


P.S: After making these change - RECOMPILE your solution
13 years ago
Thank you , my request is ;

CUSTOMER BROWSE "HTTP://www.mysite.com" ,

THEN SHOPPING

CLICK SHOPPING CART , HAVE TO VIEW "HTTPS://www.mysite.com/shoppingcart.aspx"

if you described above is correct solution for this issue , then thank you , if is not then how ?
13 years ago
By the above solution when customer will view your website - they will see "httpS://www.yourwebsite.com/" and shopping cart will : https://www.yourwebsite.com/shoppingcart.aspx

I would recommend you to try it first then you will understand clearly that this will solve your problem (if this is what you're looking for).

If you're want customer to see  your website as "http://www.yourwebsite.com/" and shopping cart will : https://www.yourwebsite.com/shoppingcart.aspx (Then you don't have to do anything - your website is already working like that by default)

If still you have any problem - feel free to ask anything anytime or contact me and I'll certainly help you.
13 years ago
I'm very pleased your attention and quick response.
13 years ago
that's the all I want :)

1. Install SSL certificate
2. Open web.config file
3. Find "UseSSL" setting and set it "true"

thank you again for your all responses.
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.