Jump to content

System Error Log


vidmarc

Recommended Posts

I seem to have a few of these errors popping up - is it anything to wory about?

File: [user.class.php] Line: [367] "INSERT INTO `CubeCart_customer` ---

File: [user.class.php] Line: [705] "INSERT INTO `CubeCart_customer` ---

Some of these errors appear to be caused via Russian spammers signing up for accounts.

Link to comment
Share on other sites

No and yes.

No, if it's junk registrations, who cares.

Yes, in that, even with missing data, the Database class, insert() function, or the code that validates the POSTed values, should be correctly handling bad or missing data. The fact that an error is being generated means something is not doing its job correctly or completely.

Please let us see a complete error message, with any emails, addresses, etc, xxxxxx'd out.

Link to comment
Share on other sites

Yesterday, 13:49 	File: [user.class.php] Line: [367] "INSERT INTO `CubeCart_customer` (`title`,`first_name`,`last_name`,`email`,`phone`,`mobile`,`password`,`new_password`,`ip_address`,`registered`,`type`) VALUES ('Herr','Jücel','*****','*****@emailn.de','*****,'*****','42176ca5015ccd9e7c4d91356d7d513e','0','188.100.190.68','1431607753','2');" - Duplicate entry '*****@emailn.de' for key 'email'
	12 May 2015, 03:36 	File: [user.class.php] Line: [705] "INSERT INTO `CubeCart_customer` (`title`,`first_name`,`last_name`,`email`,`phone`,`mobile`,`password`,`salt`,`registered`,`ip_address`) VALUES ('Http://www.itinteractiveservices.com/products-3136.htmlrn','HermanPypeXF','HermanPypeXF','[email protected]','123456','Persuit of Happiness','a917f7e4fe637bd1af45dd32d621724b88ecbf17e7c8f426109fd13188fef9ed293e71a91a62054ee10922d082eef777a89412a31c878254eeacb29f98861206','1bc7dd02','1431398192','199.15.233.176');" - Duplicate entry '[email protected]' for key 'email'
	12 May 2015, 03:36 	File: [user.class.php] Line: [705] "INSERT INTO `CubeCart_customer` (`title`,`first_name`,`last_name`,`email`,`phone`,`mobile`,`password`,`salt`,`registered`,`ip_address`) VALUES ('Http://www.virtuocp.com/products-498.htmlrn','HermanPypeXF','HermanPypeXF','[email protected]','123456','Gattaca','9d767243227d2efac5f64cef91cba7377567c0ddade6b4db0d244db5052920fdfbb342815fe5fe4474ac106c3ec4613af70740fef1dbe6e9c0a273e92c3f78ed','33f9dffc','1431398189','199.15.233.176');" - Duplicate entry '[email protected]' for key 'email'
	12 May 2015, 02:22 	File: [user.class.php] Line: [705] "INSERT INTO `CubeCart_customer` (`title`,`first_name`,`last_name`,`email`,`phone`,`mobile`,`password`,`salt`,`registered`,`ip_address`) VALUES ('Http://www.itinteractiveservices.com/products-1571.htmlrn','StevenVateRA','StevenVateRA','[email protected]','123456','Cant remember','2187145e38e5d1d7367e9112792c3ca396e547cb84a6f0ffd5ac2aba17bbef8319571ec300a3a53766f753c798e938b77c2bec44be9244a305430dcdcdfd2160','52baa9ca','1431393736','199.15.233.170');" - Duplicate entry '[email protected]' for key 'email'
	06 May 2015, 19:28 	File: [user.class.php] Line: [705] "INSERT INTO `CubeCart_customer` (`title`,`first_name`,`last_name`,`email`,`phone`,`mobile`,`password`,`salt`,`registered`,`ip_address`) VALUES ('Mr','Alan','*****','*****[email protected]','*****','*****','149e958496edc5e1fba9ec85576d0287035595afd08254cbbfca4baf6982b49a8b24e86abeac08d06c36cf5657edba6649b5beeabb85854d586ce5b49906134b','7057e01f','1430936893','2.120.247.87');" - Duplicate entry '*****@aol.com' for key 'email'
	06 May 2015, 19:25 	File: [user.class.php] Line: [705] "INSERT INTO `CubeCart_customer` (`title`,`first_name`,`last_name`,`email`,`phone`,`mobile`,`password`,`salt`,`registered`,`ip_address`) VALUES ('Mr','Alan','*****','*****@aol.com','*****','*****','6914feda41b447842b001374328fb7689876911f3a6df13ddb427d1a089b8db623f210ac6193826066fe3abd5bffc698d44abb77b3952e08d090fe9e78a825d6','5b178a80','*****','2.120.247.87');" - Duplicate entry '*****@aol.com' for key 'email'
	06 May 2015, 19:25 	File: [user.class.php] Line: [705] "INSERT INTO `CubeCart_customer` (`title`,`first_name`,`last_name`,`email`,`phone`,`mobile`,`password`,`salt`,`registered`,`ip_address`) VALUES ('Mr','Alan','*****','*****@aol.com','*****','*****','f51e024526d13cc42af82b10eca45a55fb1f85959b28e29df9e85b30248441f131dab3aa578ba056f0e3a5098c3068a986ddb98db809d00d96c06a81813e2630','2da81299','1430936710','2.120.247.87');" - Duplicate entry '*****@aol.com' for key 'email'
	30 Apr 2015, 15:48 	File: [user.class.php] Line: [367] "INSERT INTO `CubeCart_customer` (`title`,`first_name`,`last_name`,`email`,`phone`,`mobile`,`password`,`new_password`,`ip_address`,`registered`,`type`) VALUES ('','Per Ånund','*****','*****@hotmail.com','*****','*****','68c8c5889742f4498656393c24640f1e','0','80.232.86.205','1430405297','2');" - Duplicate entry *****@hotmail.com' for key 'email'
	30 Apr 2015, 11:06 	File: [user.class.php] Line: [705] "INSERT INTO `CubeCart_customer` (`title`,`first_name`,`last_name`,`email`,`phone`,`mobile`,`password`,`salt`,`registered`,`ip_address`) VALUES ('Http://www.bluemountainsmusic.com/products-9952.htmlrn','RobertKalHT','RobertKalHT','[email protected]','123456','Pulp Fiction','61673e74fe351a84cad1a750e90cf233277352b1bcfea6d25f33857e211ef33ff664300cf6e3cda282c3e844054ae4a43966f6547c957ed4b00353c58dd2296a','706dc553','*****','199.15.233.176');" - Duplicate entry '[email protected]' for key 'email'
	29 Apr 2015, 08:20 	File: [user.class.php] Line: [367] "INSERT INTO `CubeCart_customer` (`title`,`first_name`,`last_name`,`email`,`phone`,`mobile`,`password`,`new_password`,`ip_address`,`registered`,`type`) VALUES ('Mr','James','*****','*****@gmail.com','*****','','3566055a7f33678333e6895473df06f1','0','121.74.234.63','1430292040','2');" - Duplicate entry '*****@gmail.com' for key 'email'
	Check/Uncheck all 	

 

Link to comment
Share on other sites

Duplicate entry for key 'email'.

I'm surprised that the code at user.class.php line 367 is being executed. This code starts with a test to see if this email address already exists.

I wonder if that query at line 361 has been cached. And if so, it may be returning obsolete data.

Or, as I am now discovering, there may be a fault in the code that permits an email address to be databased with uppercase letters, yet the test for an existing email is asking for emails that have been converted to lowercase. I am going to test for this.

Link to comment
Share on other sites

  • 4 weeks later...
  • 2 months later...

I'm seeing the same issue on 6.0.6, error 726.  Users are reporting strange behaviour, but I can't narrow down exactly what is going on.

The symptom is that users cannot change passwords, or create an account they cannot log into, and are unable to reset the password.  Surely someone else has seen this?

It doesn't seem to happen for everyone who creates an account, but I can't for the life of me work out the common thread here that is causing the issue for some people and not others.  Error is something like this (exact details changed to protect the innocent):

File: [user.class.php] Line: [726] "INSERT INTO `pok_CubeCart_customer` (`title`,`first_name`,`last_name`,`email`,`phone`,`mobile`,`password`,`salt`,`registered`,`ip_address`) VALUES ('Mr','Firstname','Surname','[email protected]','phone_num','mobile_num','700d01880c3d112d125d728ed98db7cf6ee583a2b599732ab22a1894dd1ff9cd664cc24a14815b69b340e4cf3cafac511982d3f5e2941f5ac07eda0884df0940','0ae0ad80','1439778466','ip_address');" - Duplicate entry '[email protected]' for key 'email'

Link to comment
Share on other sites

I think I've reproduced this issue.

If I create a user account with a space after the title (eg: "Mrs " with a space at the end of the word Mrs), the account does some strange things.  I can create the account just fine as a user, I can set all the user details and save the account, but when I try and log in to the website to place an order, it sends me into an endless loop, and doesn't actually log me in.  Rather than giving me an "invalid name or password" error, it just refreshes the same page as if I haven't even logged in, asking for my username and password again, and not logging me in.

I haven't tested other combinations of spaces before and after the titles, names, passwords, etc, but it would appear that there needs to be more checking of the field data before it does into the database.

EDIT: It may also be happening with addresses too, if there is a space at the end of any field, like a street name.

Edited by James Ellerman
Link to comment
Share on other sites

Hi James, Did you import previous users in bulk into your database? We found that users which had been bulk imported were causing all sorts of problems, whereas those users who had added themselves individually had no problems.

Link to comment
Share on other sites

No bulk import. All users are created by the users themselves.

The users that create themselves with a space at the end of a field end up with corrupt accounts. Even removing the spaces and saving the accounts doesn't seem to fix it. The only fix is to delete the account and recreate it from scratch.

Only accounts created with the trailing space seem to have the problem, others that do not have the trailing space are fine.

Link to comment
Share on other sites

  • 3 weeks later...

This is still an issue for me.  Roughly 1/4 of users who create an account on the site are getting this error.  Many of them are having to use an alternate email address to create another account, but some are just not bothering to order, which is costing us hundreds of dollars at a time.

I'd really appreciate some advice on where this problem may be coming from.  Is this a hosting issue?  Perhaps there are some timing problems/delays writing to a database caused by a shared hosting solution?  Would upgrading the hosting package to a faster/dedicated server make any difference?

Link to comment
Share on other sites

Is this a hosting issue?

I would say no.

Would upgrading the hosting package to a faster/dedicated server make any difference?

I would say no.

Because you are observing roughly 25% of your visitors who create accounts are causing a "Duplicate Key" error, we need to trace this out.

But first, see if this bug report applies:
https://github.com/cubecart/v6/issues/628

 

Link to comment
Share on other sites

Yes, we are definitely running 6.0.6.

Any ideas on how to troubleshoot this further?  I can send you database dumps if that helps.  I can't see anything immediately obvious with the accounts that have the issue, looking at the underlying database.  I have manually reset the password through the admin interface on one account that had the problem, and I can log in as the user.  I note that the user has no address book entries, but I'm not sure if this is significant.

Link to comment
Share on other sites

"Any ideas on how to troubleshoot this further?"

My process would be to make changes to the database class and the user class -- by adding tracer code. I have a file that logs data sent by the tracer calls.

It won't break the store, but could generate a very large data file while waiting for a customer to trip the problem.

We can try a few situations first to test some theories. We should take this to email so as to not bore other people.

Link to comment
Share on other sites

  • 4 weeks later...

Hi All! :) Sorry I don't get the time to frequent the forums as much as I would like.

@vidmarc Some versions of CubeCart has had issues of over caching. It's been built to cache everything and not to cache when specified. Probably it should be the other way around as we have had many issues like this. I'd like to know if this problem persists since 6.0.7. 125 issues have been fixed since 6.0.5.

Ok so I don't think this is an issue on 6.0.7. Please make sure line 368 of the classes/user.class.php file reads:

if ($existing = $GLOBALS['db']->select('CubeCart_customer', 'customer_id', array('email' => $data['email']), false, 1, false, false)) {

The extra parameters prevent caching which your version doesn't have (I expect).

Edited by Al Brookbanks
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...