dont know if you still need this info, but i had exactly the same problem as you. i tinkered w/ the gui changing stuff with the groups.. more specifically, i took an account that belonged to one group and assigned it to another group, then i went back and assigned it to both its original group and new group, the new group being the primary group. that created all sorts of problems including not being able to ssh into the box, etc.
anyway, i went to this website and found the answer.
http://www.linuxgazette.com/issue70/tag/10.html
(copy/pasting from their site)
ben:ShHh!ItSaSeCrEt!:11504:0:::::
If you do that, "chage -l" reports the following:
ben@Baldur:~$ chage -l ben
Minimum: 0
Maximum: -1
Warning: -1
Inactive: -1
Last Change: Jul 01, 2001
Password Expires: Never
Password Inactive: Never
Account Expires: Never
so what you're suppose to do is run this chage command, try it on a working account and it should look something similar to above. then do the same command (chage -l <username>) and see whats different, then use the different flags to reset the values back.
good luck!