Add users through script

Need help with FileZilla Server? Something does not work as expected? In this forum you may find an answer.

Moderator: Project members

Post Reply
Message
Author
bamnet
504 Command not implemented
Posts: 6
Joined: 2004-05-22 19:56

Add users through script

#1 Post by bamnet » 2004-05-22 19:58

Is there any way to add user through something like a php script? My server is running on windows 2003 with php but working with the xml file shouldn't be too bad... except for the password. Any ideas?

User avatar
botg
Site Admin
Posts: 35562
Joined: 2004-02-23 20:49
First name: Tim
Last name: Kosse

#2 Post by botg » 2004-05-22 21:35

Editing the xml file is the easiest solution.

After making changes to the xml file, call FileZilla Server.exe with the /reload-config switch.

About the passwords: FileZilla Server does not store the passwords directly, it just stores their MD5 hash.

bamnet
504 Command not implemented
Posts: 6
Joined: 2004-05-22 19:56

#3 Post by bamnet » 2004-05-23 02:20

so how would i go about setting a users password?

eddan
226 Transfer OK
Posts: 423
Joined: 2004-02-25 08:44
Location: Norway

#4 Post by eddan » 2004-05-23 08:25


User avatar
botg
Site Admin
Posts: 35562
Joined: 2004-02-23 20:49
First name: Tim
Last name: Kosse

#5 Post by botg » 2004-05-23 11:18

That won't help, that's only for the client.


To change the password for the server, edit the XML file like you normally do in php. Use something like md5($password) to create the md hash of the pw and store it in the xml file. See http://www.php.net/md5

bamnet
504 Command not implemented
Posts: 6
Joined: 2004-05-22 19:56

#6 Post by bamnet » 2004-05-23 13:36

So I would run the users password throught the md5($password _entered) command in php and put that in the xml file? Also, how can i decypt the password? So i could email it to users if they forgot?

patrickc
504 Command not implemented
Posts: 10
Joined: 2004-04-13 17:48
Location: Geisenheim, Germany

#7 Post by patrickc » 2004-05-23 16:03

Hello bamnet,
bamnet wrote:So I would run the users password throught the md5($password _entered) command in php and put that in the xml file?
Right.
bamnet wrote:Also, how can i decypt the password? So i could email it to users if they forgot?
MD5 creates a checksum, it does not encode a string, also you can't convert this checksum into the corresponding string.

If you want to check if a entered password is right and you have stored the password as a MD5 checksum, you have to create the checksum of the entered password. Then, you compare it to the stored checksum. If the checksum correspond, the password is right.

Regards
Patrick Canterino

bamnet
504 Command not implemented
Posts: 6
Joined: 2004-05-22 19:56

#8 Post by bamnet » 2004-07-15 19:11

Are there any scripts pre-written i could use in exchange for a gmail account?

User avatar
botg
Site Admin
Posts: 35562
Joined: 2004-02-23 20:49
First name: Tim
Last name: Kosse

#9 Post by botg » 2004-07-15 19:50

OT: Why is every using that crappy gmail?

bamnet
504 Command not implemented
Posts: 6
Joined: 2004-05-22 19:56

#10 Post by bamnet » 2004-07-16 00:04

it's got the most storage....... and google's in charge of it :P

User avatar
botg
Site Admin
Posts: 35562
Joined: 2004-02-23 20:49
First name: Tim
Last name: Kosse

#11 Post by botg » 2004-07-16 06:25

More storage for spam ^^
Also they read your mails to add text ads, which can't easily be filtered out. And last but not least: No POP3 access.
"All your mail are belong to us"

bamnet
504 Command not implemented
Posts: 6
Joined: 2004-05-22 19:56

#12 Post by bamnet » 2004-07-16 12:12

no actual people read the mail... it's just like their ad delivery on web searches. SPAM has it's own folder and I have gotten NO spam in the 2 months i've been using it 8) . Who needs pop access when you've got the best webmail?


About that script....... :?: :?:

Post Reply