Skip to content

Instantly share code, notes, and snippets.

View cryptozeny's full-sized avatar

cryptozeny

View GitHub Profile
@cryptozeny
cryptozeny / pow_tests.cpp
Last active December 26, 2018 05:45
[WIP] pow_tests.cpp: Hash Attack Simulation
// Copyright (c) 2015-2017 The Bitcoin Core developers
// Distributed under the MIT/X11 software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#include <chain.h>
#include <chainparams.h>
#include <pow.h>
#include <random.h>
#include <util.h>
#include <test/test_bitcoin.h>
@cryptozeny
cryptozeny / pow_tests.cpp
Last active December 25, 2018 09:01
testing LWMA-1 suite from BTG and SUSU
// Copyright (c) 2015-2017 The Bitcoin Core developers
// Distributed under the MIT/X11 software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#include <chain.h>
#include <chainparams.h>
#include <pow.h>
#include <random.h>
#include <util.h>
#include <test/test_bitcoin.h>
@cryptozeny
cryptozeny / getExtraNonce.sh
Last active December 23, 2018 07:21
Get ExtraNonce & Nonce
#getExtraNonce
#!/bin/bash
Hash=NULL && \
Tx=NULL && \
RawTx=NULL && \
DecodeRawTx=NULL && \
ExtraNonce=NULL && \
Nonce=NULL && \
printf "%-16s %-16s \n" ExtraNonce Nonce && \
for(( i=2; i<= 12; i++ )); do
@cryptozeny
cryptozeny / hex-decimal.sh
Created December 22, 2018 23:35
convert 32-Bit Hex & Decimal
$ printf "%d\n" 0x1f07ffff
520617983
$ printf "%x\n" 520617983
1f07ffff
@cryptozeny
cryptozeny / dgw-15s-n24_default
Created December 15, 2018 07:09
DarkGravityWave 15s nPastBlocks 24 (default)
block timestamp difficulty interval AVG
0 1541009400 1.907323166912278e-06 GENESIS GENESIS
1 1544602494 1.907323166912278e-06 3593094 0
2 1544602867 1.907323166912278e-06 373 186.50
3 1544602879 1.907323166912278e-06 12 128.33
4 1544602883 1.907323166912278e-06 4 97.25
5 1544602891 1.907323166912278e-06 8 79.40
6 1544602926 1.907323166912278e-06 35 72.00
7 1544602944 1.907323166912278e-06 18 64.28
8 1544602947 1.907323166912278e-06 3 56.62
@cryptozeny
cryptozeny / dgw-15s-n200
Last active December 15, 2018 13:40
DarkGravityWave 15s nPastBlocks 200
block timestamp difficulty interval AVG
0 1541009400 1.907323166912278e-06 GENESIS GENESIS
1 1544803931 1.907323166912278e-06 3794531 0
2 1544804078 1.907323166912278e-06 147 73.50
3 1544804082 1.907323166912278e-06 4 50.33
4 1544804085 1.907323166912278e-06 3 38.50
5 1544804086 1.907323166912278e-06 1 31.00
6 1544804101 1.907323166912278e-06 15 28.33
7 1544804111 1.907323166912278e-06 10 25.71
8 1544804120 1.907323166912278e-06 9 23.62
@cryptozeny
cryptozeny / FULL-Date.md
Last active January 6, 2019 14:33
RPC getBlockInterval +Date

https://youtu.be/E97kpbg1j_o

BLOCK        TIMESTAMP             DIFFICULTY  RATIO  IV  AVERG
0      181101-03:10:00  1.907323166912278e-06  1.216 GENESIS GENESIS 
1      190104-23:20:58  1.907323166912278e-06  1.000 5602258      0 
2      190104-23:24:09  1.907323166912278e-06  1.000 191  95.50 
3      190104-23:24:09  1.907323166912278e-06  1.000   0  63.66 
4      190104-23:24:15  1.907323166912278e-06  1.000   6  49.25 
.
@cryptozeny
cryptozeny / copyright.md
Created November 15, 2018 16:02
Copyright (c) 2018 The Sugarchain developers
@cryptozeny
cryptozeny / TOSC-v1.1.0.md
Last active November 15, 2018 00:25
TOSC-v1.1.0

디펜던시 및 빌드

# dependencies \
\
sudo apt-get install -y git-core curl zlib1g-dev build-essential libssl-dev libreadline-dev libyaml-dev libxml2-dev libxslt1-dev libcurl4-openssl-dev python-software-properties libffi-dev libboost-all-dev libdb5.3-dev libdb5.3++-dev libpq-dev libminiupnpc-dev && \
\
# download tosc v1.1.0 \
cd && \
git clone https://github.com/tos-project/TOSC.git TOSC-v1.1.0 && \
cd git checkout v1.1.0 &amp;&amp; \
@cryptozeny
cryptozeny / sugarchain-copyright.txt
Created November 14, 2018 12:18
sugarchain-copyright.txt