home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
ftp.jcu.edu.au
/
2014.06.ftp.jcu.edu.au.tar
/
ftp.jcu.edu.au
/
v6.3.2b
/
SWBD63
/
fabos-6.3.2b-10.ppc.rpm
/
fabos-6.3.2b.10.cpio.gz
/
fabos-6.3.2b.10.cpio
/
sbin
/
securitydisable
< prev
next >
Wrap
Text File
|
2010-11-10
|
1KB
|
44 lines
#!/bin/sh
#
# Copyright (c) 2003 Brocade Communications Systems, Inc.
# All rights reserved.
#
# File name: logout
# Module name: fabos/src/security/utils.c
#
# This script will logout all sessions of specified particular users.
# It's called by the in a number of situtaions in secure mode
# by the FABOS code such as when passwords change or FCS role
# change.
#
export PATH=/fabos/sbin:/fabos/bin:/bin:/usr/bin:/sbin
chkstring=`ls /proc`
if [ "$chkstring" != "" ]
then
echo This is a recovery command that can only be run in single user mode.
exit -1
fi
cd /etc/fabos
# For loop will disable security on all logical switches by changing sec.mode
# value in config file to 0.
for conf_file in `ls -1 fabos.*.conf`
do
if [ "$conf_file" != "fabos.chassis.conf" ]
then
sed 's/sec.mode:.*/sec.mode:0/g' $conf_file > /tmp/$conf_file
mv /tmp/$conf_file $conf_file
fi
done
# Save config file on the secondary partition
cp /etc/fabos/fabos.*.conf /mnt/etc/fabos
# Remove binary files in case they're corrupted. The security daemon
# will create a new file during startup.
rm /etc/fabos/*.secdb
rm /mnt/etc/fabos/*.secdb