Open khieta opened 3 weeks ago
+1 I think most of the functions that are today Wasm-only should be pulled into ffi
in general, so that other bindings can make use of the same functions
Also possibly in scope: APIs to convert between different formats (e.g. JSON vs. Cedar-syntax schemas)
Note from #882: the wasm version of these functions return strings, but with this change we should update them to use the DetailedError
struct.
Category
User level API features/changes
Describe the feature you'd like to request
The FFI currently focuses on authorization and validation. It also supports parsing indirectly via the
enabled
flag inValidationSettings
(enabled=false
means just parse the schema and policy set), but it would be convenient to support parsing more directly. The WASM and Java bindings both need this functionality, and built their own support. I suspect we just want to pull what WASM is doing directly into theffi
code -- see cedar-wasm/policies_and_templates.rs and cedar-wasm/schema_and_entities_and_context.rs.Making a separate issue from #757 because if I keep increasing the scope of that issue it will never get done 😄
Describe alternatives you've considered
No response
Additional context
No response
Is this something that you'd be interested in working on?