Skip to content
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

Error when NoneType value in operating_system - function detected_os in host.py #8

Closed
ricardosupo opened this issue May 14, 2022 · 1 comment

Comments

@ricardosupo
Copy link

ricardosupo commented May 14, 2022

Using Python 3.10.4 in Linux:

_python3.10/site-packages/nessus_file_reader/host/host.py", line 119, in detected_os
    if """ in operating_system:
TypeError: argument of type 'NoneType' is not iterable_

Solution: Verify if is NoneType before if condition:

if operating_system is not None:
    if """ in operating_system:
        operating_system = str(operating_system).strip('["').strip('"]')
    else:
        operating_system = str(operating_system).strip('["').strip('"]')
else:
    operating_system = ''
@damian-krawczyk
Copy link
Collaborator

@ricardosupo check latest release v0.4.2 #10 . This suppose to be fixed now.

spyr0-sec/helper-scripts#1

lapolis added a commit to lapolis/helper-scripts that referenced this issue May 10, 2023
`nessus_file_reader` should be fixed now LimberDuck/nessus-file-reader#8 (comment)

When parsing Unix compliance scans, the `.nessus` file is different so the script breaks because no `complicance_id` is present.

Specified the file encoding, had issues probably because of win<->*nix usual encoding fight
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants