Implement safe public LSL delivery (#129)
This commit is contained in:
@@ -13,7 +13,7 @@ a CLR assembly, starts a .NET process, or delegates to a platform-only API.
|
||||
| `LibreMetaverse.Rendering.Simple` | `libremetaverse-rendering-simple` | `SimpleRenderer`, `IRendering` |
|
||||
| `LibreMetaverse.Rendering.MeshFoundry` | `libremetaverse-rendering-mesh-foundry` | `MeshFoundry`, `IRendering`, `MeshFaceAux` |
|
||||
| `LibreMetaverse.RLV` | `libremetaverse-rlv` | `RlvService`, `RlvPermissionsService`, callback traits |
|
||||
| `LibreMetaverse.LslTools` | `libremetaverse-lsl-tools` | `Lexer`, `Parser`, `Grammar`, generated tables |
|
||||
| `LibreMetaverse.LslTools` | `metacrate-lsl-tools` | `Lexer`, `Parser`, `Grammar`, generated tables |
|
||||
|
||||
The mapped PascalCase C# surface remains represented in the API ledger, while
|
||||
the callable Rust names follow the workspace's snake-case mapping. New code
|
||||
@@ -88,7 +88,7 @@ an explicit development operation; parsing never generates or compiles code at
|
||||
runtime.
|
||||
|
||||
```rust,no_run
|
||||
use libremetaverse_lsl_tools::{Lexer, Parser, generated_lexer, generated_parser};
|
||||
use metacrate_lsl_tools::{Lexer, Parser, generated_lexer, generated_parser};
|
||||
|
||||
fn parse(source: String) -> Result<String, libremetaverse_types::Error> {
|
||||
let lexer = Lexer::new(generated_lexer()?)?;
|
||||
|
||||
40
docs/grid-agent-script-delivery.md
Normal file
40
docs/grid-agent-script-delivery.md
Normal file
@@ -0,0 +1,40 @@
|
||||
# Grid-agent LSL script delivery
|
||||
|
||||
The public LSL exception is deliberately narrower than operator authority. An
|
||||
explicit public-chat or one-to-one IM request may expose only
|
||||
`deliver_generated_lsl`. Policy binds that call to the authenticated sender
|
||||
UUID; neither conversation text nor tool arguments contain a destination UUID
|
||||
or inventory folder.
|
||||
|
||||
The model must return exactly `name`, `description`, and `source`. Unknown
|
||||
fields are rejected. All three values are bounded, and source is treated as
|
||||
untrusted data. Native `metacrate-lsl-tools` lexical and structural parsing runs
|
||||
before inventory mutation, followed by checks that reject capability URLs,
|
||||
secret-like content, and public-workflow operations such as teleport, rez,
|
||||
attach, money, estate, eject, and object-return calls. Validation establishes a
|
||||
bounded syntax and policy gate, not simulator runtime safety.
|
||||
|
||||
Accepted source is uploaded as an LSL inventory item with copy, modify, and
|
||||
transfer permissions in `MetaCrate Generated Scripts`, then offered once to the
|
||||
original sender. This workflow never compiles, runs, attaches, rezzes, or
|
||||
injects the script into an object. The generated-scripts folder doubles as the
|
||||
recovery queue: a failed or ambiguous offer leaves the original item there and
|
||||
the transfer is not blindly retried. Operators can inspect and reconcile that
|
||||
folder using the audit correlation ID.
|
||||
|
||||
Per-resident and global windows limit accepted requests, and a semaphore bounds
|
||||
simultaneous creates/transfers. The enclosing tool loop supplies its bounded
|
||||
wall-clock deadline and cancellation token. Disconnect, timeout, shutdown, and
|
||||
duplicate delivery IDs are handled by the session and interaction owners before
|
||||
another inventory operation can be admitted. Default diagnostics report only
|
||||
bounded outcomes and byte counts; generated source and conversation content are
|
||||
not formatted into logs.
|
||||
|
||||
Focused verification:
|
||||
|
||||
```console
|
||||
cargo test --locked -p metacrate-grid-agent --lib script_delivery_tests
|
||||
cargo test --locked -p metacrate-grid-agent --lib interaction_tests
|
||||
cargo test --locked -p metacrate-grid-agent --test llm_transport
|
||||
cargo test --locked -p metacrate-lsl-tools
|
||||
```
|
||||
@@ -67,7 +67,7 @@ cargo package --locked --no-verify \
|
||||
-p libremetaverse-types -p libremetaverse-structured-data \
|
||||
-p libremetaverse-imaging -p libremetaverse-imaging-skia \
|
||||
-p libremetaverse-openjpeg -p libremetaverse-opus \
|
||||
-p libremetaverse-prim-mesher -p libremetaverse-lsl-tools \
|
||||
-p libremetaverse-prim-mesher -p metacrate-lsl-tools \
|
||||
-p libremetaverse -p libremetaverse-rendering-simple \
|
||||
-p libremetaverse-rendering-mesh-foundry -p libremetaverse-rlv \
|
||||
-p libremetaverse-utilities -p libremetaverse-voice-vivox \
|
||||
|
||||
@@ -23,7 +23,7 @@ they use those APIs directly.
|
||||
| `libremetaverse-prim-mesher` | Legacy prim and sculpt geometry | Pure Rust |
|
||||
| `libremetaverse-rendering-simple` | Deterministic reference geometry | Pure Rust |
|
||||
| `libremetaverse-rendering-mesh-foundry` | Prim, terrain, sculpt, and mesh-asset rendering | Pure Rust |
|
||||
| `libremetaverse-lsl-tools` | LSL lexing, parsing, diagnostics, and generation | Pure Rust |
|
||||
| `metacrate-lsl-tools` | LSL lexing, parsing, diagnostics, and generation | Pure Rust |
|
||||
| `libremetaverse-rlv` | RLV commands, restrictions, locks, camera, and inventory policy | Pure Rust |
|
||||
| `libremetaverse-utilities` | Compatible utility helpers | Pure Rust |
|
||||
| `libremetaverse-voice-vivox` | Vivox XML control protocol | External Vivox service is explicit and never spawned |
|
||||
|
||||
Reference in New Issue
Block a user