Skip to content

Go SDK and stack-encrypt: reading one child of a JSON node needs the whole subtree — open one child, bound to its parent #1677

Open

Description

@coderdan

Background

A JSON document stored as EQL v4's json_tree family keeps one entry per node. eql_v4.json_tree_children returns the entries of a node's children, and the Go SDK's JSONSelection.Open opens one entry for each document. The contract for every JSON operation is conformance/stack-encrypt/eql-json-contract.md.

Problem

There is no operation that opens one child and checks that it belongs to the parent the caller asked about. So a program reads and opens the parent's whole subtree to see one child. That transfers more data and shows the server a different set of tokens. Plan item: Open one child of a JSON node, bound to its parent. #1353, the Go JSON plan document, lists it as remaining.

Proposal

  1. Add an engine operation that opens one child entry and checks its parent link against the parent's token.
  2. Expose it in Go, and in the Rust JSON marker methods (stack-encrypt: element match and jsonpath match have no typed Rust API — only the binding layer, with no compile-time checks #1459).
  3. Add it to the eql-json-v1 conformance profile.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions