{"record":{"id":"3c136e4ff752cb1d","repo":"projectdiscovery/nuclei","slug":"dialers-not-initialized-for-execution-s","errorCode":null,"errorMessage":"dialers not initialized for execution %s","messagePattern":"dialers not initialized for execution (.+?)","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"pkg/js/libs/dcerpc/dcerpc.go","lineNumber":212,"sourceCode":"}\n\n// RpcDump enumerates every RPC endpoint registered with the EPMAPPER over\n// ncacn_ip_tcp/135 (impacket: rpcdump.py).\n//\n// @example\n// ```javascript\n// const dcerpc = require('nuclei/dcerpc');\n// const c = new dcerpc.Client('dc01', 'acme.local', 'admin', 'P@ss');\n// const eps = c.RpcDump();\n// for (const e of eps) { log(e.UUID + ' ' + e.Annotation); }\n// ```\nfunc (c *Client) RpcDump(ctx context.Context) ([]Endpoint, error) {\n\tif !protocolstate.IsHostAllowed(c.nj.ExecutionId(), c.Host) {\n\t\treturn nil, protocolstate.ErrHostDenied.Msgf(c.Host)\n\t}\n\tdialer := protocolstate.GetDialersWithId(c.nj.ExecutionId())\n\tif dialer == nil {\n\t\treturn nil, fmt.Errorf(\"dialers not initialized for execution %s\", c.nj.ExecutionId())\n\t}\n\tconn, err := dialer.Fastdialer.Dial(ctx, \"tcp\", net.JoinHostPort(c.Host, strconv.Itoa(135)))\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"dial epmapper: %w\", err)\n\t}\n\tdefer func() { _ = conn.Close() }()\n\n\trpc := gprpc.NewClientTCP(gprpc.NewTCPTransport(conn))\n\tif err := rpc.Bind(gpepm.UUID, gpepm.MajorVersion, gpepm.MinorVersion); err != nil {\n\t\treturn nil, fmt.Errorf(\"epmapper bind: %w\", err)\n\t}\n\tepm := gpepm.NewEpmClient(rpc)\n\treturn epm.Lookup()\n}\n\n// SamrEnumerateUsers connects to SAMR and returns every domain user record\n// (impacket: samrdump.py).\n//","sourceCodeStart":194,"sourceCodeEnd":230,"githubUrl":"https://github.com/projectdiscovery/nuclei/blob/265b3a3dec374741614e342f813c10f8b38d2bb7/pkg/js/libs/dcerpc/dcerpc.go#L194-L230","documentation":"Internal guard in Client.RpcDump: protocolstate.GetDialersWithId(executionId) returned nil before dialing tcp/135. The per-execution fastdialer bundle (network policy, DNS cache, proxying) was never registered for this JS execution id. This is a nuclei runtime initialization/ordering defect or an unsupported embedding path — not a property of the target.","triggerScenarios":"Calling c.RpcDump() in an execution context whose protocolstate dialers were never initialized: running code-protocol templates through lib/nuclei without the standard engine setup, a custom runner that skips dialer init, or a nuclei version regression in protocolstate wiring.","commonSituations":"Embedding nuclei as a library and invoking JS templates outside the normal runner; upgrading across a protocolstate refactor; test harnesses that construct the goja runtime manually.","solutions":["Upgrade (or pin) nuclei to a release where code templates execute normally.","If embedding via lib/nuclei, ensure the full engine initialization (protocolstate/dialer setup) runs before executing templates.","Report the bug with template and nuclei version — template code cannot fix a missing dialer table.","Meanwhile use named-pipe methods (SamrEnumerateUsers, EnumServices) which dial through the per-client exec dialer path instead."],"exampleFix":null,"handlingStrategy":"fallback","validationCode":null,"typeGuard":null,"tryCatchPattern":"let endpoints;\ntry {\n  endpoints = c.RpcDump();\n} catch (e) {\n  if (String(e).includes('dialers not initialized')) {\n    // runtime defect: fall back to named-pipe methods that use the exec dialer\n    log('RpcDump unavailable in this execution; using pipe-based enumeration');\n    endpoints = [];\n  } else throw e;\n}","preventionTips":["Keep nuclei updated; this error indicates a runtime/initialization defect, not a target issue.","When embedding via lib/nuclei, run the standard engine initialization before executing code templates.","Don't build templates that depend solely on RpcDump — keep a 445-based enumeration path."],"tags":["internal","protocolstate","initialization","runtime","bug"],"backgroundTag":null,"analyzedSha":"265b3a3dec374741614e342f813c10f8b38d2bb7","analyzedAt":"2026-08-15T20:05:51.855Z","schemaVersion":2},"datasetVersion":"2026-08-15T22:17:37.221Z"}