Skip to content

Security

weego edited this page Nov 15, 2026 · 2 revisions

Security

LightAgent is intentionally flexible: it can call Python tools, execute built-in utilities, connect MCP servers, retrieve memory, and activate Skills. Production deployments should treat these extension points as trust boundaries.

Tool Safety

Tools can read files, call networks, write databases, upload objects, or execute code depending on the callable implementation.

Recommended controls:

  • Keep tool descriptions narrow and accurate.
  • Validate required arguments and types.
  • Avoid exposing high-risk tools to broad user traffic.
  • Add approval steps for file writes, payments, database mutations, or external actions.
  • Log tool name, arguments metadata, user id, and result status.
  • Do not log secrets or sensitive raw payloads unless your compliance process requires it.

Built-in Tools

Legacy arbitrary-Python utilities are not registered by default in v1.0.0 and are blocked in model/tool dispatch. A direct trusted call is not a sandbox and is not safe for untrusted input. Use safe_expression for bounded arithmetic, or an independently isolated backend when controlled execution is required. See the v1.0.0 safety guide for authorization, fail-closed hooks, approvals, trace redaction, and optional signed Providers.

Memory Safety

Memory is a persistence boundary. Use MemoryPolicy, namespaces, provenance metadata, and backend-level access control.

Recommended defaults:

  • separate namespaces per user, tenant, agent, and environment
  • filter retrieval by provenance and user id
  • treat retrieved memory as untrusted context
  • do not allow one user's memory to overwrite trusted facts for another user

See Memory and the tagged Memory Security Guidance.

MCP Safety

MCP servers can expose external systems. For each server:

  • verify command paths and server code
  • keep credentials out of committed config files
  • use least-privilege tokens
  • disable unused servers
  • test the server independently before connecting it to an agent

Skills Safety

Skills can load long instructions, read references, execute scripts, and access assets.

Recommended controls:

  • review third-party Skills before use
  • keep scripts in scripts/ small and deterministic
  • avoid broad filesystem assumptions
  • do not put secrets in SKILL.md
  • prefer references for static knowledge and tools for external actions

Trace and Log Safety

Structured trace events are designed to avoid storing full prompts by default, but logs and tool outputs can still contain sensitive content.

Recommended controls:

  • keep trace exports out of public issue reports unless reviewed
  • redact secrets from debug logs
  • avoid logging full memory contents
  • rotate logs in long-running deployments

Responsible Disclosure

Report sensitive details through GitHub Private Vulnerability Reporting. See the repository's security policy.

Clone this wiki locally