Spec: 0010
Title: Single-SignOn Onboarding
Authors: Fabian Schuh <fabian@blockops.de>
Status: Draft
Type: off-chain
Created: 2021-03-01
In these days, internet users have a number of accounts they have to manage
import idl from '../protocol-v2/sdk/src/idl/drift.json'; | |
import { Connection, Keypair, PublicKey } from '@solana/web3.js'; | |
import { Program, ProgramAccount } from '@coral-xyz/anchor'; | |
import * as anchor from '@coral-xyz/anchor'; | |
const wallet = new anchor.Wallet(Keypair.generate()); | |
const connection = new Connection("https://api.devnet.solana.com"); | |
//const connection = new Connection("https://api.mainnet-beta.solana.com"); | |
const provider = new anchor.AnchorProvider( |
import struct | |
import time | |
from calendar import timegm | |
from binascii import hexlify, unhexlify | |
import hashlib | |
import ecdsa | |
from steembase.account import PrivateKey | |
from pprint import pprint | |
job "bash" { | |
type = "service" | |
datacenters = ["de1"] | |
group "bash" { | |
count = 1 | |
network { | |
mode = "bridge" | |
} |
{ | |
"__inputs": [ | |
{ | |
"name": "DS_PROMETHEUS", | |
"label": "Prometheus", | |
"description": "", | |
"type": "datasource", | |
"pluginId": "prometheus", | |
"pluginName": "Prometheus" | |
} |
{ | |
"__inputs": [ | |
{ | |
"name": "DS_PROMETHEUS", | |
"label": "prometheus", | |
"description": "", | |
"type": "datasource", | |
"pluginId": "prometheus", | |
"pluginName": "Prometheus" | |
} |
from getpass import getpass | |
from pprint import pprint | |
from bitshares import BitShares | |
from bitshares.account import Account | |
from bitshares.amount import Amount | |
from bitsharesbase import operations | |
bitshares = BitShares("wss://eu.nodes.bitshares.ws") | |
bitshares.wallet.unlock(getpass()) | |
ops = list() |
import hashlib | |
import json | |
from binascii import hexlify, unhexlify | |
import time | |
from pprint import pprint | |
def hash(x): | |
return hashlib.sha256(unhexlify(x)).hexdigest() | |
def hashJson(x): |
if not self.worker.blockchain.nobroadcast: | |
# We using blocking so after this call we can be sure the operation | |
# is on the blockchain. However, a transfer does not return a | |
# resulting operation id as no object is created, thus we go thru | |
# the history and obtain the most recent operation id | |
# FIXME: potentially, this could go wrong in case some other entity | |
# has access ot the accounting account too and leverages that at the | |
# very same time. The ids would still be close to each other | |
account = Account(self.accounting_account) | |
statistics = Object(account["statistics"]) |
diff --git a/Dockerfile b/Dockerfile | |
index 618ff161..78d69a1d 100644 | |
--- a/Dockerfile | |
+++ b/Dockerfile | |
@@ -17,9 +17,8 @@ RUN \ | |
libncurses-dev \ | |
doxygen \ | |
ca-certificates \ | |
+ fish \ | |
&& \ |