From: Kern Sibbald Date: Thu, 3 May 2007 07:55:25 +0000 (+0000) Subject: Update encrypt test X-Git-Tag: Release-7.0.0~6448 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=ad4b97b2fc77cc797158cf4742badbe085b78b56;p=bacula%2Fbacula Update encrypt test git-svn-id: https://bacula.svn.sourceforge.net/svnroot/bacula/trunk@4682 91ce42f0-d328-0410-95d8-f526ca767f89 --- diff --git a/regress/encrypt-bug.txt b/regress/encrypt-bug.txt new file mode 100644 index 0000000000..6a68dd8c7b --- /dev/null +++ b/regress/encrypt-bug.txt @@ -0,0 +1,49 @@ +-----BEGIN PGP MESSAGE----- +Charset: ISO-8859-1 +Version: GnuPG v1.4.2 (FreeBSD) +Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org + +hQIOA/nlxaDbIWjjEAf/dEGV3MNkQk92dZIzRIgKx3MuKElsIcQmc053MT8Wc7V3 ++FmwbqsfhirEdBU+qEINRT+3UQ+RLY1NXKlbL2JxeMdJTWx81x6wTbR+wPgi8HeE +jhPvEx1633IWS8+Au3Flmry3SxjEf4uI5N4r+hFWuvYxdalXtXtkTOvTbfmtoQPG +y9mQ7eCdpAQr/kKOpaC2wWeVrlfEUuURENATlYfdLxKGuGDqD83TmWpO5zlgJ2pL +ChpZAVBCcapC0FFDbqIYxtqbFsA8HwmNiVIeiF4Pebcq+tDBuvEt/NUCt5Piyt// +kHg9wux6q8B5a1r+95CMToQwAxwhIm6aDKiMeqnGUwgApk1MjY2jfThc4oO76Cya +am5926qs7NhiqOIGCgytVxAbnqgN2nlXaFCiGsvoY7BWQHu5/hEBUV/rZsyg2I5s +bw62sMRqMckvqGqdxhQRtlj+nSvRtBdj/Udtn91DMNVzNwzfGYUfQPWPCyuBpzNd +47xDorDvEyBf8EDMSeWtvsZXZ3DBf6TY2DPiesnBHcQjOv/zqnL9xudvD7wlhVFh +UMpMQIsltBoofrK19sm4l3yzH89PmIp4pOzYyjysEMIOz5SXisO2OBidny5eRF7/ +u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/2fcqnSW8HhoepIQ+G8I46y0wq +cPoH7hC29ojoYe7hFR93/3yDJRGF+I/9Ot+EmoObkxM2ForYzVlLkov7wmfgAZEk +hNAV7UeCNgPJgVu8uWGEkXQURUq+w4/RFwOpmIVO/ZnmxXEnA6lRq7Yb6eBkCpWX +HBG/G8pB6kUSuJ1XwNo8gct38OunjYZgEo+y3q0IFhjjDe8bHk+80DDN9qtK4Kep +LeEnLKEG+J5AJZoOXNU6tqX6VTzGdbl1QYLOZFnGlXu7pLRNnr639Iuo6L99Tgoz +V2w7IND/AdtgSchZWQPz5mKYSEz9arEC42CCufDXrDlvna622GbP1YKkrMuhZmsb +qyHkC4gkJ3VWMzKNi3Hu5oQ8rSLY9tnjIoSNYTU6DYxWpdLA0wEGN1WfVcZfqwgj +ooFwtERXyub50dBVKjms3PwYQ9E9vtfQ7ABOk4LnyEprJ/zOokEuG2cGwHr7EGMc +5xx7bWLbtxORLl4TffVvseZJD7Rjejdu+P0nV9I85dCFhhUrno+TvP2BJhLvT/x0 +tiRqTMtFrEsvfDFg6j3zbmi6U/nqtRl2Iamb6ACaBVGXeXcSZqLcizaEdxq7aXqX +GIUWMeXTvWtYE9et/3NJrRm6Eo2IOQO6J0OnUvsuBc+i0pZaIi7WVnDBDMgojXXa +yRNRgm4jtwT+5KWi8QA6owXgDhjWH+dILSWTE8Q7V7grlRp4C42STtvtXmwuIDws +sb72EmQs3IkKylS7Nk6mZwhDK8Wjo6olUjS8PceWDVWLOII+hcHiuGSZXZyy7Bwg +mfswd8sqIaWPDkYwlsBq82yRS4YV224pBBxqiT3o14LqCQ56Er3ZaogGfKiL0mpJ +Lu3fpivt/HslXbumQeggeFfhn6Z/Otbr1EGrvcslPEPLehpEfks/2syF9vfqLaFp ++spDOiRKBUg= +=W5Nc +-----END PGP MESSAGE----- \ No newline at end of file diff --git a/regress/encrypt-bug2.txt b/regress/encrypt-bug2.txt new file mode 100644 index 0000000000..ef110a6c95 --- /dev/null +++ b/regress/encrypt-bug2.txt @@ -0,0 +1,75 @@ +From: "Michel Meyers" +To: "bacula-users" +Subject: [Bacula-users] Script for pushing new clients to Windows boxes +Date: Mon, 2 Feb 2004 16:10:48 +0100 + +Hello, + +Some of you may remember my document on how to remotely push a Win32 bacula +client onto a WinNT/2k/XP box. Well, I've written a script to do it for me +and thought I'd share it with you: +- ---------------------------------------------------------------- +#!/bin/bash +# +# Remote Win32 client upgrade script +# written by Michel Meyers (last update 2006-09-25 11:34) +# +# WARNING: Make sure that no bacula-fd.conf exists in the source directory! +# You will destroy/overwrite all your client's configs if you don't +# be careful with this. +# +# The upgrade function does the following: +# - Shutdown Bacula service on remote machine +# - Wait 30 seconds (to allow proper shutdown) +# - Mount C: drive of remote box +# - Copy new client to remote machine +# - Unmount C; +# - Startup the new Bacula service +# +# To upgrade a machine append the following at the bottom of this file: +# +# SERVERNAME= +# USERNAME= +# PASSWORD= +# upgrade + +upgrade() { +net rpc -S $SERVERNAME -U $USERNAME%"$PASSWORD" service stop bacula +sleep 30 +smbmount //$SERVERNAME/c$ /mnt -o username=$USERNAME,password="$PASSWORD" +cp /home/michel/winbacula/bin/* /mnt/bacula/bin +umount /mnt +net rpc -S $SERVERNAME -U $USERNAME%"$PASSWORD" service start bacula +} + +SERVERNAME=xerxes +USERNAME=administrator +PASSWORD=secret +upgrade + +SERVERNAME=shodan +USERNAME=teh_one +PASSWORD="" +upgrade +- ---------------------------------------------------------------- + +It should be pretty self-explanatory. I'm not good at shell programming and +I don't know whether there's any notion of arrays or 'for' loops that could +make it cleaner so I simply wrote a function which references some variables +and then call that repeatedly (once per machine). You can of course change +the values according to your system and liking (if 30 secs seem to much for +you, just reduce the value after sleep, make sure to check on the paths and +mountpoint /mnt may not be usable on your system, ...) + +Note: The requirements are the same as described in my other document +(Samba-TNG clients among others, otherwise you'll be missing rpcclient). + +Update 2006-09-25: Samba-TNG is no longer required, the 'net' command from +Samba 3 works for starting and stopping services. Paths may need to be +updated with quotation marks as the new Bacula Win32 Installer no longer +installs into C:\bacula but into 'C:\Program Files\bacula' (on English +Windows versions). + + +Enjoy! + diff --git a/regress/tests/encrypt-bug-test b/regress/tests/encrypt-bug-test index 0bba2c6185..77077d7307 100755 --- a/regress/tests/encrypt-bug-test +++ b/regress/tests/encrypt-bug-test @@ -14,10 +14,12 @@ echo "${cwd}/encrypt-bug.jpg" >/tmp/file-list echo "${cwd}/encrypt-bug.jpg" >${cwd}/tmp/restore-list echo "${cwd}/encrypt-bug.txt" >>/tmp/file-list echo "${cwd}/encrypt-bug.txt" >>${cwd}/tmp/restore-list -files="encrypt-bug.jpg encrypt-bug.txt" +echo "${cwd}/encrypt-bug2.txt" >>/tmp/file-list +echo "${cwd}/encrypt-bug2.txt" >>${cwd}/tmp/restore-list +files="encrypt-bug.jpg encrypt-bug.txt encrypt-bug2.txt" mkdir -p ${cwd}/tmp/build for i in ${files}; do - cp -p ${cwd}/encrypt-bug.* ${cwd}/tmp/build + cp -p ${cwd}/encrypt-bug*.* ${cwd}/tmp/build done change_jobname NightlySave $JobName