Skip to content

Instantly share code, notes, and snippets.

@ywangd
ywangd / self-signed-certificate-with-custom-ca.md
Created March 4, 2020 04:48 — forked from fntlnz/self-signed-certificate-with-custom-ca.md
Self Signed Certificate with Custom Root CA

Create Root CA (Done once)

Create Root Key

Attention: this is the key used to sign the certificate requests, anyone holding this can sign certificates on your behalf. So keep it in a safe place!

openssl genrsa -des3 -out rootCA.key 4096
@ywangd
ywangd / psiclient.py
Last active April 10, 2020 16:32
Proof-of-Concept Client for Pythonista-Script-Index
"""
Basic client for Pythonista Script Index (https://github.com/ywangd/Pythonista-Script-Index)
See also: https://github.com/ywangd/psiclient
"""
import platform
import sys
import os
import urllib2
import json
# IMPORTANT SETUP INSTRUCTIONS:
#
# 1. Go to http://www.dropbox.com/developers/apps (log in if necessary)
# 2. Select "Create App"
# 3. Select the following settings:
# * "Dropbox API app"
# * "Files and datastores"
# * "(No) My app needs access to files already on Dropbox"
# * "All file types"
# * (Choose any app name)
import os
import sys
import pickle
import console
import dropboxlogin # this code can be found here https://gist.github.com/4034526
STATE_FILE = '.dropbox_state'
IGNORE_FILE = '.dropbox_ignore'