]> git.sur5r.net Git - bacula/bacula/commitdiff
Add data encryption test
authorKern Sibbald <kern@sibbald.com>
Fri, 1 Dec 2006 16:14:53 +0000 (16:14 +0000)
committerKern Sibbald <kern@sibbald.com>
Fri, 1 Dec 2006 16:14:53 +0000 (16:14 +0000)
git-svn-id: https://bacula.svn.sourceforge.net/svnroot/bacula/trunk@3727 91ce42f0-d328-0410-95d8-f526ca767f89

regress/all-non-root-tests
regress/kern.conf
regress/scripts/new-test-bacula-dir.conf.in
regress/tests/data-encrypt-test [new file with mode: 0755]
regress/tests/filed-crypto-test [deleted file]

index ab66b3e7fccea58c71fa445e4810dbb63c38fdbc..69e61a6cb385d6ef70e34cf9a5d64e79130aec8c 100755 (executable)
@@ -12,6 +12,7 @@ tests/bscan-test
 tests/bsr-opt-test
 tests/compressed-test
 tests/concurrent-jobs-test
+tests/data-encrypt-test
 tests/differential-test
 tests/four-concurrent-jobs-test
 tests/four-jobs-test
index 01131afbd27a9d29cfa7396abffbe67f7740ab0d..11c2c5160b4c8907cd8e821364d30406741491d6 100644 (file)
@@ -32,4 +32,4 @@ TCPWRAPPERS="--with-tcp-wrappers"
 # Set this to "" to disable OpenSSL support, "--with-openssl=yes"
 # to enable it, or provide the path to the OpenSSL installation,
 # eg "--with-openssl=/usr/local"
-OPENSSL=""
+OPENSSL="--with-openssl"
index 11863cf5c866ffaee4a695bdc0da4f56814544a0..81e520fc23a00a0aa9398b7b3fc99ba09f4efbc2 100644 (file)
@@ -5,7 +5,7 @@
 #   file or directory names in the Include directive of the
 #   FileSet resource.
 #
-#  For Bacula release 1.3
+#  For Bacula release 1.39 or later
 #
 #  You might also want to change the default email address
 #   from root to your address.  See the "mail" and "operator"
@@ -40,6 +40,20 @@ Job {
   SpoolData=yes
 }
 
+Job {
+  Name = "Crypto"
+  Type = Backup
+  Client=@hostname@-fd 
+  FileSet="SparseCompressedSet"
+  Storage = File
+  Messages = Standard
+  Pool = Default
+  Write Bootstrap = "@working_dir@/NightlySave.bsr"
+  Maximum Concurrent Jobs = 4
+  SpoolData=yes
+}
+
+
 Job {
   Name = "MonsterSave"
   Type = Backup
@@ -163,6 +177,7 @@ FileSet {
   Include {
     Options {
       signature=MD5 compression=GZIP
+      sparse=yes
     }
     File = </tmp/file-list
   }
diff --git a/regress/tests/data-encrypt-test b/regress/tests/data-encrypt-test
new file mode 100755 (executable)
index 0000000..948d9d5
--- /dev/null
@@ -0,0 +1,48 @@
+#!/bin/sh
+#
+# Run a simple backup (with encryption) of the Bacula build directory
+#   then verify the signatures.
+#
+TestName="data-encrypt-test"
+JobName=Crypto
+. scripts/functions
+set_debug 1
+
+scripts/cleanup
+scripts/copy-crypto-confs
+echo "${cwd}/build" >/tmp/file-list
+
+start_test
+
+cat <<END_OF_DATA >tmp/bconcmds
+@$out /dev/null
+messages
+@$out tmp/log1.out
+@#setdebug level=100 dir
+label storage=File volume=TestVolume001
+run job=$JobName yes
+wait
+messages
+@# 
+@# now do a restore
+@#
+@$out tmp/log2.out
+restore where=${cwd}/tmp/bacula-restores storage=File
+5
+mark *
+done
+yes
+wait
+messages
+@$out
+quit
+END_OF_DATA
+
+run_bacula
+sleep 2
+check_for_zombie_jobs storage=File 
+stop_bacula
+
+check_two_logs
+check_restore_diff
+end_test
diff --git a/regress/tests/filed-crypto-test b/regress/tests/filed-crypto-test
deleted file mode 100755 (executable)
index 0189624..0000000
+++ /dev/null
@@ -1,49 +0,0 @@
-#!/bin/sh
-#
-# Run a simple backup (with encryption) of the Bacula build directory
-#   then verify the signatures.
-#
-TestName="filed-crypto-test"
-JobName=Crypto
-. scripts/functions
-set_debug 0
-
-scripts/cleanup
-scripts/copy-crypto-confs
-echo "${cwd}/build" >/tmp/file-list
-
-change_jobname NightlySave $JobName
-start_test
-
-cat <<END_OF_DATA >tmp/bconcmds
-@$out /dev/null
-messages
-@$out tmp/log1.out
-setdebug level=1 storage=File sd
-label storage=File volume=TestVolume001
-run job=$JobName yes
-wait
-messages
-@# 
-@# now do a restore
-@#
-@$out tmp/log2.out
-restore where=${cwd}/tmp/bacula-restores storage=File
-5
-mark *
-done
-yes
-wait
-messages
-@$out
-quit
-END_OF_DATA
-
-run_bacula
-sleep 2
-check_for_zombie_jobs storage=File 
-stop_bacula
-
-check_two_logs
-check_restore_diff
-end_test