Skip to content

Instantly share code, notes, and snippets.

View zakird's full-sized avatar

Zakir Durumeric zakird

View GitHub Profile
rhcloud.com
freepornfull.com
justmysize.com
kompoz.me
allwomenstalk.com
lindamedic.com
maximonline.ru
planetromeo.com
www.net.cn
javjunkies.com
@zakird
zakird / get-root-cas.ps1
Created August 23, 2014 02:05
powershell script that exports trusted root certificate authorities on Windows machine
$type = [System.Security.Cryptography.X509Certificates.X509ContentType]::Cert
get-childitem -path cert:\LocalMachine\AuthRoot | ForEach-Object {
$hash = $_.GetCertHashString()
[System.IO.File]::WriteAllBytes("$hash.der", $_.export($type) )
}
@zakird
zakird / judycount.c
Created November 28, 2014 21:01
Judy Array Counting
#include <assert.h>
#include <stdint.h>
#include <arpa/inet.h>
#include <Judy.h>
void lml_set(Pvoid_t *a, uint64_t k1, uint64_t k2, uint64_t v)
{
Word_t *v_;
Pvoid_t b = *a;
JLI(v_, b, k1);
### Keybase proof
I hereby claim:
* I am zakird on github.
* I am zakir (https://keybase.io/zakir) on keybase.
* I have a public key whose fingerprint is D70D 134F A713 F45F F784 5711 98A3 5EEE 5966 EBBE
To claim this, I am signing this object:
{"name":"google.com","alexa_rank":1,"status":"SUCCESS","data":{"answers":[{"ttl":86395,"type":"CAA","tag":"issue","value":"symantec.com","flag":0}],"additionals":[{"ttl":341299,"type":"A","name":"ns1.google.com","answer":"216.239.32.10"},{"ttl":341299,"type":"A","name":"ns2.google.com","answer":"216.239.34.10"},{"ttl":341299,"type":"A","name":"ns3.google.com","answer":"216.239.36.10"},{"ttl":341299,"type":"A","name":"ns4.google.com","answer":"216.239.38.10"}],"authorities":[{"ttl":167769,"type":"NS","name":"google.com","answer":"ns1.google.com."},{"ttl":167769,"type":"NS","name":"google.com","answer":"ns2.google.com."},{"ttl":167769,"type":"NS","name":"google.com","answer":"ns4.google.com."},{"ttl":167769,"type":"NS","name":"google.com","answer":"ns3.google.com."}],"protocol":"udp"}}
{"name":"googleusercontent.com","alexa_rank":90,"status":"SUCCESS","data":{"answers":[{"ttl":86400,"type":"CAA","tag":"issue","value":"symantec.com","flag":0}],"additionals":[{"ttl":167770,"type":"A","name":"ns1.google.com","answ
---
receipt: Oz-Ware Purchase Invoice
date: 2012-08-06
customer:
first_name: Dorothy
family_name: Gale
items:
- part_no: A4786
descrip: Water Bucket (Filled)
@zakird
zakird / gist:6710089
Last active December 23, 2015 23:29
IPv4 Address Bitmap
// bitmap of observed IP addresses
static uint64_t *ip_seen = NULL;
static const int IP_SEEN_SIZE = 0x4000000; // == 2^32/64
// check if we've received a response from this address previously
static inline int check_ip(uint32_t ip)
{
return (ip_seen[ip >> 6] >> (ip & 0x3F)) & 1;
}
@zakird
zakird / truthy.py
Last active December 17, 2015 14:29
Module that provides a simple Pythonic interface to the Truthy twitter API. To use, place it in the folder named "truthy.py" in the same directory as your code.
#!/usr/bin/env python
"""
Module that provides a simple Pythonic interface to the Truthy twitter API.
Documentation on how the API works is available at https://www.mashape.com/truthy/truthy-1. This
library provides a very simple interface that hands back data from each of the Truthy API endpoints
and manages pagination. Each class (TruthyMemes, TruthyNetworks, TruthyTimelines, TruthyUsers) has
a single method `get` which accepts all of the parameters defined by the Truthy API and returns
all results. API exceptions are all children of APIError. Note that because this library manages
pagination, none of the library calls accept the offset parameter defined by the API documentation.
#include "postgres.h"
#include "fmgr.h"
#include <openssl/x509.h>
#include <openssl/x509v3.h>
#include <openssl/bio.h>
#ifdef PG_MODULE_MAGIC
PG_MODULE_MAGIC;
#endif
diff --git a/ztag/annotations/export.py b/ztag/annotations/export.py
index b4472ff..930c2b2 100644
--- a/ztag/annotations/export.py
+++ b/ztag/annotations/export.py
@@ -1,4 +1,4 @@
-from ztag.annotation import *
+from ztag.annotation import *
class RSAExportTag(Annotation):