d2jsp
Log InRegister
d2jsp Forums > Off-Topic > Computers & IT > Programming & Development > Ethics Of Io.filesystemwatcher And Io.file Reading
Add Reply New Topic New Poll
Member
Posts: 15,960
Joined: Nov 29 2008
Gold: 40.64
Dec 9 2021 10:57pm
I'm not very knowledgeable about coding. And i'm wondering about the ethical use of thing like IO.FileSystemWatcher and /or IO.File.ReadAllLines for monitoring changes in files from third party software and the OS (Windows 10).
I recently started making a custom user interface for Windows using Visual Basic. Currently i have buttons on the side of my screen i manually click to change my user interface theme / profiles. But i would like to automate some of this if possible since i always use certain themes with certain apps or streaming setups.

I've been trying to think of ways to detect changes within the apps i use. Detecting changes in the files has been my only simple idea so far. Using FileSystemWatcher to detect when files have been written to, and it would be useful if i used IO.File.ReadAllLines so i can read text file log and compare the strings for changes, etc.

And it occurred to me that maybe this is considered spying on other software? I this even an argument? Does anybody know what the industry standard is for using these types of tools. To be clear i won't be writing, moving, data collecting, or making copies of anything. My app would just be reading and watching for changes. Is this considered ethical from my position?

One reason this concerns me is because i'm a big gamer and i wouldn't want to bother any of these companies or violate any TOS, EULA, etc. Am I being paranoid worrying about using FileSystemWatcher? I'm quite ignorant about these matters.

This post was edited by NatureNames on Dec 9 2021 11:00pm
Member
Posts: 12,703
Joined: May 17 2013
Gold: 2,935.00
Dec 10 2021 07:59am
It's completely fine to read any file on your system. I wouldn't write to them unless you know it's only a log file, to avoid breaking other applications though.

Games only start being mad at you if you start reading/writing process memory, or if you edit(write) game files.

This post was edited by Klexmoo on Dec 10 2021 08:00am
Member
Posts: 22,237
Joined: Dec 6 2008
Gold: 2,971.74
Trader: Mediator
Dec 10 2021 11:03am
You're not reading the changes, right? Just looking for changes? It's your computer, can you spy on yourself? :P

I would suggest making a 'ignore this process' button because some of them might blow up your logger if it's not multithreaded, even if it is, it'd be a lot of logging!
Member
Posts: 15,960
Joined: Nov 29 2008
Gold: 40.64
Dec 10 2021 07:32pm
Quote (Candyzcanes @ Dec 10 2021 09:03am)
You're not reading the changes, right? Just looking for changes? It's your computer, can you spy on yourself? :P

I would suggest making a 'ignore this process' button because some of them might blow up your logger if it's not multithreaded, even if it is, it'd be a lot of logging!


One method does involve reading a file and to see if it contains a certain word. I'll show what I have in mind:

In this example, first I watch the directory for write changes to any text files there:





When a change has been detected, it then runs this code to read a log file and see if the last line contains the word "Exiting" and if it does, it triggers a function I want:




Is this too invasive? If its questionable, i'd rather be cautious and not do it.
I feel like there is probably a more hands-off approach to detecting this same thing, but any ideas i've googled involved a lot of code way over my head. This project is just for fun but it's time consuming learning new things. I was trying to keep things as simple as i could.
Member
Posts: 22,237
Joined: Dec 6 2008
Gold: 2,971.74
Trader: Mediator
Dec 10 2021 07:34pm
Quote (NatureNames @ Dec 10 2021 06:32pm)
One method does involve reading a file and to see if it contains a certain word. I'll show what I have in mind:
In this example, first I watch the directory for write changes to any text files there:
https://i.imgur.com/3YjETlH.png



When a change has been detected, it then runs this code to read a log file and see if the last line contains the word "Exiting" and if it does, it triggers a function I want:

https://i.imgur.com/DngYro8.png


Is this too invasive? If its questionable, i'd rather be cautious and not do it.
I feel like there is probably a more hands-off approach to detecting this same thing, but any ideas i've googled involved a lot of code way over my head. This project is just for fun but it's time consuming learning new things. I was trying to keep things as simple as i could.


I don't know the language, but it seems fine to me. Nothing invasive about checking your own pcs logs, as long as your LoadDesktopUI() is linear time then i don't see why not
Go Back To Programming & Development Topic List
Add Reply New Topic New Poll