[SOLVED] error when trying to delete item

shuckyd

Joined: 2007-03-30
Posts: 12
Posted: Fri, 2010-11-05 02:36

I'm really getting annoyed with my install of Gallery 2 now. Seems as though I had one of my staff's FTP credentials comprimised and pretty much any .php header had a base64 decode script/virus/thing on it and it took most of a weekend to go through all the files to clean them up. I dont know if this has anything to do with that incident, but what's happening is I cant click the option under the picture to delete the item instead I get this error in my status bar (IE 8 and FF)

Any help on how to get this to work again would be greatly appreciated, I really dont want to have to reinstall gallery and risk the customizations I have done to it. I am suppose to be posting pictures for a wedding right now and I want the user to be able to delete them, but this isnt working.

Webpage error details

User Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.1; WOW64; Trident/4.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; InfoPath.2; Creative AutoUpdate v1.40.01)
Timestamp: Fri, 5 Nov 2010 01:22:47 UTC

Message: Unterminated string constant
Line: 2
Char: 13
Code: 0
URI: http://www.uniqueimagesinc.com/gallery2/main.php?g2_view=core.ItemDeleteJs&g2_lang=en_US

Message: Object expected
Line: 845
Char: 58
Code: 0
URI: http://www.uniqueimagesinc.com/gallery2/main.php?g2_itemId=15185

 
suprsidr
suprsidr's picture

Joined: 2005-04-17
Posts: 8339
Posted: Fri, 2010-11-05 02:41
 
shuckyd

Joined: 2007-03-30
Posts: 12
Posted: Fri, 2010-11-05 11:05

well it looks like 109 files are listed in there, I see some have to do with modules like CheckoutPDF that I've added, whats the best way to replace these...?

lib/adodb/drivers/adodb-ado5.inc.php
lib/adodb/drivers/adodb-ado_mssql.inc.php
lib/adodb/drivers/adodb-db2.inc.php
lib/adodb/drivers/adodb-mysql.inc.php
lib/adodb/drivers/adodb-oracle.inc.php
lib/adodb/drivers/adodb-pdo.inc.php
lib/adodb/drivers/adodb-pdo_sqlite.inc.php
lib/adodb/drivers/adodb-postgres64.inc.php
lib/adodb/drivers/adodb-postgres7.inc.php
lib/adodb/perf/perf-db2.inc.php
lib/adodb/perf/perf-mssql.inc.php
lib/adodb/perf/perf-mysql.inc.php
lib/adodb/perf/perf-postgres.inc.php
lib/pear/HTMLSax3.php
lib/smarty/internals/core.assemble_plugin_filepath.php
lib/smarty/internals/core.assign_smarty_interface.php
lib/smarty/internals/core.create_dir_structure.php
lib/smarty/internals/core.display_debug_console.php
lib/smarty/internals/core.get_include_path.php
lib/smarty/internals/core.get_microtime.php
lib/smarty/internals/core.get_php_resource.php
lib/smarty/internals/core.is_secure.php
lib/smarty/internals/core.is_trusted.php
lib/smarty/internals/core.load_plugins.php
lib/smarty/internals/core.load_resource_plugin.php
lib/smarty/internals/core.process_cached_inserts.php
lib/smarty/internals/core.process_compiled_include.php
lib/smarty/internals/core.read_cache_file.php
lib/smarty/internals/core.rm_auto.php
lib/smarty/internals/core.run_insert_handler.php
lib/smarty/internals/core.smarty_include_php.php
lib/smarty/internals/core.write_cache_file.php
lib/smarty/internals/core.write_compiled_include.php
lib/smarty/internals/core.write_compiled_resource.php
lib/smarty/internals/core.write_file.php
lib/smarty/plugins/block.textformat.php
lib/smarty/plugins/compiler.assign.php
lib/smarty/plugins/function.assign_debug_info.php
lib/smarty/plugins/function.config_load.php
lib/smarty/plugins/function.counter.php
lib/smarty/plugins/function.cycle.php
lib/smarty/plugins/function.debug.php
lib/smarty/plugins/function.eval.php
lib/smarty/plugins/function.html_checkboxes.php
lib/smarty/plugins/function.html_image.php
lib/smarty/plugins/function.html_options.php
lib/smarty/plugins/function.html_radios.php
lib/smarty/plugins/function.html_select_date.php
lib/smarty/plugins/function.html_select_time.php
lib/smarty/plugins/function.html_table.php
lib/smarty/plugins/function.mailto.php
lib/smarty/plugins/function.math.php
lib/smarty/plugins/function.popup.php
lib/smarty/plugins/function.popup_init.php
lib/smarty/plugins/modifier.capitalize.php
lib/smarty/plugins/modifier.cat.php
lib/smarty/plugins/modifier.count_characters.php
lib/smarty/plugins/modifier.count_paragraphs.php
lib/smarty/plugins/modifier.count_sentences.php
lib/smarty/plugins/modifier.count_words.php
lib/smarty/plugins/modifier.date_format.php
lib/smarty/plugins/modifier.debug_print_var.php
lib/smarty/plugins/modifier.default.php
lib/smarty/plugins/modifier.escape.php
lib/smarty/plugins/modifier.indent.php
lib/smarty/plugins/modifier.lower.php
lib/smarty/plugins/modifier.nl2br.php
lib/smarty/plugins/modifier.regex_replace.php
lib/smarty/plugins/modifier.replace.php
lib/smarty/plugins/modifier.spacify.php
lib/smarty/plugins/modifier.string_format.php
lib/smarty/plugins/modifier.strip.php
lib/smarty/plugins/modifier.strip_tags.php
lib/smarty/plugins/modifier.truncate.php
lib/smarty/plugins/modifier.upper.php
lib/smarty/plugins/modifier.wordwrap.php
lib/smarty/plugins/outputfilter.trimwhitespace.php
lib/smarty/plugins/shared.escape_special_chars.php
lib/smarty/plugins/shared.make_timestamp.php
lib/smarty_plugins/modifier.print_r.php
lib/support/index.php
lib/tools/po/extract.php
lib/tools/po/trim-po.php
modules/checkoutpdfinvoice/lib/fpdf/decoders/ASCII85Decode.php
modules/checkoutpdfinvoice/lib/fpdf/decoders/LZWDecode.php
modules/checkoutpdfinvoice/lib/fpdf/font/courier.php
modules/checkoutpdfinvoice/lib/fpdf/font/helvetica.php
modules/checkoutpdfinvoice/lib/fpdf/font/helveticab.php
modules/checkoutpdfinvoice/lib/fpdf/font/helveticabi.php
modules/checkoutpdfinvoice/lib/fpdf/font/helveticai.php
modules/checkoutpdfinvoice/lib/fpdf/font/makefont/makefont.php
modules/checkoutpdfinvoice/lib/fpdf/font/symbol.php
modules/checkoutpdfinvoice/lib/fpdf/font/times.php
modules/checkoutpdfinvoice/lib/fpdf/font/timesb.php
modules/checkoutpdfinvoice/lib/fpdf/font/timesbi.php
modules/checkoutpdfinvoice/lib/fpdf/font/timesi.php
modules/checkoutpdfinvoice/lib/fpdf/font/zapfdingbats.php
modules/checkoutpdfinvoice/lib/fpdf/fpdf.php
modules/checkoutpdfinvoice/lib/fpdf/fpdf_tpl.php
modules/checkoutpdfinvoice/lib/fpdf/fpdi.php
modules/checkoutpdfinvoice/lib/fpdf/fpdi_pdf_parser.php
modules/checkoutpdfinvoice/lib/fpdf/pdf_context.php
modules/checkoutpdfinvoice/lib/fpdf/pdf_parser.php
modules/checkoutpdfinvoice/lib/fpdf/wrapper_functions.php
modules/rewrite/data/path_info/index.php
modules/webdav/lib/HTTP/WebDAV/Server.php
modules/webdav/lib/HTTP/WebDAV/Tools/_parse_lockinfo.php
modules/webdav/lib/HTTP/WebDAV/Tools/_parse_propfind.php
modules/webdav/lib/HTTP/WebDAV/Tools/_parse_proppatch.php

 
suprsidr
suprsidr's picture

Joined: 2005-04-17
Posts: 8339
Posted: Fri, 2010-11-05 11:27

download the version of gallery you currently have installed, and replace the infected directories/files.
As you've said, I would not worry about checkoutPDF

-s
FlashYourWeb and Your Gallery with The E2 XML Media Player for Gallery2

 
shuckyd

Joined: 2007-03-30
Posts: 12
Posted: Fri, 2010-11-05 13:14

Gallery version = 2.3 core 1.3.0
API = Core 7.54, Module 3.9, Theme 2.6, Embed 1.5
PHP version = 5.2.14 cgi-fcgi
Webserver = Apache

Yay, I'm going to go look for that version and create a temp directory on the webserver and install it to there, then copy over the necessary files :)

EDIT: I cant download 2.3 anymore or can I? I see 2.26 and 2.3.1 here: http://codex.gallery2.org/Gallery2:Download#Packages

 
suprsidr
suprsidr's picture

Joined: 2005-04-17
Posts: 8339
Posted: Fri, 2010-11-05 13:49

go ahead and upgrade to 2.3.1 - no need to install a separate copy.
FAQ: How to upgrade Gallery2?

-s
FlashYourWeb and Your Gallery with The E2 XML Media Player for Gallery2

 
shuckyd

Joined: 2007-03-30
Posts: 12
Posted: Fri, 2010-11-05 13:55

Really... upgrade live??? I already put something up at www.uniqueimagesinc.com/TESTG2/gallery2/ which is 2.3.1 and I was going to copy and paste files. I was thinking about updating, but I have alot of custom and "commerce" stuff done and I want this to not be overwritten. Now I have used "local" folders for many things like the banners, etc.

 
suprsidr
suprsidr's picture

Joined: 2005-04-17
Posts: 8339
Posted: Fri, 2010-11-05 14:01

make a backup of your custom modules/themes ect and upgrade.
2.3.1 was just a minor update to address php 5.3.x compatibility issues

-s
FlashYourWeb and Your Gallery with The E2 XML Media Player for Gallery2

 
shuckyd

Joined: 2007-03-30
Posts: 12
Posted: Fri, 2010-11-05 18:00

so even with an upgrade I still see 109 tampered files... so I should still go through and replace them manually?

My system readout still says:
Gallery URL = http://www.uniqueimagesinc.com/gallery2/main.php
Gallery version = 2.3 core 1.3.0
API = Core 7.54, Module 3.9, Theme 2.6, Embed 1.5
PHP version = 5.2.14 cgi-fcgi

I probably didnt do the upgrade properly. Maybe I can do it with the preinstaller.php file

 
shuckyd

Joined: 2007-03-30
Posts: 12
Posted: Fri, 2010-11-05 21:15

Tis fixed, there's approximately 20 files that werent upgraded, but they dealt with the checkoutPDF that I modded. Yay the upgrade to 2.3.1 worked fine

 
Dayo

Joined: 2005-11-04
Posts: 1642
Posted: Fri, 2010-11-05 21:22

The way you should do it is as follows:
Backup your DB.
Rename your existing gallery2 folder to old_gallery2
Download 2.3.1 and extract as gallery2
Copy your current theme files into the new gallery2 folder (Important!)
Navigate to your yoursite/gallery2
When you are redirected to the install process, fill in your existing db details and proceed.
You will be bounced to the upgrade bit at some point and you can just proceed.
Copy your other custom stuff across
Delete the old_gallery2 after you are happy everything in working as it should.
--
dakanji.com

 
Dayo

Joined: 2005-11-04
Posts: 1642
Posted: Fri, 2010-11-05 21:22

See it was fixed while I was posting.

--
dakanji.com

 
shuckyd

Joined: 2007-03-30
Posts: 12
Posted: Sat, 2010-11-06 02:43

Thank you all for your help! :)