Skip to content

Instantly share code, notes, and snippets.

- Copy the delivered ipa into a directory to work in.
- export PlistBuddy="/usr/libexec/PlistBuddy" to get the PlistBuddy tool to your shell. If it is not added, all references to PlistBuddy
will need to be written as the full path.
- Take the delivered App.ipa and unzip it using the unzip command. This should produce a Payload directory containing the app and its
resources.
- Enter the command "codesign -d --entitlements :enterprise.plist Payload/PathToApp.app/" This pulls the entitlements out of the app, and
prints them to a plist, without a leading "blob" of data. Pay particular attention to the colon before the enterprise.plist file name.
@mikale
mikale / batch-strace.sh
Created August 16, 2012 17:03 — forked from hydra35/batch-strace.sh
strace all the php-fpm worker processes
#!/bin/bash
additional_strace_args="$1"
MASTER_PID=$(ps auwx | grep php-fpm | grep -v grep | grep 'master process' | cut -d ' ' -f 6)
while read -r pid;
do
if [[ $pid != $MASTER_PID ]]; then
nohup strace -r -p "$pid" $additional_strace_args >"$pid.trc" 2>&1 &
<?php
function fruit () {
return array('a' => 'apple', 'b' => 'banana');
}
echo fruit()['a']; // apple
<?php
trait foo{
function testFoo(){
echo 'foo';
}
}
class bar {
use foo;
def main():
try:
opts, args = getopt.getopt(sys.argv[1:], "ht:", ["help" ])
except getopt.GetoptError, err:
raise UseError()
if not len(args):
raise UseError()
try:
pathtype = int(opts["-t"])