Ravens PHP Scripts: Forums
 

 

View next topic
View previous topic
Post new topic   Reply to topic    Ravens PHP Scripts And Web Hosting Forum Index -> MySQL
Author Message
sixonetonoffun
Spouse Contemplates Divorce



Joined: Jan 02, 2003
Posts: 2496

PostPosted: Tue Mar 09, 2004 7:34 am Reply with quote

I just rewrote a login/validation password function using the AES_CRYPT() AES_DECRYPT() functions. Sure is slick too bad it is only in MySQL 4.1 and up no sense in writing 2 login functions to maintain compatability with the popular 3.23x series. (Well I might I really like this function).

Biggest plus is unlike other encryption methods it should be cross platform portable without any hassles.

But once 3.23 is phased AES_ECRYPT will be fast and simple to implement.
 
View user's profile Send private message
Rikk03
Worker
Worker



Joined: Feb 16, 2004
Posts: 164

PostPosted: Tue Mar 09, 2004 11:25 am Reply with quote

Nice - I would like that for my own site, - is it really that easy to rewrite?
 
View user's profile Send private message
sixonetonoffun







PostPosted: Tue Mar 09, 2004 12:25 pm Reply with quote

Edited:
There was fundimental flaws in this code. Will post new code as soon as I get a chance. (Tonight?)

Ok here is a demo like package.
SUA.ZIP

I did change so that a cookie is required as a third check uses a hash not an IP so should be aol compatable? Is just a nice little demo not bullet proof. It also show KSES in a very basic use processing forms lol.

I believe all the major bugs are out of the basic functions and authentification is a little crude but I think very effective. Some error messages should be changed ect.. to clean it up for actual use.

Peter


Last edited by sixonetonoffun on Mon Mar 15, 2004 11:30 pm; edited 2 times in total 
sixonetonoffun







PostPosted: Tue Mar 09, 2004 4:13 pm Reply with quote

Got around setting an email cookie by adding this code maybe explode()chop() would be better?
Code:


list($user_email, $trash) = explode("::", $hash);
$email = $user_email;

to verify just above
$check2 = $hash;
At the beginning. This works slick because $hash is the users email address and $trash adds a unique string to the session and cookie. $trash is the $email (user email) $passwd (encrypted) using $password (encrypted as Salt) none of which can be decoded even if someone could split it down without the original Salt in this example $sitekey.
 
Rikk03







PostPosted: Tue Mar 09, 2004 5:42 pm Reply with quote

I know just the thing to test this on...........interesting..........thanks for the Encrypt 101
 
sixonetonoffun







PostPosted: Tue Mar 09, 2004 7:25 pm Reply with quote

lol ya just just be sure to add something to the salt thats unique to the user I used email and it works fine. Comes out like this the same password from 3 different users.
s7£YkÔŒbOVp‡a—²
€£î^ûGØ$ûÕÔ
Ý!lu.ñ.r}Ϻ„ •

Now thats also so my password here so ... if someone cracks that Mr. Green
The egg is on my face.
 
sixonetonoffun







PostPosted: Mon Mar 15, 2004 11:35 pm Reply with quote

Bounce fixed issues/errors and packed up a simple demo see above post sua.zip

If any huge bugs let me know. I'm just about ready to try something like this on a site.
 
Display posts from previous:       
Post new topic   Reply to topic    Ravens PHP Scripts And Web Hosting Forum Index -> MySQL

View next topic
View previous topic
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum


Powered by phpBB © 2001-2007 phpBB Group
All times are GMT - 6 Hours
 
Forums ©