This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Tested with Python 3.6 | |
# receipt_data.bin is assumed to be a base64 encoded receipt | |
# pip install asn1crypto cryptography cryptography pprint | |
from pprint import pprint | |
import base64 | |
import urllib.request | |
from asn1crypto.cms import ContentInfo | |
from OpenSSL.crypto import load_certificate, FILETYPE_ASN1, FILETYPE_PEM, X509Store, X509StoreContext, X509StoreContextError, verify | |
from asn1crypto.core import Any, Integer, ObjectIdentifier, OctetString, Sequence, SetOf, UTF8String, IA5String |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudo apt-get install libssl-dev libevent-dev build-essential libtool autotools-dev automake pkg-config libssl-dev libevent-dev bsdmainutils python-dev libxml2-dev libxslt-dev libbz2-dev | |
sudo apt-get install software-properties-common | |
sudo add-apt-repository ppa:bitcoin/bitcoin | |
sudo apt-get update | |
sudo apt-get install libdb4.8-dev libdb4.8++-dev | |
git clone https://github.com/Gulden/gulden-official.git | |
cd gulden-official/ | |
git checkout old_autotools | |
sudo mkdir /boost166 && sudo chmod -R a+rwx /boost166 && wget https://sourceforge.net/projects/boost/files/boost/1.61.0/boost_1_61_0.tar.bz2 && tar -xvf boost_1_61_0.tar.bz2 && cd boost_1_61_0/ && ./bootstrap.sh && ./b2 --prefix=/boost166 cxxflags=-fPIC cflags=-fPIC link=static install |