Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix workflow validation logic #5805

Merged
merged 1 commit into from
Nov 8, 2024
Merged

Conversation

dogancanbakir
Copy link
Member

Proposed changes

Closes #5686

$ cat test_workflow.yaml 
id: kev-workflow

info:
  name: KEV Workflow
  description: This workflow runs the relevant Nuclei templates to detect Known Exploited Vulnerabilities.
workflows:
  - tags: kev

$  go run . -w test_template.yaml -validate

                     __     _
   ____  __  _______/ /__  (_)
  / __ \/ / / / ___/ / _ \/ /
 / / / / /_/ / /__/ /  __/ /
/_/ /_/\__,_/\___/_/\___/_/   v3.3.5

                projectdiscovery.io

[VER] Started metrics server at localhost:9092
[ERR] Error occurred parsing template ../test_workflow.yaml: [invalid template:RUNTIME] no template author field provided
[FTL] Could not validate templates: errors occurred during template validation
exit status 1

Checklist

  • Pull request is created against the dev branch
  • All checks passed (lint, unit/integration/regression tests etc.) with my changes
  • I have added tests that prove my fix is effective or that my feature works
  • I have added necessary documentation (if appropriate)

@dogancanbakir dogancanbakir self-assigned this Nov 8, 2024
@auto-assign auto-assign bot requested a review from dwisiswant0 November 8, 2024 10:56
@ehsandeep ehsandeep merged commit 529ac9d into dev Nov 8, 2024
12 checks passed
@ehsandeep ehsandeep deleted the fix_workflow_validation_logic branch November 8, 2024 13:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[BUG] SIGSEGV when validating workflow without author, silent error when workflow does not contain author
3 participants