{"id":18725627,"url":"https://github.com/dbus2/zbus_polkit","last_synced_at":"2025-10-07T02:28:06.329Z","repository":{"id":184731288,"uuid":"672373448","full_name":"dbus2/zbus_polkit","owner":"dbus2","description":"PolicyKit zbus proxy","archived":false,"fork":false,"pushed_at":"2025-09-21T08:43:11.000Z","size":247,"stargazers_count":9,"open_issues_count":0,"forks_count":3,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-09-27T15:43:59.444Z","etag":null,"topics":["policykit","security","unix","zbus"],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/dbus2.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,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2023-07-29T21:18:45.000Z","updated_at":"2025-09-21T08:43:04.000Z","dependencies_parsed_at":"2024-05-16T07:29:06.169Z","dependency_job_id":"8a38e306-82f4-4680-b682-ba1e140dfcce","html_url":"https://github.com/dbus2/zbus_polkit","commit_stats":null,"previous_names":["dbus2/zbus_polkit"],"tags_count":16,"template":false,"template_full_name":null,"purl":"pkg:github/dbus2/zbus_polkit","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dbus2%2Fzbus_polkit","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dbus2%2Fzbus_polkit/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dbus2%2Fzbus_polkit/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dbus2%2Fzbus_polkit/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dbus2","download_url":"https://codeload.github.com/dbus2/zbus_polkit/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dbus2%2Fzbus_polkit/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":278708243,"owners_count":26031979,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-07T02:00:06.786Z","response_time":59,"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":["policykit","security","unix","zbus"],"created_at":"2024-11-07T14:11:07.490Z","updated_at":"2025-10-07T02:28:06.281Z","avatar_url":"https://github.com/dbus2.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# zbus_polkit\n\n[![CI Pipeline Status](https://github.com/dbus2/zbus/actions/workflows/rust.yml/badge.svg)](https://github.com/dbus2/zbus/actions/workflows/rust.yml)\n[![Documentation](https://docs.rs/zbus_polkit/badge.svg)](https://docs.rs/zbus_polkit/)\n[![crates.io](https://img.shields.io/crates/v/zbus_polkit)](https://crates.io/crates/zbus_polkit)\n\nA crate to interact with [PolicyKit], a toolkit for defining and handling authorizations. It is used\nfor allowing unprivileged processes to speak to privileged processes.\n\n**Status:** Stable.\n\n## Example code\n\n```rust,no_run\nuse zbus::Connection;\nuse zbus_polkit::policykit1::*;\n\n// Although we use `tokio` here, you can use any async runtime of choice.\n#[tokio::main(flavor = \"current_thread\")]\nasync fn main() -\u003e Result\u003c(), Box\u003cdyn std::error::Error\u003e\u003e {\n    let connection = Connection::system().await?;\n    let proxy = AuthorityProxy::new(\u0026connection).await?;\n    let subject = Subject::new_for_owner(std::process::id(), None, None)?;\n    let result = proxy.check_authorization(\n        \u0026subject,\n        \"org.zbus.BeAwesome\",\n        \u0026std::collections::HashMap::new(),\n        CheckAuthorizationFlags::AllowUserInteraction.into(),\n        \"\",\n    ).await?;\n\n    Ok(())\n}\n```\n\n[PolicyKit]: https://gitlab.freedesktop.org/polkit/polkit/\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdbus2%2Fzbus_polkit","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdbus2%2Fzbus_polkit","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdbus2%2Fzbus_polkit/lists"}