1 |
snetram |
1.1 |
diff -up e-smith-backup-2.0.0/createlinks.CIFScredentials e-smith-backup-2.0.0/createlinks |
2 |
|
|
--- e-smith-backup-2.0.0/createlinks.CIFScredentials 2008-10-07 19:34:31.000000000 +0200 |
3 |
|
|
+++ e-smith-backup-2.0.0/createlinks 2009-08-25 20:11:57.000000000 +0200 |
4 |
|
|
@@ -32,6 +32,7 @@ event_link("reset-restore-idle-flag", $e |
5 |
|
|
$event = "conf-backup"; |
6 |
|
|
|
7 |
|
|
templates2events("/etc/crontab", $event); |
8 |
|
|
+templates2events("/etc/dar/CIFScredentials", $event); |
9 |
|
|
|
10 |
|
|
#-------------------------------------------------- |
11 |
|
|
# events for pre-backup action |
12 |
|
|
diff -up e-smith-backup-2.0.0/root/etc/e-smith/events/actions/workstation-backup-dar.CIFScredentials e-smith-backup-2.0.0/root/etc/e-smith/events/actions/workstation-backup-dar |
13 |
|
|
--- e-smith-backup-2.0.0/root/etc/e-smith/events/actions/workstation-backup-dar.CIFScredentials 2009-08-25 19:57:09.000000000 +0200 |
14 |
|
|
+++ e-smith-backup-2.0.0/root/etc/e-smith/events/actions/workstation-backup-dar 2009-08-25 20:08:32.000000000 +0200 |
15 |
|
|
@@ -122,7 +122,7 @@ if ($err) |
16 |
|
|
|
17 |
|
|
if ($VFSType eq 'cifs') |
18 |
|
|
{ |
19 |
|
|
- $err = qx(/bin/mount -t cifs "$smbhost:$smbshare" $mntdir -o user=$login,pass=$password 2>&1); |
20 |
|
|
+ $err = qx(/bin/mount -t cifs "$smbhost:$smbshare" $mntdir -o credentials=/etc/dar/CIFScredentials,nounix 2>&1); |
21 |
|
|
ldie("Error while mounting $smbhost:$smbshare : \n" . $err) if $err; |
22 |
|
|
} |
23 |
|
|
elsif ($VFSType eq 'nfs') |
24 |
|
|
diff -up e-smith-backup-2.0.0/root/etc/e-smith/templates/etc/dar/CIFScredentials/template-begin.CIFScredentials e-smith-backup-2.0.0/root/etc/e-smith/templates/etc/dar/CIFScredentials/template-begin |
25 |
|
|
--- e-smith-backup-2.0.0/root/etc/e-smith/templates/etc/dar/CIFScredentials/template-begin.CIFScredentials 2009-08-25 20:02:17.000000000 +0200 |
26 |
|
|
+++ e-smith-backup-2.0.0/root/etc/e-smith/templates/etc/dar/CIFScredentials/template-begin 2009-08-23 18:23:00.000000000 +0200 |
27 |
|
|
@@ -0,0 +1,2 @@ |
28 |
|
|
+username={$backupwk{'Login'}} |
29 |
|
|
+password={$backupwk{'Password'}} |
30 |
|
|
diff -up e-smith-backup-2.0.0/root/etc/e-smith/templates.metadata/etc/dar/CIFScredentials.CIFScredentials e-smith-backup-2.0.0/root/etc/e-smith/templates.metadata/etc/dar/CIFScredentials |
31 |
|
|
--- e-smith-backup-2.0.0/root/etc/e-smith/templates.metadata/etc/dar/CIFScredentials.CIFScredentials 2009-08-25 20:05:59.000000000 +0200 |
32 |
|
|
+++ e-smith-backup-2.0.0/root/etc/e-smith/templates.metadata/etc/dar/CIFScredentials 2009-08-23 22:18:00.000000000 +0200 |
33 |
|
|
@@ -0,0 +1 @@ |
34 |
|
|
+PERMS=0600 |
35 |
|
|
diff -up e-smith-backup-2.0.0/root/etc/e-smith/web/functions/backup.CIFScredentials e-smith-backup-2.0.0/root/etc/e-smith/web/functions/backup |
36 |
|
|
--- e-smith-backup-2.0.0/root/etc/e-smith/web/functions/backup.CIFScredentials 2009-08-25 19:57:09.000000000 +0200 |
37 |
|
|
+++ e-smith-backup-2.0.0/root/etc/e-smith/web/functions/backup 2009-08-25 20:10:13.000000000 +0200 |
38 |
|
|
@@ -3234,7 +3234,7 @@ sub dmount() |
39 |
|
|
|
40 |
|
|
if ($VFSType eq 'cifs') |
41 |
|
|
{ |
42 |
|
|
- return ( qx(/bin/mount -t cifs "$host:$share" $mountdir -o user=$login,pass=$password) ); |
43 |
|
|
+ return ( qx(/bin/mount -t cifs "$host:$share" $mountdir -o credentials=/etc/dar/CIFScredentials,nounix) ); |
44 |
|
|
} |
45 |
|
|
elsif ($VFSType eq 'nfs') |
46 |
|
|
{ |