mrjackwills / havn

A fast configurable port scanner with reasonable defaults
MIT License
167 stars 5 forks source link

[BUG] something is definitely broken with the windows release #1

Closed ghost closed 1 year ago

ghost commented 1 year ago

Describe the bug something is definitely broken with the windows release

To Reproduce Steps to reproduce the behavior:

  1. Download havn for windows from the latest release as of 17/06/2023
  2. Execute havn from cmd
  3. Do something with it

Expected behavior For the program to display the intended UI and to work correctly

Screenshots image

Desktop (please complete the following information):

Additional context

mrjackwills commented 1 year ago

Thank you, that isn't good. I can't get the issue to replicate on my system, I'm on Windows 11, using cmd.exe it works as expected. I might have Windows 10 on another machine, so I can see if I can get it to error out on that one

dobin commented 1 year ago

Same, win10 cmd/powershell cant handle terminal escape sequences. Maybe an option to disable them?

mrjackwills commented 1 year ago

Same, win10 cmd/powershell cant handle terminal escape sequences. Maybe an option to disable them?

Yeah that was my first idea to fix it. I have implemented a monochrome feature, that won't use escape codes, it is accessed by using the cli arg -m, e.g. havn.exe -m www.youtube.com.

If you would like to test it, and supply feedback if possible, I have built an example of it just for Windows and attached to this comment. If you are unhappy downloading a random binary, there is also a feat/monochrome branch that you could pull and build on your own machine.

Thanks

EDIT - I think there is a more elegant way to do it, by automatically detecting Windows 10, and applying monochrome if that is true. I have update the attached binary here, and the feat/monochrome branch.

EDIT 2 - I think having a -m option is also a good idea, so this latest version has both. It should, on Windows 10, remove all escape codes/coloring automatically, but you can also use the -m flag to do that as well

Download - havn.zip