Skip to content

Instantly share code, notes, and snippets.

View umrysh's full-sized avatar
🏠
Working from home

Dave Umrysh umrysh

🏠
Working from home
View GitHub Profile
@umrysh
umrysh / main.dart
Created February 23, 2024 17:22
Generated code from pixels2flutter.dev
import 'package:flutter/material.dart';
void main() {
runApp(MyApp());
}
class MyApp extends StatelessWidget {
@override
Widget build(BuildContext context) {
return MaterialApp(
@umrysh
umrysh / masto_search.py
Created July 26, 2019 15:39
mastodon category search
import urllib.request
import sys
import os
import re
import sqlite3 as lite
from bs4 import BeautifulSoup, Comment
# Using https://fediverse.network to get the list of Mastodon Instances
url = 'https://fediverse.network/mastodon'
@umrysh
umrysh / play.py
Last active July 5, 2018 15:18
Listen to Google Play Music playlists from the terminal
#######################################################################
# You will need gmusicapi (https://github.com/simon-weber/gmusicapi)
# You can install it with:
# pip install gmusicapi
#######################################################################
import sys,warnings,subprocess,os,time
from gmusicapi import Mobileclient
from random import shuffle
import curses
@umrysh
umrysh / tompool.py
Last active October 1, 2016 14:44
Dashboard for Tompool.org that also transfers and sells coins
import requests
import json
import subprocess as sp
import time
from bittrex import Bittrex
import hmac
import urllib
import hashlib
import base64
import sys
@umrysh
umrysh / torrentIPs.py
Created December 21, 2015 16:08
Create a list of people downloading Star Wars: The Force Awakens
import libtorrent as lt
import time
import pickle
import MySQLdb as mdb
#import sqlite3 as lite
#import BeautifulSoup as bs
import bs4 as bs
import pickle
import urllib2
import sys
@umrysh
umrysh / mailgun-webhook.php
Created January 29, 2015 23:11
Very simple PHP webhook for Mailgun that emails you on errors.
<?php
$key = "<API Key>";
$from = "info@example.com";
$to = "dave@example.com";
if ($_SERVER['REQUEST_METHOD'] == 'POST') {
if(isset($_POST['timestamp']) && isset($_POST['token']) && isset($_POST['signature']) && hash_hmac('sha256', $_POST['timestamp'] . $_POST['token'], $key) === $_POST['signature'])
{
if($_POST['event'] == 'complained') {

Keybase proof

I hereby claim:

  • I am umrysh on github.
  • I am umrysh (https://keybase.io/umrysh) on keybase.
  • I have a public key whose fingerprint is CB52 F88F C12C 8C20 2C5F 2D16 91FF 74B4 E946 E9D2

To claim this, I am signing this object:

@umrysh
umrysh / checkpassword.sh
Last active September 15, 2021 07:22
Time-based One-time Passwords for Email
#!/bin/bash
# Example Dovecot checkpassword script that may be used as both passdb or userdb.
#
# Originally written by Nikolay Vizovitin, 2013.
# Assumes authentication DB is in /etc/dovecot/users, each line has '<user>:<password>' format.
# Place this script into /etc/dovecot/checkpassword.sh file and make executable.
# Implementation guidelines at http://wiki2.dovecot.org/AuthDatabase/CheckPassword
@umrysh
umrysh / gist:da4a81f798443a742eee
Created November 14, 2014 02:29
onename.io verification
Verifying that +umrysh is my openname (Bitcoin username). https://onename.io/umrysh
@umrysh
umrysh / compile_bash.sh
Created September 25, 2014 19:53
Patch the bash CVE-2014-6271 vulnerability (shellshock) on old versions of Debian (5 - Lenny, 6 - Squeeze) and OpenMediaVault
#!/bin/bash
#
# Put this in /usr/local/src/, make it executable and run it.
# Script From [https://dmsimard.com/2014/09/25/the-bash-cve-2014-6271-shellshock-vulnerability/]
#
# dependencies
apt-get update; apt-get install build-essential gettext bison
# get bash 3.2 source
wget http://ftp.gnu.org/gnu/bash/bash-3.2.tar.gz