antlr4nasl

package
v1.3.4-alpha0725 Latest Latest
Warning

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

Go to latest
Published: Jul 24, 2024 License: AGPL-3.0 Imports: 8 Imported by: 0

README

NASL 的一些语法规则

变量类型

INT、STRING、DATA、ARRAY、UNDEF

类型 说明 映射到的 Go 类型
INT 整型 int64
STRING 字符串 string
DATA 二进制数据 []byte
ARRAY 数组 struct NaslArray
UNDEF 未定义 nil

array类型是一个特殊类型,和传统的array不同,它既是map又是list,后端存在形式是hash_index和num_index

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Exports = map[string]any{
	"UpdateDatabase":  UpdateDatabase,
	"RemoveDatabase":  RemoveDatabase,
	"QueryAllScripts": QueryAllScripts,
	"ScanTarget":      ScanTarget,
	"Scan":            script_core.NaslScan,
	"plugin":          script_core.WithPlugins,
	"family":          script_core.WithFamily,
	"riskHandle":      script_core.WithRiskHandle,
	"proxy":           script_core.WithProxy,
	"conditions":      script_core.WithConditions,
}

Functions

func QueryAllScripts added in v1.2.6

func QueryAllScripts(script ...any) []*script_core.NaslScriptInfo

func RemoveDatabase added in v1.2.6

func RemoveDatabase() error

func ScanTarget added in v1.2.6

func ScanTarget(target string, opts ...script_core.NaslScriptConfigOptFunc) (chan *script_core.NaslKBs, error)

func UpdateDatabase added in v1.2.6

func UpdateDatabase(p string)

Types

This section is empty.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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