Check These Out
It seems to completely void the benefit of having an encrypted folder if you then have a script on your unencrypted hard drive with your password in it. This command will mount a truecrypt file at a given mount point after asking you for the password.
cdrecord -scanbus will tell you the (x,y,z) value of your cdr (for example, mine is 3,0,0)
displays current time in "binary clock" format
(loosely) inspired by: http://www.thinkgeek.com/homeoffice/lights/59e0/
"Decoding":
8421
.... - 1st hour digit: 0
*..* - 2nd hour digit: 9 (8+1)
.*.. - 1st minutes digit: 4
*..* - 2nd minutes digit: 9 (8+1)
Prompt-command version:
PROMPT_COMMAND='echo "10 i 2 o $(date +"%H%M"|cut -b 1,2,3,4 --output-delimiter=" ") f"|dc|tac|xargs printf "%04d\n"|tr "01" ".*"'
jhead is required
specially usefull for sql scripts with insert / update statements, to add a commit command after n statements executed.
Counts TCP states from Netstat and displays in an ordered list.
Acquires a bit-by-bit data image, gzip-compresses it on multiple cores (pigz) and encrypts the data for multiple recipients (gpg -e -r). It finally sends it off to a remote machine.
You might want to secure your AWS operations requiring to use a MFA token. But then to use API or tools, you need to pass credentials generated with a MFA token.
This commands asks you for the MFA code and retrieves these credentials using AWS Cli. To print the exports, you can use:
`awk '{ print "export AWS_ACCESS_KEY_ID=\"" $1 "\"\n" "export AWS_SECRET_ACCESS_KEY=\"" $2 "\"\n" "export AWS_SESSION_TOKEN=\"" $3 "\"" }'`
You must adapt the command line to include:
* $MFA_IDis ARN of the virtual MFA or serial number of the physical one
* TTL for the credentials
It handles all possible combination of the hex bytes, including NaNs, Infinities, Normalized and Subnormal Numbers...
$ This crazy DC stuff spent me a few days to write, optimize, polish and squeeze so that it works within the tight 255 character bound...
$ You can modify it easily for other IEEE754 numbers, say, half, double, double-extended, quadruple
$ (I hope someone will find this useful and submit more dc code to commandlinefu!)