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

"-info" option does not work with "-config" option #157

Closed
mhogomchungu opened this issue Nov 14, 2017 · 4 comments
Closed

"-info" option does not work with "-config" option #157

mhogomchungu opened this issue Nov 14, 2017 · 4 comments

Comments

@mhogomchungu
Copy link

mhogomchungu commented Nov 14, 2017

What i want is to get properties of a volume that uses an external config file.

Command like below does not work.

/usr/bin/gocryptfs -info -config "/home/ink/gocryptfs.conf"
@mhogomchungu mhogomchungu changed the title "--info" option does not work with "--config" option "-info" option does not work with "-config" option Nov 14, 2017
@rfjakob rfjakob added the bug label Nov 15, 2017
@rfjakob
Copy link
Owner

rfjakob commented Nov 15, 2017

Hmm, cannot reproduce

$ gocryptfs -info -config external.config a 
Using config file at custom location /tmp/tmp.6BWwz3pvnN/external.config
Creator:      gocryptfs v1.4.2-3-ge36a0eb-dirty
FeatureFlags: GCMIV128 HKDF DirIV EMENames LongNames Raw64
EncryptedKey: 64B
ScryptObject: Salt=32B N=65536 R=8 P=1 KeyLen=32

@rfjakob rfjakob removed the bug label Nov 15, 2017
@mhogomchungu
Copy link
Author

[ink@mtz ~]$ gocryptfs -info -config gocryptfs.conf /root/
Using config file at custom location /home/ink/gocryptfs.conf
Creator:      gocryptfs v1.4.1
FeatureFlags: GCMIV128 HKDF DirIV EMENames LongNames Raw64
EncryptedKey: 64B
ScryptObject: Salt=32B N=65536 R=8 P=1 KeyLen=32
[ink@mtz ~]$ 

So,the command seems to require a folder as the last option without carrying about the contents of the folder since it works even with folders it can not access.

It did not occur to me to try the command with cipher folder because i correctly suspected there is nothing worth reading from it.

I think the command should not require the cipher folder path to work correctly.

rfjakob added a commit that referenced this issue Nov 15, 2017
Getting just the help text in response to

	gocryptfs -info -config external.config

is confusing: #157
@rfjakob
Copy link
Owner

rfjakob commented Nov 15, 2017

It's true that CIPHERDIR is not needed in this case, but it's documented in the help text like that, and it makes command-line parsing so much easier.

However, you used to just get the help text in response to

$ gocryptfs -info -config foo.conf

which was pretty unclear in explaining what is wrong. So now you get this:

$ gocryptfs -info -config foo.conf
CIPHERDIR argument is missing

I think this should keep user frustation to a minimum.

@mhogomchungu
Copy link
Author

Fixed the bug on my end with this[1] commit.

[1] mhogomchungu/sirikali@d6306a5

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

No branches or pull requests

2 participants