Closed suchiksagar closed 3 months ago
Hi, thanks for opening this issue. We do have this on our roadmap, but don't have a timeline set.
Cheers -Phil
This would be an excellent enhancement. I have been exploring this feature to establish basic constraints on policies using tools such as conftest, aiming to prevent users from creating policies that permit everything, for example:
permit(
principal,
action,
resource
)
Is there anything I can do to assist in implementing this feature?
This would be an excellent enhancement. I have been exploring this feature to establish basic constraints on policies using tools such as conftest, aiming to prevent users from creating policies that permit everything, for example:
permit( principal, action, resource )
Is there anything I can do to assist in implementing this feature?
@caiorcferreira - I had a similar thought, perhaps can collaborate or atleast give some usecases.. I'll try to upload my repo soon to see if it helps. @philhassey - You mind sharing the roadmap please? Been comparing policy libraries and this will help. Thanks!
The approximate roadmap is:
If you have ideas as to a Go idiomatic shape for the Go version of the AST (for programmatic building), please share those ideas, as that'll help us figuring what shape we want to use.
I don't have an approximate timeline yet.
The approximate roadmap is:
- Add in JSON support
- Add in JSON Schema support
- Add in partial evaluation
- Add in human readable Schema support
If you have ideas as to a Go idiomatic shape for the Go version of the AST (for programmatic building), please share those ideas, as that'll help us figuring what shape we want to use.
I don't have an approximate timeline yet.
Hi @philhassey,
Regarding 1, I raised a PR to add the feature of 'Convert a JSON-Policy to a cedar Text-Policy' ==> https://github.com/cedar-policy/cedar-go/pull/15 I'll add @philhassey & @caiorcferreira as reviewers, anybody else you suggest?
Thanks!
We are considering using Cedar, and this seems like critical functionality to enable its usage.
Looking forward to this feature. Hopefully, it lands soon.
We may skip over the current JSON representation and go right to the next version that is being rolled out:
As of v0.2.0 we have JSON marshaling and unmarshaling.
How can I convert the policy to a JSON representation and vice-versa. I'm looking to dynamically author a policy and came across this documentation but I couldn't achieve this through cedar-go. Can someone help me please?
See this snippet from cedar docs:
Example A “standard” Cedar policy looks like the following:
When you retrieve the JSON representation of this policy, it looks like the following:
They talk about two functions to convert a policy to/from json, which I couldn't figure in Go implementation