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
wrong handling of xml.etreeElementTree objects #19
Comments
Thank you for that insight. Will get time to fix that, Also if you can open a pull request about it that would be fine. |
I sent pr #21 with some untested code, I will use that in my development but I will be able to test only some of the code paths. |
okay |
thank you for merging. as far as I can tell this issue should be resolved, but I hadn't exercised all possible code paths. |
oh and if you could cut a new release on PyPI that would be great |
Okay let get that done. |
Thank you @wangoloj for your quick support, you've been very helpful. As far as I can tell this problem is now fixed in code and also in the PyPI released version, I'm closing the issue. |
This library has code like this in multiple places:
Under some Python / xml.etree versions this will not work as intended, for example I am getting this output from
Nmap().nmap_version_detection()
(notice missing information about port state and service exposed on the port):In the case of
Nmap().nmap_version_detection()
this happens because<state>
and<service>
do not have any further sub-elements and as the docs say:Changing
if(port.find("service")):
withif port.find("service") is not None:
will restore correct behaviour and give complete results like:The text was updated successfully, but these errors were encountered: