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

Move Create/Change Passphrase to middleware #1524

Merged
merged 2 commits into from Jul 12, 2018

Conversation

william-gr
Copy link
Member

No description provided.

Used to add/change/remove passphrase.

Ticket:	#37622
@ghost ghost assigned william-gr Jul 11, 2018
@ghost ghost added the review label Jul 11, 2018
Set a passphrase in a geli
If passphrase is None then remove the passphrase
"""
if passphrase:

Choose a reason for hiding this comment

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

If we care about None, perhaps this check should be a bit more specific with if passphrase is None

Copy link
Member Author

Choose a reason for hiding this comment

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

We dont, empty string is to be treated as none.

self.geli_delkey(dev, GELI_RECOVERY_SLOT, force=True)
self.geli_setkey(dev, pool['encryptkey_path'], GELI_KEY_SLOT, passphrase)
finally:
if passphrase:

Choose a reason for hiding this comment

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

Here as well

@william-gr william-gr merged commit 47b9326 into freenas/11.3-devel Jul 12, 2018
@ghost ghost removed the review label Jul 12, 2018
@william-gr william-gr deleted the issues/37622 branch July 12, 2018 12:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants