Welcome, Guest. Please Login or Register.
April 26, 2025, 02:02:20 PM
Home Help Search Log in Register
News: If you are still using YaBB SE, please consider upgrading to SMF as soon as possible.

YaBB SE Community  |  Development  |  Completed mods  |  [Beta 1.5.0] Proper Crypt Mod « previous next »
Pages: [1] Reply Ignore Print
Author Topic: [Beta 1.5.0] Proper Crypt Mod  (Read 2739 times)
GodFarmer
Noobie
*
Posts: 10


[Beta 1.5.0] Proper Crypt Mod
« on: December 29, 2002, 01:43:45 AM »
Reply with quote

Proper Crypt Mod
Version: 0.1 Alpha (proof of concept)

Author: GodFarmer

This is a mod to make the way crypt is used for encrypting passwords more secure.

Check my endless efforts in convincing the YaBB SE team of this for more info:
http://www.yabbse.org/community/index.php?board=142;action=display;threadid=16428

What is does:
Uses the crypt function as described in the PHP manual. This has the effect that password verification is backwards compatible for passwords stored by the old
procedure. When storing new passwords, what PHP considers as the default encryption type is used (probably MD5 on new systems) with a random salt.

modification.mod:
<file>
Reminder.php
</file>

<search>
$cryptpassword = crypt($password,substr($password,0,2));
</search>

<replace>
$cryptpassword = crypt($password);
</replace>

<file>
Sources/LogInOut.php
</file>

<search>
   $passwrd = crypt($passwrd, substr($passwrd, 0, 2));

   if (mysql_num_rows($request) == 0)
      fatal_error($txt[40] . ' - ' . htmlspecialchars($user) . ': ' . htmlspecialchars($attempt));
   else
   {
      $settings = mysql_fetch_row($request);
</search>

<replace>
   if (mysql_num_rows($request) == 0)
      fatal_error($txt[40] . ' - ' . htmlspecialchars($user) . ': ' . htmlspecialchars($attempt));
   else
   {
      $settings = mysql_fetch_row($request);
      $passwrd = crypt($passwrd, $settings[0]);
</replace>

<file>
Sources/Profile.php
</file>

<search>
      if ($settings[0] != crypt($member['oldpasswrd'], substr($member['oldpasswrd'], 0, 2)))
</search>

<replace>
      if ($settings[0] != crypt($member['oldpasswrd'], $settings[0]))
</replace>

<search>
         $queryPasswdPart="passwd='" . crypt($member['passwrd1'], substr($member['passwrd1'], 0, 2)) . "',";
</search>

<replace>
         $queryPasswdPart="passwd='" . crypt($member['passwrd1']) . "',";
</replace>

<search>
         $queryPasswdPart = "passwd='" . crypt($pswd, substr($pswd, 0, 2)) . "'";
</search>

<replace>
         $queryPasswdPart = "passwd='" . crypt($pswd) . "'";
</replace>

<file>
Sources/Register.php
</file>

<search>
   $queryPasswdPart = crypt($member['passwrd1'], substr($member['passwrd1'], 0, 2));
</search>

<replace>
   $queryPasswdPart = crypt($member['passwrd1']);
</replace>

modification.txt
Proper Crypt Mod
0.1 Alpha

Author: GodFarmer

This is a mod to make the way crypt is used for encrypting passwords more secure.

See my endless efforts in convincing the YaBB SE team of this for more info:
http://www.yabbse.org/community/index.php?board=142;action=display;threadid=16428

What is does:
Uses the crypt function as described in the PHP manual. This has the effect that
password verification is backwards compatible for passwords stored by the old
procedure. When storing new passwords, what PHP considers as the default encryption
type is used (probably MD5 on new systems) with a random salt.
Logged
[Unknown]
Global Moderator
YaBB God
*****
Posts: 7830


ICQ - 179721867unknownbrackets@hotmail.com WWW
Re:[Beta 1.5.0] Proper Crypt Mod
« Reply #1 on: December 29, 2002, 03:54:13 AM »
Reply with quote

Well, I don't know if you mind... but I put this up on my package server.

Package Server: http://gbaetc.homeip.net/yypack
YaBBpak: http://gbaetc.homeip.net/yypack/propercrypt.mod.yp
Boardmod: http://gbaetc.homeip.net/yypack/propercrypt.mod
Zip File: http://gbaetc.homeip.net/yypack/propercrypt.zip

This way it's uninstallable.... if you mind I'll take it off.

-[Unknown]
Logged
GodFarmer
Noobie
*
Posts: 10


Re:[Beta 1.5.0] Proper Crypt Mod
« Reply #2 on: December 29, 2002, 09:33:53 AM »
Reply with quote

Thanks!
Bruno.
Logged
Pages: [1] Reply Ignore Print 
YaBB SE Community  |  Development  |  Completed mods  |  [Beta 1.5.0] Proper Crypt Mod « previous - next »
 


Powered by MySQL Powered by PHP YaBB SE Community | Powered by YaBB SE
© 2001-2003, YaBB SE Dev Team. All Rights Reserved.
SMF 2.1.4 © 2023, Simple Machines
Valid XHTML 1.0! Valid CSS

Page created in 0.196 seconds with 19 queries.