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 | |
# Settings | |
SMTP_SERVER = 'smtp.gmail.com' | |
SMTP_PORT = 465 | |
SMTP_USERNAME = 'EMAILHERE' | |
SMTP_PASSWORD = 'PASSHERE' | |
SMTP_FROM = 'SAMEASUSERNAME' | |
SMTP_TO = 'TOEMAIL' |
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 | |
from Foundation import CFPreferencesCopyValue, \ | |
kCFPreferencesAnyUser, \ | |
kCFPreferencesAnyHost | |
def getpreferencekey(keytolookup): | |
''' | |
Returns Value for Requested Key in ManagedInstalls | |
''' | |
return CFPreferencesCopyValue(keytolookup, "/Library/Preferences/ManagedInstalls", | |
kCFPreferencesAnyUser, kCFPreferencesAnyHost) |
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 | |
# Grabs the current logged in user and detects if they are admin | |
# Per MacMule's better dection of the logged in user: | |
loggedInUser=`python -c 'from SystemConfiguration import SCDynamicStoreCopyConsoleUser; import sys; username = (SCDynamicStoreCopyConsoleUser(None, None, None) or [None])[0]; username = [username,""][username in [u"loginwindow", None, u""]]; sys.stdout.write(username + "\n");'` | |
# Per munkireport-php's localadmin module | |
admin_users='' | |
for user in $(dscl . -list /Users | grep -v "^_\|^root$") ; do |
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 | |
''' | |
Gets the Model Info of your Mac from Apple's product site. | |
''' | |
from urllib2 import urlopen | |
from xml.dom import minidom | |
from sys import argv | |
def getmodeldesc(serial): | |
''' |
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 json | |
import sys | |
from urllib2 import urlopen | |
AppID = sys.argv[1] | |
#AppID = "284910350" # Yelp app for testing | |
url = urlopen("https://itunes.apple.com/lookup?id={0}".format(AppID)) |
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 | |
''' | |
Sends boxcar.io notifications, you need a token so sign up at boxcar.io! | |
''' | |
try: | |
import requests | |
except ImportError: | |
print 'Please install requests' | |
defaulticon = "https://github.com/munkireport/munkireport-php/raw/wip/assets/images/favicons/android-chrome-192x192.png" | |
def boxcarnotify(accesstoken, title, message, sound="success", |
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 | |
'''Provides utility functions for encoding and decoding linestrings using the | |
Google encoded polyline algorithm. | |
Original Script at https://gist.github.com/signed0/2031157 | |
''' | |
from sys import argv | |
from ast import literal_eval | |
def encode_coords(coords): | |
'''Encodes a polyline using Google's polyline algorithm |
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 | |
# # -*- coding: utf-8 -*- | |
import plistlib | |
import os | |
from subprocess import call | |
#import base64 | |
manifestpath = os.path.abspath('/Applications/Google Chrome.app/Contents/Resources/com.google.Chrome.manifest/Contents/Resources/com.google.Chrome.manifest') |
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
Table Name , Column | |
(u'Address', u'AddressID') | |
(u'Address', u'AddressType') | |
(u'Address', u'City') | |
(u'Address', u'Line1') | |
(u'Address', u'Line2') | |
(u'Address', u'OtherPhone') | |
(u'Address', u'PatronID') | |
(u'Address', u'PrimaryPhone') | |
(u'Address', u'State') |
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
<?xml version="1.0" encoding="UTF-8"?> | |
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | |
<plist version="1.0"> | |
<dict> | |
<key>PayloadIdentifier</key> | |
<string>org.example.profile.chrome</string> | |
<key>PayloadRemovalDisallowed</key> | |
<true/> | |
<key>PayloadScope</key> | |
<string>System</string> |
OlderNewer