.lmnet — Network | LMX

LMX // .LMNET

.lmnetNetwork

ping / fetch / post over the network (SSRF-sensitive).

  • Operator only
  • a .lmnet file
  • free to run
WHAT IT IS

Why .lmnet exists.

A networking DSL: ping a host or fetch/post to a URL. Can reach internal services (SSRF risk), so it is admin-only and requires LMX_ENABLE_NET=1.

Operator only

This one touches the host machine, so it needs an operator: an admin role AND an explicit environment flag, both off by default. That is a security control, not a paywall.

Enabled with LMX_ENABLE_NET=1 on the API, by an operator, on purpose.


A WORKED EXAMPLE

LMNET Demo — outbound network (admin-only). Prints status + response for each request.

The same script the engine test suite runs, so it cannot quietly stop working.

# LMNET Demo — outbound network (admin-only). Prints status + response for each request.

# Fetch a public URL
fetch "https://example.com"

# Post JSON to an endpoint (uncomment to try against a real server):
# post "https://httpbin.org/post" --body "{\"message\":\"hello\"}"

# Ping a host (Linux hosts only — uses `ping -c`):
# ping "1.1.1.1"

SYNTAX

The shape of it.

Straight from the interpreter catalogue — the same summary the editor shows as a placeholder.

fetch "https://example.com"
ping "1.1.1.1"

NEXT

Where to take it.