Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Reset Admin Username and Password


caryne444

Recommended Posts

Hi Karen what version of osc are you using?

 

I am also having this problem. Currently using RC 2.2 or something around there i believe. I used to be able to do this very easily. Something like clearing the username and password columns in the administrator table in phpMyAdmin, then I could simply input new values on the login.php page.

 

If you can give me instructions on this, or another simple way to change the username/password it would be much appreciated.

 

I've had people say you can edit the value through phpmyadmin and input a new encrypted password, but I dont see where exactly to put in this new value, nor do I see an old one.

 

help please!

Link to comment
Share on other sites

I've migrated my site to another host and now the Admin username/password does not work. In what file can I reset the Admin Username and Password?

 

Thanks!

 

 

If I am not mistaken, you have to edit the config.php under Admin.

Do or Do Not, there is no try.

Link to comment
Share on other sites

I have the exact same problem. I am using osCommerce 1.5 though...

 

I migrated to a new server and everything works fine except the /admin username and password did not migrate with the rest of the site. I now do not have access to my /admin and I really need to get in there to ship some orders. Anyone know what to do?

 

thanks a lot.

Link to comment
Share on other sites

I have the exact same problem. I am using osCommerce 1.5 though...

 

I migrated to a new server and everything works fine except the /admin username and password did not migrate with the rest of the site. I now do not have access to my /admin and I really need to get in there to ship some orders. Anyone know what to do?

 

thanks a lot.

 

i believe older versions store passwords in .htaccess files. check the .htpasswds folder in the root directory of your ftp client and see if there is an admin folder in there, then try editing the file associated with it and look to see if the password is in there. If that dosnt work check the admin folder in your osc setup and edit the .htaccess file in there.

Link to comment
Share on other sites

i believe older versions store passwords in .htaccess files. check the .htpasswds folder in the root directory of your ftp client and see if there is an admin folder in there, then try editing the file associated with it and look to see if the password is in there. If that dosnt work check the admin folder in your osc setup and edit the .htaccess file in there.

 

You should be able to do this through your webs site control panel, under password protect directories or similar

Nic

Sometimes you're the dog and sometimes the lamp post

[/url]

My Contributions

Link to comment
Share on other sites

  • 1 year later...

 

Newbie response to similar problem.

 

I didn't follow any of that, if you've lost your admin login, just delete oscommerce and reload it! Viz Top Tip

 

Is there no simple explanation for this? Many systems send a reminder mail, nothing like that on os?

 

If you have no idea how .htaccess or config.php works you're stuck, as passwords / users are not going to be in plain text for obvious reasons.

Any other ideas? Thx.

Link to comment
Share on other sites

Newbie response to similar problem.

 

I didn't follow any of that, if you've lost your admin login, just delete oscommerce and reload it! Viz Top Tip

 

Is there no simple explanation for this? Many systems send a reminder mail, nothing like that on os?

 

If you have no idea how .htaccess or config.php works you're stuck, as passwords / users are not going to be in plain text for obvious reasons.

Any other ideas? Thx.

If you use the older versions of osC, or even if you have a new version with the admin directory protected by .htaccess then the way to reset your password is this:

 

Log in to your website cPanel. Select the admin directory and select remove directory passwords. Then, select the directory and select Password Protect Directory. Put in your new username and password.

 

If you do not have a cPanel then looking in the .htaccess file it will say exactly where your password file is. Say it is at /public/your_site/passwords

On a command line enter htpass /public/your_site/passwords username

where username is the name of the administrator you want to use. Press return and it will prompt you for a new password.

 

Very few persons have command line access. But if you do, this will fix your problem. If you do not have cPanel nor command line access then how did you protect the directory in the first place? Call your host. They can fix it for you.

Community Bootstrap Edition, Edge

 

Avoid the most asked question. See How to Secure My Site and How do I...?

Link to comment
Share on other sites

  • 7 months later...

Hi Karen!

 

It may be too late to replay since I got the same situation like your case to migrate a shop to a new box.

 

My solution is:

 

1). install a blank new oscommerce 2.2 to a directory other than the production one.

2). Create an "Admin" account with new known password (it doesn't matter whether both the new or old "Admin" IDs are the same).

3). Use Webmin (my favour web admin tools. PhpAdmin or other similar is OK for you) to copy the encrypted password string from the newly created "blank shop" admin table to the migrated production shop.

4). Cheers !!!

YaNotCook !!

Link to comment
Share on other sites

  • 1 month later...

I have just had a similar problem. My user name and password although it had been working, no longer worked. I tried the add on suggested earlier, and by resetting it using phpmyadmin. Neither worked. In the end i had to totally delete the administrators table from the database. I re installed the table using the section from the sql file in a standard install of oscommerce. Hey presto when i then tried to enter a new password and user name it worked. I just wish i knew what went wrong.

REMEMBER BACKUP, BACKUP AND BACKUP

Link to comment
Share on other sites

I've upgraded my shop from 2.2 MS2 to 2.2 RC2a using the contribution however I can not login to the admin part of the shop anymore. I know that in MS2 there was no administrators table so I copied it from another RC2a shop I have running. I emptied the table and went to the admin section (as described in this topic and http://www.clubosc.com/forgotten-your-admin-password-shock-horror.html ) but I still cannot login, nor was I asked to create an administrator account...

 

No idea what to do next, anyone??

Link to comment
Share on other sites

Oh wait, you have the author of this contribution, Nic, (FIMBLE) online.

 

Nic, I have a question, does the fact your contribution work so easily, say anything about the security of the admin password system?

Oscommerce site:

 

 

OSC to CSS, http://addons.oscommerce.com/info/7263 -Mail Manager, http://addons.oscommerce.com/info/8120

Link to comment
Share on other sites

Thanks, this worked. I didn't get offered to enter a new admin password but I could login with the old one...

 

 

I have still one question though; where is the old password stored?? The database table administrator remains empty :o and the reset.php doesn't work with htaccess files... :blink:

Link to comment
Share on other sites

Hey everyone,

 

Another newbie here!

 

I have looked all over the place and still can't find an answer..

 

I have reset my admin user name fine, but the password, I forgot to encrypte it and now I can not access my shop/admin/

 

I have looked in MyPHPmyAdmin and there is no administrators table!?

 

The two files .htaccess and .htpasswd are in the shop/admin but not in FTP?!

 

Just want to know besides the obvious, how to change it and/or delete it!?

 

Thanks,

 

Rob

Link to comment
Share on other sites

Rob,

 

Use phpmyadmin to run this:

 

CREATE TABLE administrators (

id int NOT NULL auto_increment,

user_name varchar(32) binary NOT NULL,

user_password varchar(40) NOT NULL,

PRIMARY KEY (id)

);

 

Then, go to your admin using your URL (www.yourdomain.com/catalog/admin) and you will be notified that there is NO default admin username and password. Enter one, this becomes your default log in to your admin area.

 

 

 

Chris

Link to comment
Share on other sites

Oh wait, you have the author of this contribution, Nic, (FIMBLE) online.

 

Nic, I have a question, does the fact your contribution work so easily, say anything about the security of the admin password system?

 

 

Hi

No it does not, it calls in the application top which gives via configure.php files access to the database just the same as any other file with SQL queries in it.

All it is really is just on query, the same as you run via phpmyadmin TRUNCATE `administrators` all this does is to empty the table, thats it!

It is intended for users who are not confident with phpmyadmin.

It is good practice to delete the file after use thought !!

The user + passwords for admin are safe enough.

Nic

Sometimes you're the dog and sometimes the lamp post

[/url]

My Contributions

Link to comment
Share on other sites

Rob,

 

Use phpmyadmin to run this:

 

CREATE TABLE administrators (

id int NOT NULL auto_increment,

user_name varchar(32) binary NOT NULL,

user_password varchar(40) NOT NULL,

PRIMARY KEY (id)

);

 

Then, go to your admin using your URL (www.yourdomain.com/catalog/admin) and you will be notified that there is NO default admin username and password. Enter one, this becomes your default log in to your admin area.

 

 

 

Chris

 

Chris,

 

Thanks for the reply!

 

I have successfully created the administrators table in phpmyadmin, did what you said but it is still asking for a user name and password.. saying "To view this page, you must log in to this area on (my site)" Then I enter a new user name and password then it says "The user name or password you entered for this area on (my site) was incorrect. Make sure you’re entering them correctly, and then try again."

 

So I am guessing the user name and password are stored somewhere else maybe?! Just don't know where?!

 

I know the two files .htaccess and .htpasswd are in (https://secure.mysite.com.au/shop/admin/) but I can not access them?!

 

Cheers,

 

Rob

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...