alexsen
Aug 26 2003, 08:48 AM
Is there a file cleaner or a pipe command in linux that will clean the text like this :
ip - text
xxx.xxx.xxx.xxx text
xxx.xxx.xxx.xxx text
to just remove the text ?
i am askiing strange things
OneNight
Aug 26 2003, 08:55 AM
I usually do stuff like that with mirc (/filter command and $left, in ur case). So if ur familiar with mirc scripting i suggest you use it!
But i am sure whater language you are experienced with will do the job.
alexsen
Aug 26 2003, 08:59 AM
that is the problem i haven't started any language yet, i will soon thought i got some nice eBooks.
mrBob
Aug 26 2003, 09:38 AM
ehm, copy/paste the text in notepad and replace ' text' with nothing?
then copy/paste it back
dR4g0N
Aug 26 2003, 10:01 AM
those things u can make with perl :> a friend wrote me an perl script some times ago, that pings the xray sql results and wrote it in another txt with user/pass.
usage: perl sql_ping.pl ???1.txt ???2.txt
alexsen
Aug 26 2003, 10:27 AM
sorry but i always got an error on line 5 but thanks a lot
dR4g0N
Aug 26 2003, 10:38 AM
hmm lil example:
when u have a txt called scan.txt (with xray sql results) - so u must use it:
perl sql_ping.pl scan.txt scanresults.txt
---
instead of scanresults.txt u can choose lala.txt ^^
ahh and u need a perl interpreter
FLW
Aug 26 2003, 02:04 PM
Logged in as root, from the cmd line "rm -rf /etc/filename.ext | touch /etc/filename.ext" .
The only issue I can think of is permissions. This would depend on what the file is for and is it dynamically accessed or just on boot up.
The other is if the file is not very long, open your text editor of choice and just delete the lines and save. No permission issues.
I would also steer clear of using someone elses scripts of any language unless you know the language. Even with positive intent on the script writers part, on the wrong disto it could be a disaster or could mislead you as to the cause of your problem. This is a point for any issue you may incounter. This would also apply to command line statements like the one above. i.e rm=remove rf=recursively force which will delete any sub direcories as well as files. rm -rf can be the kiss of death to your OS if accidently used incorrectly.
You need to have a basic understanding of the cmd line before any real scripting so you understand "other" reasons it may work or fail.
dozolax
Dec 20 2003, 03:29 AM
good post
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please
click here.