lib/pwn/plugins/defect_dojo.rb in pwn-0.4.937 vs lib/pwn/plugins/defect_dojo.rb in pwn-0.4.938

- old
+ new

@@ -447,11 +447,13 @@ end # Should only ever return 1 result so we should be good here http_body[:lead] = user_by_username_object.first[:id] end - http_body[:tags] = opts[:tags].to_s.strip.chomp.scrub.gsub("\s,\s", ',').split(',') if opts[:tags] + # http_body[:tags] = opts[:tags].to_s.strip.chomp.scrub.gsub("\s,\s", ',').split(',') if opts[:tags] + # String should include [] around tag values + http_body[:tags] = opts[:tags].to_s.strip.chomp.scrub.gsub("\s,\s", ',').split(',').to_s if opts[:tags] minimum_severity = opts[:minimum_severity].to_s.strip.chomp.scrub.downcase.capitalize case minimum_severity when '', 'Info', 'Low', 'Medium', 'High', 'Critical' # Defaults to 'Info' @@ -557,10 +559,13 @@ # TODO: wait for solution to: # https://github.com/DefectDojo/django-DefectDojo/issues/457 # in order to obtain the unique test resource_uri # by searching tags for unique identifier (would be better to have a unique test names) - http_body[:tags] = opts[:tags].to_s.strip.chomp.scrub.gsub("\s,\s", ',').split(',') if opts[:tags] + + # http_body[:tags] = opts[:tags].to_s.strip.chomp.scrub.gsub("\s,\s", ',').split(',') if opts[:tags] + # String should include [] around tag values + http_body[:tags] = opts[:tags].to_s.strip.chomp.scrub.gsub("\s,\s", ',').split(',').to_s if opts[:tags] http_body[:test] = opts[:test_resource_uri] if opts[:test_resource_uri] minimum_severity = opts[:minimum_severity].to_s.strip.chomp.scrub.downcase.capitalize case minimum_severity