Code Duplication    Length = 28-28 lines in 2 locations

gvm/protocols/gmpv8/types.py 1 location

@@ 179-206 (lines=28) @@
176
        ) from None
177
178
179
class FilterType(Enum):
180
    """Enum for filter types"""
181
182
    AGENT = "agent"
183
    ALERT = "alert"
184
    ASSET = "asset"
185
    SCAN_CONFIG = "config"
186
    CREDENTIAL = "credential"
187
    FILTER = "filter"
188
    GROUP = "group"
189
    HOST = "host"
190
    NOTE = "note"
191
    OPERATING_SYSTEM = "os"
192
    OVERRIDE = "override"
193
    PERMISSION = "permission"
194
    PORT_LIST = "port_list"
195
    REPORT = "report"
196
    REPORT_FORMAT = "report_format"
197
    RESULT = "result"
198
    ROLE = "role"
199
    SCHEDULE = "schedule"
200
    ALL_SECINFO = "secinfo"
201
    TAG = "tag"
202
    TARGET = "target"
203
    TASK = "task"
204
    TICKET = "ticket"
205
    USER = "user"
206
    VULNERABILITY = "vuln"
207
208
209
def get_filter_type_from_string(

gvm/protocols/gmpv208/types.py 1 location

@@ 172-199 (lines=28) @@
169
        ) from None
170
171
172
class FilterType(Enum):
173
    """Enum for filter types"""
174
175
    ALERT = "alert"
176
    ASSET = "asset"
177
    SCAN_CONFIG = "config"
178
    CREDENTIAL = "credential"
179
    FILTER = "filter"
180
    GROUP = "group"
181
    HOST = "host"
182
    NOTE = "note"
183
    OPERATING_SYSTEM = "os"
184
    OVERRIDE = "override"
185
    PERMISSION = "permission"
186
    PORT_LIST = "port_list"
187
    REPORT = "report"
188
    REPORT_FORMAT = "report_format"
189
    RESULT = "result"
190
    ROLE = "role"
191
    SCHEDULE = "schedule"
192
    ALL_SECINFO = "secinfo"
193
    TAG = "tag"
194
    TARGET = "target"
195
    TASK = "task"
196
    TICKET = "ticket"
197
    TLS_CERTIFICATE = "tls_certificate"
198
    USER = "user"
199
    VULNERABILITY = "vuln"
200
201
202
def get_filter_type_from_string(