Sales Tax Refunds from Apple

27 03 2015

For sales tax refunds on purchases made through the Mac App Store or iTunes Store, contact:

itunes_tax_refunds@apple.com

with attached exemption certificate and information in the format:

Your Name:
Name of Exempt Organization:
Amount of Sales Tax to be Refunded:
Order Numbers:

For sales tax refunds on purchases made through the Apple Store, contact:

salestax@apple.com





LDAP group memberships per individual

15 10 2014

To find out all the groups of which a user is a member, use:

ldapsearch -x -h ldap.uvm.edu -b 'ou=groups,dc=uvm,dc=edu' memberuid=[netid] cn





CFEngine-Supported Certificate Signing Request (CSR) Generation

18 07 2014

Much of this is preconfigured by cfengine using a Makefile. Here’e the general procedure for RHEL5/RHEL6 boxes:

sudo su
cd /etc/pki/tls/certs
make myhostname.csr

Answer the questions (US, Vermont, Burlington, etc). CN is hostname. Password is password. Then you’ll have the .csr file, and the .key file (which is encrypted). Assuming you want it unencrypted:

umask 077
openssl rsa -in myhostname.key -out myhostname.key.notcrypted
(enter password)
mv myhostname.key.notcrypted myhostname.key.new

Update 2017-04-11: Makefile still generates SHA1 requests. Here’s the openssl commands to manually make a SHA2 request:

openssl genrsa -aes128 2048 > myhostname.key
(enter password)
openssl req -utf8 -new -sha256 -key test.key -out myhostname.csr





Shell variable substitutions within single quotes

3 06 2014

You want single quotes AND variable substitutions? Surely you can’t be serious!

I am serious. And don’t call me Shirley.

In short, put double quotes around the single quotes.

> STUFF=things
> echo $STUFF
things
> echo "$STUFF"
things
> echo '$STUFF'
$STUFF
> echo "'$STUFF'"
'things'

Via this guy.





diff STDOUT or other output streams

3 04 2014

The ‘diff’ shell command is useful for comparing text files, but also great for comparing shell outputs with this method:

diff <(ls -alh /or/something) <(ls -alh /or/whatever)

Add any favorite flags and go to town.

diff -y --suppress-common-lines <(ls -alh /or/something) <(ls -alh /or/whatever)

(Note: this may not work for all substitutions.)








Skip to toolbar