summaryrefslogtreecommitdiff
path: root/packaging/Caldera/OpenLinux/updatesmbpasswd.perl
diff options
context:
space:
mode:
Diffstat (limited to 'packaging/Caldera/OpenLinux/updatesmbpasswd.perl')
-rwxr-xr-xpackaging/Caldera/OpenLinux/updatesmbpasswd.perl10
1 files changed, 10 insertions, 0 deletions
diff --git a/packaging/Caldera/OpenLinux/updatesmbpasswd.perl b/packaging/Caldera/OpenLinux/updatesmbpasswd.perl
new file mode 100755
index 00000000000..60f572b4905
--- /dev/null
+++ b/packaging/Caldera/OpenLinux/updatesmbpasswd.perl
@@ -0,0 +1,10 @@
+#!/usr/bin/perl -w
+while ( <> ) {
+ print;
+ @V = split(/:/);
+ $_ = $V[3];
+ if ( $V[0] !~ /^\#/ && !(/^[0-9A-F]{32}$/ || /^X{32}$/ || /^\*{32}$/) ) {
+ $V[3] = "X" x 32;
+ }
+ print( join( ':', @V));
+}