l-teles / steampipe-plugin-detectify

Detectify plugin for Steampipe
https://hub.steampipe.io/plugins/l-teles/detectify
Apache License 2.0
2 stars 1 forks source link

Initial suggestions for plugin release #3

Closed misraved closed 1 month ago

misraved commented 1 month ago

Thank you @l-teles for the new plugin. The basic structure and results look good so far. While using the plugin, we did come up with a few suggestions based on our best practices:

  select
    to_char(created_at, 'YYYY-MM-DD HH24:MI:SS') as "Creation Date",
    date_part('day', NOW() - created_at) AS "Days Open",
    status as "Status",
    cvss_scores -> 'cvss_3_1' ->> 'severity' as "Severity",
    host as "Asset",
    title as "Title",
    case
      when source ->> 'value' = 'surface-monitoring' then 'EASM'
      else 'WebApp Scan'
    end as "Source",
    location as "URL",
    definition ->> 'description' as "Description"
from
  detectify_finding
where
  status not in ('accepted_risk','patched','false_positive');

Overall the plugin looks great, the tables and the example queries are very compact.

Great work 🎉 !!

l-teles commented 1 month ago

Hi @misraved,

Thank you very much for your review and support!

Can you please have a look into #4? It should address all your suggestions :)

Regarding:

Could you please explain the difference between DETECTIFY_API_SECRET and DETECTIFY_API_TOKEN_V3 config arguments?

This was actually a typo on the README.md that was fixed on #1 on detectify.spc but not in the README. The variable name for DETECTIFY_API_TOKEN_V3 should be tokenv3 instead. It is also fixed as part of the PR ☝️.