Bug 432955

Summary: ecryptfs_cipher option doesn't work for des3_ede
Product: Red Hat Enterprise Linux 5 Reporter: Jan Tluka <jtluka>
Component: ecryptfs-utilsAssignee: Karsten Hopp <karsten>
Status: CLOSED NOTABUG QA Contact:
Severity: low Docs Contact:
Priority: low    
Version: 5.2CC: mhalcrow
Target Milestone: rc   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2008-02-18 21:09:00 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Jan Tluka 2008-02-15 12:58:40 UTC
Description of problem:
When I try to mount ecryptfs filesystem with option 'ecryptfs_cipher=des3_ede' i
get an error and filesystem is not mounted.

Version-Release number of selected component (if applicable):
ecryptfs-utils-38-1.el5
linux kernel 2.6.18-79.el5


How reproducible:
100% running mount.ecryptfs with appropriate options


Steps to Reproduce:
1.
as root run following command:
mount.ecryptfs .secret/ .secret/ -o
key=passphrase:passwd=secret,ecryptfs_key_bytes=16,ecryptfs_cipher=des3_ede,verbosity=0


Actual results:
- mount.ecryptfs output:
Attempting to mount with the following options:
  ecryptfs_cipher=des3_ede
  ecryptfs_sig=7a1719eb53966dd1
Error mounting eCryptfs; rc = [-22]; strerr = [Invalid argument]. Check your
system logs; visit <http://ecryptfs.sourceforge.net/ecryptfs-faq.html>.

- dmesg output:
ecryptfs_parse_options: eCryptfs: unrecognized option 'verbosity=0'
Error attempting to set key of size [16] for cipher [des3_ede]; rc = [-22]
Error attempting to initialize key TFM cipher with name = [des3_ede]; rc = [-22]
Error attempting to initialize cipher with name = [des3_ede] and key size =
[16]; rc = [-22]
Error parsing options; rc = [-22]


Expected results:
Filesystem is mounted with no error.


Additional info:
Mount will succeed if I use 'cipher=des3_ede' instead of 'ecryptfs_cipher=des3_ede'.
I don't see this error when mounting with other ciphers.

Comment 1 Michael Halcrow 2008-02-18 21:09:00 UTC
ecryptfs_key_bytes=16 is not valid with des3_ede; des3_ede requires a 24 byte
key. The cipher failing to initialize with a key size of 16 is expected behavior.

Mike