]> git.sur5r.net Git - bacula/bacula/commitdiff
Add tls authenticate test
authorKern Sibbald <kern@sibbald.com>
Tue, 11 Dec 2007 20:01:46 +0000 (20:01 +0000)
committerKern Sibbald <kern@sibbald.com>
Tue, 11 Dec 2007 20:01:46 +0000 (20:01 +0000)
git-svn-id: https://bacula.svn.sourceforge.net/svnroot/bacula/trunk@6039 91ce42f0-d328-0410-95d8-f526ca767f89

regress/scripts/do_sed
regress/tests/tls-authenticate-test [new file with mode: 0755]

index 48a7cab73e80d7235653328ede0264b4e0a6258d..ed1e39ad203d344970d83301f37c82ab50605225 100755 (executable)
@@ -76,6 +76,11 @@ sed -f ${out} ${cwd}/scripts/tls-bacula-fd.conf.in >${cwd}/scripts/tls-bacula-fd
 sed -f ${out} ${cwd}/scripts/tls-bacula-sd.conf.in >${cwd}/scripts/tls-bacula-sd.conf
 sed -f ${out} ${cwd}/scripts/tls-bacula-dir.conf.in >${cwd}/scripts/tls-bacula-dir.conf
 
+sed -f ${out} ${cwd}/scripts/tls-auth-bacula-fd.conf.in >${cwd}/scripts/tls-auth-bacula-fd.conf
+sed -f ${out} ${cwd}/scripts/tls-auth-bacula-sd.conf.in >${cwd}/scripts/tls-auth-bacula-sd.conf
+sed -f ${out} ${cwd}/scripts/tls-auth-bacula-dir.conf.in >${cwd}/scripts/tls-auth-bacula-dir.conf
+
+
 sed -f ${out} ${cwd}/scripts/bacula-fd-2d.conf.in >${cwd}/scripts/bacula-fd-2d.conf
 sed -f ${out} ${cwd}/scripts/bacula-sd-2d.conf.in >${cwd}/scripts/bacula-sd-2d.conf
 sed -f ${out} ${cwd}/scripts/bacula-dir-2d.conf.in >${cwd}/scripts/bacula-dir-2d.conf
diff --git a/regress/tests/tls-authenticate-test b/regress/tests/tls-authenticate-test
new file mode 100755 (executable)
index 0000000..38dffaf
--- /dev/null
@@ -0,0 +1,52 @@
+#!/bin/sh
+#
+# Run a simple backup of the Bacula build directory with TLS
+#   communications code enabled then restore it.
+#
+TestName="tls-authenticate-test"
+JobName=tls
+. scripts/functions
+
+scripts/cleanup
+scripts/copy-tls-confs
+echo "${cwd}/build" >${cwd}/tmp/file-list
+
+change_jobname CompressedTest $JobName
+start_test
+      
+cat <<END_OF_DATA >tmp/bconcmds
+@output
+messages
+@$out tmp/log1.out
+setdebug level=100 dir
+setdebug level=100 storage=File
+setdebug level=100 client
+status all
+status all
+messages
+label storage=File volume=TestVolume001 pool=Default
+run job=$JobName storage=File yes
+wait
+messages
+@# 
+@# now do a restore
+@#
+@$out tmp/log2.out
+restore where=${cwd}/tmp/bacula-restores select storage=File
+unmark *
+mark *
+done
+yes
+wait
+messages
+@output
+quit
+END_OF_DATA
+
+run_bacula
+check_for_zombie_jobs storage=File
+stop_bacula
+
+check_two_logs
+check_restore_diff
+end_test