Closed michael1026 closed 2 years ago
I was able to get around this issue using for f in $(cat myfile.txt); do ... done
instead. Not sure why the other loop wasn't working, so it actually might not be an issue with this project.
Hi there, apologies for the late reply. I had the same issue a while ago and ended up fixing it in a similar way as well. It's also in the docs.
I think there's a way to change something in the code to avoid this entirely, but not really sure what to touch :smile:
Ah! How did I mange to miss that in the docs. Thanks for the reply.
Hello,
I noticed when running fleex scans from within a bash loop, it causes an issue with SSH. I have not been able to figure out the solution to this yet, but it should be easy to reproduce.
Error I get:
FATA[0002] terminal make raw:inappropriate ioctl for device
Working bash script
Erroring bash script
You should even be able to reproduce with less code...
Possible code in question: https://github.com/FleexSecurity/fleex/blob/f4a0d874ba5c933dec2602145abfca1fdb8ef980/pkg/sshutils/sshutils.go#L101
Possible solution 1: https://github.com/golang/go/issues/19909 Possible solution 2: https://github.com/c-bata/go-prompt/issues/88
Thanks!