Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

server: Load and dispatch login/default collection/keyring #142

Merged
merged 2 commits into from
Oct 24, 2024

Conversation

warusadura
Copy link
Collaborator

@warusadura warusadura commented Oct 21, 2024

Load temporary keyring when dispatching the session collection. Since the session collection is never stored to the disk, loading a temporary keyring is enough.

  • And add Collection::new()
  • Also store a Keyring in Collection struct.

This change loads and dispatches the login/default collection/keyring into the object tree. This change also adds,

  • --login command line option to oo7-daemon.
  • -l, --login option will read a password from stdin, and use it to unlock the login keyring.
  • Note: currently -l option will only load the login keyring and not perform anything related to unlocking the keyring.

server/src/main.rs Outdated Show resolved Hide resolved
server/src/main.rs Outdated Show resolved Hide resolved
server/src/main.rs Outdated Show resolved Hide resolved
server/Cargo.toml Outdated Show resolved Hide resolved
@warusadura
Copy link
Collaborator Author

Thanks for the prompt review and I'm sorry for the late response from my side :)

@warusadura warusadura force-pushed the login branch 2 times, most recently from 09d26c7 to 7ff8bfe Compare October 22, 2024 09:31
server/src/service.rs Outdated Show resolved Hide resolved
server/src/service.rs Outdated Show resolved Hide resolved
server/src/service.rs Outdated Show resolved Hide resolved
server/src/service.rs Outdated Show resolved Hide resolved
server/src/service.rs Outdated Show resolved Hide resolved
server/src/service.rs Outdated Show resolved Hide resolved
server/src/service.rs Outdated Show resolved Hide resolved
server/src/service.rs Outdated Show resolved Hide resolved
server/src/main.rs Outdated Show resolved Hide resolved
server/src/main.rs Outdated Show resolved Hide resolved
@warusadura warusadura marked this pull request as draft October 23, 2024 04:28
@warusadura warusadura force-pushed the login branch 4 times, most recently from 0049157 to ae3d5a6 Compare October 24, 2024 07:34
@warusadura warusadura marked this pull request as ready for review October 24, 2024 07:40
Copy link
Owner

@bilelmoussaoui bilelmoussaoui left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

almost there

client/src/portal/secret.rs Outdated Show resolved Hide resolved
server/src/main.rs Outdated Show resolved Hide resolved
server/src/service.rs Outdated Show resolved Hide resolved
server/src/service.rs Outdated Show resolved Hide resolved
server/src/service.rs Outdated Show resolved Hide resolved
server/src/service.rs Outdated Show resolved Hide resolved
@bilelmoussaoui
Copy link
Owner

Also you have access to this repo, use a branch in it to make it easier for me to push quick fixes :)

That generates and returns a random Secret.

Signed-off-by: Dhanuka Warusadura <dhanuka@gnome.org>
@warusadura
Copy link
Collaborator Author

Also you have access to this repo, use a branch in it to make it easier for me to push quick fixes :)

Yeah, thanks! But I kinda like this way, I'm learning a lot of Rust from you :)

@bilelmoussaoui
Copy link
Owner

Looks good, just squash the last 3 server related commits as they are not clean by themselves and there is little benefit in cleaning them up. Maybe re-change the commit message to "server: Create a keyring when dispatching default/login collections"

Also add the following changes:
Add Error.
Load a temporary keyring when dispatching the session collection.
Add --login command line option.

Signed-off-by: Dhanuka Warusadura <dhanuka@gnome.org>
@warusadura
Copy link
Collaborator Author

Done.

@bilelmoussaoui bilelmoussaoui merged commit 350927b into bilelmoussaoui:main Oct 24, 2024
7 checks passed
@bilelmoussaoui
Copy link
Owner

thanks

@warusadura warusadura deleted the login branch October 24, 2024 10:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants