zed/crates
Niklas Wimmer ff65008316
linux: add credentials impl via oo7 (#8035)
This change implements gpui's credentials API for the linux platform,
using the [`oo7`](https://lib.rs/crates/oo7) library.

We had a short discussion on Discord about where to store credentials
and landed on the two dbus APIs
[`org.freedesktop.Secrets`](https://specifications.freedesktop.org/secret-service/latest/index.html)
and
[`org.freedesktop.portal.Secrets`](https://flatpak.github.io/xdg-desktop-portal/docs/doc-org.freedesktop.portal.Secret.html).
The first one provides access to a more or less general purpose
keystore, the second provides a way of obtaining a unique masterkey
which in turn can be used for encrypting stuff and storing it to disk
(especially interesting for sandboxed apps, think flatpak/snap).

I decided to give the implementation a try with `oo7`, which uses the
portal if the app is sandboxed and the secret service otherwise. If we
do not want to use that library, we would probably have to more or less
copy its functionality anyways. I also heard rumors of eventually
changing the credentials API and I think this implementation serves as a
starting point to discuss the need for this?

With a working credentials implementation the sign in button now works
(it panicked before).

Todos:
- [x] implement keystore unlocking
- [x] try the change with oo7's tracing enabled?
- [x] test the password deletion

Release Notes:

- N/A

---------

Signed-off-by: Niklas Wimmer <mail@nwimmer.me>
Co-authored-by: Mikayla Maki <mikayla@zed.dev>
2024-03-03 13:54:06 -08:00
..
activity_indicator Add initial support for defining language server adapters in WebAssembly-based extensions (#8645) 2024-03-01 16:00:55 -08:00
ai Enable clippy::unnecessary_unwrap (#8756) 2024-03-02 23:10:56 -05:00
assets chore: Move workspace dependencies to workspace.dependencies (#7454) 2024-02-06 20:41:36 +01:00
assistant Enable clippy::useless_conversion (#8767) 2024-03-03 10:22:55 -05:00
audio Clean up many small dependencies (part 3) (#8425) 2024-02-26 11:08:57 +02:00
auto_update Enable clippy::map_flatten (#8733) 2024-03-02 18:24:22 -05:00
breadcrumbs Clean up many small dependencies (part 3) (#8425) 2024-02-26 11:08:57 +02:00
call Enable clippy::clone_on_copy (#8728) 2024-03-02 17:37:48 -05:00
channel Enable clippy::needless_lifetimes (#8777) 2024-03-03 11:52:58 -05:00
cli Add cargo xtask clippy (#8722) 2024-03-02 14:46:02 -05:00
client Fix Clippy warnings in client crate (#8719) 2024-03-02 12:33:02 -05:00
clock Add SystemClock (#8239) 2024-02-22 22:28:08 -05:00
collab Enable clippy::needless_lifetimes (#8777) 2024-03-03 11:52:58 -05:00
collab_ui Enable clippy::useless_conversion (#8767) 2024-03-03 10:22:55 -05:00
collections gpui: Add Global marker trait (#7095) 2024-01-30 14:08:20 -05:00
color docs: Fix "it's" typos that should be "its" (#8690) 2024-03-01 20:32:27 -05:00
command_palette Improve matches on command palette (#8515) 2024-02-29 18:31:13 +01:00
command_palette_hooks Add command_palette_hooks crate (#8398) 2024-02-25 13:21:20 -05:00
copilot Remove unneeded 'static lifetimes on &strs in constants (#8698) 2024-03-02 00:40:49 -05:00
copilot_ui Enable clippy::useless_conversion (#8767) 2024-03-03 10:22:55 -05:00
db Remove unneeded 'static lifetimes on &strs in constants (#8698) 2024-03-02 00:40:49 -05:00
diagnostics Enable clippy::useless_conversion (#8767) 2024-03-03 10:22:55 -05:00
editor Enable clippy::default_constructed_unit_structs (#8778) 2024-03-03 12:07:53 -05:00
extension Enable clippy::useless_conversion (#8767) 2024-03-03 10:22:55 -05:00
extension_api Add initial support for defining language server adapters in WebAssembly-based extensions (#8645) 2024-03-01 16:00:55 -08:00
extensions_ui Enable clippy::useless_conversion (#8767) 2024-03-03 10:22:55 -05:00
feature_flags Enable clippy::search_is_some (#8748) 2024-03-02 21:46:30 -05:00
feedback Upgrade bitflags to v2.4.2 (#8693) 2024-03-01 21:07:39 -05:00
file_finder Enable clippy::single_char_pattern (#8727) 2024-03-02 17:04:59 -05:00
fs Fix Clippy warnings in fs (#8696) 2024-03-01 23:22:22 -05:00
fsevent Upgrade bitflags to v2.4.2 (#8693) 2024-03-01 21:07:39 -05:00
fuzzy Fix Clippy warnings in fuzzy crate (#8701) 2024-03-02 01:02:34 -05:00
git Enable clippy::needless_lifetimes (#8777) 2024-03-03 11:52:58 -05:00
go_to_line Clean up many small dependencies (part 3) (#8425) 2024-02-26 11:08:57 +02:00
gpui linux: add credentials impl via oo7 (#8035) 2024-03-03 13:54:06 -08:00
gpui_macros gpui: Don't impl IntoElement on () (#8555) 2024-02-28 15:19:05 -07:00
install_cli Remove ! from todo!() in comments (#8643) 2024-02-29 18:19:05 -07:00
journal Cleanup dependencies (part 4) (#8468) 2024-02-27 20:41:49 +02:00
language Enable clippy::needless_lifetimes (#8777) 2024-03-03 11:52:58 -05:00
language_selector Clean up deps for file_finder, language_selector, task, rpc, storybook (#8353) 2024-02-25 10:10:07 +02:00
language_tools Enable clippy::useless_conversion (#8724) 2024-03-02 16:31:47 -05:00
languages Enable clippy::identity_op (#8773) 2024-03-03 11:05:08 -05:00
live_kit_client Remove ! from todo!() in comments (#8643) 2024-02-29 18:19:05 -07:00
live_kit_server Clean up many small dependencies (part 3) (#8425) 2024-02-26 11:08:57 +02:00
lsp Enable clippy::too_many_arguments (#8734) 2024-03-02 18:42:05 -05:00
markdown_preview Enable clippy::useless_conversion (#8767) 2024-03-03 10:22:55 -05:00
media Clean up many small dependencies (part 3) (#8425) 2024-02-26 11:08:57 +02:00
menu Added menu::UseSelectedQuery command that populates task modal query with the selected task name (#8572) 2024-02-29 02:20:43 +02:00
multi_buffer Enable clippy::needless_lifetimes (#8777) 2024-03-03 11:52:58 -05:00
node_runtime Cleanup dependencies (part 4) (#8468) 2024-02-27 20:41:49 +02:00
notifications Cleanup dependencies (part 4) (#8468) 2024-02-27 20:41:49 +02:00
outline Enable clippy::useless_conversion (#8767) 2024-03-03 10:22:55 -05:00
picker Added menu::UseSelectedQuery command that populates task modal query with the selected task name (#8572) 2024-02-29 02:20:43 +02:00
prettier Enable clippy::manual_find (#8737) 2024-03-02 20:03:49 -05:00
project Enable clippy::needless_lifetimes (#8777) 2024-03-03 11:52:58 -05:00
project_core Enable clippy::extra_unused_lifetimes (#8754) 2024-03-02 22:43:00 -05:00
project_panel Enable clippy::needless_question_mark (#8759) 2024-03-02 23:40:39 -05:00
project_symbols Add initial support for defining language server adapters in WebAssembly-based extensions (#8645) 2024-03-01 16:00:55 -08:00
quick_action_bar Hide Inline Assist button if assistant.button is disabled (#7932) 2024-02-18 08:14:08 +02:00
recent_projects Enable clippy::useless_conversion (#8767) 2024-03-03 10:22:55 -05:00
refineable Clean up many small dependencies (part 3) (#8425) 2024-02-26 11:08:57 +02:00
release_channel Document release_channel crate (#8695) 2024-03-01 22:05:46 -05:00
rich_text Enable clippy::too_many_arguments (#8734) 2024-03-02 18:42:05 -05:00
rope Add documentation to many core editor types (#7919) 2024-02-17 09:03:05 -07:00
rpc Enable clippy::redundant_locals (#8750) 2024-03-02 21:57:40 -05:00
search Enable clippy::useless_conversion (#8767) 2024-03-03 10:22:55 -05:00
semantic_index Enable clippy::needless_question_mark (#8759) 2024-03-02 23:40:39 -05:00
settings Fix Clippy warnings in settings crate (#8700) 2024-03-02 00:29:29 -05:00
snippet Clean up Cargo.toml files (#7044) 2024-01-29 23:47:20 -05:00
sqlez Use collections::{HashMap, HashSet} instead of its std:: counterpart (#7502) 2024-02-07 19:06:03 +02:00
sqlez_macros Clean up many small dependencies (part 3) (#8425) 2024-02-26 11:08:57 +02:00
story chore: Move workspace dependencies to workspace.dependencies (#7454) 2024-02-06 20:41:36 +01:00
storybook Enable clippy::clone_on_copy (#8728) 2024-03-02 17:37:48 -05:00
sum_tree Enable clippy::search_is_some (#8748) 2024-03-02 21:46:30 -05:00
task docs: Fix "it's" typos that should be "its" (#8690) 2024-03-01 20:32:27 -05:00
tasks_ui Prompt to save files on recent project selection (#8673) 2024-03-01 18:48:06 +02:00
telemetry_events Add telemetry events backend for collab (#8220) 2024-02-23 11:13:28 -05:00
terminal Move windows up to workspace dependency (#8786) 2024-03-03 11:58:31 -08:00
terminal_view Enable clippy::nonminimal_bool (#8755) 2024-03-02 22:57:37 -05:00
text Clean up many small dependencies (part 3) (#8425) 2024-02-26 11:08:57 +02:00
theme Fix Clippy warnings in theme crate (#8715) 2024-03-02 11:11:08 -05:00
theme_importer Add cargo xtask clippy (#8722) 2024-03-02 14:46:02 -05:00
theme_selector Clean up many small dependencies (part 3) (#8425) 2024-02-26 11:08:57 +02:00
time_format Replace lazy_static! with OnceLock in time_format crate (#8648) 2024-02-29 23:58:45 -05:00
ui Enable clippy::unnecessary_unwrap (#8756) 2024-03-02 23:10:56 -05:00
util Fix Clippy warnings in util crate (#8721) 2024-03-02 13:06:35 -05:00
vcs_menu Use Pointer cursor style on Recent Projects, VCS Menu. (#8595) 2024-02-29 12:27:56 +01:00
vim Enable clippy::useless_conversion (#8767) 2024-03-03 10:22:55 -05:00
welcome Add OpenExcerptsSplit (#8574) 2024-02-28 19:23:36 -07:00
workspace Enable clippy::vec_init_then_push (#8771) 2024-03-03 10:53:23 -05:00
zed Windows gpui platform (#8490) 2024-03-03 10:53:22 -08:00
zed_actions chore: Move workspace dependencies to workspace.dependencies (#7454) 2024-02-06 20:41:36 +01:00