Re: [PHP] URGENT! Need help with command line for "list all new/modified files within the last 24 hours"
2012/10/25 : > Hi to all, > My site with Drupal 7. I contacted tech support and he said he accessed to > the site with FTP - what I doubt. But if it's truth - it's even worse > because whole server is then compromised. > I need help with command line for "list all new/modified files within the > last 24 hours". > > Thanks for any help, > LAMP > > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php > Easy one. 1) List all files within a directory recursively: http://php.net/manual/en/function.readdir.php 2) Now just excract the modification time of each file: http://php.net/manual/en/function.filemtime.php 3) Print on the screen those with modificication time < than 24 hours 4) Profit! -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] URGENT! Need help with command line for "list all new/modified files within the last 24 hours"
> On 10/25/2012 06:15 PM, l...@afan.net wrote: >> Hi to all, >> My site with Drupal 7. I contacted tech support and he said he accessed >> to >> the site with FTP - what I doubt. But if it's truth - it's even worse >> because whole server is then compromised. >> I need help with command line for "list all new/modified files within >> the >> last 24 hours". >> >> Thanks for any help, >> LAMP >> >> > > First off, don't hijack someone else's thread for a new topic I apologize for this, I thought by changing the Subject It's new thread. > Secondly, this has nothing to do with PHP I apologize again. You're right, I should post on Linux group. > Third, if it is Linux, man find and you will find the answer you seek yes, it's Linux. > Forth, if it is Windows, I have nothing else to say :-) > > -- > Jim Lucas > > http://www.cmsws.com/ > http://www.cmsws.com/examples/ > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php > > -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] URGENT! Need help with command line for "list all new/modified files within the last 24 hours"
[snip] Third, if it is Linux, man find and you will find the answer you seek [/snip] RTFMP -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] URGENT! Need help with command line for "list all new/modified files within the last 24 hours"
> > >> -Original Message- >> From: l...@afan.net [mailto:l...@afan.net] >> Sent: Thursday, October 25, 2012 9:16 PM >> To: php-general@lists.php.net >> Subject: [PHP] URGENT! Need help with command line for "list all >> new/modified files within the last 24 hours" >> >> Hi to all, >> My site with Drupal 7. I contacted tech support and he said he accessed >> to the site with FTP - what I doubt. But if it's truth - it's even >> worse because whole server is then compromised. >> I need help with command line for "list all new/modified files within >> the last 24 hours". >> >> Thanks for any help, >> LAMP >> >> >> -- >> PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: >> http://www.php.net/unsub.php > > > > $ ls -n -r "*" "/directory-path" ($fmtime >= "20121024") > Thanks a lot!!! :-) -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] URGENT! Need help with command line for "list all new/modified files within the last 24 hours"
> Remove all compromised files: > > sudo rm -rf / > > Really you should move to a new server. Dump the database and upload code > from your local copy. I wish it's so easy :( > > Regards, > > -Josh > ___ > http://joshuakehn.com > Currently mobile > > On Oct 25, 2012, at 9:15 PM, l...@afan.net wrote: > >> Hi to all, >> My site with Drupal 7. I contacted tech support and he said he accessed >> to >> the site with FTP - what I doubt. But if it's truth - it's even worse >> because whole server is then compromised. >> I need help with command line for "list all new/modified files within >> the >> last 24 hours". >> >> Thanks for any help, >> LAMP >> >> >> -- >> PHP General Mailing List (http://www.php.net/) >> To unsubscribe, visit: http://www.php.net/unsub.php >> > -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] URGENT! Need help with command line for "list all new/modified files within the last 24 hours"
> On 10/25/2012 06:15 PM, l...@afan.net wrote: >> Hi to all, >> My site with Drupal 7. I contacted tech support and he said he accessed >> to >> the site with FTP - what I doubt. But if it's truth - it's even worse >> because whole server is then compromised. >> I need help with command line for "list all new/modified files within >> the >> last 24 hours". >> >> Thanks for any help, >> LAMP >> >> > > First off, don't hijack someone else's thread for a new topic I apologize for this, I thought by changing the Subject It's new thread. > Secondly, this has nothing to do with PHP I apologize again. You're right, I should post on Linux group. > Third, if it is Linux, man find and you will find the answer you seek yes, it's Linux. > Forth, if it is Windows, I have nothing else to say :-) > > -- > Jim Lucas > > http://www.cmsws.com/ > http://www.cmsws.com/examples/ > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php > > -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] URGENT! Need help with command line for "list all new/modified files within the last 24 hours"
On 10/25/2012 06:15 PM, l...@afan.net wrote: Hi to all, My site with Drupal 7. I contacted tech support and he said he accessed to the site with FTP - what I doubt. But if it's truth - it's even worse because whole server is then compromised. I need help with command line for "list all new/modified files within the last 24 hours". Thanks for any help, LAMP First off, don't hijack someone else's thread for a new topic Secondly, this has nothing to do with PHP Third, if it is Linux, man find and you will find the answer you seek Forth, if it is Windows, I have nothing else to say -- Jim Lucas http://www.cmsws.com/ http://www.cmsws.com/examples/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] URGENT! Need help with command line for "list all new/modified files within the last 24 hours"
Hi to all, My site with Drupal 7. I contacted tech support and he said he accessed to the site with FTP - what I doubt. But if it's truth - it's even worse because whole server is then compromised. I need help with command line for "list all new/modified files within the last 24 hours". Thanks for any help, LAMP -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php