kics icon indicating copy to clipboard operation
kics copied to clipboard

Capacity to override the metadatas of a query

Open jycamier opened this issue 2 years ago • 2 comments

Is your feature request related to a problem? Please describe.

As a final user of KICS, I would like to override the metadata.json file of a query :

  • to set my own documentation in descriptionUrl
  • to set my own severity level on a query

Describe the solution you'd like

I would like the possibility to add in my queries a new query with a single metadata.json file referring to an existing query ID.

Describe alternatives you've considered

  • ignore the existing query
  • copy /past this one in my own query directory
  • change the query ID

jycamier avatar Sep 28 '22 15:09 jycamier

The more I use KICS, the more I think it's a really important feature.

jycamier avatar Sep 30 '22 08:09 jycamier

How do you suggest finding those "custom metadata" files? Through a new flag or a path defined by KICS?

lipeavelar avatar Oct 07 '22 16:10 lipeavelar

The same way to stock custom queries.

jycamier avatar Oct 07 '22 19:10 jycamier

I think the way KICS do with custom queries would be a little strange… What I thought was something more like input data, since, if I understood correctly, just want to overwrite metadata information… What do you think?

lipeavelar avatar Oct 10 '22 22:10 lipeavelar

IMHO, that's not the same thing. The input data is to contextualize a query to business inputs.

On my hand, I want to override existing metadata like :

  • the descriptionUrl of an existing query to put my own documentation with something to help developers
  • the severity of a query : sometime, a specific query must be HIGH in a business context when this one is currently LOW

jycamier avatar Oct 11 '22 08:10 jycamier

I understand your point, but I think I expressed my point wrongly. What I suggested was to follow something like input data overwrite system, like create a custom-metadata folder or update how this behaves to create a folder with query ID and overwrite files that are in there, which I prefer. I'm pointing this, because the way you proposed is not how KICS handles custom queries, but input data overwrite system looks really close to what you want to achieve on overwriting default metadata... I will try to create a proposal of what I'm trying to explain here, and you could check it, WDYT?

lipeavelar avatar Oct 18 '22 20:10 lipeavelar

Alright. Understood ! 😄 It sounds good to me !

jycamier avatar Oct 18 '22 22:10 jycamier

Similar issue https://github.com/Checkmarx/kics/issues/5960

jycamier avatar Oct 26 '22 09:10 jycamier