Login Problems

Having trouble installing serendipity?
Post Reply
System0
Posts: 4
Joined: Tue Feb 23, 2010 2:40 pm

Login Problems

Post by System0 »

I'm having the same login problem as everyone else. It happened when I upgraded to 1.5.1. I never really looked into the matter much as I don't update the blog that often anymore though I now want to get it up and running.

I upgraded 1.5.2 as I thought it would add the hashtype column to the authors table, but it hasn't (my bad) :)

I executed the following SQL query via phpmyadmin:

Code: Select all

create table serendipity_tempauthors (
  realname varchar(255) NOT NULL default '',
  username varchar(32) default null,
  password varchar(64) default null,
  authorid {AUTOINCREMENT} {PRIMARY},
  mail_comments int(1) default '1',
  mail_trackbacks int(1) default '1',
  email varchar(128) not null default '',
  userlevel int(4) {UNSIGNED} not null default '0',
  right_publish int(1) default '1',
  hashtype int(1) default '0'
) {UTF_8};

INSERT INTO serendipity_tempauthors 
(realname,username,password,authorid,mail_comments,mail_trackbacks,email,userlevel,right_publish,hashtype) SELECT 
realname,username,password,authorid,mail_comments,mail_trackbacks,email,userlevel,right_publish,0 FROM serendipity_authors;
DROP TABLE serendipity_authors;

create table serendipity_authors (
  realname varchar(255) NOT NULL default '',
  username varchar(32) default null,
  password varchar(64) default null,
  authorid {AUTOINCREMENT} {PRIMARY},
  mail_comments int(1) default '1',
  mail_trackbacks int(1) default '1',
  email varchar(128) not null default '',
  userlevel int(4) {UNSIGNED} not null default '0',
  right_publish int(1) default '1',
  hashtype int(1) default '0'
) {UTF_8};


INSERT INTO serendipity_authors 
(realname,username,password,authorid,mail_comments,mail_trackbacks,email,userlevel,right_publish,hashtype) SELECT 
realname,username,password,authorid,mail_comments,mail_trackbacks,email,userlevel,right_publish,hashtype FROM serendipity_tempauthors;
DROP TABLE serendipity_tempauthors;
However this gives me the following error:
MySQL said:

#1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '{AUTOINCREMENT} {PRIMARY},
mail_comments int(1) default '1',
mail_trackbac' at line 5
Any idea what I am doing wrong and what the best method is in resolving this.

Thanks,
Kevin
garvinhicking
Core Developer
Posts: 30022
Joined: Tue Sep 16, 2003 9:45 pm
Location: Cologne, Germany
Contact:

Re: Login Problems

Post by garvinhicking »

Hi!

When you are using MySQL you don't need to perform these steps only required for SQLite!

When you use phpMyAdmin to check the "authors" table, does it have a "hashtype" column or doesn't it? Then we can proceed from there, I can give you directions.

Regards,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
System0
Posts: 4
Joined: Tue Feb 23, 2010 2:40 pm

Re: Login Problems

Post by System0 »

Hi Garvin,

Thanks for the prompt reply.

No I can't see the hashtype column anywhere.

Here's a screenshot of the author table.

Image removed due to security reasons by kleinerChemiker.

:)
kleinerChemiker
Regular
Posts: 765
Joined: Tue Oct 17, 2006 2:36 pm
Location: Vienna/Austria
Contact:

Re: Login Problems

Post by kleinerChemiker »

It's nice that you hide your email but it would have been much better if you hide your password (and user). Thats why I removed your picture.
System0
Posts: 4
Joined: Tue Feb 23, 2010 2:40 pm

Re: Login Problems

Post by System0 »

kleinerChemiker wrote:It's nice that you hide your email but it would have been much better if you hide your password (and user). Thats why I removed your picture.
Thanks. I didn't think it would be a concern as the blog I am referring to is not listed on any other website I own (It's a blog for family and friends).

Image
kleinerChemiker
Regular
Posts: 765
Joined: Tue Oct 17, 2006 2:36 pm
Location: Vienna/Austria
Contact:

Re: Login Problems

Post by kleinerChemiker »

Many people use similar or the same passwords for different sites. As long as your blog is online, some "funny" kids could think they are c3wl when they damage your blog. But of course, when somebody wants to hack your blog, with that easy password it won't take them long ;)
garvinhicking
Core Developer
Posts: 30022
Joined: Tue Sep 16, 2003 9:45 pm
Location: Cologne, Germany
Contact:

Re: Login Problems

Post by garvinhicking »

Hi!

Okay, as you are missing the "hashtype" column, this means that when you upgraded your serendipity, you might have missed to execute the update. From which version did you update from?

You can restore the 'hashtype' column by executing this SQL:

Code: Select all

ALTER TABLE serendipity_authors ADD COLUMN hashtype int(1);
ALTER TABLE serendipity_authors CHANGE password password VARCHAR(64) NOT NULL;
HTH,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
System0
Posts: 4
Joined: Tue Feb 23, 2010 2:40 pm

Re: Login Problems

Post by System0 »

thanks Garvin.

All good now :)

Kevin
Post Reply