pwndoc-ng / pwndoc-ng

Pentest Report Generator
https://pwndoc-ng.github.io/pwndoc-ng/#/
MIT License
372 stars 84 forks source link

{identifier | changeID: 'PROJ1-'} questions #341

Open HeadGapped opened 8 months ago

HeadGapped commented 8 months ago

Hi,

I understand I can call {identifier | changeID: 'PROJ1-'} and it will change the prefix of IDX to PROJ1, but {identifier | changeID: 'PROJ1-'} needs to be called inside the template itself, meaning any template I run will have the same Identifier.

However, for my use case I would like to set a custom Identifier or changeID before the template is run setting it inside Pwndoc-ng as I use my clients short name for this field.

I want to do this to generate an OWASP top 10 table, using the vulnerability {identifier} and listing it next to which OWASP top 10 it aligns.

Is this possible?

dfktvS2 commented 8 months ago

You may be able to do this with audit and/or finding custom data and a template that uses that custom data as you described.

You could add a custom field to findings for selecting the top 10. then in your template setup your table, for each item in the top 10, filter findings based on that value and print them in the table

I'd recommend throwing some debugging around https://github.com/pwndoc-ng/pwndoc-ng/blob/master/backend/src/lib/report-generator.js#L80. This will allow you to see what the custom data actually looks like to the template.

Good luck!