openssl encrypt decrypt script | password handling
Add -pass pass:YOURPASS as an argument.
Add -pass pass:YOURPASS as an argument.
ARRAY=(${STRING//,/ }) Dont forget the space character after the last slash.
# XX=5;top -n $XX | grep CPU | grep id | awk ‘{print $8}’ | awk ‘{s+=$1} END {print s}’ | xargs -I % echo “scale=0;%/$XX” | bc -l
# systat -d 2 cpu 5 | tail -n 1 | grep ‘%’ | awk ‘{print $6}’| sed ‘s|%||’ # systat -d 2 ifstat 1
Linux: # FLOCK STUFF PIDFILE=/var/run/$(basename $0) exec 100>$PIDFILE flock -n 100 || exit 1 echo $ > $PIDFILE # … your code … test -r $PIDFILE && rm -f $PIDFILE FreeBSD: Install flock Other BSD: THATSME=”$(ps wwaux | grep -w $ | grep -v grep | awk ‘{$1=$2=$3=$4=$5=$6=$7=$8=$9=$10=””;print $0}’ | sed ‘s|^\s*||’)” && ps wwaux […]
function createPassword () { CNTSYLL=$1 CNTNUM=$2 test “x$1” == “x” && return 1 test “x$2” == “x” && return 1 PASS=”” YYY=( a e i o u ei au ai eu iu ui oi) ZZZ=( b c d f g h j k l m n p q r s t v w x y […]
Create some functions: function prepare_dialog () { # DIALOG STDOUT exec 3>&1 } function d_selectOneGender () { C_GEND_LIST=”$(getexistinggenders)” D_STRG=”” for C_GEND in $C_GEND_LIST; do D_STRG=”${D_STRG} $C_GEND Gender OFF $C_GEND” done dialog \ –backtitle “$VERSION” \ –clear \ –title “$1” \ –item-help \ –radiolist ‘Select one:’ \ $H $W $MH \ $D_STRG return $? } … […]
LDAP TIME is calculated in nanoseconds (factor 10000000) from 01/01/1601 echo $((($LDAPTIME/10000000)-11644473600)) 01/01/1601 .. 01/01/1970 in seconds: 11644473600
OBJECT2DELETE=Workstation03 ldbdel -H $SAMBA_LDB “$(ldbsearch -H $SAMBA_LDB “(sAMAccountName=$OBJECT2DELETE)” dn | grep -v ‘^#’ | head -n 1 | grep ‘dn:’ | sed ‘s|dn:\ ||’ | grep ‘DC’)”
For the second column… # cat $FILE | awk ‘{$2=$2==int($2)?int($2):int($2)+1}1’
You must be logged in to post a comment.