Not sure how to phrase the title as there are two large concerns with what I am thinking of doing for the review of this question:
Batch script to make folders hidden
It is largely a batch script with some PowerShell in the mix. The latter of which I am more familiar with.
Main issue that I have with the code is that it is implementing a security though obscurity approach. There is no sentiment to this effect so I am not sure whether or not this code is for fun or to be taken seriously.
Also, since the OP is using PowerShell there is, in theory, some familiarity with the language. PowerShell can do the same thing that this code is doing and it would be likely shorter and definitely cleaner and easier to understand.
My two questions based on that are:
- How well received would suggestions be to use another language, in this case PowerShell? I don't mean in this case specifically but have there been other occasions where this has happened where the answerer is a different language? Is it considered a bad practice on CodeReview.
- The whole concept of this code would do very little to provide security other than to fool the most basic of users. Could a review be based on "Don't bother doing this". I'm sure I could make the process a little better but it relies on a password being stored somewhere at a basic level without overly complicating the entire process.
I intend to leave a comment or two to this effect but I am looking for guidance as I am sure these things have happened before.