This file contains 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
const supportsFrameCallback = 'requestVideoFrameCallback' in HTMLVideoElement.prototype, | |
requestAnimationFrame = window.requestAnimationFrame || window.mozRequestAnimationFrame || | |
window.webkitRequestAnimationFrame || window.msRequestAnimationFrame, | |
cancelAnimationFrame = window.cancelAnimationFrame || window.mozCancelAnimationFrame; | |
export default class VideoAnimation { | |
constructor(callback, video) { | |
this.callback = callback, | |
this.video = video, | |
this.animationID = null, |
This file contains 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
# Stripe Checkout Webhook Lambda Function | |
# Updates customer with missing name and address | |
# Sends custom SES email with product, price and any metadata field required | |
# Possible to send custom post payment invoice | |
# @author Daniel Rossi | |
import stripe | |
import boto3 | |
import json | |
import os |
This file contains 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 -*- | |
# pip install sox | |
import json | |
from multiprocessing import Pool | |
import logging | |
import os |
This file contains 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
package org.electroteque.widevine.drm; | |
import android.content.Context; | |
import android.content.SharedPreferences; | |
import android.util.Base64; | |
public class PersistDrmKeySetIdManager { | |
private SharedPreferences settings; |
This file contains 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/sh | |
AWS_ACCESS_KEY_ID="key" \ | |
AWS_SECRET_ACCESS_KEY="key" \ | |
letsencrypt \ | |
--renew-by-default --text \ | |
--agree-tos -a letsencrypt-s3front:auth \ | |
--letsencrypt-s3front:auth-s3-bucket bucket-name \ | |
--letsencrypt-s3front:auth-s3-region bucket-region \ | |
-i letsencrypt-s3front:installer \ |
This file contains 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/sh | |
AWS_ACCESS_KEY_ID="key" \ | |
AWS_SECRET_ACCESS_KEY="key" \ | |
letsencrypt \ | |
--agree-tos -a letsencrypt-s3front:auth \ | |
--letsencrypt-s3front:auth-s3-bucket bucket-name \ | |
--letsencrypt-s3front:auth-s3-region bucket-region \ | |
-i letsencrypt-s3front:installer \ | |
--letsencrypt-s3front:installer-cf-distribution-id cloudfront-dist-id \ |
This file contains 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/sh | |
service nginx stop # or whatever your webserver is | |
letsencrypt renew -nvv --standalone > /var/log/letsencrypt/renew.log 2>&1 | |
LE_STATUS=$? | |
service nginx start # or whatever your webserver is | |
if [ "$LE_STATUS" != 0 ]; then | |
echo Automated renewal failed: | |
cat /var/log/letsencrypt/renew.log | |
exit 1 | |
fi |
This file contains 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
export PATH=/opt/local/bin:/opt/local/msf3:/opt/local/lib/postgresql84/bin:$PATH | |
# download ruby and postgresql. postgres of mysql is required it wont work with sqlite ? | |
sudo port install ruby19 +nosuffix postgresql84-server | |
# install pg gem | |
sudo gem install pg | |
# select default ruby | |
sudo port select --set ruby ruby19 | |
# download metasploit framework sources | |
wget http://downloads.metasploit.com/data/releases/framework-latest.tar.bz2 -O - | tar -xj |
This file contains 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/sh | |
usage() | |
{ | |
cat << EOF | |
usage: $0 options | |
This script generates HLs streaming files with variant playlist and alternate audio. | |
OPTIONS: |
This file contains 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/sh | |
SRC_INPUT=$1 | |
OUT_FILENAME=$2 | |
TMP_DIR=/tmp | |
SRC_FILENAME=`basename ${SRC_INPUT}` | |
ffmpeg -i "$SRC_INPUT" -acodec pcm_s16le -ac 2 "${TMP_DIR}/${SRC_FILENAME}.wav" |