New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
use taint on syntax check #172
use taint on syntax check #172
Conversation
This add's the -T taint check always, that might break other code that does not use tainting. I think taint checks should be an option. |
That is what I thought first too. But in this case I use it only with -c for syntax checking. The option version didn't look nice to me, since it should detect automatically and no need for adding options. The third way to do it, would be scan the first line and apply -T if it is in the hash bang line. Let me know, how to solve it |
Actually also perl -c can execute code. For example all BEGIN blocks will run, also when you run perl -c . So I think -T should only be applied if necessary. I would go with your third idea, scan the first line and if there is -T in it, also apply it to perl -c. Also it would be a good idea the the -T option also for the debugger. Here it would make sense to do automatic scaning of line 1 and in addition have an option to set -T independed of line 1 |
I go for the small solution (just option, no auto detect) |
If I want to debug code with hashbang and taint, I have the same problem. |
Haveing a similar option in lauch.json for debugging, look like a very good idea. |
Like described in issue #143
Using taint check for syntax check to prevent error message
when first line is like "#!/usr/bin/perl -T" or "#!/usr/bin/perl -t"