Skip to content

[FEATURE] Add list processing in CPE sections #17

Description

@e6e6e

Is there an existing feature request or discussion for this?

  • I have searched the existing feature requests and discussions

Problem

It would be logical to add the ability to specify a list of CPEs for one software.
At the current moment, if I specify a list of CPE for one software in infrastructure profile, then an error occurs when processing a string value.

For example like this:

  • role: Workstations
    category: Host
    id: S0003
    cpe-fs:
    • 'cpe:2.3:o:microsoft:windows_10::::::::'
    • 'cpe:2.3:o:microsoft:windows_8.1::::::::'`

Error:
File "/usr/local/lib/python3.11/dist-packages/cpe/cpe.py", line 231, in __init__ self._str = cpe_str.lower() ^^^^^^^^^^^^^ AttributeError: 'list' object has no attribute 'lower'

Solution

Always use a list with CPE and process each element of this list.

Improvements

No response

Anything else?

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    Status
    Todo

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions