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

feat: Added change passphrase dialog #1659

Draft
wants to merge 14 commits into
base: master
Choose a base branch
from

Conversation

jetchirag
Copy link
Contributor

@jetchirag jetchirag commented Mar 17, 2023

Description

A way to change the password I provided when the repo were created.

Related Issue

Fixes #303

How Has This Been Tested?

Manually tested with local repos. Pending more extensive testing.

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Checklist:

  • I have read the CONTRIBUTING guide.
  • My code follows the code style of this project.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have added tests to cover my changes.
  • All new and existing tests passed.

I provide my contribution under the terms of the license of this repository and I affirm the Developer Certificate of Origin.

Signed-off-by: Chirag Aggarwal <[email protected]>
@real-yfprojects
Copy link
Collaborator

I was thinking that we could use a common widget (a self-implemented one) for all password entries in vorta. Can you implement such thing?

@jetchirag
Copy link
Contributor Author

@real-yfprojects I am assuming password marking, visibility toggle and validation etc in the widget. Should I subclass QLineEdit?

@real-yfprojects
Copy link
Collaborator

No, I wouldn't do that you can subclass QWidget and add a layout with the widgets.

@jetchirag
Copy link
Contributor Author

Okay I'll open a new PR for widget after closing this.

Signed-off-by: Chirag Aggarwal <[email protected]>
@jetchirag
Copy link
Contributor Author

I've added 2 new tests but currently the test repo doesn't have encryption so it would run mock command on non-encrypted repo. I can add another repo but it doesn't seem necessary since in GUI button is disabled.

@jetchirag jetchirag marked this pull request as ready for review March 18, 2023 11:52
@jetchirag jetchirag mentioned this pull request Mar 18, 2023
9 tasks
src/vorta/assets/icons/lock.svg Outdated Show resolved Hide resolved
src/vorta/borg/_compatibility.py Show resolved Hide resolved
src/vorta/borg/change_passphrase.py Outdated Show resolved Hide resolved
src/vorta/views/change_borg_passphrase_dialog.py Outdated Show resolved Hide resolved
src/vorta/views/repo_tab.py Outdated Show resolved Hide resolved
src/vorta/views/repo_tab.py Show resolved Hide resolved
src/vorta/borg/change_passphrase.py Outdated Show resolved Hide resolved
src/vorta/views/repo_tab.py Outdated Show resolved Hide resolved
@stale
Copy link

stale bot commented Jul 19, 2023

Is this still relevant? If so, what is blocking it? Is there anything you can do to help move it forward?

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.

@real-yfprojects
Copy link
Collaborator

This can now be updated to use the new widgets you implemented @jetchirag

Signed-off-by: Chirag Aggarwal <[email protected]>
@jetchirag jetchirag mentioned this pull request Aug 3, 2023
9 tasks
Signed-off-by: Chirag Aggarwal <[email protected]>
Copy link
Collaborator

@real-yfprojects real-yfprojects left a comment

Choose a reason for hiding this comment

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

Almost ready to be merged!
Currently the dialog has Vorta as a window title. This should be something like Change Encryption Passphrase. I think we no longer need the 'title' label then.

Signed-off-by: Chirag Aggarwal <[email protected]>
@jetchirag
Copy link
Contributor Author

Done ✅

@jetchirag
Copy link
Contributor Author

Just noticed merge conflict. Will solve them.

Comment on lines +68 to +73
# def validate(self):
# """Check encryption type"""
# if self.profile.repo.encryption.startswith('repokey'):
# return True
# self.errorText.setText(translate('utils', 'Encryption type must be repokey.'))
# return False
Copy link
Collaborator

Choose a reason for hiding this comment

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

Dead code, Is this still needed?

@m3nu m3nu marked this pull request as draft January 9, 2024 08:08
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.

Change password
2 participants