Support more languages of Casbin like Go Casbin in the editor
@hsluoyz is already working on this.
Since Jul 3, 2024.
Assessment
This issue has not been assessed yet.
Description
We want to use the Casbin editor (this repo) to invoke different languages of Casbin libraries (like Go Casbin, jCasbin, Node-Casbin, PyCasbin, etc.)
How to do this?
Step-1: The editor code in the browser first calls the Casdoor HTTP API of the Casdoor official demo site: https://door.casdoor.com/ (see docs: https://casdoor.org/docs/permission/exposed-casbin-apis).
Step-2: The Casdoor backend (in Go) will call the Casbin CLI (like casbin-go-cli, casbin-java-cli, etc.) via shell/CMD locally:
Step-3: The Casbin CLI will call the Casbin library of its language. Like casbin-go-cli will call Go Casbin via lib. casbin-java-cli will call jCasbin via lib, etc.
The Step-1 and Step-2 are already completed. The remaining part is Step-3: we need to make a new casbin-xxx-cli for each language, to integrate that language of Casbin into the web editor.
When you implement a new casbin-xxx-cli, you can refer to existing code like casbin-go-cli, casbin-java-cli, etc. For example, you learn how casbin-java-cli calls into jCasbin, you will know how casbin-rust-cli should call into Casbin-RS.
The code quality of the new casbin-xxx-cli will be guaranteed by its own test cases and also the result of this Casbin editor (both web UI and the editor's test cases).
See what we have got now: https://editor.casbin.org/
Now we already have the following remote Casbin engines:
- Go (https://github.com/casbin/casbin-go-cli)
- Java (https://github.com/jcasbin/casbin-java-cli)
- Python
- Rust
- C#
- PHP
- C++
- Dominant language
- TypeScript
- Stars
- 119
- Forks
- 35
- PR merge metrics
- No merged PRs in 30d
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from apache/casbin-editor
-
enhancement
Difficulty 5/5 Over a week Newbie friendliness 15/100
apache/casbin-editor#369 ·
-
bug
apache/casbin-editor#254 · 1 reaction · 1 assignee ·
-
bug
apache/casbin-editor#162 · 1 comment · 1 assignee ·
-
Support a way to see who has shared the policy, and better with a "Policy" showcase or PolicyHub Openenhancement
apache/casbin-editor#139 · 1 comment · 1 assignee ·
-
enhancement good first issue help wanted
apache/casbin-editor#66 · 2 comments · 1 assignee ·
All issues in apache/casbin-editor
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
Eynzof/Hermes-CN-Desktop#610 ·
-
bug clawsweeper:linked-pr-open clawsweeper:needs-live-repro clawsweeper:no-new-fix-pr impact:message-loss issue-rating: 🐚 platinum hermit P2 regression
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
-
enhancement
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
-
calcite-components needs triage refactor
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
Esri/calcite-design-system#15203 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 90/100
danielmiessler/LifeOS#2218 ·