Solved

Apache and SSL, basic question

Posted on 2006-06-09
6
201 Views
Last Modified: 2010-03-04
I am building a website using PHP and its going to live on an Apache server. There are certain parts of the site that are just content, they don't need to be secure but there are a few pages like the login and settings pages that I'd like to be secure. I've heard about SSL and I was wondering. How does it work? Do I need to add special code to my PHP code or is it something that I just do on the server.

For example, say my source file is login.php, how do I just tell Apache to use SSL on that? Sorry if this is a pretty basic and newbie question but I am lost when it comes to this sort of stuff.
0
Comment
Question by:Linky
  • 3
  • 3
6 Comments
 
LVL 15

Accepted Solution

by:
periwinkle earned 125 total points
ID: 16870749
Assuming that you have SSL set up on your server, with a certificate, etc., to access via SSL is simply a matter of changing the url from:

http://www.yourdomain.com/login.php

to

https://www.yourdomain.com/login.php

(i.e. from http:// protocol to https:// protocol).
0
 
LVL 2

Author Comment

by:Linky
ID: 16871131
then what is stopping people from just typing http instead of https
0
 
LVL 15

Expert Comment

by:periwinkle
ID: 16871485
Nothing, unless you code preventatively!
0
Microsoft Certification Exam 74-409

Veeam® is happy to provide the Microsoft community with a study guide prepared by MVP and MCT, Orin Thomas. This guide will take you through each of the exam objectives, helping you to prepare for and pass the examination.

 
LVL 2

Author Comment

by:Linky
ID: 16871801
And how can that be done, so that even if they type http://whatever it will use SSL anyway. I'm using PHP but I doubt that matters since this is mainly dealing with the server.
0
 
LVL 15

Expert Comment

by:periwinkle
ID: 16872296
It won't - unless you redirect the http:// request to a https:// request.  But from what you have said, you're only having a few pages that are ssl - if you LINK to them as https:// then they'll be secure!
0
 
LVL 2

Author Comment

by:Linky
ID: 16885108
Sounds good, thanks for the help.
0

Featured Post

What Security Threats Are You Missing?

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

Suggested Solutions

Title # Comments Views Activity
Php Remote Files 13 56
new line in php on linux server 6 169
apache and php 3 91
Problem to go to page 12 67
If you are running a LAMP infrastructure, this little code snippet is very helpful if you are serving lots of HTML, JavaScript and CSS-related information. The mod_deflate module, which is part of the Apache 2.2 application, provides the DEFLATE…
If your site has a few sections that need to be secure when data is transmitted between the server and local computer, such as a /order/ section for ordering or /customer/ which contains customer data, etc it would of course be recommended to secure…
In this seventh video of the Xpdf series, we discuss and demonstrate the PDFfonts utility, which lists all the fonts used in a PDF file. It does this via a command line interface, making it suitable for use in programs, scripts, batch files — any pl…
Access reports are powerful and flexible. Learn how to create a query and then a grouped report using the wizard. Modify the report design after the wizard is done to make it look better. There will be another video to explain how to put the final p…

760 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

19 Experts available now in Live!

Get 1:1 Help Now