Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Checking File Permissions


Recommended Posts

Hi there,

 

I have added this contrib but it doesn't seem to be working when i navigate to the link through tools in admin, i just get a 404 not found FILENAME_CHECK_PERMISSIONS was not found on this server.

 

If i navigate to check_permissions.php through a web browser it works.

 

Anyone have any ideas? :)

Link to comment
Share on other sites

  • 2 months later...
  • Replies 71
  • Created
  • Last Reply

Top Posters In This Topic

Hi there,

 

I have added this contrib but it doesn't seem to be working when i navigate to the link through tools in admin, i just get a 404 not found FILENAME_CHECK_PERMISSIONS was not found on this server.

 

If i navigate to check_permissions.php through a web browser it works.

 

Anyone have any ideas? :)

 

You missed out one of the installation steps.

 

HTH

 

G

Need help installing add ons/contributions, cleaning a hacked site or a bespoke development, check my profile

 

Virus Threat Scanner

My Contributions

Basic install answers.

Click here for Contributions / Add Ons.

UK your site.

Site Move.

Basic design info.

 

For links mentioned in old answers that are no longer here follow this link Useful Threads.

 

If this post was useful, click the Like This button over there ======>>>>>.

Link to comment
Share on other sites

  • 2 weeks later...

I used this to change all my folders to 755 and my files to 644. I didn't notice for a few hours I had a "warning: able to write to the config file" at the top of the store so hopefully everything is all good. I changed it to 0444. My question is, what other files do not need to be writeable and need to be changed from 644 to 444?

RC2.2a

Link to comment
Share on other sites

  • 2 weeks later...

This is the only one that I know of.

 

Cheers

 

G

Need help installing add ons/contributions, cleaning a hacked site or a bespoke development, check my profile

 

Virus Threat Scanner

My Contributions

Basic install answers.

Click here for Contributions / Add Ons.

UK your site.

Site Move.

Basic design info.

 

For links mentioned in old answers that are no longer here follow this link Useful Threads.

 

If this post was useful, click the Like This button over there ======>>>>>.

Link to comment
Share on other sites

  • 2 weeks later...

Hello, I followed the readme provided with the download and for some reason when I click the check permissions button in the admin I get an error saying the page requested can not be found do you know what I can do to fix this or if I did something wrong

 

Thanks

 

Adamanto

Link to comment
Share on other sites

I get an error saying the page requested can not be found

 

This normally means you have not followed all of the installation steps.

 

If you post the whole message I could tell you more.

 

G

Need help installing add ons/contributions, cleaning a hacked site or a bespoke development, check my profile

 

Virus Threat Scanner

My Contributions

Basic install answers.

Click here for Contributions / Add Ons.

UK your site.

Site Move.

Basic design info.

 

For links mentioned in old answers that are no longer here follow this link Useful Threads.

 

If this post was useful, click the Like This button over there ======>>>>>.

Link to comment
Share on other sites

  • 1 month later...

I'm trying to install this add-on and am running into a problem. I uploaded all the files like the instructions in the zip say, but on step 3 it says:

 

3. Add this line to admin/includes/boxes/tools.php

 

'<a href="' . tep_href_link(FILENAME_CHECK_PERMISSIONS) . '" class="menuBoxContentLink">' . BOX_TOOLS_CHECK_PERMISSIONS . '</a><br>' .

 

after

 

BOX_TOOLS_NEWSLETTER_MANAGER . '</a><br>' .

 

When I go to that file and open it up to add the above line, this is what it looks like:

 

<?php
/*
 $Id$

 osCommerce, Open Source E-Commerce Solutions
 http://www.oscommerce.com

 Copyright (c) 2010 osCommerce

 Released under the GNU General Public License
*/

 $cl_box_groups[] = array(
   'heading' => BOX_HEADING_TOOLS,
   'apps' => array(
     array(
       'code' => FILENAME_ACTION_RECORDER,
       'title' => BOX_TOOLS_ACTION_RECORDER,
       'link' => tep_href_link(FILENAME_ACTION_RECORDER)
     ),
     array(
       'code' => FILENAME_BACKUP,
       'title' => BOX_TOOLS_BACKUP,
       'link' => tep_href_link(FILENAME_BACKUP)
     ),
     array(
       'code' => FILENAME_BANNER_MANAGER,
       'title' => BOX_TOOLS_BANNER_MANAGER,
       'link' => tep_href_link(FILENAME_BANNER_MANAGER)
     ),
     array(
       'code' => FILENAME_CACHE,
       'title' => BOX_TOOLS_CACHE,
       'link' => tep_href_link(FILENAME_CACHE)
     ),
     array(
       'code' => FILENAME_DEFINE_LANGUAGE,
       'title' => BOX_TOOLS_DEFINE_LANGUAGE,
       'link' => tep_href_link(FILENAME_DEFINE_LANGUAGE)
     ),
     array(
       'code' => FILENAME_MAIL,
       'title' => BOX_TOOLS_MAIL,
       'link' => tep_href_link(FILENAME_MAIL)
     ),
     array(
       'code' => FILENAME_NEWSLETTERS,
       'title' => BOX_TOOLS_NEWSLETTER_MANAGER,
       'link' => tep_href_link(FILENAME_NEWSLETTERS)
     ),
     array(
       'code' => FILENAME_SEC_DIR_PERMISSIONS,
       'title' => BOX_TOOLS_SEC_DIR_PERMISSIONS,
       'link' => tep_href_link(FILENAME_SEC_DIR_PERMISSIONS)
     ),
     array(
       'code' => FILENAME_SERVER_INFO,
       'title' => BOX_TOOLS_SERVER_INFO,
       'link' => tep_href_link(FILENAME_SERVER_INFO)
     ),
     array(
       'code' => FILENAME_VERSION_CHECK,
       'title' => BOX_TOOLS_VERSION_CHECK,
       'link' => tep_href_link(FILENAME_VERSION_CHECK)
     ),
     array(
       'code' => FILENAME_WHOS_ONLINE,
       'title' => BOX_TOOLS_WHOS_ONLINE,
       'link' => tep_href_link(FILENAME_WHOS_ONLINE)
     )
   )
 );
?>

 

Where am I supposed to add this line?

Link to comment
Share on other sites

  • 2 weeks later...

I'm having the same problem! I do not have the line BOX_TOOLS_NEWSLETTER_MANAGER . '</a><br>' in my tools.php file. Running 2.3.1

Edited by biggeorge
Link to comment
Share on other sites

config's set to 644 can allow you to view the sites db password by directly loading the config file:

www.sitepath.com/store/includes/configure.php

file --> save as --> .txt gives you the full config file.

I'd HIGHLY recommend using 400...

 

i am still trying to piece my site back together after a massive hack and will more than likely have to start from scratch.

 

Please safeguard your config files!!!!

Link to comment
Share on other sites

  • 2 weeks later...

Same problem here, looks like the code has likely changed in 2.3.1 ? Don't know php well enough to know how to tweak it, played around a bit but nothing shows up in the admin section...

 

Any thoughts?

 

I'm having the same problem! I do not have the line BOX_TOOLS_NEWSLETTER_MANAGER . '</a><br>' in my tools.php file. Running 2.3.1

Link to comment
Share on other sites

  • 4 weeks later...

Hi all and thanks Geoffrey for a great contribution.

 

My question:-

How can I change the default permissions which appear just before I click on update?

 

Details:-

When I add a new product, the images are uploaded with a 777 permission.

There might be an easier way to change these permissions but about once a week, I just use this addon and update

image permissions to 644. To my annoyance, I have to change ALL the default permissions to my desired permission

EVERYTIME.

 

Also, It's been mentioned in the previous page or two that some of the suggested permissions are strange.

This problem can be eliminated if the contribution user can change the default permissions themselves

to their desired settings.

 

Thanks.

Link to comment
Share on other sites

You can set the permissions you want to test against on the first screen, the advice on permission levels may have changed since I last amended this or alternatively I might just be prompting with the wrong value.

 

Just change it to the one you want.

 

G

 

Hi Geoffrey,

I have a crontab set up to execute admin/sitemonitor.php but after I update my php files to 644, I get a message (execute) "permission denied". When I change this file to 700, it works. My problem here is that after I update my permissions in the administration panel, I need to go to my hosting control panel everytime to change my admin/sitemonitor.php permission setting.

I guess the only solution to this is to individualize the admin/sitemonitor.php permission like you have done to configure.php and IPtrap.php???

Edited by CutieCute2
Link to comment
Share on other sites

To change the default permissions that appear in the boxes can be done very easily by editing /admin/check_permissions.php.

 

Because different hosts have different requirements I can't please all of the people all of the time.

 

Just nip in there and change it to your requirments.

 

Adding in a new file that needs a special/different level can be done by duplicating the code for one of the other files that need specified permissions.

 

HTH

 

G

Need help installing add ons/contributions, cleaning a hacked site or a bespoke development, check my profile

 

Virus Threat Scanner

My Contributions

Basic install answers.

Click here for Contributions / Add Ons.

UK your site.

Site Move.

Basic design info.

 

For links mentioned in old answers that are no longer here follow this link Useful Threads.

 

If this post was useful, click the Like This button over there ======>>>>>.

Link to comment
Share on other sites

Same problem here, looks like the code has likely changed in 2.3.1 ? Don't know php well enough to know how to tweak it, played around a bit but nothing shows up in the admin section...

 

Any thoughts?

 

This was written for 2.2 and not 2.3.1.

 

For those of you running IP Trap, AVS (Anti-Virus System) and Site Monitor check this does not break them.

 

If things ever quieten down I'll look at adding code to cater specifically for them.

 

Cheers

 

G

Edited by geoffreywalton

Need help installing add ons/contributions, cleaning a hacked site or a bespoke development, check my profile

 

Virus Threat Scanner

My Contributions

Basic install answers.

Click here for Contributions / Add Ons.

UK your site.

Site Move.

Basic design info.

 

For links mentioned in old answers that are no longer here follow this link Useful Threads.

 

If this post was useful, click the Like This button over there ======>>>>>.

Link to comment
Share on other sites

  • 3 weeks later...

Just nip in there and change it to your requirments.

 

Adding in a new file that needs a special/different level can be done by duplicating the code for one of the other files that need specified permissions.

 

HTH

 

G

I've made some progress creating a special entry for sitemonitor.

I've tried twice, once duplicating the IP_trap (15) and once duplicating the sitemap (16) info to sitemonitor (17), and both times the sitemonitor appears on the first page but after I click on "check" or "update", nothing happens. The default permission is 700, but the check shows 644 OK.

Thanks.

Link to comment
Share on other sites

  • 2 weeks later...
  • 2 weeks later...

Hi Geoffrey and other "permissions checker" fans. You must all be busy?

 

My problem isn't a big one so I'm still hoping to solve it.

 

To reiterate my problem and question.......

When I upload new products, the uploaded images have a 777 permission instead of 644.

The option of updating all permissions with Geoffrey's Permission Checker seems better than changing the permissions of each new image, however,

I require a 700 permission for my sitemonitor.php file so I have to change that manually.

 

I have tried to create an individual checker thingy for sitemonitor.php by changing sitemap to sitemonitor.

It all appears and looks good but doesn't change the permissions.

Could someone please tell me the lines I need to change?

Link to comment
Share on other sites

  • 7 months later...

Back monitoring this as the "follow" disppeared with the forum upgrade.

Need help installing add ons/contributions, cleaning a hacked site or a bespoke development, check my profile

 

Virus Threat Scanner

My Contributions

Basic install answers.

Click here for Contributions / Add Ons.

UK your site.

Site Move.

Basic design info.

 

For links mentioned in old answers that are no longer here follow this link Useful Threads.

 

If this post was useful, click the Like This button over there ======>>>>>.

Link to comment
Share on other sites

  • 3 months later...

1. Will this work in 2.3.1? the tools.php file looks different

 

array(

'code' => FILENAME_NEWSLETTERS,

'title' => BOX_TOOLS_NEWSLETTER_MANAGER,

'link' => tep_href_link(FILENAME_NEWSLETTERS)

),

 

2. Will this work for Windows/IIS?

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
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
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...