nuclei

package
v0.2.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 28, 2026 License: GPL-3.0 Imports: 8 Imported by: 0

Documentation

Overview

Package nuclei provides an adapter to convert Nuclei JSONL output to CTIS.

Package nuclei provides an adapter to convert Nuclei JSONL output to CTIS.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ParseToCTIS

func ParseToCTIS(data []byte, opts *core.ParseOptions) (*ctis.Report, error)

ParseToCTIS is a convenience function to parse Nuclei JSONL to CTIS format.

Types

type Adapter

type Adapter struct{}

Adapter converts Nuclei JSONL output to CTIS.

func NewAdapter

func NewAdapter() *Adapter

NewAdapter creates a new Nuclei adapter.

func (*Adapter) CanConvert

func (a *Adapter) CanConvert(input []byte) bool

CanConvert checks if the input can be converted.

func (*Adapter) Convert

func (a *Adapter) Convert(ctx context.Context, input []byte, opts *core.AdapterOptions) (*ctis.Report, error)

Convert transforms Nuclei JSONL input to CTIS Report.

func (*Adapter) InputFormats

func (a *Adapter) InputFormats() []string

InputFormats returns supported input formats.

func (*Adapter) Name

func (a *Adapter) Name() string

Name returns the adapter name.

func (*Adapter) OutputFormat

func (a *Adapter) OutputFormat() string

OutputFormat returns the output format.

type NucleiClassification

type NucleiClassification struct {
	CVEID       interface{} `json:"cve-id,omitempty"`
	CWEID       interface{} `json:"cwe-id,omitempty"`
	CVSSMetrics string      `json:"cvss-metrics,omitempty"`
	CVSSScore   float64     `json:"cvss-score,omitempty"`
	EPSSP       float64     `json:"epss-score,omitempty"`
	EPSSPerc    float64     `json:"epss-percentile,omitempty"`
	CPE         string      `json:"cpe,omitempty"`
}

NucleiClassification contains vulnerability classification.

type NucleiInfo

type NucleiInfo struct {
	Name           string                 `json:"name"`
	Severity       string                 `json:"severity"`
	Description    string                 `json:"description,omitempty"`
	Author         interface{}            `json:"author,omitempty"`
	Tags           interface{}            `json:"tags,omitempty"`
	Reference      interface{}            `json:"reference,omitempty"`
	Classification *NucleiClassification  `json:"classification,omitempty"`
	Remediation    string                 `json:"remediation,omitempty"`
	Metadata       map[string]interface{} `json:"metadata,omitempty"`
}

NucleiInfo contains template metadata.

type NucleiResult

type NucleiResult struct {
	TemplateID       string     `json:"template-id"`
	TemplatePath     string     `json:"template,omitempty"`
	Info             NucleiInfo `json:"info"`
	Type             string     `json:"type"`
	Host             string     `json:"host"`
	MatchedAt        string     `json:"matched-at"`
	ExtractedResults []string   `json:"extracted-results,omitempty"`
	IP               string     `json:"ip,omitempty"`
	Timestamp        string     `json:"timestamp,omitempty"`
	CurlCommand      string     `json:"curl-command,omitempty"`
	MatcherName      string     `json:"matcher-name,omitempty"`
	MatcherStatus    bool       `json:"matcher-status,omitempty"`
	TemplateURL      string     `json:"template-url,omitempty"`
}

NucleiResult represents a single Nuclei finding (one JSON object per line).

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL