Shaggydog
(Fresh Scripter)
2003-09-02 09:07 PM
Implementing virus tools network-wide

Hi.

Due to the problems we've had with the viruses around the company,I'm being asked to create a script that will copy a file from our server to a local machine, and then to run that file from the local machine.

Anythoughts?

Thanks for your help.
Shaggy


Shaggydog
(Fresh Scripter)
2003-09-02 09:09 PM
Re: Implementing virus tools network-wide

I also would like to build an if statement around the entire function.

I'd like for the script to look to see if the file is already present in the dir. that would mean the script had already run it once, and would not need to again.

Thanks again


Jack Lothian
(MM club member)
2003-09-02 09:10 PM
Re: Implementing virus tools network-wide

You could copy it in your logon script & then poke the name of the exe into the runonce key so it will run right after logon. Reboots might be a problem if this is necessary plus you need to set a flag somewhere so you will not instal the update twice.

LonkeroAdministrator
(KiX Master Guru)
2003-09-02 09:12 PM
Re: Implementing virus tools network-wide

not sure what is so hard in this.
copy "serverlocation" "locallocation"
run "locallocation"


Mart
(KiX Supporter)
2003-09-02 09:15 PM
Re: Implementing virus tools network-wide

You could copy a txt file or so along with the program file. Do a check if the txt file exists before copying the program file to avoid double copying.

If this is a virus canner or so you probably need your users to have admin privileges. If they don’t have this you can use the taskscheduler UDF or (not desirable because of security issues) use su.

Do a search on the taskschedular UDF or su and you'll find what you need.


Kdyer
(KiX Supporter)
2003-09-02 09:17 PM
Re: Implementing virus tools network-wide

quote:

You could copy a txt file or so along with the program file. Do a check if the txt file exists before copying the program file to avoid double copying.

Why? Why not look for a Reg Key or value?

Kent


LonkeroAdministrator
(KiX Master Guru)
2003-09-02 09:18 PM
Re: Implementing virus tools network-wide

if you want to check file, these will be enough:
-filename
-filetime same
-file size same

checking these you can verify, you have already done the job.
if you want to be sure, you need to check from registry that the update has done.

could I ask what AV you use?


Shaggydog
(Fresh Scripter)
2003-09-02 09:28 PM
Re: Implementing virus tools network-wide

We use Norton Antivirus corporate edition here at our headquarters. Trouble is that we never got the funding to buy the extra licenses for the plants out of town. Anyways, here's where I'm at.

Copy "f:\FixVirus.exe" "C:\temp"

That, according to my manual, should work.
How would I go about coding that check for filename?


Mart
(KiX Supporter)
2003-09-02 09:28 PM
Re: Implementing virus tools network-wide

Just checking the registry, check if the file exist, check the version or something should be enough indeed.

LonkeroAdministrator
(KiX Master Guru)
2003-09-02 09:34 PM
Re: Implementing virus tools network-wide

read the manual about getfiletime() and getfilesize()
whit these, being the same as the one on the server, you can be quite sure.


Shaggydog
(Fresh Scripter)
2003-09-02 10:00 PM
Re: Implementing virus tools network-wide

Apparently this is a file that will only run with administrative rights. I tried doing
run "C:temp\FixVirus.exe" /user:administrator
/password:blahblahblah

Doesn't seem to run.


Mart
(KiX Supporter)
2003-09-02 10:02 PM
Re: Implementing virus tools network-wide

Quoting myself [Big Grin]

quote:

If this is a virus canner or so you probably need your users to have admin privileges. If they don’t have this you can use the taskscheduler UDF or (not desirable because of security issues) use su.



LonkeroAdministrator
(KiX Master Guru)
2003-09-03 12:25 AM
Re: Implementing virus tools network-wide

shaggyboy, sure it runs.
it fails to work though [Big Grin]

like r2d2 said, you need to tweak the thing.


Sealeopard
(KiX Master)
2003-09-17 11:30 PM
Re: Implementing virus tools network-wide

Running applicaitons with admin powers is explained in the FAQ Forum.