Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 367937
Collapse All | Expand All

(-)a/dm-crypt-start.sh (-2 / +2 lines)
Lines 150-162 dm_crypt_execute_dmcrypt() { Link Here
150
		: ${gpg_options:='-q -d'}
150
		: ${gpg_options:='-q -d'}
151
		# gpg available ?
151
		# gpg available ?
152
		if type -p gpg >/dev/null ; then
152
		if type -p gpg >/dev/null ; then
153
			for (( i = 0 ; i < 3 ; i++ ))
153
			i=0; while [ $i -lt 3 ]
154
			do
154
			do
155
				# paranoid, don't store key in a variable, pipe it so it stays very little in ram unprotected.
155
				# paranoid, don't store key in a variable, pipe it so it stays very little in ram unprotected.
156
				# save stdin stdout stderr "values"
156
				# save stdin stdout stderr "values"
157
				gpg ${gpg_options} ${key} 2>/dev/null | cryptsetup ${options} ${arg1} ${arg2} ${arg3}
157
				gpg ${gpg_options} ${key} 2>/dev/null | cryptsetup ${options} ${arg1} ${arg2} ${arg3}
158
				ret="$?"
158
				ret="$?"
159
				[ "$ret" -eq 0 ] && break
159
				[ "$ret" -eq 0 ] && break
160
				i=$(($i+1))
160
			done
161
			done
161
			eend "${ret}" "failure running cryptsetup"
162
			eend "${ret}" "failure running cryptsetup"
162
		else
163
		else
163
- 

Return to bug 367937