Trax Posted July 20, 2014 Share Posted July 20, 2014 I have written a program that needs to be running on the users computers 100% of the time. The program is not very popular with the users because it limits what they can do with the computer hence they are always trying to find a way to defeat the program and terminate it. The program is started by putting an entry in the registry (HKLMSoftwareMicrosoftWindowsCurrent VersionRun). On Windows 7 they are defeating it by opening Wordpad and with Wordpad open shutting down the computer. When the computer starts to shutdown Wordpad asks if they want to save the current document. If they just let it sit at that point Windows pops up with the screen saying "These programs are open" and gives them two options. Eithe Folrce the programs to close or Cancel the shutdown. If they cancel the shutdown my program has already been close and they can continue their Windows session without my program running. Not good. I do use the WM_CLOSE() function to politely exit my progam and am wondering if that is where I leave myself open to this issue. If I take out the WM_CLOSE() function with this avert the above mentioned problem? Any ideas on how to keep them from doing this would be greatly appreciated. Thanks! Link to comment Share on other sites More sharing options...
232showtime Posted July 20, 2014 Share Posted July 20, 2014 why do you want to run your program to other computers?? are you spying on them?? smells like keylogger.. this is where malware/spyware goes, HKLMSoftwareMicrosoftWindowsCurrent VersionRun + NoFolderOption. ill get to that... i still need to learn and understand a lot of codes Correct answer, learn to walk before you take on that marathon. Link to comment Share on other sites More sharing options...
Shane0000 Posted July 20, 2014 Share Posted July 20, 2014 Who is them and why are they going through so much effort to make sure your program isn't running? Link to comment Share on other sites More sharing options...
Moderators Melba23 Posted July 20, 2014 Moderators Share Posted July 20, 2014 Trax,Welcome to the AutoIt forums. I would like a lot more information before you get any help. Why does this program need to run on these computers? What is it intended to stop the users from doing? Why can you not impose other sanctions to dissuade them from closing it? Over to you. All,Just to make things absolutely clear - DO NOT POST in this thread until the all clear is given. M23 Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area Link to comment Share on other sites More sharing options...
Trax Posted July 20, 2014 Author Share Posted July 20, 2014 Thanks for the welcome Melba23. In short it limits what the users can do and the programs they are allowed to use. The boss thinks too much time is wasted on non-business related activities. What do you mean "Why can you not impose other sanctions to dissuade them from closing it?"? Threat of termination doesn't seem to work. Trying to make it "tamper proof". Link to comment Share on other sites More sharing options...
Moderators Melba23 Posted July 20, 2014 Moderators Share Posted July 20, 2014 Trax, Threat of termination doesn't seem to workInteresting working environment.... Are the machines networked? M23 Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area Link to comment Share on other sites More sharing options...
Trax Posted July 20, 2014 Author Share Posted July 20, 2014 (edited) I don't know. I think it is the same old story of a few wrecking it for so many. I think of it like Parental Controls. There are only one or two people abusing things and they wreck it for everyone else. It really isn't any worse than web filters or not allowing them to put there own software on. I am not collecting any data of logging anything. Just restricting what they can do and where they can go. The computers are networked. So... any ideas? Edited July 20, 2014 by Trax Link to comment Share on other sites More sharing options...
Shane0000 Posted July 21, 2014 Share Posted July 21, 2014 I dont see anyone jumping in on this and you last asked for ideas ... Perhaps you can set a host program on the server and have your program ping the program on the server , let the server program check for time between pings, if greater than your preferred inactivity time, alert or take some action. Every one should have unique non dynamic IPs (I assume this is a office intranet) so it should be easy to see which user's program is no longer running. Should work also if they block the program in firewall, Not sure if this is a good idea or bad idea but its what I would try with my limited programming finesse Link to comment Share on other sites More sharing options...
232showtime Posted July 21, 2014 Share Posted July 21, 2014 I assume that you are an ITAdmin coz you want to limit user on something, well I dont have much experience on windows server but I guess windows server can restrict user on doing such non-related activities. you also don't know if the machines are networked, Let the admin make the decision... :muttley: ill get to that... i still need to learn and understand a lot of codes Correct answer, learn to walk before you take on that marathon. Link to comment Share on other sites More sharing options...
Moderators Melba23 Posted July 21, 2014 Moderators Share Posted July 21, 2014 Trax,if the machines are networked then I believe you should be able to limit activities by setting permissions - I will ask someone who know more about networks to look in. Shane0000 & 232showtime,Which bit of:All,Just to make things absolutely clear - DO NOT POST in this thread until the all clear is given. M23did you not understand? As it happens, you both suggested the same thing as myself, which is the only reason I am taking no further action. But think yourselves extremely lucky. M23 232showtime 1 Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area Link to comment Share on other sites More sharing options...
jvanegmond Posted July 21, 2014 Share Posted July 21, 2014 You should create a service out of your AutoIt script. Services are shut down after the normal applications and have a whole set of recovery options, for example to restart the service whenever it is killed. Normal users also do not have permissions to disable or stop services (by default, though this can be changed). Make sure to "Allow service to interact with the desktop". Gr, Mana github.com/jvanegmond Link to comment Share on other sites More sharing options...
Trax Posted July 23, 2014 Author Share Posted July 23, 2014 Thanks Mana. The suggestion of turning it in to a service seems like the only real alternative but I can't seem to find out how to do that. I have asked if current scripts (V3.3.12.0) could be installed natively with the SC command or whether they need to be wrapped with something like Svrany or _Services_UDF V4 and I haven't been able to get any responses. It is like talking about services is taboo for some reason. Hopefully this weekend maybe someone will respond. Only time will tell..... Link to comment Share on other sites More sharing options...
Moderators JLogan3o13 Posted July 23, 2014 Moderators Share Posted July 23, 2014 I would ask (again) what exactly are you trying to restrict, and what sort of network you have in place? With 2008 and above A.D., you can restrict a vast array of activities, without the need for a registry-based script that runs as a service. Can you please give some examples of what I, as WorkerA, might be doing that you want to stop me from accomplishing? "Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball How to get your question answered on this forum! Link to comment Share on other sites More sharing options...
Trax Posted July 23, 2014 Author Share Posted July 23, 2014 Thanks for the reply JLogan3o13. I am aware of what you can do with GPOs in a AD environment. That is actually what I do for a living. I really don't want to have to rely on the computers being networked in a AD environment. There are a lot of standalone computers in this environment too. I need to make it as generic as possible it will work on a standalone or networked computers. I don't think what I am trying to do is really relavant. Let's say instead of restricting what the users do I simply want to write a program that logs how much time a user spends on the computer. It is the exact same senario. They can do the above mentioned "Word Pad Work Around" to kill my program and it will no longer be tracking how much time they spend on the computer. What I really need to focus on is getting an AutoIT script to function well as a service. Link to comment Share on other sites More sharing options...
Moderators JLogan3o13 Posted July 23, 2014 Moderators Share Posted July 23, 2014 And you have to understand, too, when you offer only vague responses to questions regarding your intent on inserting a Service-level script into a bunch of machines, that there is going to be a lot of skepticism. I do this for a living too, and was gently pointing out that there are GPOs and security measures in place for a reason. What you have posted thus far still begs the question why you feel the need to circumvent these measures. We'll let the Mods weigh in, but I find the "what I'm trying to do is not relavant (sic), just tell me what I want to know" is not an acceptable answer. "Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball How to get your question answered on this forum! Link to comment Share on other sites More sharing options...
Moderators Melba23 Posted July 23, 2014 Moderators Share Posted July 23, 2014 Trax,I agree with JLogan3o13. I allowed the thread to continue because I assumed that network policy would provide sufficient control for you. But the vagueness of your replies is reigniting my initial concerns - please provide some specifics or I will be forced to do what I have been trying very hard to avoid. M23 232showtime 1 Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area Link to comment Share on other sites More sharing options...
Bert Posted July 23, 2014 Share Posted July 23, 2014 Everyone, I've been working with Trax privately in a PM. I can tell you what he is doing is legit and I'm helping him solve the service issue. Steve, if you would like for me to invite you to the PM I'm happy to do so. The Vollatran project My blog: http://www.vollysinterestingshit.com/ Link to comment Share on other sites More sharing options...
Moderators Melba23 Posted July 23, 2014 Moderators Share Posted July 23, 2014 MBALZESHARI,No need - if you are happy then so am I. M23 Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area Link to comment Share on other sites More sharing options...
Bert Posted July 23, 2014 Share Posted July 23, 2014 Thanks. The Vollatran project My blog: http://www.vollysinterestingshit.com/ Link to comment Share on other sites More sharing options...
Bert Posted July 23, 2014 Share Posted July 23, 2014 (edited) To explain it simply for everyone: The environment Trax supports is a mix of stand alone PCs as well as network PCs. He needs ALL the PCs to have the same controls as afar as restrictions. Currently he has running an AutoIt solution on each PC that for the most part works fine. The problem is he has several users who have figured out ways to defeat the AutoIt solution by 'cancelling a "in progress" shutdown'. With a "cancelled in progress shutdown" all the programs that were not running as a service get cut off and this kills the AutoIt solution, thus allowing users to have access to things and websites that the company does not desire. His company is very happy with the AutoIt solution so buying a specific product to do what the AutoIt solution does is simply not in the cards here. Saying that, the helpful suggestions to go this route will not be used. With the other suggestion that he use AD, seeing how some of the PCs are standalone using AD is not the best way to go. Having to deal with this problem myself in years past; Trax and I agree running the AutoIt solution as a service is the best solution. This will prevent the users from using the "cancelling a in progress shutdown" method of defeating the AutoIt solution. I found on the Wiki this information on how do run an AutoIt script as a service. http://www.autoitscript.com/wiki/FAQ#How_can_I_create.2Fstart.2Fstop_or_otherwise_control_a_service.3F Edited July 23, 2014 by MBALZESHARI The Vollatran project My blog: http://www.vollysinterestingshit.com/ Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now