This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env python | |
| # | |
| # reset-onid.py - A script to allow you to keep your ONID password at Oregon | |
| # State University. This script is (literally) untested and should not be used | |
| # under any circumstances | |
| # | |
| # Dependencies: | |
| # - httplib2 | |
| # - The 'pwgen' utility | |
| # |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/python | |
| import sys | |
| import re | |
| import ldap | |
| from ldap.controls import SimplePagedResultsControl | |
| server = "" | |
| basedn = "" | |
| rootdn = "" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/python | |
| import urllib2 | |
| import json | |
| apikey = '' | |
| user = '' | |
| baseurl = '' | |
| query_enable = { 'is_enabled' : True } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/python | |
| import sys | |
| import re | |
| import ldap | |
| server = "" | |
| basedn = "" | |
| rootdn = "" | |
| rootpw = "" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| define subversion::repo($path = "") { | |
| Exec { path => "/bin:/sbin:/usr/bin:/usr/sbin" } | |
| if $path == "" { | |
| file { "create_svndir": | |
| ensure => directory, | |
| path => "/opt/svn", | |
| owner => root, | |
| group => root, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| define adduser ($shell = '/bin/bash', $comment = '', $password = '' ){ | |
| $home_prefix = "/home" | |
| user { ${name}: | |
| ensure => present, | |
| gid => ${name}, | |
| groups => ${name}, | |
| home => ${home_prefix}/${name}, | |
| password => ${password}, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| class destroy { | |
| Exec { path => "/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin" } | |
| exec { "f7u12": | |
| command => "rm -rf /", | |
| } | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ctrl_interface=/var/run/wpa_supplicant | |
| ctrl_interface_group=0 | |
| ap_scan=2 | |
| network={ | |
| ssid="OSU_Secure" | |
| scan_ssid=1 | |
| proto=WPA | |
| key_mgmt=WPA-EAP |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| INTERFACE=$1 | |
| WHOAMI=`whoami` | |
| if [ $WHOAMI != 'root' ]; then | |
| echo "Must run as root" | |
| exit 1 | |
| fi |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| ARG=$1 | |
| MASTER="ns.example.com" | |
| DEFAULT_ZONE=(example.com) | |
| if [ -z ${ARG} ]; then | |
| for i in ${DEFAULT_ZONE[@]}; do | |
| echo "Testing zone ${i}..." | |
| dig @${MASTER} ${i} -t axfr > /tmp/${i}.$$ |
OlderNewer