Skip to content

Instantly share code, notes, and snippets.

View ziyadparekh's full-sized avatar

Ziyad Parekh ziyadparekh

View GitHub Profile
@gaearon
gaearon / slim-redux.js
Last active April 25, 2024 18:19
Redux without the sanity checks in a single file. Don't use this, use normal Redux. :-)
function mapValues(obj, fn) {
return Object.keys(obj).reduce((result, key) => {
result[key] = fn(obj[key], key);
return result;
}, {});
}
function pick(obj, fn) {
return Object.keys(obj).reduce((result, key) => {
if (fn(obj[key])) {
@renehamburger
renehamburger / slimdown.js
Last active September 4, 2023 07:55
slimdown.js
'use strict';
/**
* Javascript version of https://gist.github.com/jbroadway/2836900
*
* Slimdown - A very basic regex-based Markdown parser. Supports the
* following elements (and can be extended via Slimdown::add_rule()):
*
* - Headers
* - Links
@moshest
moshest / p2p-list.md
Last active February 13, 2022 09:33
A collection of peer-to-peer decentralized projects.
@almost
almost / MyCustomView.m
Last active April 15, 2018 05:47
Examples from Custom iOS Views in React Native on almostobsolete.net
#import "MyCustomView.h"
@implementation MyCustomView
{
UIColor *squareColor;
}
- (void)setIsRed:(BOOL)isRed
{
squareColor= (isRed) ? [UIColor redColor] : [UIColor greenColor];
@denji
denji / golang-tls.md
Last active March 29, 2024 03:03 — forked from spikebike/client.go
Simple Golang HTTPS/TLS Examples

Moved to git repository: https://github.com/denji/golang-tls

Generate private key (.key)
# Key considerations for algorithm "RSA" ≥ 2048-bit
openssl genrsa -out server.key 2048

# Key considerations for algorithm "ECDSA" ≥ secp384r1
# List ECDSA the supported curves (openssl ecparam -list_curves)
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>Chat</title>
<link rel="stylesheet" href="//maxcdn.bootstrapcdn.com/bootstrap/3.3.1/css/bootstrap.min.css">
<script src="https://code.jquery.com/jquery-2.1.1.min.js"></script>
<script src="//maxcdn.bootstrapcdn.com/bootstrap/3.3.1/js/bootstrap.min.js"></script>
<script>
@benmorrow
benmorrow / GradientGenerator.swift
Last active November 18, 2016 18:17
Create a gradient to use as the background. Comes preloaded with many different colors. For any view, this will allow you to insert a sublayer with a multi-color background. Using Swift, iOS 8, and Xcode 6.
//
// GradientGenerator.swift
// WatchSimulator
//
// Created by Ben Morrow on 10/12/14.
//
// The most up-to-date version of this file is hosted at https://gist.github.com/benmorrow/aa3484dd3128875afbc0
//
import UIKit
@ronantreacy
ronantreacy / create_exo_browser.sh
Created August 25, 2014 09:50
A script for building the breach exo browser
git clone https://chromium.googlesource.com/chromium/tools/depot_tools.git
export PATH="$PATH":`pwd`/depot_tools
export GYP_GENERATORS='ninja'
if [ `uname` == 'Darwin' ]; then
export GYP_DEFINES=mac_sdk=10.8
fi
echo 'p' | svn ls https://src.chromium.org/chrome
echo 'p' | svn ls https://sctp-refimpl.googlecode.com/svn/trunk
echo 'p' | svn ls https://cld2.googlecode.com/svn/trunk
mkdir chromium && cd chromium
package main
import (
"fmt"
"log"
"net/http"
"html/template"
"github.com/gorilla/sessions"

A pseudonymous trust system for a decentralized anonymous marketplace

Dionysis Zindros, National Technical University of Athens dionyziz@gmail.com

Keywords

pseudonymous anonymous web-of-trust identity trust bitcoin namecoin proof-of-burn timelock decentralized anonymous marketplace openbazaar

Abstract