Skip to content

Instantly share code, notes, and snippets.


Pelle Braendgaard pelle

View GitHub Profile
View VASPDIDDocument.json
"@context": "",
"id": "did:example:123456789abcdefghi",
"authentication": [{
"id": "did:example:123456789abcdefghi#keys-1",
"type": "Ed25519VerificationKey2018",
"controller": "did:example:123456789abcdefghi",
"publicKeyBase58": "H3C2AVvLMv6gmMNam3uVAjZpfkcJCwDwnZn6z3wXmqPV"
"service": [{
pelle / mainnet-connect.js
Created July 27, 2018 13:47
Main net Uport Connect
View mainnet-connect.js
import { Connect } from 'uport-connect'
const uport = new Connect('My App', {
network: 'mainnet'
View didauth-integration.js
import { Credentials } from 'uport'
import { verifyJWT } from 'did-jwt'
async function mySigner (data) {
// bring up signing UX
// sign data with sha256/secpk256k1
// see
pelle / eth
Last active October 24, 2017 23:17
View eth
pelle / package.json
Created April 10, 2017 21:43
Uport Connect - React Native example
View package.json
"name": "exampleapp",
"version": "0.0.1",
"private": true,
"scripts": {
"start": "node_modules/react-native/packager/ --nonPersistent",
"test": "jest",
"build-uport-connect": "node_modules/.bin/derequire node_modules/uport-connect/dist/uport-connect.js >src/vendor/uport-connect.js"
"dependencies": {
View EscrowContract.sol
contract EscrowContract {
address buyer;
address seller;
address agent;
// Each party has an entry here with the timestamp of their acceptance
uint[3] acceptances;
bool active;
pelle / Escrow.sol
Created January 10, 2016 21:14
Simple Escrow with Agent
View Escrow.sol
contract Escrow {
address buyer;
address seller;
address agent;
function Escrow(address _agent, address _seller) {
// In this simple example, the person sending money is the buyer and sets up the initial contract
buyer = msg.sender;
agent = _agent;
seller = _seller;

Keybase proof

I hereby claim:

  • I am pelle on github.
  • I am pelle ( on keybase.
  • I have a public key whose fingerprint is 3810 F094 D2F8 9DDF 6468 2B72 CB8D 0835 0187 B1A9

To claim this, I am signing this object:

pelle / accounts.clj
Created May 8, 2012 14:37
Using database functions in Datomic transactions and annotating transaction history
View accounts.clj
(use '[datomic.api :only [q db] :as d])
(def uri "datomic:mem://accounts")
;; create database
(d/create-database uri)
;; connect to database
(def conn (d/connect uri))
View gist:1191915
<?xml version="1.0" encoding="UTF-8"?>
<Document xmlns:xsi="" xmlns="urn:iso:std:iso:20022:tech:xsd:pain.001.001.03">
<Nm>ABC Corporation</Nm>