I hereby claim:
- I am abhn on github.
- I am abhn (https://keybase.io/abhn) on keybase.
- I have a public key ASC2Qt0_C769tGtV0Z1LNDPyL3lj1BTMieseE3ZeNXwnNAo
To claim this, I am signing this object:
const toCamel = s => { | |
return s.replace(/([-_][a-z])/ig, ($1) => { | |
return $1.toUpperCase() | |
.replace('-', '') | |
.replace('_', ''); | |
}); | |
}; | |
const isArray = a => { | |
return Array.isArray(a); |
from os import listdir | |
from os.path import isfile, join | |
onlyfiles = [f for f in listdir('./') if isfile(join('./', f))] | |
for file in onlyfiles: | |
print(file) | |
if file == 'helper.py': | |
continue | |
with open(file, 'r') as myfile: |
I hereby claim:
To claim this, I am signing this object:
import hashlib | |
sha = hashlib.sha256() | |
f = open('vid1', 'rb') | |
chunklist = [] | |
hashlist = [] | |
tmp = f.read(1024) |
To ensure that the pieces of secrets ('shards') are not misplaced or stolen, and to avoid the possibility of losing your secret, there are some measures that need to be taken to ensure safe and secure storage of each shard. Here are some suggested ways of storing them.
Storage is two step process. There's the storage of the actual secret on a media, and then there's storage of the media itself. Let's call it technical and physical storage respectively. Listed below are some of the best practices for each.
The solution you choose depends upon your usecase and level of paranoia.
# Encryption/Decryption script | |
# Requires "rync" (for incremental sync) and "gpg" (for encryption/decryption) | |
# Usage: | |
# Download this script | |
# $ chmod +x script.sh | |
### Encrypt | |
# (-e) (-s/--source) (-d/--destination) (-pf/--password-file) | |
# $ ./script.sh -e -s=./path/to/source-dir -d=./path/to/destination-dir -pf=./passfile.txt.gpg |
import re | |
import sys, os | |
import httplib2 | |
import boto3, botocore | |
from BeautifulSoup import BeautifulSoup, SoupStrainer | |
from optparse import OptionParser | |
# base url supplied. The search will move inward | |
globalBaseUrl = "" | |
globalLinkList = [] |
int ledPin = 7; // choose the pin for the LED | |
int inputPin = 2; // choose the input pin (for PIR sensor) | |
int val = 0; // variable for reading the pin status | |
void setup() { | |
pinMode(ledPin, OUTPUT); // declare LED as output | |
pinMode(inputPin, INPUT); // declare sensor as input | |
Serial.begin(9600); | |
} | |
#include "linkedlist.h" | |
#include <string.h> | |
#include <stdlib.h> | |
#include <stdio.h> | |
#include <stdbool.h> | |
struct node { | |
void *dataptr; | |
struct node *link; | |
char *type; |