Jack_mcs Posted August 9, 2006 Author Share Posted August 9, 2006 It's a server setting. On shared servers, you don't have any control over it and it is usually 30 seconds. On dedicated servers, you can change it to what you want via the php.ini file. Jack Quote Support Links: For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc. Get the latest versions of my addons Recommended SEO Addons Link to comment Share on other sites More sharing options...
Guest Posted August 9, 2006 Share Posted August 9, 2006 isn't it possible to spoof the edit time for any given file? i would assume the majority of hackers would take this step to prevent you from knowing what files they touched. would this contribution still work, in that case? Quote Link to comment Share on other sites More sharing options...
Jack_mcs Posted August 9, 2006 Author Share Posted August 9, 2006 You can change the timestamp of a file but the size would still have to be exact and that would be difficult to do since it involves more than just the file size. Jack Quote Support Links: For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc. Get the latest versions of my addons Recommended SEO Addons Link to comment Share on other sites More sharing options...
Sid04 Posted August 10, 2006 Share Posted August 10, 2006 Anybody else getting errors in their cron output? Ive got the cron job setup and running ok but its outputting errors(the cron sends an email out after it runs). This normal? Quote Link to comment Share on other sites More sharing options...
Sid04 Posted August 10, 2006 Share Posted August 10, 2006 heres the cron output is interested: Warning</b>: session_start() [<a href='function.session-start'>function.session-start</a>]: Cannot send session cookie - headers already sent in <b>/home2/mydomain/public_html/catalog/admin/includes/functions/sessions.php</b> on line <b>67</b><br /><br /> <b>Warning</b>: session_start() [<a href='function.session-start'>function.session-start</a>]: Cannot send session cache limiter - headers already sent (output started at /home2/mydomain/public_html/catalog/admin/includes/functions/sessions.php:67) in <b>/home2/mydomain/public_html/catalog/admin/includes/functions/sessions.php</b> on line <b>67</b><br /> <br /> <b>Warning</b>: main(includes/languages/english/) [<a href='function.main'>function.main</a>]: failed to open stream: No such file or directory in <b>/home2/mydomain/public_html/catalog/admin/includes/application_top.php</b> on line <b>133</b><br /> <br /> <b>Warning</b>: main() [<a href='function.include'>function.include</a>]: Failed opening 'includes/languages/english/' for inclusion (include_path='.:/usr/lib/php:/usr/local/lib/php:/home2/mydomain/public_html/catalog/admin') in <b>/home2/mydomain/public_html/catalog/admin/includes/application_top.php</b> on line <b>133</b><br /> Quote Link to comment Share on other sites More sharing options...
moraira Posted August 10, 2006 Share Posted August 10, 2006 Hi all, I downloaded and installed Sitemonitor contribution and it works great, no pb at all :D All the features work perfectly... Many thanks to the author !!! Jean-Pierre. Quote Link to comment Share on other sites More sharing options...
Jack_mcs Posted August 10, 2006 Author Share Posted August 10, 2006 heres the cron output is interested:Does the sitemonitor.php script work when ran manually? Jack Quote Support Links: For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc. Get the latest versions of my addons Recommended SEO Addons Link to comment Share on other sites More sharing options...
moraira Posted August 10, 2006 Share Posted August 10, 2006 Does the sitemonitor.php script work when ran manually? Jack Yes it works fine when run manually, I tried to modify one file and the email alert work too !!! Thanks a lot. Jean-Pierre bonus34 1 Quote Link to comment Share on other sites More sharing options...
Sid04 Posted August 10, 2006 Share Posted August 10, 2006 Does the sitemonitor.php script work when ran manually? Jack Yes. It works fine when run with the cron job as well, its just that the cron generates those errors. I still get the output from the sitemonitor if anything has changed. I was just curious if anybody elses cron output was like that(if anybody even checks it). Quote Link to comment Share on other sites More sharing options...
Sid04 Posted August 12, 2006 Share Posted August 12, 2006 I have to block out my admin directory or the script times out. Is there a way to specify not to scan certain folders within the admin directory, such as images, so that we can scan the other php files in admin and not timeout? Would something like this work? : $excludeList = array("cgi-bin","admin/images","downloads","images","pub","tmp","temp"); Im back to this point. I was mistaken, the "admin/images" part didnt work. The admin images folder was still in the reference file. Any ideas how how to block just this folder or any subfolder? Quote Link to comment Share on other sites More sharing options...
Rezolles_Net Posted August 12, 2006 Share Posted August 12, 2006 Warning</b>: session_start() [<a href='function.session-start'>function.session-start</a>]: Cannot send session cookie - headers already sent in <b>/home2/mydomain/public_html/catalog/admin/includes/functions/sessions.php</b> on line <b>67</b><br /> <br /> <b>Warning</b>: session_start() [<a href='function.session-start'>function.session-start</a>]: Cannot send session cache limiter - headers already sent (output started at /home2/mydomain/public_html/catalog/admin/includes/functions/sessions.php:67) in <b>/home2/mydomain/public_html/catalog/admin/includes/functions/sessions.php</b> on line <b>67</b><br /> <br /> <b>Warning</b>: main(includes/languages/english/) [<a href='function.main'>function.main</a>]: failed to open stream: No such file or directory in <b>/home2/mydomain/public_html/catalog/admin/includes/application_top.php</b> on line <b>133</b><br /> <br /> <b>Warning</b>: main() [<a href='function.include'>function.include</a>]: Failed opening 'includes/languages/english/' for inclusion (include_path='.:/usr/lib/php:/usr/local/lib/php:/home2/mydomain/public_html/catalog/admin') in <b>/home2/mydomain/public_html/catalog/admin/includes/application_top.php</b> on line <b>133</b><br /> I also facing with that problem Quote Link to comment Share on other sites More sharing options...
matrix2223 Posted August 13, 2006 Share Posted August 13, 2006 (edited) Hi Jack, Thanks agian for this supper tool. Their is only one issue that I see. I think I just have a configure that I didnt do but not sure what. The script works great when you run it manually, but it finds nothing when it runs with a cron job. Any ideas? What does it mean when the times are mismatched? Thanks, Eric Edited August 13, 2006 by matrix2223 Quote Eric Keep up on osCommerce changes and updates at Github | Understand osCommerce a little further at OsCommerce Documentation | Copy and paste your error message in Google add "in osCommerce" at the end to get relevant answers to most issues. Link to comment Share on other sites More sharing options...
Jack_mcs Posted August 13, 2006 Author Share Posted August 13, 2006 Are you getting an error message from cron? When a file is written to the server, the date and time are recorded for when that happened. So if the times don't match, it means the file has been rewritten. Jack Quote Support Links: For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc. Get the latest versions of my addons Recommended SEO Addons Link to comment Share on other sites More sharing options...
pyramids Posted August 14, 2006 Share Posted August 14, 2006 (edited) Great script, everything is working but.... If I delete a file and change a permission - only the deleted file is shown as being changed. Anyway we can show both changes? Edited August 14, 2006 by pyramids Quote Link to comment Share on other sites More sharing options...
Jack_mcs Posted August 14, 2006 Author Share Posted August 14, 2006 If a file is deleted, the rest of the checking is skipped. The reason for this is because in order to compare the reference file with the new list when a file is deleted, multiple compares would have to be performed between the two lists. That would take too much time for most servers and the script would time out. There is a way to code around it but I didn't think it was worth the time when I was writing it since, I think, most sites don't delete files as a general rule. But it can be added to the next version. For now, if a file is intentionally deleted, it is best to also delete the reference file. Jack Quote Support Links: For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc. Get the latest versions of my addons Recommended SEO Addons Link to comment Share on other sites More sharing options...
matrix2223 Posted August 15, 2006 Share Posted August 15, 2006 Hi Jack, Im not getting any errors from the cron job. When it sends me the email it says everything is fine. Even though I have been working on it and adding a bunch of new files. Howerver when I run it automatically. It tells me all the necessarry stuff. No biggie to me I was just wondering if it was something that I was supposed to set with it the sitemonitor.php Thanks, Eric Quote Eric Keep up on osCommerce changes and updates at Github | Understand osCommerce a little further at OsCommerce Documentation | Copy and paste your error message in Google add "in osCommerce" at the end to get relevant answers to most issues. Link to comment Share on other sites More sharing options...
Jack_mcs Posted August 15, 2006 Author Share Posted August 15, 2006 The only difference between running it from cron and manually, is that the path may be different. Try deleting the reference file and let cron create it when it runs. That might fix it. Jack Quote Support Links: For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc. Get the latest versions of my addons Recommended SEO Addons Link to comment Share on other sites More sharing options...
pyramids Posted August 24, 2006 Share Posted August 24, 2006 Jack I modified the script to do the following: 1: Keep a detailed log 2: Update the reference file every time there are changes. 3: Added a timer 4: Will now check all file changes including deleted files 5: List sub directories to exclude 6: Removed the call to "require('includes/application_top.php')" and updated the mail function 7: Updated message and email reporting Besides being a script to keep an eye out for hackers....especially any 777 folders - it now is a great way to journal any modifications automatically. If you are interested I will post the script Quote Link to comment Share on other sites More sharing options...
Jack_mcs Posted August 24, 2006 Author Share Posted August 24, 2006 Update the reference file every time there are changes.Doesn't this defeat the purpose? If an email is missed or not delivered for some reason, one would never know a change has been made. Jack Quote Support Links: For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc. Get the latest versions of my addons Recommended SEO Addons Link to comment Share on other sites More sharing options...
pyramids Posted August 24, 2006 Share Posted August 24, 2006 I updated the script to be more of a journal to keep a running list of all changes. This way a year from now I won't be referencing files I may have removed or changed due to a modification. The script updates a log besides the email so a missing email shouldn't be a problem. Quote Link to comment Share on other sites More sharing options...
pyramids Posted August 24, 2006 Share Posted August 24, 2006 I updated the script to be more of a journal to keep a running list of all changes. This way a year from now I won't be referencing files I may have removed or changed due to a modification. The script updates a log besides the email so a missing email shouldn't be a problem. Jack, After thinking about it you have a good point...In regard to the ref file and when it is written: I added the ability for the user to choose between a journal that writes a new ref file every time there are changes or the original way of writing the file one time only that can only be overwritten when the user deletes the ref file. Have a nice day! Quote Link to comment Share on other sites More sharing options...
Sid04 Posted August 27, 2006 Share Posted August 27, 2006 (edited) 5: List sub directories to exclude6: Removed the call to "require('includes/application_top.php')" and updated the mail function Im interested in those two changes. Can we just remove the 'require('includes/application_top.php')' part without anything else being effected? Some of my cron job errors refer to application_top.php. Edited August 27, 2006 by Sid04 Quote Link to comment Share on other sites More sharing options...
pyramids Posted August 27, 2006 Share Posted August 27, 2006 Im interested in those two changes. Can we just remove the 'require('includes/application_top.php')' part without anything else being effected? Some of my cron job errors refer to application_top.php. It is more involved than just a few simple changes. PM me with your email address and I will email you the updated script. Quote Link to comment Share on other sites More sharing options...
Jack_mcs Posted August 27, 2006 Author Share Posted August 27, 2006 Im interested in those two changes. Can we just remove the 'require('includes/application_top.php')' part without anything else being effected? Some of my cron job errors refer to application_top.php. If your cron job is failing on that, it is because it is not setup correctly. You probably have to add a command to cd into the admin directory, something like cd /home/user/public_html/admin/; Jack Quote Support Links: For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc. Get the latest versions of my addons Recommended SEO Addons Link to comment Share on other sites More sharing options...
Guest Posted September 12, 2006 Share Posted September 12, 2006 Hi, Is it possible to get this great contribution to check changes in directory permissions also? Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.