[ Index ] |
PHP Cross Reference of Unnamed Project |
[Summary view] [Print] [Text view]
1 # Overwrite passwords in unattend.txt with X marks 2 3 use warnings; 4 use strict; 5 6 my $unattend = 'c:\\netinst\\unattend.txt'; 7 8 open UNATTEND, $unattend 9 or die "Unable to open $unattend for reading: $^E"; 10 11 my @lines = <UNATTEND>; 12 13 close UNATTEND 14 or die "Unable to close $unattend: $^E"; 15 16 map { s/^(.*Password\s*)=.*$/$1=xxxxxxxx/i; } @lines; 17 18 open UNATTEND, ">$unattend" 19 or die "Unable to open $unattend for writing: $^E"; 20 21 print UNATTEND @lines; 22 23 close UNATTEND 24 or die "Unable to close $unattend: $^E"; 25 26 exit 0;
title
Description
Body
title
Description
Body
title
Description
Body
title
Body
Generated: Tue Mar 17 22:47:18 2015 | Cross-referenced by PHPXref 0.7.1 |