endojs / endo

Endo is a distributed secure JavaScript sandbox, based on SES
Apache License 2.0
768 stars 68 forks source link

feat(daemon): Store passable values #2226

Closed kriskowal closed 2 months ago

kriskowal commented 2 months ago

This change adds a E(host).storeValue(value, name) API allowing us to store passable data, provided it consists of copy-data and references with known formulas.

kriskowal commented 2 months ago

This looks good (@endo/marshal is cool!), but I'm hesitant to approve because I'm anxious about introducing a formula type named "value", given our prolific use of that word in the sense of "incarnated formula". It might be worth the trouble because it is a good word choice for the use case, but have we exhausted alternatives, e.g. "data"?

I think this is worth some conversation. Data would be appropriate if these formulas couldn’t capture formula remoteables, e.g., just passStyle cap-data.

kriskowal commented 2 months ago

This looks good (@endo/marshal is cool!), but I'm hesitant to approve because I'm anxious about introducing a formula type named "value", given our prolific use of that word in the sense of "incarnated formula". It might be worth the trouble because it is a good word choice for the use case, but have we exhausted alternatives, e.g. "data"?

I think this is worth some conversation. Data would be appropriate if these formulas couldn’t capture formula remoteables, e.g., just passStyle cap-data.

We settled on “marshal” for the formula type out-of-band.