Skip to Content.
Sympa Menu

sm-commit - [SM-Commit] GIT changes to master grimoire by David Brown (d582150dac32a18059e33e2b16fbcffcec01fb8b)

sm-commit AT lists.ibiblio.org

Subject: Source Mage code commit list

List archive

Chronological Thread  
  • From: David Brown <scm AT sourcemage.org>
  • To: sm-commit AT lists.ibiblio.org
  • Subject: [SM-Commit] GIT changes to master grimoire by David Brown (d582150dac32a18059e33e2b16fbcffcec01fb8b)
  • Date: Wed, 26 Sep 2007 23:35:27 -0500

GIT changes to master grimoire by David Brown <dmlb2000 AT gmail.com>:

smgl/init.d/DETAILS | 2 +-
smgl/init.d/HISTORY | 4 ++++
smgl/init.d/init.d/mountall.sh | 30 ++++++++++++++++++++++++++++++
3 files changed, 35 insertions(+), 1 deletion(-)

New commits:
commit d582150dac32a18059e33e2b16fbcffcec01fb8b
Author: David Brown <dmlb2000 AT gmail.com>
Commit: David Brown <dmlb2000 AT gmail.com>

init.d mountall.sh added luks encrypted partition opening to mountall.sh

diff --git a/smgl/init.d/DETAILS b/smgl/init.d/DETAILS
index 51e6a8b..cf16004 100755
--- a/smgl/init.d/DETAILS
+++ b/smgl/init.d/DETAILS
@@ -1,6 +1,6 @@
SPELL=init.d
VERSION=2.2.2
- PATCHLEVEL=1
+ PATCHLEVEL=2
LICENSE[0]=GPL
KEYWORDS="smgl"
ENTERED=20030505
diff --git a/smgl/init.d/HISTORY b/smgl/init.d/HISTORY
index aaf775b..97cb5b1 100644
--- a/smgl/init.d/HISTORY
+++ b/smgl/init.d/HISTORY
@@ -1,3 +1,7 @@
+2007-09-26 David Brown <dmlb2000 AT gmail.com>
+ * mountall.sh: added luks partition additions for encrypted
partitions
+ * DETAILS: updated patchlevel
+
2007-09-19 Arwed v. Merkatz <v.merkatz AT gmx.net>
* files/rc: fix init script execution if a script exists in more than
one runlevel
diff --git a/smgl/init.d/init.d/mountall.sh b/smgl/init.d/init.d/mountall.sh
index 4235fd5..71238c2 100755
--- a/smgl/init.d/init.d/mountall.sh
+++ b/smgl/init.d/init.d/mountall.sh
@@ -68,6 +68,33 @@ scanlvm()
fi
}

+start_cryptfs()
+{
+ if optional_executable /usr/sbin/cryptsetup && [ -f /etc/crypttab ]
+ then
+ echo "Attempting to open luks encrypted partitions"
+ grep -v '^#' /etc/crypttab |
+ grep -v '^$' |
+ while read line
+ do
+ parts=( $line )
+ echo "Opening ${parts[0]} as ${parts[1]}"
+ if cryptsetup isLuks ${parts[0]}
+ then
+ if [[ -b /dev/mapper/${parts[1]} ]]
+ then
+ builtin echo "Device already exists maybe its open already"
+ else
+ cryptsetup luksOpen ${parts[0]} ${parts[1]} < /dev/console >
/dev/console 2>&1
+ fi
+ else
+ builtin echo "Error device ${parts[0]} isn't a luks partition"
+ return 1
+ fi
+ done
+ fi
+}
+
start()
{
required_executable /bin/mount
@@ -75,6 +102,9 @@ start()

scanlvm
evaluate_retval
+
+ start_cryptfs
+ evaluate_retval

checkfs




  • [SM-Commit] GIT changes to master grimoire by David Brown (d582150dac32a18059e33e2b16fbcffcec01fb8b), David Brown, 09/27/2007

Archive powered by MHonArc 2.6.24.

Top of Page