PhotoPost Photo Gallery Sales PhotoPost Sales Toll Free Phone Number
Mon-Fri 9am-4pm EST
  PhotoPost Photo Sharing Photo Gallery    Visualize community tm
| | | | | | | | |

Go Back   PhotoPost Community > PhotoPost Support > PhotoPost Pro Support Forums > Photopost Pro Bug Reports

Photopost Pro Bug Reports Post post installation PhotoPost Pro problems here.

Reply
 
LinkBack Thread Tools Rate Thread Display Modes
Old July 17th, 2006, 01:44 AM   #1 (permalink)
Junior Member
Verified Customer
 
Join Date: Apr 2005
Location: San Jose, CA
Posts: 8
Bad SQL generation in move_image_cat

My PhotoPost installation (v5.3) emailed me a notice the other day that it had received an SQL error when trying to submit the following SQL command:

REPLACE INTO pp_admlog (adminuser,ip,datestamp,description) VALUES ('Mackey's Things','72.166.163.248','1152989903','Moved Image: Cosmo_stickers.jpg from 500 to 580')

Notice that the adminuser value is Mackey's Things, which is not properly escaped for insertion into SQL.

I've looked through the PhotoPost source and discovered that pp-inc.php includes a function, adminlog, that correctly escapes its data and inserts a record into the admlog table.

I further discovered that pp-inc.php has another function, move_image_cat, that also inserts records in the admlog table but does not correctly escape its data.

I further discovered that adm-misc.php includes code in three places (near lines 1441, 1680, 2573) that inserts records into the admlog table and correctly escapes its data but does it nakedly.

To fix the observed SQL error, I have patched move_image_cat to call adminlog instead of trying to perform its own record insertion.

For consistency and future-proofing, I have also patched all three locations in adm-misc.php to call adminlog instead of performing their own record insertion.

Thought you'd be interested in applying these same patches to the PhotoPost mainline code.
berdahl is offline   Reply With Quote
Old July 17th, 2006, 06:18 AM   #2 (permalink)
Photopost Developer
Verified Customer
 
Chuck S's Avatar
 
Join Date: Jun 2002
Location: Abingdon,MD
Posts: 71,650
ok thanks
__________________
Photopost Developer and Support Engineer

Please do not PM me for support or sales questions. Thank you for your understanding.
Chuck S is offline   Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Enable the order prints functions in PP? rbl Photopost Pro How Do I...? 17 January 19th, 2006 12:43 PM
2 Fatal Errors from Calling undefined functions fonzerelli_79 ReviewPost Installation & Upgrades 2 November 2nd, 2005 06:24 PM
where in the world are these functions/classes located??? Ginger2 Photopost Pro How Do I...? 1 March 29th, 2005 09:01 AM


All times are GMT -5. The time now is 01:33 PM.

Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0