I need a secured login script

Links for php scripts

Moderators: egami, macek, gesf

Post Reply

Sat Mar 25, 2006 2:50 am

Hi Friends,

I am new to PHP technology.I need a small requirement in PHP.
I am building a tool which needs login page.I don't want to use any database.But the password security should be high.I want to use encryption algorithms(md5,hash etc.). So please help me for making the script as per my requirements.

Please send me the scripts if u people already build it.


New php-forum User
New php-forum User
Posts: 243
Joined: Wed Feb 01, 2006 9:18 am
Location: Netherlands

Sat Mar 25, 2006 2:15 pm

If you don't want to use a database, the password will have to be stored somewhere else, eg a PHP script. However, that immediately makes the script less secure.

Your best bet is to secure the entire folder using .htaccess files (for apache) or IISPassword (IIS).


User avatar
Posts: 1716
Joined: Sun Dec 29, 2002 5:03 am
Location: Portugal / Sweden

Sun Apr 02, 2006 4:29 pm

Using some DB is the best option no doubt.
Like coditor said, if you're about to use Apache for that it can be also easy as you can put all user names/pass line by line in the .htpasswd.
You can also create a simple PHP script to handle that (insert/edit/remove).
Gonçalo "gesf" Fontoura

New php-forum User
New php-forum User
Posts: 101
Joined: Sun Feb 06, 2005 10:54 am

Fri Feb 01, 2008 10:28 pm

Hay gesf, Can u tell me about .htpasswd file. How can I read/write/edit that file & how can I access my site with that file. I never used that file. So, pls tell me from the begining. Thanks in Advance.

Post Reply