{"id":36537910,"url":"https://github.com/julisch94/rqlite-adapter","last_synced_at":"2026-01-15T02:22:26.781Z","repository":{"id":124224560,"uuid":"101405739","full_name":"julisch94/rqlite-adapter","owner":"julisch94","description":"RQLite adapter for Casbin https://github.com/casbin/casbin","archived":false,"fork":false,"pushed_at":"2017-10-05T10:04:44.000Z","size":10,"stargazers_count":161,"open_issues_count":0,"forks_count":1,"subscribers_count":5,"default_branch":"master","last_synced_at":"2023-11-07T18:43:29.448Z","etag":null,"topics":["casbin","rqlite","rqlite-adapter"],"latest_commit_sha":null,"homepage":null,"language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/julisch94.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2017-08-25T13:18:57.000Z","updated_at":"2023-03-06T16:28:33.000Z","dependencies_parsed_at":"2023-06-18T07:06:03.079Z","dependency_job_id":null,"html_url":"https://github.com/julisch94/rqlite-adapter","commit_stats":null,"previous_names":["edomosystems/rqlite-adapter"],"tags_count":0,"template":null,"template_full_name":null,"purl":"pkg:github/julisch94/rqlite-adapter","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/julisch94%2Frqlite-adapter","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/julisch94%2Frqlite-adapter/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/julisch94%2Frqlite-adapter/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/julisch94%2Frqlite-adapter/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/julisch94","download_url":"https://codeload.github.com/julisch94/rqlite-adapter/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/julisch94%2Frqlite-adapter/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28441273,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-15T00:55:22.719Z","status":"online","status_checked_at":"2026-01-15T02:00:08.019Z","response_time":62,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["casbin","rqlite","rqlite-adapter"],"created_at":"2026-01-12T05:13:28.718Z","updated_at":"2026-01-15T02:22:26.774Z","avatar_url":"https://github.com/julisch94.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"RQLite Adapter\n====\n\n[![GoDoc](https://godoc.org/github.com/edomosystems/rqlite-adapter?status.svg)](https://godoc.org/github.com/edomosystems/rqlite-adapter)\n\nThis adapter is the [RQLite](https://github.com/rqlite/rqlite) adapter for [Casbin](https://github.com/casbin/casbin). With this library, Casbin can load policies from RQLite databases or save policies to it which will then be distributed over the RQLite cluster.\n\n## Installation\n\n    go get github.com/edomosystems/rqlite-adapter\n\n\n## Simple Example\n\n```go\npackage main\n\nimport (\n  \"fmt\"\n  \"github.com/casbin/casbin\"\n  \"github.com/edomosystems/rqlite-adapter\"\n)\n\nfunc main() {\n  /* Specify the http api url your\n  * rqlite node is listening on */\n  adapter := rqliteadapter.NewAdapter(\"http://10.10.40.23:4001\")\n\n  enforcer := casbin.NewEnforcer(\"model.conf\", adapter, false)\n\n  enforcer.LoadPolicy()\n  enforcer.EnableAutoSave(true)\n\n  enforcer.AddRoleForUser(\"alice\", \"admin\")\n  enforcer.AddRoleForUser(\"bob\", \"guest\")\n\n  enforcer.AddPermissionForUser(\"admin\", \"file\", \"read\")\n  enforcer.AddPermissionForUser(\"admin\", \"file\", \"write\")\n  enforcer.AddPermissionForUser(\"guest\", \"file\", \"read\")\n\n  enforcer.Enforce(\"alice\", \"file\", \"read\")    // -\u003e True\n  enforcer.Enforce(\"alice\", \"file\", \"write\")   // -\u003e True\n  enforcer.Enforce(\"bob\", \"file\", \"read\")      // -\u003e True\n  enforcer.Enforce(\"bob\", \"file\", \"write\")     // -\u003e False\n\n  /* Simple role hirearchie */\n  enforcer.AddRoleForUser(\"chalie\", \"interim\")\n  enforcer.AddRoleForUser(\"interim\", \"guest\")  // interim inherits from guest\n\n  enforcer.Enforce(\"charlie\", \"file\", \"read\")  // -\u003e True\n  enforcer.Enforce(\"charlie\", \"file\", \"write\") // -\u003e False\n}\n```\n\n## Getting Help\n\n- [Casbin](https://github.com/casbin/casbin)\n\n## License\n\nThis project is under Apache 2.0 License. See the [LICENSE](LICENSE) file for the full license text.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjulisch94%2Frqlite-adapter","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjulisch94%2Frqlite-adapter","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjulisch94%2Frqlite-adapter/lists"}