Documentation
¶
Index ¶
- Constants
- Variables
- func AIForgeExec(forgeName string, forgeParams any, opts ...aicommon.ConfigOption) (any, error)
- func BindAIConfigToEngine(nIns *antlr4yak.Engine, agentOptions ...any)
- func BindYakitPluginContextToEngine(nIns *antlr4yak.Engine, pluginContext *YakitPluginContext)
- func BuildIndexKnowledgeFromFile(kbName string, path string, option ...any) error
- func BuildLiteForgeCreateOption(anyOptions ...any) []aiforge.LiteForgeOption
- func BuildLiteForgeExecOption(anyOptions ...any) []any
- func CallYakitPluginFunc(scriptName string, hookName string) (interface{}, error)
- func ClearHelper(helper *yakdoc.DocumentHelper)
- func DefaultAfterRequestCallArgumentHook(name string, numIn int, args []any) []any
- func DefaultBeforeRequestCallArgumentHook(name string, numIn int, args []any) []any
- func DocumentHelperWithVerboseInfo(funcMap map[string]any) *yakdoc.DocumentHelper
- func EngineToDocumentHelperWithVerboseInfo(engine *antlr4yak.Engine) *yakdoc.DocumentHelper
- func EngineToLibDocuments(engine *antlr4yak.Engine) []yakdocument.LibDoc
- func Execute(code string, params ...map[string]any) (*antlr4yak.Engine, error)
- func ExecuteForge(forgeName string, i any, iopts ...any) (any, error)
- func FeedbackFactory(db *gorm.DB, caller func(result *ypb.ExecResult) error, saveToDb bool, ...) func(i interface{}, items ...interface{})
- func Fuzz_WithAllHotPatch(ctx context.Context, code string) []mutate.FuzzConfigOpt
- func Fuzz_WithDynHotPatch(ctx context.Context, code string) mutate.FuzzConfigOpt
- func Fuzz_WithHotPatch(ctx context.Context, code string) mutate.FuzzConfigOpt
- func GetDeprecatedFunctionDecls(helper *yakdoc.DocumentHelper) []*yakdoc.DeprecateFunction
- func GetHookCliApp(tempArg []string) *cli.CliApp
- func GetInterfaceDocumentFromAST(pkg *ast.Package, interfaceName string) map[string]string
- func GetMethodFuncDeclFromAST(pkg *ast.Package, libName, structName, methodName, yakFuncName string, ...) *yakdoc.FuncDecl
- func GetPluginExecutionStatistics(tracker *PluginExecutionTracker) map[string]interface{}
- func ImportVarFromFile(file string, exportsName string) (interface{}, error)
- func ImportVarFromScript(engine *antlr4yak.Engine, script string, exportsName string) (interface{}, error)
- func ImportVarFromYakFile(path string, exportsName string) (interface{}, error)
- func InitYaklangLib()
- func IsSameTypeName(typName1, typName2 string) bool
- func LoadingVariableFrom(path string, exportsName string, opts ...yakEvalConfigOpt) ([]*yakVariable, error)
- func MutateHookCaller(ctx context.Context, raw string, caller YakitCallerIf, ...) (func(https bool, originReq []byte, req []byte) []byte, ...)
- func MutateWithParamsGetter(raw string) func() *mutate.RegexpMutateCondition
- func MutateWithYaklang(raw string) *mutate.RegexpMutateCondition
- func NewExecutorFromForge(forge *aiforge.ForgeBlueprint, i any, opts ...any) (*aid.Coordinator, error)
- func NewExecutorFromJson(json string, i any, opts ...any) (*aid.Coordinator, error)
- func NewFetchFuncFromSrcCodeConfig() *fetchFuncFromSrcCodeConfig
- func NewForgeBlueprint(name string, opts ...any) *aiforge.ForgeBlueprint
- func NewForgeExecutor(name string, i any, opts ...any) (*aid.Coordinator, error)
- func NewLiteForge(name string, opts ...any) (*aiforge.LiteForge, error)
- func NewYakitFetchFuncFromSrcCodeConfig() *fetchFuncFromSrcCodeConfig
- func QuickEvalWithoutContext(i interface{}) error
- func StaticAnalyze(code string, opts ...StaticAnalyzeOption) []*result.StaticAnalyzeResult
- func WithFetchCallArgumentHook(name string, hook callArgumentHookFunc) fetchFuncFromSrcCodeOptions
- func WithFetchCode(code string) fetchFuncFromSrcCodeOptions
- func WithFetchEngineHook(hook func(e *antlr4yak.Engine) error) fetchFuncFromSrcCodeOptions
- func WithFetchFunctionNames(names ...string) fetchFuncFromSrcCodeOptions
- func WithFetchScript(script *schema.YakScript) fetchFuncFromSrcCodeOptions
- func YakTool2AITool(aitools []*schema.AIYakTool) []*aitool.Tool
- type AIAgentOption
- type Agent
- type CallConfig
- type CallOpt
- func WithCallConfigCallback(callback func()) CallOpt
- func WithCallConfigForceSync(forceSync bool) CallOpt
- func WithCallConfigItemFuncs(itemFuncs ...func() interface{}) CallOpt
- func WithCallConfigItems(items ...interface{}) CallOpt
- func WithCallConfigPluginId(pluginId string) CallOpt
- func WithCallConfigRuntimeCtx(ctx context.Context) CallOpt
- type Caller
- type CallerHookDescription
- type CallerHooks
- type EmbedFieldTypeAndMethod
- type InstanceMethodHandler
- type LibFuncWithFrameType
- type MixPluginCaller
- func (m *MixPluginCaller) AddExecutionTraceCallback(callback func(*PluginExecutionTrace)) (callbackID string, remove func())
- func (m *MixPluginCaller) CallAfterRequestWithCtx(runtimeCtx context.Context, isHttps bool, u string, originReq, req []byte, ...) []byte
- func (m *MixPluginCaller) CallAnalyzeHTTPFlow(runtimeCtx context.Context, flow *schema.HTTPFlow, ...)
- func (m *MixPluginCaller) CallBeforeRequestWithCtx(runtimeCtx context.Context, isHttps bool, u string, originReq, req []byte) []byte
- func (m *MixPluginCaller) CallHijackRequest(isHttps bool, u string, getRequest func() interface{}, ...)
- func (m *MixPluginCaller) CallHijackRequestWithCtx(runtimeCtx context.Context, isHttps bool, u string, ...)
- func (m *MixPluginCaller) CallHijackResponse(isHttps bool, u string, getResponse, reject, drop func() interface{})
- func (m *MixPluginCaller) CallHijackResponseEx(isHttps bool, u string, ...)
- func (m *MixPluginCaller) CallHijackResponseExWithCtx(runtimeCtx context.Context, isHttps bool, u string, ...)
- func (m *MixPluginCaller) CallHijackResponseWithCtx(runtimeCtx context.Context, isHttps bool, u string, ...)
- func (m *MixPluginCaller) CallMockHTTPRequest(isHttps bool, u string, getRequest func() interface{}, ...)
- func (m *MixPluginCaller) CallMockHTTPRequestWithCtx(runtimeCtx context.Context, isHttps bool, u string, ...)
- func (m *MixPluginCaller) CallOnAnalyzeHTTPFlowFinish(runtimeCtx context.Context, totalCount int64, matchedCount int64)
- func (m *MixPluginCaller) CancelAllExecutionTraces()
- func (m *MixPluginCaller) CancelExecutionTrace(traceID string) bool
- func (m *MixPluginCaller) CleanupCompletedExecutionTraces(olderThan time.Duration)
- func (m *MixPluginCaller) EnableExecutionTracing(enable bool)
- func (c *MixPluginCaller) FeedbackOrdinary(i interface{})
- func (m *MixPluginCaller) GetAllExecutionTraces() []*PluginExecutionTrace
- func (m *MixPluginCaller) GetExecutionTracesByHook(hookName string) []*PluginExecutionTrace
- func (m *MixPluginCaller) GetExecutionTracesByPlugin(pluginID string) []*PluginExecutionTrace
- func (m *MixPluginCaller) GetExecutionTracker() *PluginExecutionTracker
- func (m *MixPluginCaller) GetFingerprintMatcher() *fp.Matcher
- func (c *MixPluginCaller) GetLongRunningThreshold() int
- func (m *MixPluginCaller) GetNativeCaller() *YakToCallerManager
- func (m *MixPluginCaller) GetRunningExecutionTraces() []*PluginExecutionTrace
- func (m *MixPluginCaller) HandleServiceScanResult(r *fp.MatchResult)
- func (m *MixPluginCaller) HaveTheHookFunc(name string) bool
- func (m *MixPluginCaller) HijackSaveHTTPFlow(flow *schema.HTTPFlow, reject func(httpFlow *schema.HTTPFlow), drop func())
- func (m *MixPluginCaller) HijackSaveHTTPFlowEx(runtimeCtx context.Context, flow *schema.HTTPFlow, callback func(), ...)
- func (m *MixPluginCaller) IsExecutionTracingEnabled() bool
- func (c *MixPluginCaller) IsPassed(target string) bool
- func (c *MixPluginCaller) IsStatic(rawUrl string, req, rsp []byte) bool
- func (m *MixPluginCaller) LastErr() error
- func (c *MixPluginCaller) LoadHotPatch(ctx context.Context, params []*ypb.ExecParamItem, code string) error
- func (m *MixPluginCaller) LoadPlugin(scriptName string, params ...*ypb.ExecParamItem) error
- func (m *MixPluginCaller) LoadPluginByName(ctx context.Context, name string, params []*ypb.ExecParamItem, codes ...string) error
- func (m *MixPluginCaller) LoadPluginEx(ctx context.Context, script *schema.YakScript, params ...*ypb.ExecParamItem) error
- func (m *MixPluginCaller) MirrorHTTPFlow(isHttps bool, u string, req, rsp, body []byte, filters ...bool)
- func (m *MixPluginCaller) MirrorHTTPFlowEx(scanPort bool, isHttps bool, u string, req, rsp, body []byte, filters ...bool)
- func (m *MixPluginCaller) MirrorHTTPFlowExSync(scanPort bool, isHttps bool, u string, req, rsp, body []byte, filters ...bool)
- func (m *MixPluginCaller) MirrorHTTPFlowWithCtx(runtimeCtx context.Context, isHttps bool, u string, req, rsp, body []byte, ...)
- func (c *MixPluginCaller) ResetFilter()
- func (m *MixPluginCaller) SetCache(b bool)
- func (c *MixPluginCaller) SetCallPluginTimeout(i float64)
- func (c *MixPluginCaller) SetConcurrent(i int) error
- func (m *MixPluginCaller) SetCtx(ctx context.Context)
- func (m *MixPluginCaller) SetDividedContext(b bool)
- func (m *MixPluginCaller) SetFeedback(i func(i *ypb.ExecResult) error)
- func (c *MixPluginCaller) SetLoadPluginTimeout(i float64)
- func (c *MixPluginCaller) SetLongRunningThreshold(seconds int)
- func (m *MixPluginCaller) SetProxy(s ...string)
- func (m *MixPluginCaller) SetRuntimeId(s string)
- func (m *MixPluginCaller) SetVar(key string, value any)
- func (c *MixPluginCaller) Wait()
- type PalmScriptEngineHelper
- type PalmScriptLib
- type PalmScriptLibFunc
- type PalmScriptLibInstance
- type PluginExecutionStatus
- type PluginExecutionTrace
- type PluginExecutionTracker
- func (t *PluginExecutionTracker) AddCallback(callback func(*PluginExecutionTrace)) (callbackID string, remove func())
- func (t *PluginExecutionTracker) CancelAllTraces()
- func (t *PluginExecutionTracker) CancelTrace(traceID string) bool
- func (t *PluginExecutionTracker) CleanupCompletedTraces(olderThan time.Duration)
- func (t *PluginExecutionTracker) ClearStaleTraces()
- func (t *PluginExecutionTracker) CreateTrace(pluginID, hookName string, runtimeCtx context.Context) *PluginExecutionTrace
- func (t *PluginExecutionTracker) FindLatestRunningTraceByPluginAndHook(pluginID, hookName string) *PluginExecutionTrace
- func (t *PluginExecutionTracker) FindTraceByPluginAndHook(pluginID, hookName string) *PluginExecutionTrace
- func (t *PluginExecutionTracker) GetActiveTraces() []*PluginExecutionTrace
- func (t *PluginExecutionTracker) GetAllTraces() []*PluginExecutionTrace
- func (t *PluginExecutionTracker) GetRunningTraces() []*PluginExecutionTrace
- func (t *PluginExecutionTracker) GetStaleQueueInfo() map[string]interface{}
- func (t *PluginExecutionTracker) GetStaleTraces() []*PluginExecutionTrace
- func (t *PluginExecutionTracker) GetTrace(traceID string) (*PluginExecutionTrace, bool)
- func (t *PluginExecutionTracker) GetTracesByHook(hookName string) []*PluginExecutionTrace
- func (t *PluginExecutionTracker) GetTracesByPlugin(pluginID string) []*PluginExecutionTrace
- func (t *PluginExecutionTracker) RemoveTrace(traceID string) bool
- func (t *PluginExecutionTracker) RemoveTracesByPluginAndHook(pluginID, hookName string) int
- func (t *PluginExecutionTracker) StartExecution(traceID string, args []interface{}) bool
- func (t *PluginExecutionTracker) UpdateTraceStatus(traceID string, status PluginExecutionStatus, result interface{}, err error)
- type Sandbox
- type SandboxConfig
- type SandboxOption
- type ScriptEngine
- func (e *ScriptEngine) Compile(code string) ([]byte, error)
- func (e *ScriptEngine) Execute(code string) error
- func (e *ScriptEngine) ExecuteEx(code string, params map[string]interface{}) (*antlr4yak.Engine, error)
- func (e *ScriptEngine) ExecuteExWithContext(ctx context.Context, code string, params map[string]interface{}) (_ *antlr4yak.Engine, fErr error)
- func (e *ScriptEngine) ExecuteMain(code string, AbsFile string) error
- func (e *ScriptEngine) ExecuteMainWithContext(ctx context.Context, code string, AbsFile string) error
- func (e *ScriptEngine) ExecuteWithContext(ctx context.Context, code string) error
- func (e *ScriptEngine) ExecuteWithTaskID(taskId, code string) error
- func (e *ScriptEngine) ExecuteWithTaskIDAndContext(ctx context.Context, taskId, code string) error
- func (e *ScriptEngine) ExecuteWithTaskIDAndParams(ctx context.Context, taskId, code string, params map[string]interface{}) error
- func (e *ScriptEngine) ExecuteWithTemplate(codeTmp string, i map[string][]string) error
- func (e *ScriptEngine) ExecuteWithoutCache(code string, params map[string]interface{}) (*antlr4yak.Engine, error)
- func (s *ScriptEngine) GetTaskByTaskID(id string) (*Task, error)
- func (e *ScriptEngine) HookOsExit()
- func (e *ScriptEngine) RegisterEngineHooks(f func(engine *antlr4yak.Engine) error)
- func (s *ScriptEngine) SaveTask(task *Task) error
- func (e *ScriptEngine) SetCallFuncCallback(f func(caller *yakvm.Value, wavy bool, args []*yakvm.Value))
- func (s *ScriptEngine) SetCryptoKey(key []byte) error
- func (s *ScriptEngine) SetDebug(debug bool)
- func (s *ScriptEngine) SetDebugCallback(callback func(*yakvm.Debugger))
- func (s *ScriptEngine) SetDebugInit(callback func(*yakvm.Debugger))
- func (e *ScriptEngine) SetYakitClient(client *yaklib.YakitClient)
- func (s *ScriptEngine) Status() map[string]*Task
- type StaleTraceQueue
- func (q *StaleTraceQueue) Capacity() int
- func (q *StaleTraceQueue) Clear()
- func (q *StaleTraceQueue) GetAll() []*PluginExecutionTrace
- func (q *StaleTraceQueue) GetByTraceID(traceID string) *PluginExecutionTrace
- func (q *StaleTraceQueue) Push(trace *PluginExecutionTrace) *PluginExecutionTrace
- func (q *StaleTraceQueue) Size() int
- type StaticAnalyzeConfig
- type StaticAnalyzeOption
- type Task
- type TextHandlingScript
- type TextParser
- type YakFunctionCaller
- type YakToCallerManager
- func (y *YakToCallerManager) Add(ctx context.Context, script *schema.YakScript, paramMap map[string]any, ...) (retError error)
- func (y *YakToCallerManager) AddExecutionTraceCallback(callback func(*PluginExecutionTrace)) (callbackID string, remove func())
- func (y *YakToCallerManager) AddForYakit(ctx context.Context, script *schema.YakScript, paramMap map[string]any, ...) error
- func (y *YakToCallerManager) Call(name string, opts ...CallOpt) (results []any)
- func (y *YakToCallerManager) CallByName(name string, items ...interface{})
- func (y *YakToCallerManager) CallByNameExSync(name string, items ...func() interface{})
- func (y *YakToCallerManager) CallByNameSync(name string, items ...interface{})
- func (y *YakToCallerManager) CallByNameWithCallback(name string, callback func(), items ...interface{})
- func (y *YakToCallerManager) CallPluginKeyByName(pluginId string, name string, items ...interface{})
- func (y *YakToCallerManager) CallPluginKeyByNameEx(pluginId string, name string, callback func(), ...)
- func (y *YakToCallerManager) CallPluginKeyByNameExWithAsync(runtimeCtx context.Context, forceSync bool, pluginId string, name string, ...)
- func (y *YakToCallerManager) CallPluginKeyByNameSyncWithCallback(pluginId string, name string, callback func(), items ...interface{})
- func (y *YakToCallerManager) CallPluginKeyByNameWithCallback(pluginId string, name string, callback func(), items ...interface{})
- func (y *YakToCallerManager) CancelAllExecutionTraces()
- func (y *YakToCallerManager) CancelExecutionTrace(traceID string) bool
- func (y *YakToCallerManager) CleanupCompletedExecutionTraces(olderThan time.Duration)
- func (y *YakToCallerManager) EnableExecutionTracing(enable bool)
- func (y *YakToCallerManager) GetAllExecutionTraces() []*PluginExecutionTrace
- func (y *YakToCallerManager) GetCurrentHooks() []*CallerHooks
- func (y *YakToCallerManager) GetCurrentHooksGRPCModel() []*ypb.YakScriptHooks
- func (y *YakToCallerManager) GetExecutionTracesByHook(hookName string) []*PluginExecutionTrace
- func (y *YakToCallerManager) GetExecutionTracesByPlugin(pluginID string) []*PluginExecutionTrace
- func (y *YakToCallerManager) GetExecutionTracker() *PluginExecutionTracker
- func (y *YakToCallerManager) GetLongRunningThreshold() int
- func (y *YakToCallerManager) GetRunningExecutionTraces() []*PluginExecutionTrace
- func (y *YakToCallerManager) GetWaitingEventCount() int
- func (y *YakToCallerManager) IsExecutionTracingEnabled() bool
- func (y *YakToCallerManager) LoadPlugin(t string, hooks ...string) error
- func (y *YakToCallerManager) LoadPluginContext(ctx context.Context, t string, hooks ...string) error
- func (y *YakToCallerManager) Remove(params *ypb.RemoveHookParams)
- func (y *YakToCallerManager) Set(ctx context.Context, code string, paramMap map[string]any, ...) (retError error)
- func (y *YakToCallerManager) SetCallPluginTimeout(i float64)
- func (y *YakToCallerManager) SetConcurrent(i int) error
- func (y *YakToCallerManager) SetDividedContext(b bool)
- func (y *YakToCallerManager) SetForYakit(ctx context.Context, code string, paramMap map[string]any, ...) error
- func (y *YakToCallerManager) SetLoadPluginTimeout(i float64)
- func (y *YakToCallerManager) SetLongRunningThreshold(seconds int)
- func (y *YakToCallerManager) ShouldCallByName(name string, callbacks ...func()) (ret bool)
- func (y *YakToCallerManager) SyncCallPluginKeyByNameEx(pluginId string, name string, callback func(), ...)
- func (y *YakToCallerManager) Wait()
- func (y *YakToCallerManager) WithVulFilter(filter filter.Filterable) *YakToCallerManager
- type YakitCallerIf
- type YakitPluginContext
- func (y *YakitPluginContext) WithCliApp(cliApp *cli.CliApp) *YakitPluginContext
- func (y *YakitPluginContext) WithContext(ctx context.Context) *YakitPluginContext
- func (y *YakitPluginContext) WithContextCancel(cancel context.CancelFunc) *YakitPluginContext
- func (y *YakitPluginContext) WithPluginName(id string) *YakitPluginContext
- func (y *YakitPluginContext) WithPluginUUID(uuid string) *YakitPluginContext
- func (y *YakitPluginContext) WithProxy(proxy string) *YakitPluginContext
- func (y *YakitPluginContext) WithVulFilter(filter filter.Filterable) *YakitPluginContext
- func (y *YakitPluginContext) WithYakitClient(yakitClient *yaklib.YakitClient) *YakitPluginContext
Constants ¶
const ( // func mirrorHTTPFlow(isHttps, url, request, response, body) // mirror hijacked by filtered http flows HOOK_MirrorFilteredHTTPFlow = "mirrorFilteredHTTPFlow" // func mirrorHTTPFlow(isHttps, url, request, response, body) // mirror hijacked all HOOK_MirrorHTTPFlow = "mirrorHTTPFlow" // func mirrorNewWebsite(isHttps, url, request, response, body) HOOK_MirrorNewWebsite = "mirrorNewWebsite" // schema + addr // func mirrorNewWebsitePath(isHttps, url, request, response, body) HOOK_MirrorNewWebsitePath = "mirrorNewWebsitePath" // schema + addr + path (remove params) // func mirrorNewWebsitePathParams(isHttps, url, request, response, body) HOOK_MirrorNewWebsitePathParams = "mirrorNewWebsitePathParams" // schema + addr + path + param_names // func hijackHTTPRequest(isHttps, url, request, forward/*func(modified []byte)*/, drop /*func()*/) HOOK_HijackHTTPRequest = "hijackHTTPRequest" // func hijackHTTPRequest(isHttps, url, response, forward/*func(modified []byte)*/, drop /*func()*/) HOOK_HijackHTTPResponse = "hijackHTTPResponse" // func hijackHTTPRequest(isHttps, url, request, response, forward/*func(modified []byte)*/, drop /*func()*/) HOOK_HijackHTTPResponseEx = "hijackHTTPResponseEx" // func mockHTTPRequest(isHttps, url, request, mockResponse /*func(rsp interface{})*/) HOOK_MockHTTPRequest = "mockHTTPRequest" // func hijackSaveHTTPFlow(record *httpFlow, forward func(*httpFlow), drop func()) return (*httpFlow) HOOK_hijackSaveHTTPFlow = "hijackSaveHTTPFlow" // func handle(r *fp.MatchResult) HOOK_PortScanHandle = "handle" // func execNuclei(target) HOOK_NucleiScanHandle = "execNuclei" HOOK_NaslScanHandle = "execNasl" HOOK_LoadNaslScriptByNameFunc = "loadNaslScriptByNameFunc" // beforeRequest, afterRequest HOOK_BeforeRequest = "beforeRequest" HOOK_AfterRequest = "afterRequest" HOOK_CLAER = "clear" // httpflow analyze HOOK_Analyze_HTTPFlow = "analyzeHTTPFlow" HOOK_OnAnalyzeHTTPFlowFinish = "onAnalyzeHTTPFlowFinish" )
const ( DefaultStaleQueueSize = 1000 // 默认保留1000个已完成的trace MaxStaleQueueSize = 10000 // 最大保留10000个已完成的trace )
默认 stale 队列大小
Variables ¶
var ( // Additional With options WithCoordinatorId = func(id string) AIAgentOption { return func(ag *Agent) error { ag.CoordinatorId = id return nil } } WithAiAgentEventHandler = func(handler func(e *schema.AiOutputEvent)) AIAgentOption { return func(ag *Agent) error { ag.AgentEventHandler = handler return nil } } WithDisallowRequireForUserPrompt = aicommon.WithDisallowRequireForUserPrompt WithAICallback = aicommon.WithAICallback WithPromptContextProvider = aid.WithPromptContextProvider WithResultHandler = aid.WithResultHandler // aitools AllYakScriptTools = yakscripttools.GetAllYakScriptAiTools )
var ( MITMAndPortScanHooks = []string{ HOOK_MirrorFilteredHTTPFlow, HOOK_MirrorHTTPFlow, HOOK_MirrorNewWebsite, HOOK_MirrorNewWebsitePath, HOOK_MirrorNewWebsitePathParams, HOOK_CLAER, HOOK_HijackHTTPRequest, HOOK_HijackHTTPResponse, HOOK_HijackHTTPResponseEx, HOOK_MockHTTPRequest, HOOK_hijackSaveHTTPFlow, HOOK_PortScanHandle, HOOK_BeforeRequest, HOOK_AfterRequest, HOOK_Analyze_HTTPFlow, HOOK_OnAnalyzeHTTPFlowFinish, } HotPatchScriptName = "@HotPatchCode" )
var AIAgentExport = map[string]any{ "ExecuteForge": ExecuteForge, "CreateForge": NewForgeBlueprint, "NewExecutor": NewForgeExecutor, "NewExecutorFromJson": NewExecutorFromJson, "CreateLiteForge": NewLiteForge, "planAICallback": aicommon.WithQualityPriorityAICallback, "taskAICallback": aicommon.WithSpeedPriorityAICallback, "aiCallback": aicommon.WithAICallback, "liteForgePrompt": aiforge.WithLiteForge_Prompt, "liteForgeOutputSchema": aiforge.WithLiteForge_OutputSchema, "liteForgedRequireParams": aiforge.WithLiteForge_RequireParams, "liteForgeOutputSchemaRaw": aiforge.WithLiteForge_OutputSchemaRaw, "tools": aicommon.WithTools, "forgeTools": aiforge.WithTools, "initPrompt": aiforge.WithInitializePrompt, "initializePrompt": aiforge.WithInitializePrompt, "persistentPrompt": aiforge.WithPersistentPrompt, "persistentPromptForge": aiforge.WithPersistentPrompt, "resultPrompt": aiforge.WithResultPrompt, "resultPromptForge": aiforge.WithResultPrompt, "plan": aid.WithPlanMocker, "forgePlanMocker": aiforge.WithPlanMocker, "resultHandlerForge": aiforge.WithResultHandler, "toolKeywords": aiforge.WithToolKeywords, "originYaklangCliCode": aiforge.WithOriginYaklangCliCode, "offsetSeq": aicommon.WithSequence, "tool": aicommon.WithTool, "agreeAuto": aicommon.WithAgreeAuto, "agreeYOLO": aicommon.WithAgreeYOLO, "agreePolicyAI": aicommon.WithAIAgree, "agreeManual": aicommon.WithAgreeManual, "agreePolicy": aicommon.WithAgreePolicy, "extendedActionCallback": aicommon.WithExtendedActionCallback, "resultHandler": aid.WithResultHandler, "forgeName": WithForgeName, "context": WithContext, "extendAIDOptions": WithExtendAICommonOptions, "disallowRequireForUserPrompt": aicommon.WithDisallowRequireForUserPrompt, "manualAssistantCallback": aicommon.WithManualAssistantCallback, "allowRequireForUserInteract": aicommon.WithAllowRequireForUserInteract, "coordinatorAICallback": aicommon.WithQualityPriorityAICallback, "systemFileOperator": aicommon.WithSystemFileOperator, "omniSearchTool": aicommon.WithOmniSearchTool, "debugPrompt": aicommon.WithDebugPrompt, "debug": aicommon.WithDebug, "appendPersistentMemory": aicommon.WithAppendPersistentMemory, "timelineContentLimit": aicommon.WithTimelineContentLimit, "disableToolUse": aicommon.WithDisableToolUse, "aiAutoRetry": aicommon.WithAIAutoRetry, "aiTransactionRetry": aicommon.WithAITransactionRetry, "disableOutputType": aicommon.WithDisableOutputEvent, "ExtractPlan": aid.ExtractPlan, "ExtractAction": aicommon.ExtractAction, "GetDefaultContextProvider": aid.GetDefaultContextProvider, "AllYakScriptAiTools": AllYakScriptTools, "UpdateYakScriptMetaData": genmetadata.UpdateYakScriptMetaData, "ParseYakScriptToAiTools": yakscripttools.LoadYakScriptToAiTools, }
exports to yaklang
var AIEngineExports map[string]interface{}
var (
CRYPTO_KEY_SIZE = 16
)
var DEFAULT_FORGE_HANDLE_NAME = "__DEFAULT_FORGE_HANDLE__"
var DEFAULT_INIT_PROMPT_NAME = "__INIT_PROMPT__"
var DEFAULT_PERSISTENT_PROMPT_NAME = "__PERSISTENT_PROMPT__"
var DEFAULT_PLAN_PROMPT_NAME = "__PLAN_PROMPT__"
var DEFAULT_RESULT_PROMPT_NAME = "__RESULT_PROMPT__"
var EvalExports = map[string]interface{}{ "Eval": QuickEvalWithoutContext, "LoadVarFromFile": LoadingVariableFrom, "Import": ImportVarFromFile, "IsYakFunc": yaklib.IsYakFunction, "params": setYakEvalParams, "recursive": setYakBatchImportRecursiveParams, }
var GlobalEvalExports = map[string]interface{}{ "import": ImportVarFromFile, }
var HOOK_AI_FORGE = "forgeHandle"
var HooksExports = map[string]interface{}{ "NewManager": NewYakToCallerManager, "NewMixPluginCaller": NewMixPluginCaller, "NewMixPluginCallerWithFilter": NewMixPluginCallerWithFilter, "RemoveYakitPluginByName": removeScriptByNameCtx, "LoadYakitPluginContext": loadScriptCtx, "LoadYakitPlugin": loadScript, "LoadYakitPluginByName": loadScriptByName, "CallYakitPluginFunc": CallYakitPluginFunc, }
var RagExports = map[string]interface{}{ "Get": rag.Get, "GetCollection": rag.Get, "embeddingHandle": _embeddingHandle, "DeleteCollection": _deleteCollection, "DeleteRAG": _deleteRAG, "ListCollection": _listCollection, "ListRAG": _listRAG, "GetCollectionInfo": _getCollectionInfo, "HasCollection": _hasCollection, "Query": rag.QueryYakitProfile, "queryLimit": rag.WithRAGLimit, "queryType": rag.WithRAGDocumentType, "queryCollection": rag.WithRAGCollectionName, "queryStatus": rag.WithRAGQueryStatus, "queryEnhance": rag.WithRAGEnhance, "queryCtx": rag.WithRAGCtx, "queryConcurrent": rag.WithRAGConcurrent, "queryScoreLimit": rag.WithRAGCollectionScoreLimit, "AddDocument": _addDocument, "DeleteDocument": _deleteDocument, "QueryDocuments": _queryDocuments, "ragForceNew": rag.WithForceNew, "ragDescription": rag.WithDescription, "ragEmbeddingModel": rag.WithEmbeddingModel, "ragModelDimension": rag.WithModelDimension, "ragCosineDistance": rag.WithCosineDistance, "ragHNSWParameters": rag.WithHNSWParameters, "docMetadata": rag.WithDocumentMetadataKeyValue, "docRawMetadata": rag.WithDocumentRawMetadata, "NewRagDatabase": rag.NewVectorStoreDatabase, "NewTempRagDatabase": _newTempRagDatabase, "EnableMockMode": _enableMockMode, "ctx": aiforge.WithAnalyzeContext, "log": aiforge.WithAnalyzeLog, "statusCard": aiforge.WithAnalyzeStatusCard, "extraPrompt": aiforge.WithExtraPrompt, "entryLength": aiforge.RefineWithKnowledgeEntryLength, "chunkSize": chunkmaker.WithChunkSize, "khopk": rag.WithKHopK, "khopLimit": rag.WithKHopLimit, "khopkMin": rag.WithKHopKMin, "khopkMax": rag.WithKHopKMax, "buildQuery": rag.WithKHopRagQuery, "buildFilter": rag.WithKHopStartFilter, "pathDepth": rag.WithKHopPathDepth, "getEntityFilter": schema.SimpleBuildEntityFilter, "BuildCollectionFromFile": aiforge.BuildKnowledgeFromFile, "BuildCollectionFromReader": aiforge.BuildKnowledgeFromReader, "BuildCollectionFromRaw": aiforge.BuildKnowledgeFromBytes, "BuildKnowledgeFromEntityRepos": aiforge.BuildKnowledgeFromEntityReposByName, "BuildIndexKnowledgeFromFile": BuildIndexKnowledgeFromFile, "Import": rag.ImportRAG, "db": rag.WithDB, "importOverwrite": rag.WithExportOverwriteExisting, "importName": rag.WithRAGCollectionName, "importRebuildGraph": rag.WithImportRebuildHNSWIndex, "documentHandler": rag.WithExportDocumentHandler, "progressHandler": rag.WithExportOnProgressHandler, "aiServiceType": rag.WithAIServiceType, "aiService": rag.WithAIService, "Export": rag.ExportRAG, "noHNSWGraph": rag.WithExportNoHNSWIndex, "noMetadata": rag.WithExportNoMetadata, "noOriginInput": rag.WithExportNoOriginInput, "onlyPQCode": rag.WithExportOnlyPQCode, "noEntityRepository": _noEntityRepository, "noKnowledgeBase": _noKnowledgeBase, "ragImportFile": rag.WithImportFile, }
导出的公共函数
var SandboxExports = map[string]any{ "Create": NewSandbox, "library": WithSandbox_ExternalLib, }
var YAK_TEMPLATE_NUCLEI_EXECUTOR string
Functions ¶
func AIForgeExec ¶
func BindAIConfigToEngine ¶
func BindYakitPluginContextToEngine ¶ added in v1.2.3
func BindYakitPluginContextToEngine(nIns *antlr4yak.Engine, pluginContext *YakitPluginContext)
func BuildLiteForgeCreateOption ¶
func BuildLiteForgeCreateOption(anyOptions ...any) []aiforge.LiteForgeOption
func CallYakitPluginFunc ¶
func ClearHelper ¶ added in v1.2.9
func ClearHelper(helper *yakdoc.DocumentHelper)
func DocumentHelperWithVerboseInfo ¶ added in v1.3.1
func DocumentHelperWithVerboseInfo(funcMap map[string]any) *yakdoc.DocumentHelper
func EngineToDocumentHelperWithVerboseInfo ¶
func EngineToDocumentHelperWithVerboseInfo(engine *antlr4yak.Engine) *yakdoc.DocumentHelper
func EngineToLibDocuments ¶
func EngineToLibDocuments(engine *antlr4yak.Engine) []yakdocument.LibDoc
! 老接口
func FeedbackFactory ¶
func Fuzz_WithAllHotPatch ¶
func Fuzz_WithAllHotPatch(ctx context.Context, code string) []mutate.FuzzConfigOpt
func Fuzz_WithDynHotPatch ¶
func Fuzz_WithDynHotPatch(ctx context.Context, code string) mutate.FuzzConfigOpt
func Fuzz_WithHotPatch ¶ added in v1.2.6
func Fuzz_WithHotPatch(ctx context.Context, code string) mutate.FuzzConfigOpt
func GetDeprecatedFunctionDecls ¶ added in v1.3.1
func GetDeprecatedFunctionDecls(helper *yakdoc.DocumentHelper) []*yakdoc.DeprecateFunction
func GetHookCliApp ¶
func GetInterfaceDocumentFromAST ¶ added in v1.2.9
func GetMethodFuncDeclFromAST ¶ added in v1.2.9
func GetPluginExecutionStatistics ¶
func GetPluginExecutionStatistics(tracker *PluginExecutionTracker) map[string]interface{}
GetPluginExecutionStatistics 获取插件执行统计信息
func ImportVarFromFile ¶
func ImportVarFromScript ¶
func ImportVarFromYakFile ¶
func InitYaklangLib ¶
func InitYaklangLib()
func IsSameTypeName ¶ added in v1.2.9
func LoadingVariableFrom ¶
func MutateHookCaller ¶
func MutateHookCaller(ctx context.Context, raw string, caller YakitCallerIf, params ...*ypb.ExecParamItem) ( func(https bool, originReq []byte, req []byte) []byte, func(https bool, originReq []byte, req []byte, originRsp []byte, rsp []byte) []byte, func([]byte, []byte, map[string]string) map[string]string, func(bool, int, []byte, []byte, func(...[]byte)), func(bool, []byte, []byte, func(string)), )
func MutateWithParamsGetter ¶
func MutateWithParamsGetter(raw string) func() *mutate.RegexpMutateCondition
func MutateWithYaklang ¶
func MutateWithYaklang(raw string) *mutate.RegexpMutateCondition
func NewExecutorFromForge ¶
func NewExecutorFromForge(forge *aiforge.ForgeBlueprint, i any, opts ...any) (*aid.Coordinator, error)
func NewExecutorFromJson ¶
func NewFetchFuncFromSrcCodeConfig ¶
func NewFetchFuncFromSrcCodeConfig() *fetchFuncFromSrcCodeConfig
func NewForgeBlueprint ¶
func NewForgeBlueprint(name string, opts ...any) *aiforge.ForgeBlueprint
func NewForgeExecutor ¶
func NewYakitFetchFuncFromSrcCodeConfig ¶
func NewYakitFetchFuncFromSrcCodeConfig() *fetchFuncFromSrcCodeConfig
func QuickEvalWithoutContext ¶
func QuickEvalWithoutContext(i interface{}) error
func StaticAnalyze ¶
func StaticAnalyze(code string, opts ...StaticAnalyzeOption) []*result.StaticAnalyzeResult
func WithFetchCallArgumentHook ¶
func WithFetchCallArgumentHook(name string, hook callArgumentHookFunc) fetchFuncFromSrcCodeOptions
func WithFetchCode ¶
func WithFetchCode(code string) fetchFuncFromSrcCodeOptions
func WithFetchEngineHook ¶
func WithFetchFunctionNames ¶
func WithFetchFunctionNames(names ...string) fetchFuncFromSrcCodeOptions
func WithFetchScript ¶
Types ¶
type AIAgentOption ¶
func WithContext ¶
func WithContext(ctx context.Context) AIAgentOption
func WithExtendAICommonOptions ¶
func WithExtendAICommonOptions(opts ...aicommon.ConfigOption) AIAgentOption
func WithForgeName ¶
func WithForgeName(forgeName string) AIAgentOption
type Agent ¶
type Agent struct {
ForgeName string
CoordinatorId string
ExtendAICommonOptions []aicommon.ConfigOption
AiForgeOptions []aiforge.Option
AgentEventHandler func(e *schema.AiOutputEvent)
// contains filtered or unexported fields
}
func (*Agent) AICommonOptions ¶
func (ag *Agent) AICommonOptions() []aicommon.ConfigOption
func (*Agent) SubOption ¶
func (ag *Agent) SubOption() []AIAgentOption
type CallConfig ¶
type CallConfig struct {
// contains filtered or unexported fields
}
func NewCallConfig ¶
func NewCallConfig() *CallConfig
type CallOpt ¶
type CallOpt func(*CallConfig)
func WithCallConfigCallback ¶
func WithCallConfigCallback(callback func()) CallOpt
func WithCallConfigForceSync ¶
func WithCallConfigItemFuncs ¶
func WithCallConfigItemFuncs(itemFuncs ...func() interface{}) CallOpt
func WithCallConfigItems ¶
func WithCallConfigItems(items ...interface{}) CallOpt
func WithCallConfigPluginId ¶
type CallerHookDescription ¶
type CallerHooks ¶
type CallerHooks struct {
HookName string
Hooks []*CallerHookDescription
}
type EmbedFieldTypeAndMethod ¶ added in v1.2.9
type InstanceMethodHandler ¶ added in v1.2.9
type InstanceMethodHandler struct {
// contains filtered or unexported fields
}
type LibFuncWithFrameType ¶
type MixPluginCaller ¶
type MixPluginCaller struct {
// contains filtered or unexported fields
}
func NewMixPluginCaller ¶
func NewMixPluginCaller() (*MixPluginCaller, error)
func NewMixPluginCallerWithFilter ¶ added in v1.3.1
func NewMixPluginCallerWithFilter(webFilter filter.Filterable) (*MixPluginCaller, error)
func (*MixPluginCaller) AddExecutionTraceCallback ¶
func (m *MixPluginCaller) AddExecutionTraceCallback(callback func(*PluginExecutionTrace)) (callbackID string, remove func())
AddExecutionTraceCallback 添加执行跟踪回调
func (*MixPluginCaller) CallAfterRequestWithCtx ¶
func (*MixPluginCaller) CallAnalyzeHTTPFlow ¶
func (*MixPluginCaller) CallBeforeRequestWithCtx ¶
func (*MixPluginCaller) CallHijackRequest ¶
func (m *MixPluginCaller) CallHijackRequest( isHttps bool, u string, getRequest func() interface{}, reject func() interface{}, drop func() interface{}, )
func (*MixPluginCaller) CallHijackRequestWithCtx ¶
func (m *MixPluginCaller) CallHijackRequestWithCtx( runtimeCtx context.Context, isHttps bool, u string, getRequest func() interface{}, reject func() interface{}, drop func() interface{}, )
func (*MixPluginCaller) CallHijackResponse ¶
func (m *MixPluginCaller) CallHijackResponse( isHttps bool, u string, getResponse, reject, drop func() interface{}, )
func (*MixPluginCaller) CallHijackResponseEx ¶
func (m *MixPluginCaller) CallHijackResponseEx( isHttps bool, u string, getRequest, getResponse, reject, drop func() interface{}, )
func (*MixPluginCaller) CallHijackResponseExWithCtx ¶
func (m *MixPluginCaller) CallHijackResponseExWithCtx( runtimeCtx context.Context, isHttps bool, u string, getRequest, getResponse, reject, drop func() interface{}, )
func (*MixPluginCaller) CallHijackResponseWithCtx ¶
func (m *MixPluginCaller) CallHijackResponseWithCtx( runtimeCtx context.Context, isHttps bool, u string, getResponse, reject, drop func() interface{}, )
func (*MixPluginCaller) CallMockHTTPRequest ¶
func (m *MixPluginCaller) CallMockHTTPRequest( isHttps bool, u string, getRequest func() interface{}, mockResponse func(rsp interface{}), )
func (*MixPluginCaller) CallMockHTTPRequestWithCtx ¶
func (m *MixPluginCaller) CallMockHTTPRequestWithCtx( runtimeCtx context.Context, isHttps bool, u string, getRequest func() interface{}, mockResponse func(rsp interface{}), )
func (*MixPluginCaller) CallOnAnalyzeHTTPFlowFinish ¶
func (m *MixPluginCaller) CallOnAnalyzeHTTPFlowFinish( runtimeCtx context.Context, totalCount int64, matchedCount int64, )
func (*MixPluginCaller) CancelAllExecutionTraces ¶
func (m *MixPluginCaller) CancelAllExecutionTraces()
CancelAllExecutionTraces 取消所有执行跟踪
func (*MixPluginCaller) CancelExecutionTrace ¶
func (m *MixPluginCaller) CancelExecutionTrace(traceID string) bool
CancelExecutionTrace 取消指定的执行跟踪
func (*MixPluginCaller) CleanupCompletedExecutionTraces ¶
func (m *MixPluginCaller) CleanupCompletedExecutionTraces(olderThan time.Duration)
CleanupCompletedExecutionTraces 清理已完成的执行跟踪
func (*MixPluginCaller) EnableExecutionTracing ¶
func (m *MixPluginCaller) EnableExecutionTracing(enable bool)
EnableExecutionTracing 启用插件执行跟踪
func (*MixPluginCaller) FeedbackOrdinary ¶
func (c *MixPluginCaller) FeedbackOrdinary(i interface{})
func (*MixPluginCaller) GetAllExecutionTraces ¶
func (m *MixPluginCaller) GetAllExecutionTraces() []*PluginExecutionTrace
GetAllExecutionTraces 获取所有执行跟踪
func (*MixPluginCaller) GetExecutionTracesByHook ¶
func (m *MixPluginCaller) GetExecutionTracesByHook(hookName string) []*PluginExecutionTrace
GetExecutionTracesByHook 根据Hook名获取执行跟踪
func (*MixPluginCaller) GetExecutionTracesByPlugin ¶
func (m *MixPluginCaller) GetExecutionTracesByPlugin(pluginID string) []*PluginExecutionTrace
GetExecutionTracesByPlugin 根据插件ID获取执行跟踪
func (*MixPluginCaller) GetExecutionTracker ¶
func (m *MixPluginCaller) GetExecutionTracker() *PluginExecutionTracker
GetExecutionTracker 获取执行跟踪器
func (*MixPluginCaller) GetFingerprintMatcher ¶
func (m *MixPluginCaller) GetFingerprintMatcher() *fp.Matcher
func (*MixPluginCaller) GetLongRunningThreshold ¶
func (c *MixPluginCaller) GetLongRunningThreshold() int
GetLongRunningThreshold 获取插件长时间运行阈值(秒)
func (*MixPluginCaller) GetNativeCaller ¶
func (m *MixPluginCaller) GetNativeCaller() *YakToCallerManager
func (*MixPluginCaller) GetRunningExecutionTraces ¶
func (m *MixPluginCaller) GetRunningExecutionTraces() []*PluginExecutionTrace
GetRunningExecutionTraces 获取正在运行的执行跟踪
func (*MixPluginCaller) HandleServiceScanResult ¶
func (m *MixPluginCaller) HandleServiceScanResult(r *fp.MatchResult)
func (*MixPluginCaller) HaveTheHookFunc ¶
func (m *MixPluginCaller) HaveTheHookFunc(name string) bool
func (*MixPluginCaller) HijackSaveHTTPFlow ¶
func (m *MixPluginCaller) HijackSaveHTTPFlow(flow *schema.HTTPFlow, reject func(httpFlow *schema.HTTPFlow), drop func())
func (*MixPluginCaller) HijackSaveHTTPFlowEx ¶
func (*MixPluginCaller) IsExecutionTracingEnabled ¶
func (m *MixPluginCaller) IsExecutionTracingEnabled() bool
IsExecutionTracingEnabled 检查是否启用了插件执行跟踪
func (*MixPluginCaller) IsPassed ¶ added in v1.3.2
func (c *MixPluginCaller) IsPassed(target string) bool
func (*MixPluginCaller) IsStatic ¶
func (c *MixPluginCaller) IsStatic(rawUrl string, req, rsp []byte) bool
func (*MixPluginCaller) LastErr ¶
func (m *MixPluginCaller) LastErr() error
func (*MixPluginCaller) LoadHotPatch ¶
func (c *MixPluginCaller) LoadHotPatch(ctx context.Context, params []*ypb.ExecParamItem, code string) error
func (*MixPluginCaller) LoadPlugin ¶
func (m *MixPluginCaller) LoadPlugin(scriptName string, params ...*ypb.ExecParamItem) error
func (*MixPluginCaller) LoadPluginByName ¶
func (m *MixPluginCaller) LoadPluginByName(ctx context.Context, name string, params []*ypb.ExecParamItem, codes ...string) error
LoadPluginByName 基于脚本名加载插件,如果没有指定代码,则从数据库中加载,如果指定了代码,则默认视为mitm插件执行
func (*MixPluginCaller) LoadPluginEx ¶ added in v1.3.2
func (m *MixPluginCaller) LoadPluginEx(ctx context.Context, script *schema.YakScript, params ...*ypb.ExecParamItem) error
func (*MixPluginCaller) MirrorHTTPFlow ¶
func (m *MixPluginCaller) MirrorHTTPFlow( isHttps bool, u string, req, rsp, body []byte, filters ...bool, )
func (*MixPluginCaller) MirrorHTTPFlowEx ¶
func (*MixPluginCaller) MirrorHTTPFlowExSync ¶ added in v1.3.2
func (*MixPluginCaller) MirrorHTTPFlowWithCtx ¶
func (*MixPluginCaller) ResetFilter ¶
func (c *MixPluginCaller) ResetFilter()
func (*MixPluginCaller) SetCache ¶ added in v1.2.2
func (m *MixPluginCaller) SetCache(b bool)
func (*MixPluginCaller) SetCallPluginTimeout ¶ added in v1.3.2
func (c *MixPluginCaller) SetCallPluginTimeout(i float64)
func (*MixPluginCaller) SetConcurrent ¶
func (c *MixPluginCaller) SetConcurrent(i int) error
func (*MixPluginCaller) SetCtx ¶ added in v1.3.2
func (m *MixPluginCaller) SetCtx(ctx context.Context)
func (*MixPluginCaller) SetDividedContext ¶
func (m *MixPluginCaller) SetDividedContext(b bool)
func (*MixPluginCaller) SetFeedback ¶
func (m *MixPluginCaller) SetFeedback(i func(i *ypb.ExecResult) error)
func (*MixPluginCaller) SetLoadPluginTimeout ¶
func (c *MixPluginCaller) SetLoadPluginTimeout(i float64)
func (*MixPluginCaller) SetLongRunningThreshold ¶
func (c *MixPluginCaller) SetLongRunningThreshold(seconds int)
SetLongRunningThreshold 设置插件长时间运行阈值(秒)
func (*MixPluginCaller) SetProxy ¶ added in v1.2.4
func (m *MixPluginCaller) SetProxy(s ...string)
func (*MixPluginCaller) SetRuntimeId ¶ added in v1.2.3
func (m *MixPluginCaller) SetRuntimeId(s string)
func (*MixPluginCaller) SetVar ¶
func (m *MixPluginCaller) SetVar(key string, value any)
func (*MixPluginCaller) Wait ¶
func (c *MixPluginCaller) Wait()
type PalmScriptEngineHelper ¶
type PalmScriptEngineHelper struct {
Libs map[string]*PalmScriptLib
BuildInFunctions map[string]*PalmScriptLibFunc
UserFunctions map[string]*PalmScriptLibFunc
Instances map[string]*PalmScriptLibInstance
}
func EngineToHelper ¶
func EngineToHelper(engine *antlr4yak.Engine) *PalmScriptEngineHelper
func (*PalmScriptEngineHelper) GetAllLibs ¶
func (p *PalmScriptEngineHelper) GetAllLibs() []string
func (*PalmScriptEngineHelper) HelpInfo ¶
func (p *PalmScriptEngineHelper) HelpInfo() string
func (*PalmScriptEngineHelper) LibHelpInfo ¶
func (p *PalmScriptEngineHelper) LibHelpInfo(name string) string
func (*PalmScriptEngineHelper) ShowHelpInfo ¶
func (p *PalmScriptEngineHelper) ShowHelpInfo()
func (*PalmScriptEngineHelper) ShowLibHelpInfo ¶
func (p *PalmScriptEngineHelper) ShowLibHelpInfo(name string)
type PalmScriptLib ¶
type PalmScriptLib struct {
Name string
Values map[string]interface{}
ElementDocs []string
FuncElements []*PalmScriptLibFunc
InstanceElements []*PalmScriptLibInstance
}
func (*PalmScriptLib) String ¶
func (p *PalmScriptLib) String() string
type PalmScriptLibFunc ¶
func (*PalmScriptLibFunc) String ¶
func (p *PalmScriptLibFunc) String() string
type PalmScriptLibInstance ¶
type PalmScriptLibInstance struct {
LibName string
InstanceName string
Type string
Value interface{}
}
func (*PalmScriptLibInstance) String ¶
func (p *PalmScriptLibInstance) String() string
type PluginExecutionStatus ¶
type PluginExecutionStatus string
PluginExecutionStatus 插件执行状态
const ( PluginStatusPending PluginExecutionStatus = "pending" // 等待执行 PluginStatusRunning PluginExecutionStatus = "running" // 正在执行 PluginStatusCompleted PluginExecutionStatus = "completed" // 执行完成 PluginStatusFailed PluginExecutionStatus = "failed" // 执行失败 PluginStatusCancelled PluginExecutionStatus = "cancelled" // 被取消 )
type PluginExecutionTrace ¶
type PluginExecutionTrace struct {
TraceID string `json:"trace_id"` // 跟踪ID,唯一标识一次执行
PluginID string `json:"plugin_id"` // 插件ID
HookName string `json:"hook_name"` // Hook函数名
Status PluginExecutionStatus `json:"status"` // 执行状态
LoadedTime time.Time `json:"loaded_time"` // 插件加载时间
StartTime time.Time `json:"start_time"` // 执行开始时间
EndTime time.Time `json:"end_time"` // 执行结束时间
Duration time.Duration `json:"duration"` // 执行耗时
Args []interface{} `json:"args"` // 执行参数
Result interface{} `json:"result"` // 执行结果
Error string `json:"error"` // 错误信息
CancelFunc context.CancelFunc `json:"-"` // 取消函数
RuntimeCtx context.Context `json:"-"` // 运行时上下文
}
PluginExecutionTrace 插件执行跟踪信息
type PluginExecutionTracker ¶
type PluginExecutionTracker struct {
// contains filtered or unexported fields
}
PluginExecutionTracker 插件执行跟踪器
func NewPluginExecutionTracker ¶
func NewPluginExecutionTracker() *PluginExecutionTracker
NewPluginExecutionTracker 创建新的插件执行跟踪器
func NewPluginExecutionTrackerWithStaleSize ¶
func NewPluginExecutionTrackerWithStaleSize(staleQueueSize int) *PluginExecutionTracker
NewPluginExecutionTrackerWithStaleSize 创建指定stale队列大小的插件执行跟踪器
func (*PluginExecutionTracker) AddCallback ¶
func (t *PluginExecutionTracker) AddCallback(callback func(*PluginExecutionTrace)) (callbackID string, remove func())
AddCallback 添加跟踪回调函数
func (*PluginExecutionTracker) CancelAllTraces ¶
func (t *PluginExecutionTracker) CancelAllTraces()
CancelAllTraces 取消所有跟踪
func (*PluginExecutionTracker) CancelTrace ¶
func (t *PluginExecutionTracker) CancelTrace(traceID string) bool
CancelTrace 取消跟踪
func (*PluginExecutionTracker) CleanupCompletedTraces ¶
func (t *PluginExecutionTracker) CleanupCompletedTraces(olderThan time.Duration)
CleanupCompletedTraces 清理已完成的跟踪信息(现在主要用于清理stale队列中过旧的数据)
func (*PluginExecutionTracker) ClearStaleTraces ¶
func (t *PluginExecutionTracker) ClearStaleTraces()
ClearStaleTraces 清空stale队列
func (*PluginExecutionTracker) CreateTrace ¶
func (t *PluginExecutionTracker) CreateTrace(pluginID, hookName string, runtimeCtx context.Context) *PluginExecutionTrace
CreateTrace 创建新的插件执行跟踪记录(每次调用都创建新的Trace)
func (*PluginExecutionTracker) FindLatestRunningTraceByPluginAndHook ¶
func (t *PluginExecutionTracker) FindLatestRunningTraceByPluginAndHook(pluginID, hookName string) *PluginExecutionTrace
FindLatestRunningTraceByPluginAndHook 查找指定插件和Hook的最新正在运行的Trace
func (*PluginExecutionTracker) FindTraceByPluginAndHook ¶
func (t *PluginExecutionTracker) FindTraceByPluginAndHook(pluginID, hookName string) *PluginExecutionTrace
FindTraceByPluginAndHook 根据插件ID和Hook名查找最新的跟踪记录 注意:此方法现在返回最新创建的Trace记录,主要用于兼容性
func (*PluginExecutionTracker) GetActiveTraces ¶
func (t *PluginExecutionTracker) GetActiveTraces() []*PluginExecutionTrace
GetActiveTraces 获取所有活跃的跟踪信息(不包括stale的)
func (*PluginExecutionTracker) GetAllTraces ¶
func (t *PluginExecutionTracker) GetAllTraces() []*PluginExecutionTrace
GetAllTraces 获取所有跟踪信息(包括活跃的和stale的)
func (*PluginExecutionTracker) GetRunningTraces ¶
func (t *PluginExecutionTracker) GetRunningTraces() []*PluginExecutionTrace
GetRunningTraces 获取正在运行的跟踪信息(只从活跃traces中查找)
func (*PluginExecutionTracker) GetStaleQueueInfo ¶
func (t *PluginExecutionTracker) GetStaleQueueInfo() map[string]interface{}
GetStaleQueueInfo 获取stale队列信息
func (*PluginExecutionTracker) GetStaleTraces ¶
func (t *PluginExecutionTracker) GetStaleTraces() []*PluginExecutionTrace
GetStaleTraces 获取所有stale的跟踪信息
func (*PluginExecutionTracker) GetTrace ¶
func (t *PluginExecutionTracker) GetTrace(traceID string) (*PluginExecutionTrace, bool)
GetTrace 获取跟踪信息(先从活跃traces查找,再从stale队列查找)
func (*PluginExecutionTracker) GetTracesByHook ¶
func (t *PluginExecutionTracker) GetTracesByHook(hookName string) []*PluginExecutionTrace
GetTracesByHook 根据Hook名获取跟踪信息(包括活跃的和stale的)
func (*PluginExecutionTracker) GetTracesByPlugin ¶
func (t *PluginExecutionTracker) GetTracesByPlugin(pluginID string) []*PluginExecutionTrace
GetTracesByPlugin 根据插件ID获取跟踪信息(包括活跃的和stale的)
func (*PluginExecutionTracker) RemoveTrace ¶
func (t *PluginExecutionTracker) RemoveTrace(traceID string) bool
RemoveTrace 删除指定的跟踪记录(只能删除活跃的trace)
func (*PluginExecutionTracker) RemoveTracesByPluginAndHook ¶
func (t *PluginExecutionTracker) RemoveTracesByPluginAndHook(pluginID, hookName string) int
RemoveTracesByPluginAndHook 删除指定插件和Hook的所有跟踪记录(只能删除活跃的trace)
func (*PluginExecutionTracker) StartExecution ¶
func (t *PluginExecutionTracker) StartExecution(traceID string, args []interface{}) bool
StartExecution 开始执行跟踪(从Pending转为Running)
func (*PluginExecutionTracker) UpdateTraceStatus ¶
func (t *PluginExecutionTracker) UpdateTraceStatus(traceID string, status PluginExecutionStatus, result interface{}, err error)
UpdateTraceStatus 更新跟踪状态
type Sandbox ¶ added in v1.3.1
type Sandbox struct {
// contains filtered or unexported fields
}
func NewSandbox ¶ added in v1.3.1
func NewSandbox(opts ...SandboxOption) *Sandbox
func (*Sandbox) ExecuteAsBoolean ¶ added in v1.3.1
func (*Sandbox) ExecuteAsExpression ¶ added in v1.3.1
type SandboxConfig ¶ added in v1.3.1
type SandboxConfig struct {
// contains filtered or unexported fields
}
type SandboxOption ¶ added in v1.3.1
type SandboxOption func(*SandboxConfig)
func WithSandbox_ExternalLib ¶ added in v1.3.1
func WithSandbox_ExternalLib(lib map[string]any) SandboxOption
func WithYaklang_Libs ¶
func WithYaklang_Libs(b bool) SandboxOption
type ScriptEngine ¶
type ScriptEngine struct {
// 设定几个 hook
RegisterLogHook yaklib.RegisterOutputFuncType
UnregisterLogHook yaklib.UnregisterOutputFuncType
RegisterLogConsoleHook yaklib.RegisterOutputFuncType
UnregisterLogConsoleHook yaklib.UnregisterOutputFuncType
RegisterOutputHook yaklib.RegisterOutputFuncType
UnregisterOutputHook yaklib.UnregisterOutputFuncType
RegisterFailedHook yaklib.RegisterOutputFuncType
UnregisterFailedHook yaklib.UnregisterOutputFuncType
RegisterFinishHook yaklib.RegisterOutputFuncType
UnregisterFinishHook yaklib.UnregisterOutputFuncType
RegisterAlertHook yaklib.RegisterOutputFuncType
UnregisterAlertHook yaklib.UnregisterOutputFuncType
// contains filtered or unexported fields
}
func NewScriptEngine ¶
func NewScriptEngine(maxConcurrent int) *ScriptEngine
func NewYakitVirtualClientScriptEngine ¶ added in v1.2.2
func NewYakitVirtualClientScriptEngine(client *yaklib.YakitClient) *ScriptEngine
func (*ScriptEngine) Execute ¶
func (e *ScriptEngine) Execute(code string) error
func (*ScriptEngine) ExecuteExWithContext ¶
func (*ScriptEngine) ExecuteMain ¶
func (e *ScriptEngine) ExecuteMain(code string, AbsFile string) error
func (*ScriptEngine) ExecuteMainWithContext ¶
func (*ScriptEngine) ExecuteWithContext ¶
func (e *ScriptEngine) ExecuteWithContext(ctx context.Context, code string) error
func (*ScriptEngine) ExecuteWithTaskID ¶
func (e *ScriptEngine) ExecuteWithTaskID(taskId, code string) error
func (*ScriptEngine) ExecuteWithTaskIDAndContext ¶
func (e *ScriptEngine) ExecuteWithTaskIDAndContext(ctx context.Context, taskId, code string) error
func (*ScriptEngine) ExecuteWithTaskIDAndParams ¶
func (*ScriptEngine) ExecuteWithTemplate ¶
func (e *ScriptEngine) ExecuteWithTemplate(codeTmp string, i map[string][]string) error
func (*ScriptEngine) ExecuteWithoutCache ¶
func (*ScriptEngine) GetTaskByTaskID ¶
func (s *ScriptEngine) GetTaskByTaskID(id string) (*Task, error)
func (*ScriptEngine) HookOsExit ¶
func (e *ScriptEngine) HookOsExit()
func (*ScriptEngine) RegisterEngineHooks ¶
func (e *ScriptEngine) RegisterEngineHooks(f func(engine *antlr4yak.Engine) error)
func (*ScriptEngine) SaveTask ¶
func (s *ScriptEngine) SaveTask(task *Task) error
func (*ScriptEngine) SetCallFuncCallback ¶
func (*ScriptEngine) SetCryptoKey ¶
func (s *ScriptEngine) SetCryptoKey(key []byte) error
func (*ScriptEngine) SetDebug ¶
func (s *ScriptEngine) SetDebug(debug bool)
func (*ScriptEngine) SetDebugCallback ¶
func (s *ScriptEngine) SetDebugCallback(callback func(*yakvm.Debugger))
func (*ScriptEngine) SetDebugInit ¶
func (s *ScriptEngine) SetDebugInit(callback func(*yakvm.Debugger))
func (*ScriptEngine) SetYakitClient ¶ added in v1.2.2
func (e *ScriptEngine) SetYakitClient(client *yaklib.YakitClient)
func (*ScriptEngine) Status ¶
func (s *ScriptEngine) Status() map[string]*Task
type StaleTraceQueue ¶
type StaleTraceQueue struct {
// contains filtered or unexported fields
}
StaleTraceQueue stale trace 队列,使用 container/ring 实现
func NewStaleTraceQueue ¶
func NewStaleTraceQueue(capacity int) *StaleTraceQueue
NewStaleTraceQueue 创建新的stale trace队列
func (*StaleTraceQueue) GetAll ¶
func (q *StaleTraceQueue) GetAll() []*PluginExecutionTrace
GetAll 获取所有stale traces(按时间顺序,最新的在前面)
func (*StaleTraceQueue) GetByTraceID ¶
func (q *StaleTraceQueue) GetByTraceID(traceID string) *PluginExecutionTrace
GetByTraceID 根据traceID查找stale trace
func (*StaleTraceQueue) Push ¶
func (q *StaleTraceQueue) Push(trace *PluginExecutionTrace) *PluginExecutionTrace
Push 添加trace到队列,如果队列满了则覆盖最老的trace
type StaticAnalyzeConfig ¶
type StaticAnalyzeConfig struct {
// contains filtered or unexported fields
}
func NewStaticAnalyzeConfig ¶
func NewStaticAnalyzeConfig() *StaticAnalyzeConfig
type StaticAnalyzeOption ¶
type StaticAnalyzeOption func(*StaticAnalyzeConfig)
func WithStaticAnalyzeKindAnalyze ¶
func WithStaticAnalyzeKindAnalyze() StaticAnalyzeOption
func WithStaticAnalyzeKindScore ¶
func WithStaticAnalyzeKindScore() StaticAnalyzeOption
func WithStaticAnalyzePluginType ¶
func WithStaticAnalyzePluginType(typ string) StaticAnalyzeOption
type Task ¶
type Task struct {
TaskID string
Code string
Output []string
Log []string
Alert []string
Finished []string
Failed []string
// contains filtered or unexported fields
}
func (*Task) IsFinished ¶
type TextHandlingScript ¶
type TextParser ¶
type TextParser struct {
Scripts map[string]*TextHandlingScript
// contains filtered or unexported fields
}
type YakFunctionCaller ¶
type YakToCallerManager ¶
type YakToCallerManager struct {
ContextCancelFuncs *sync.Map
Err error
// contains filtered or unexported fields
}
YakToCallerManager 是 Yaklang 中用于管理插件函数调用的核心结构体。
func NewYakToCallerManager ¶
func NewYakToCallerManager() *YakToCallerManager
func (*YakToCallerManager) AddExecutionTraceCallback ¶
func (y *YakToCallerManager) AddExecutionTraceCallback(callback func(*PluginExecutionTrace)) (callbackID string, remove func())
AddExecutionTraceCallback 添加执行跟踪回调
func (*YakToCallerManager) AddForYakit ¶
func (*YakToCallerManager) Call ¶
func (y *YakToCallerManager) Call(name string, opts ...CallOpt) (results []any)
only forceSync can get results
func (*YakToCallerManager) CallByName ¶
func (y *YakToCallerManager) CallByName(name string, items ...interface{})
func (*YakToCallerManager) CallByNameExSync ¶
func (y *YakToCallerManager) CallByNameExSync(name string, items ...func() interface{})
func (*YakToCallerManager) CallByNameSync ¶ added in v1.3.2
func (y *YakToCallerManager) CallByNameSync(name string, items ...interface{})
func (*YakToCallerManager) CallByNameWithCallback ¶
func (y *YakToCallerManager) CallByNameWithCallback(name string, callback func(), items ...interface{})
func (*YakToCallerManager) CallPluginKeyByName ¶
func (y *YakToCallerManager) CallPluginKeyByName(pluginId string, name string, items ...interface{})
func (*YakToCallerManager) CallPluginKeyByNameEx ¶
func (y *YakToCallerManager) CallPluginKeyByNameEx(pluginId string, name string, callback func(), itemsFuncs ...func() interface{})
func (*YakToCallerManager) CallPluginKeyByNameExWithAsync ¶
func (*YakToCallerManager) CallPluginKeyByNameSyncWithCallback ¶
func (y *YakToCallerManager) CallPluginKeyByNameSyncWithCallback(pluginId string, name string, callback func(), items ...interface{})
func (*YakToCallerManager) CallPluginKeyByNameWithCallback ¶
func (y *YakToCallerManager) CallPluginKeyByNameWithCallback(pluginId string, name string, callback func(), items ...interface{})
func (*YakToCallerManager) CancelAllExecutionTraces ¶
func (y *YakToCallerManager) CancelAllExecutionTraces()
CancelAllExecutionTraces 取消所有执行跟踪
func (*YakToCallerManager) CancelExecutionTrace ¶
func (y *YakToCallerManager) CancelExecutionTrace(traceID string) bool
CancelExecutionTrace 取消指定的执行跟踪
func (*YakToCallerManager) CleanupCompletedExecutionTraces ¶
func (y *YakToCallerManager) CleanupCompletedExecutionTraces(olderThan time.Duration)
CleanupCompletedExecutionTraces 清理已完成的执行跟踪
func (*YakToCallerManager) EnableExecutionTracing ¶
func (y *YakToCallerManager) EnableExecutionTracing(enable bool)
EnableExecutionTracing 启用插件执行跟踪
func (*YakToCallerManager) GetAllExecutionTraces ¶
func (y *YakToCallerManager) GetAllExecutionTraces() []*PluginExecutionTrace
GetAllExecutionTraces 获取所有执行跟踪
func (*YakToCallerManager) GetCurrentHooks ¶
func (y *YakToCallerManager) GetCurrentHooks() []*CallerHooks
func (*YakToCallerManager) GetCurrentHooksGRPCModel ¶
func (y *YakToCallerManager) GetCurrentHooksGRPCModel() []*ypb.YakScriptHooks
func (*YakToCallerManager) GetExecutionTracesByHook ¶
func (y *YakToCallerManager) GetExecutionTracesByHook(hookName string) []*PluginExecutionTrace
GetExecutionTracesByHook 根据Hook名获取执行跟踪
func (*YakToCallerManager) GetExecutionTracesByPlugin ¶
func (y *YakToCallerManager) GetExecutionTracesByPlugin(pluginID string) []*PluginExecutionTrace
GetExecutionTracesByPlugin 根据插件ID获取执行跟踪
func (*YakToCallerManager) GetExecutionTracker ¶
func (y *YakToCallerManager) GetExecutionTracker() *PluginExecutionTracker
GetExecutionTracker 获取执行跟踪器
func (*YakToCallerManager) GetLongRunningThreshold ¶
func (y *YakToCallerManager) GetLongRunningThreshold() int
GetLongRunningThreshold 获取插件长时间运行阈值(秒)
func (*YakToCallerManager) GetRunningExecutionTraces ¶
func (y *YakToCallerManager) GetRunningExecutionTraces() []*PluginExecutionTrace
GetRunningExecutionTraces 获取正在运行的执行跟踪
func (*YakToCallerManager) GetWaitingEventCount ¶
func (y *YakToCallerManager) GetWaitingEventCount() int
func (*YakToCallerManager) IsExecutionTracingEnabled ¶
func (y *YakToCallerManager) IsExecutionTracingEnabled() bool
IsExecutionTracingEnabled 检查是否启用了插件执行跟踪
func (*YakToCallerManager) LoadPlugin ¶
func (y *YakToCallerManager) LoadPlugin(t string, hooks ...string) error
func (*YakToCallerManager) LoadPluginContext ¶
func (*YakToCallerManager) Remove ¶
func (y *YakToCallerManager) Remove(params *ypb.RemoveHookParams)
func (*YakToCallerManager) SetCallPluginTimeout ¶ added in v1.3.2
func (y *YakToCallerManager) SetCallPluginTimeout(i float64)
func (*YakToCallerManager) SetConcurrent ¶
func (y *YakToCallerManager) SetConcurrent(i int) error
func (*YakToCallerManager) SetDividedContext ¶
func (y *YakToCallerManager) SetDividedContext(b bool)
func (*YakToCallerManager) SetForYakit ¶
func (*YakToCallerManager) SetLoadPluginTimeout ¶
func (y *YakToCallerManager) SetLoadPluginTimeout(i float64)
func (*YakToCallerManager) SetLongRunningThreshold ¶
func (y *YakToCallerManager) SetLongRunningThreshold(seconds int)
SetLongRunningThreshold 设置插件长时间运行阈值(秒)
func (*YakToCallerManager) ShouldCallByName ¶ added in v1.2.6
func (y *YakToCallerManager) ShouldCallByName(name string, callbacks ...func()) (ret bool)
func (*YakToCallerManager) SyncCallPluginKeyByNameEx ¶
func (y *YakToCallerManager) SyncCallPluginKeyByNameEx(pluginId string, name string, callback func(), itemsFuncs ...func() interface{})
func (*YakToCallerManager) Wait ¶
func (y *YakToCallerManager) Wait()
func (*YakToCallerManager) WithVulFilter ¶
func (y *YakToCallerManager) WithVulFilter(filter filter.Filterable) *YakToCallerManager
type YakitCallerIf ¶
type YakitCallerIf func(result *ypb.ExecResult) error
func (YakitCallerIf) Send ¶
func (y YakitCallerIf) Send(i *ypb.ExecResult) error
type YakitPluginContext ¶ added in v1.2.4
type YakitPluginContext struct {
yakit.YakitPluginInfo
Proxy string
Ctx context.Context
CliApp *cli.CliApp
Cancel context.CancelFunc
YakitClient *yaklib.YakitClient
// contains filtered or unexported fields
}
func CreateYakitPluginContext ¶ added in v1.3.1
func CreateYakitPluginContext(runtimeId string) *YakitPluginContext
func (*YakitPluginContext) WithCliApp ¶ added in v1.3.1
func (y *YakitPluginContext) WithCliApp(cliApp *cli.CliApp) *YakitPluginContext
func (*YakitPluginContext) WithContext ¶ added in v1.3.1
func (y *YakitPluginContext) WithContext(ctx context.Context) *YakitPluginContext
func (*YakitPluginContext) WithContextCancel ¶ added in v1.3.2
func (y *YakitPluginContext) WithContextCancel(cancel context.CancelFunc) *YakitPluginContext
func (*YakitPluginContext) WithPluginName ¶ added in v1.3.1
func (y *YakitPluginContext) WithPluginName(id string) *YakitPluginContext
func (*YakitPluginContext) WithPluginUUID ¶
func (y *YakitPluginContext) WithPluginUUID(uuid string) *YakitPluginContext
func (*YakitPluginContext) WithProxy ¶ added in v1.3.1
func (y *YakitPluginContext) WithProxy(proxy string) *YakitPluginContext
func (*YakitPluginContext) WithVulFilter ¶
func (y *YakitPluginContext) WithVulFilter(filter filter.Filterable) *YakitPluginContext
func (*YakitPluginContext) WithYakitClient ¶
func (y *YakitPluginContext) WithYakitClient(yakitClient *yaklib.YakitClient) *YakitPluginContext
Source Files
¶
- ai_forge_executor.go
- aiagent.go
- aiagent_executor.go
- aiagent_options.go
- aiagent_utils.go
- document.go
- dynamic_eval.go
- helper.go
- hook_mixed_plugin_caller.go
- line_parser.go
- plugin_context.go
- plugin_execution_tracker.go
- rag_export.go
- sandbox.go
- script_engine.go
- script_engine_for_fuzz.go
- static_analyzer.go
- task.go
- yak_to_caller_manager.go
Directories
¶
| Path | Synopsis |
|---|---|
|
antlr4JS
|
|
|
antlr4c
|
|
|
antlr4go
|
|
|
cmd
command
|
|
|
yakcmds
Package yakcmds @Author bcy2007 2024/3/12 16:06
|
Package yakcmds @Author bcy2007 2024/3/12 16:06 |
|
java
|
|
|
php
|
|
|
typescript
|
|
|
frontend/diagnostics
Package diagnostics contains generated localizable diagnostic messages.
|
Package diagnostics contains generated localizable diagnostic messages. |
|
frontend/jsnum
Package jsnum provides JS-like number handling.
|
Package jsnum provides JS-like number handling. |
|
frontend/stringutil
Package stringutil Exports common rune utilities for parsing and emitting javascript
|
Package stringutil Exports common rune utilities for parsing and emitting javascript |
|
generate_doc
command
|
|
|
generate_web_doc
command
|
|
|
codec/codegrpc/doc
command
|
|