Skip to content

Instantly share code, notes, and snippets.

@rtrouton
rtrouton / cipher.sh
Last active January 14, 2016 20:45 — forked from opragel/cipher.sh
#!/bin/bash
# Add the user and group used by Tomcat on your Linux
# server. For Casper 9.x running on Red Hat Enterprise
# Linux, the user and group are filled in below.
linux_tomcat_user="tomcat7"
linux_tomcat_group="tomcat7"
# Add the user and group used by Tomcat on your Linux
#!/bin/bash
### ACTIVE DIRECTORY USER PERMISSIONS SCRIPT ###
### by Graham Pugh
### Props to Jeff Kelley, Graham Gilbert and various others for elements of script
### This script looks at the "Allow Administration By" field of the
### `dsconfigad -show` command and checks each of the Active Directory users
### with mobile accounts on the computer to check whether they should have
### local admin rights. It amends each user's membership of the local
#!/bin/sh
#fix for custom guest login keychain errors
LOGGER="/usr/bin/logger"
GID=`id -g`
if [[ ${GID} == 201 ]]; then
$LOGGER -s -t fix.guest.keychain.sh "Current user is guest. Creating a login.keychain" 1>&2
security create-keychain -p "" login.keychain
security login-keychain -s ~/Library/Keychains/login.keychain