mirror of https://github.com/daffainfo/nuclei.git
assigment duplication removed, defaults from description removed
parent
354c82defe
commit
33bb3d5c64
|
@ -92,9 +92,9 @@ on extensive configurability, massive extensibility and ease of use.`)
|
|||
flagSet.StringVarP(&options.SarifExport, "sarif-export", "se", "", "file to export results in SARIF format"),
|
||||
|
||||
flagSet.StringVar(&options.ESExport, "es-ip", "", "the ip address for elasticsearch . Ex: 127.0.0.1"),
|
||||
flagSet.IntVar(&options.ESPort, "es-port", 9200, "the port number on which elasticsearch is running, by default 9200"),
|
||||
flagSet.BoolVar(&options.ESSSL, "es-ssl", true, "false if http is to be used, true by default"),
|
||||
flagSet.BoolVar(&options.ESSSLVerificaiton, "es-ssl-verify", true, "false if ssl verificaiton needs to be disabled, by default true"),
|
||||
flagSet.IntVar(&options.ESPort, "es-port", 9200, "the port number on which elasticsearch is running"),
|
||||
flagSet.BoolVar(&options.ESSSL, "es-ssl", true, "false if http is to be used"),
|
||||
flagSet.BoolVar(&options.ESSSLVerificaiton, "es-ssl-verify", true, "false if ssl verificaiton needs to be disabled"),
|
||||
flagSet.StringVar(&options.ESUsername, "es-user", "", "the username for elasticsearch"),
|
||||
flagSet.StringVar(&options.ESPassword, "es-password", "", "the password for elasticsearch"),
|
||||
)
|
||||
|
|
|
@ -107,25 +107,19 @@ func New(options *types.Options) (*Runner, error) {
|
|||
}
|
||||
}
|
||||
if options.ESExport != "" {
|
||||
es_temp := &es.Options{
|
||||
ESIP: options.ESExport,
|
||||
ESPort: options.ESPort,
|
||||
ESSSL: options.ESSSL,
|
||||
ESSSLVerificaiton: options.ESSSLVerificaiton,
|
||||
ESUsername: options.ESUsername,
|
||||
ESPassword: options.ESPassword,
|
||||
}
|
||||
if reportingOptions != nil {
|
||||
reportingOptions.ElasticsearchExporter = &es.Options{
|
||||
ESIP: options.ESExport,
|
||||
ESPort: options.ESPort,
|
||||
ESSSL: options.ESSSL,
|
||||
ESSSLVerificaiton: options.ESSSLVerificaiton,
|
||||
ESUsername: options.ESUsername,
|
||||
ESPassword: options.ESPassword,
|
||||
}
|
||||
reportingOptions.ElasticsearchExporter = es_temp
|
||||
} else {
|
||||
reportingOptions = &reporting.Options{}
|
||||
reportingOptions.ElasticsearchExporter = &es.Options{
|
||||
ESIP: options.ESExport,
|
||||
ESPort: options.ESPort,
|
||||
ESSSL: options.ESSSL,
|
||||
ESSSLVerificaiton: options.ESSSLVerificaiton,
|
||||
ESUsername: options.ESUsername,
|
||||
ESPassword: options.ESPassword,
|
||||
}
|
||||
reportingOptions.ElasticsearchExporter = es_temp
|
||||
}
|
||||
}
|
||||
if options.SarifExport != "" {
|
||||
|
|
Loading…
Reference in New Issue