XFileSharing Pro - usr_password=ENCODE(?,?)

Message
Author
dzimi83
Posts: 66
Joined: Mar 09, 2009 1:08 pm

usr_password=ENCODE(?,?)

#1 Postby dzimi83 » Mar 09, 2009 1:18 pm

Hello,

I am working on additional script to adding sold accounts which one was bought useing Dotpay Payment System.
I start writing it in php (i am not good in perl). Currently I stop on at SQL INSERT function.

Code: Select all

INSERT INTO Users SET usr_login='aaaa', usr_password=ENCODE('ccc','ccc'), usr_adm='0', usr_status='OK', usr_premium_expire=DATE_ADD(NOW(),INTERVAL 30 DAY), usr_add_login='0', usr_direct_downloads='0', usr_rapid_login='', usr_rapid_pass='', usr_points='8000', usr_created=NOW(), usr_lastlogin='0', usr_lastip='0', usr_email=''


Seems like I do it wrong. SQL function ENCODE() should work like:
ENCODE(str,pass_str) - Encrypt str using pass_str as the password.

In perl script (index.cgi) I didn't see the pass_str value, what should be there ? Which string should be used for crypt user passwd ?

User avatar
PilgrimX182
Posts: 2187
Joined: Mar 22, 2006 1:39 pm

#2 Postby PilgrimX182 » Mar 09, 2009 11:49 pm

pasword_salt from XFileConfig.pm

dzimi83
Posts: 66
Joined: Mar 09, 2009 1:08 pm

#3 Postby dzimi83 » Mar 10, 2009 3:28 am

Thanks. It's works. Greetings !


Return to “XFileSharing Pro”