Current time: 11-16-2024, 06:50 PM Hello There, Guest! (LoginRegister)


Post Reply 
ftp passwd= *0
Author Message
saturnsuper Offline
Newbie
*

Posts: 7
Joined: Nov 2008
Reputation: 0
Post: #11
RE: ftp passwd= *0
I set
if (CRYPT_BLOWFISH == 1) {
$length = 16;
$pre = '$2$';

But problem didn't resolve!
(This post was last modified: 12-08-2008 03:03 AM by saturnsuper.)
12-08-2008 02:43 AM
Find all posts by this user Quote this message in a reply
joximu Offline
helper
*****
Moderators

Posts: 7,024
Joined: Jan 2007
Reputation: 92
Post: #12
RE: ftp passwd= *0
Hi

I don't know your system. Obviously there's something wrong, either a apckage is missing or your system does not like crypting or something else.

You have to be a little bit more active to solve the problem.

Maybe you try to find the bug by exercising with the php-crypt command.
eg. as in the php documentation:
Code:
<?php
if (CRYPT_STD_DES == 1) {
    echo 'Standard DES: ' . crypt('rasmuslerdorf', 'rl') . "\n";
}

if (CRYPT_EXT_DES == 1) {
    echo 'Extended DES: ' . crypt('rasmuslerdorf', '_J9..rasm') . "\n";
}

if (CRYPT_MD5 == 1) {
    echo 'MD5:          ' . crypt('rasmuslerdorf', '$1$rasmusle$') . "\n";
}

if (CRYPT_BLOWFISH == 1) {
    echo 'Blowfish:     ' . crypt('rasmuslerdorf', '$2a$07$rasmuslerd...........$') . "\n";
}
?>

and compare the output with the one in the docu:
http://ch2.php.net/manual/en/function.crypt.php

/J
12-08-2008 05:39 PM
Visit this user's website Find all posts by this user Quote this message in a reply
rurk Offline
Junior Member
*

Posts: 18
Joined: Apr 2009
Reputation: 0
Post: #13
RE: ftp passwd= *0
It takes place because there is an error in a code. In the file of calc-functions.php which is in gui/include/ line 191
PHP Code:
$salt .= chr(mt_rand($min$max)); 
change to
PHP Code:
$salt chr(mt_rand($min$max)); 
10-19-2009 10:54 PM
Find all posts by this user Quote this message in a reply
joximu Offline
helper
*****
Moderators

Posts: 7,024
Joined: Jan 2007
Reputation: 92
Post: #14
RE: ftp passwd= *0
ah - you mean here?

Code:
for ($i = 0; $i < $length; $i++) {
        $salt .= chr(mt_rand($min, $max));
    }

I would not say that the ".=" is wrong - you want to add characters to the string - not overwrite...

btw. it's line 119 not 191... :-)

/J
10-19-2009 11:56 PM
Visit this user's website Find all posts by this user Quote this message in a reply
rurk Offline
Junior Member
*

Posts: 18
Joined: Apr 2009
Reputation: 0
Post: #15
RE: ftp passwd= *0
(10-19-2009 11:56 PM)joximu Wrote:  btw. it's line 119 not 191... :-)

/J

And indeed 119, am sorry! I had the same problem in a version 1.0.0 it and remained in a version 1.0.2. In 1.0.0 I rewrote a code that it is possible it was to work even with Plaintext. After an update to 1.0.2 a problem appeared again, and only since cleaned a point all decided! I do not talk that it so but for me so it works(it is tested on a version 1.0.0)
10-20-2009 12:27 AM
Find all posts by this user Quote this message in a reply
joximu Offline
helper
*****
Moderators

Posts: 7,024
Joined: Jan 2007
Reputation: 92
Post: #16
RE: ftp passwd= *0
Most of the problems were because of blowfish.

The block sometimes need to be like this:

if (CRYPT_BLOWFISH == 2) {
$length = 13;
$pre = '$2a$';
}

-> $2a$ instead of $2$

/J
10-20-2009 12:31 AM
Visit this user's website Find all posts by this user Quote this message in a reply
rurk Offline
Junior Member
*

Posts: 18
Joined: Apr 2009
Reputation: 0
Post: #17
RE: ftp passwd= *0
Possibly, but I look on Mysql. When a point costs that in the field a password stands ":", when take away a point the field is filled characters.
10-20-2009 12:56 AM
Find all posts by this user Quote this message in a reply
Post Reply 


Forum Jump:


User(s) browsing this thread: 6 Guest(s)