bugphpGroupWare - Bugs: bug #3374, Bad SQL and poor relation in...

 
 

You are not allowed to post comments on this tracker with your current authentication level.

bug #3374: Bad SQL and poor relation in /registration/inc/class.soreg.inc.php

Submitted by:  Kai Hofmann <powerstat>
Submitted on:  Tue 29 Apr 2003 09:06:03 AM UTC  
 
Item Group:  SVN trunk (dev code) Category:  registration
Severity:  3 - Normal Priority:  3 - Low
Status:  None Privacy:  Public
Assigned to:  Joseph Engo <jengo> Open/Closed:  Open
Component Version:  None Operating System:  None
Reproducibility:  Every Time Planned Release:  0.9.18.000
Fixed Release: 

Wed 21 Apr 2004 08:10:46 AM UTC, comment #2:

jengo's app. registration was not included in 16 afaik.

Dave Hall <skwashd>
Project Administrator
Wed 21 Apr 2004 07:42:29 AM UTC, comment #1:

is this still valid?
Kai, did you provide a patch?

Dr. Christian Böttger <cboettger>
Tue 29 Apr 2003 09:06:03 AM UTC, original submission:

The SQL statement I found here is wrong - because in SQL

phpgw_addressbook.lid='*$account_lid*'

is not what you want - correct it must be:

phpgw_addressbook.lid like '%$account_lid%'

last but not least referencing two tables in this way is absolutly evil! primary and foreign keys should always
be of the same type without a pattern matching!

$GLOBALS['phpgw']->db->query("select * from phpgw_accounts, phpgw_addressbook where account_lid='$account_lid' and phpgw_addressbook.lid='*$account_lid*'",__LINE__,__FILE__);
./registration/inc/class.soreg.inc.php

Kai Hofmann <powerstat>

 

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

CC list is empty

 

Do you think this task is very important?
If so, you can add your encouragement to it.
This task has 0 encouragements so far.

Only logged-in users can vote.

 

 

 

Follow 6 latest changes.

Date Changed by Updated Field Previous Value => Replaced by
2004-07-15 skwashd Planned ReleaseNone => 0.9.18.000
2004-04-21 skwashd Priority5 - Normal => 3 - Low
    Assigned toskwashd => jengo
2004-04-21 cboettger Assigned toNone => skwashd
2003-04-29 skwashd ReproducibilityNone => (Error - Not Found)
    SummaryBad SQL and relation usage =>

Back to the top


Powered by Savane 3.3