Learn how to a build a cloud-first strategyRegister Now


PHP Security Session Manager Example

Posted on 2012-09-11
Medium Priority
Last Modified: 2012-09-21
Hi guys,

I have a XML Request webservice that i must first authenticate users on, can somebody provide me with an example of a secure way to preserve the session of the user to keep them logged in for a time and request they log in if they are not logged in on certain pages.

This should be in PHP Please.
This should be secure please.

Thanks a ton.
Question by:EasyToHelp
1 Comment
LVL 111

Accepted Solution

Ray Paseur earned 2000 total points
ID: 38387234
You might want to consider this:

If you just put the service behind HTTPS and require the client to furnish an API key, that might be adequate for many applications. Just a thought... ~Ray

Featured Post

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction This article is intended for those who are new to PHP error handling (https://www.experts-exchange.com/articles/11769/And-by-the-way-I-am-New-to-PHP.html).  It addresses one of the most common problems that plague beginning PHP develop…
Many old projects have bad code, but the budget doesn't exist to rewrite the codebase. You can update this code to be safer by introducing contemporary input validation, sanitation, and safer database queries.
Explain concepts important to validation of email addresses with regular expressions. Applies to most languages/tools that uses regular expressions. Consider email address RFCs: Look at HTML5 form input element (with type=email) regex pattern: T…
The viewer will learn how to look for a specific file type in a local or remote server directory using PHP.
Suggested Courses
Course of the Month21 days, 3 hours left to enroll

810 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