Skip to main content

Batch File/Script

More
16 years 10 months ago #24209 by skepticals
Batch File/Script was created by skepticals
Hopefully someone can point me in the right direction with this situation...

We have a software application that calls a file "Remove.exe" when a user closes Internet Explorer AND when they log off the system (They are not logging off of Windows - just logging off a program.)

I replaced Remove.exe with my own modified file, but I only want the file to execute when someone logs off the system NOT when someone closes Internet Explorer.

Is there a way is some type of batch file or scripting language that I can have the system check if a processes is running? My thought is that when a user logs off there will be at least one less process; so in the batch file I can say somehting like, if this process is running do nothing and if the process is not running do this.

Or is there a better way?

I am open to other ideas as well...

Thanks!
More
16 years 10 months ago #24212 by Smurf
Replied by Smurf on topic Re: Batch File/Script
Group policies can be configured to run a script during logoff.

Wayne Murphy
Firewall.cx Team Member
www.firewall.cx

Now working for a Security Company called Sec-1 Ltd in the UK, for any
Penetration Testing work visit www.sec-1.com or PM me for details.
More
16 years 10 months ago #24213 by skepticals
Replied by skepticals on topic Re: Batch File/Script

(They are not logging off of Windows - just logging off a program.)


They are not logging off of Windows... this is why I am having this problem. In order to resolve it, I want to overwrite a file that the software calls and have it do what I want, but the file I am replacing gets called when a browser is closed and whey they log off (not Windows, it's an application that runs on top of Windows).

Does that make any sense?

I found a web site that will help me with the batch file, but now I am having a problem figuring out when the program calls the file. I am trying to use Windows/Sys Internal process monitor, but I can't make heads or tails of it.
More
16 years 10 months ago #24215 by Smurf
Replied by Smurf on topic Re: Batch File/Script
How is the program called ? Not fully understanding how this program is executed when you close IE and the other application ?

Also, whats the program doing ?

Wayne Murphy
Firewall.cx Team Member
www.firewall.cx

Now working for a Security Company called Sec-1 Ltd in the UK, for any
Penetration Testing work visit www.sec-1.com or PM me for details.
More
16 years 10 months ago #24216 by skepticals
Replied by skepticals on topic Re: Batch File/Script
Sorry, it's hard to explain...

Windows loads.
This software loads that takes up the entire screen and allows for a username and password to be entered. If you enter in a username and password the full screen goes away and allows you to use the computer. It is essentially just a session time program. It will kick the person off after a certain amount of time.

I am not exactly sure how the remove.exe file is called, but all it does is empty Internet Explorer's history. This is why I know I can safely overwrite it. The problem is I want my file to run only when a user is kicked off or logs off the software (again, not Windows).

Thoughts?
More
16 years 10 months ago #24218 by TheBishop
Replied by TheBishop on topic Re: Batch File/Script
Let me get this straight - you want to write a script that (among other things) checks whether a process is running? If so, you can do that in ActiveState Perl. Don't know offhand of a way to do it in a batch file, but I'll think about it
Time to create page: 0.135 seconds