Skip to content

Commit

Permalink
Merge pull request #8 from NicholasAdmin/1.0
Browse files Browse the repository at this point in the history
1.0
  • Loading branch information
npq7721 committed Apr 21, 2018
2 parents fdef6ec + e119695 commit 9950bef
Show file tree
Hide file tree
Showing 70 changed files with 112 additions and 77 deletions.
12 changes: 12 additions & 0 deletions BITCOIN_TALK_ANNOUNCEMENT.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
REDEN: The Anti-Scam, De-risking, Community Run Altcoin
What in the world is REDEN?
REDEN is a direct continuation of the coin once known as EDEN. On [April 4?], the developer of EDEN, iodev, ran off with almost [16 btc?] worth of investment money that was to be used for exchanges, listings, and devlopments. Today, the community's response to this terrible incident is the birth of a new coin, headed by theBeard.be (a trusted escrow on Discord): REDEN.
How will REDEN help stop scams from occuring?
1. New and current Altcoins will have the opportunity to list on the reden.io website with any amount of collateral in REDEN. There will be no maximum or minimum.
2. On reden.io, anyone can publicly view the collateral offered by the developer.
3. It is then up to the investor whether he wants to invest. Should the dev run away with the investor's money, scam victims may exchange their coins for a portion the REDEN collateral. (these exchanges will be verified and users will have a [week?] to submit their complaints.
REDEN will be the altcoin that ends developer scamming:
a) Investors will have the opportunity to view publicly offered collateral
b) There is a scam-watch channel in the current Discord to help advise investors of possible scams
c) There is a #scam-stories channel [or scam stories section of the website..], where scam victims may publicly post their scam stories, whether it be by a developer or Discord user, and post donation addresses for community members to help.

Binary file added about.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Empty file modified depends/config.guess
100644 → 100755
Empty file.
Empty file modified depends/config.sub
100644 → 100755
Empty file.
4 changes: 2 additions & 2 deletions qa/pull-tester/run-bitcoind-for-test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,14 @@
# Distributed under the MIT software license, see the accompanying
# file COPYING or http://www.opensource.org/licenses/mit-license.php.
#
DATADIR="/home/ubuntu/EDEN-MN-SETUP/hey/Reden/.redencore"
DATADIR="/home/ubuntu/Reden/.redencore"
rm -rf "$DATADIR"
mkdir -p "$DATADIR"/regtest
touch "$DATADIR/regtest/debug.log"
tail -q -n 1 -F "$DATADIR/regtest/debug.log" | grep -m 1 -q "Done loading" &
WAITER=$!
PORT=`expr 10000 + $$ % 55536`
"/home/ubuntu/EDEN-MN-SETUP/hey/Reden/src/redend" -connect=0.0.0.0 -datadir="$DATADIR" -rpcuser=user -rpcpassword=pass -listen -keypool=3 -debug -debug=net -logtimestamps -checkmempool=0 -relaypriority=0 -port=$PORT -whitelist=127.0.0.1 -regtest -rpcport=`expr $PORT + 1` &
"/home/ubuntu/Reden/src/redend" -connect=0.0.0.0 -datadir="$DATADIR" -rpcuser=user -rpcpassword=pass -listen -keypool=3 -debug -debug=net -logtimestamps -checkmempool=0 -relaypriority=0 -port=$PORT -whitelist=127.0.0.1 -regtest -rpcport=`expr $PORT + 1` &
BITCOIND=$!

#Install a watchdog.
Expand Down
2 changes: 1 addition & 1 deletion qa/pull-tester/tests_config.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
# Distributed under the MIT software license, see the accompanying
# file COPYING or http://www.opensource.org/licenses/mit-license.php.

BUILDDIR="/home/ubuntu/EDEN-MN-SETUP/hey/Reden"
BUILDDIR="/home/ubuntu/Reden"
EXEEXT=""

# These will turn into comments if they were disabled when configuring.
Expand Down
Binary file added reden_logo_horizontal.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added splash.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added splash_testnet.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion src/amount.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

#include "tinyformat.h"

const std::string CURRENCY_UNIT = "REDEN";
const std::string CURRENCY_UNIT = "REDN";

CFeeRate::CFeeRate(const CAmount& nFeePaid, size_t nSize)
{
Expand Down
51 changes: 31 additions & 20 deletions src/chainparams.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ static CBlock CreateGenesisBlock(const char* pszTimestamp, const CScript& genesi
*/
static CBlock CreateGenesisBlock(uint32_t nTime, uint32_t nNonce, uint32_t nBits, int32_t nVersion, const CAmount& genesisReward)
{
const char* pszTimestamp = "Reden coin will start April 2017";
const char* pszTimestamp = "4/21/2018 iodev regrets the day he scammed the EDEN community";
const CScript genesisOutputScript = CScript() << ParseHex("040a3ada5ba6280b99f49a92ba47221e6a72af844ec49d0c8bbdae1ec09a4c79b22e42eefe670ae04490556f91780eb57de76493d020c91d0c421c2fa052b28a2b") << OP_CHECKSIG;
return CreateGenesisBlock(pszTimestamp, genesisOutputScript, nTime, nNonce, nBits, nVersion, genesisReward);
}
Expand All @@ -65,7 +65,7 @@ class CMainParams : public CChainParams {
public:
CMainParams() {
strNetworkID = "main";
consensus.nSubsidyHalvingInterval = 60000; // every 65k blocks
consensus.nSubsidyHalvingInterval = 60000; // every130k blocks
consensus.nMasternodePaymentsStartBlock = 2; // block after premine
consensus.nMasternodePaymentsIncreaseBlock = 158000000; // not used
consensus.nMasternodePaymentsIncreasePeriod = 576*30; // not used
Expand All @@ -85,7 +85,7 @@ class CMainParams : public CChainParams {
consensus.BIP34Height = 227931; // FIX
consensus.BIP34Hash = uint256S("0x000000000000024b89b42a942fe0d9fea3bb44ab7bd1b19115dd6a759c0808b8"); // FIX
consensus.powLimit = uint256S("00000fffff000000000000000000000000000000000000000000000000000000");
consensus.nPowTargetTimespan = 2 * 2 * 60; // Reden: 2 blocks
consensus.nPowTargetTimespan = 2 * 60; // Reden: every blocks
consensus.nPowTargetSpacing = 2 * 60; // Reden: 2 minutes
consensus.fPowAllowMinDifficultyBlocks = false;
consensus.fPowNoRetargeting = false;
Expand All @@ -98,7 +98,7 @@ class CMainParams : public CChainParams {
// Deployment of BIP68, BIP112, and BIP113.
consensus.vDeployments[Consensus::DEPLOYMENT_CSV].bit = 0;
consensus.vDeployments[Consensus::DEPLOYMENT_CSV].nStartTime = 1523675804; // Aug 17th, 2019
consensus.vDeployments[Consensus::DEPLOYMENT_CSV].nTimeout = 9999999999; // April 17, 2019
consensus.vDeployments[Consensus::DEPLOYMENT_CSV].nTimeout = 1555459200; // April 17, 2019

// The best chain should have at least this much work.
consensus.nMinimumChainWork = uint256S("0x00000000000000000000000000000000000000000000000000010d96c32fd677"); //1938
Expand All @@ -119,9 +119,9 @@ class CMainParams : public CChainParams {
nMaxTipAge = 1.5 * 60 * 60; // ~36 blocks behind -> 2 x fork detection time, was 24 * 60 * 60 in bitcoin
nPruneAfterHeight = 100000;

genesis = CreateGenesisBlock(1523734358, 2873696, 0x1e0ffff0, 1, 50 * COIN);
genesis = CreateGenesisBlock(1523764584, 360505, 0x1e0ffff0, 1, 50 * COIN);
consensus.hashGenesisBlock = genesis.GetHash();
/*
/*
//////////////
//////////////
// calculate Genesis Block
Expand Down Expand Up @@ -161,9 +161,9 @@ class CMainParams : public CChainParams {
// Mainnet --- nonce: 296277 time: 1390095618 hash: 000000bdd771b14e5a031806292305e563956ce2584278de414d9965f6ab54b0
}
std::cout << std::string("Finished calculating Mainnet Genesis Block:\n");
*/
assert(consensus.hashGenesisBlock == uint256S("000006a04073197d3b91fd78ba34b34d8448b1e2fbe517435eff7263c88033bc"));
assert(genesis.hashMerkleRoot == uint256S("b3916e47e0807fede5527cb643d8088537f178068458ebf8a7c11b595743f002"));
*/
assert(consensus.hashGenesisBlock == uint256S("00000a8144601b679fc258d5aba342076e89e81573676eda958f75ff0a0a8561"));
assert(genesis.hashMerkleRoot == uint256S("b45ba0de34d2c0f9440de4f7bbbda79989a0d41757f5e145aab55cf386d15e80"));

//genesis = CreateGenesisBlock(1504653953, 0, 0x1d00ffff, 1, 50 * COIN);
//genesis = CreateGenesisBlock(1523513141, 25449000, 0x1e00ffff, 4, 50 * COIN);
Expand All @@ -172,12 +172,14 @@ class CMainParams : public CChainParams {
//printf("%s\n", genesis.hashMerkleRoot.ToString().c_str());
//assert(consensus.hashGenesisBlock == uint256S("a51381143c954ecdd9584989a01b37e673867a11309f592dbe6fc2ab92a160f2"));
//assert(genesis.hashMerkleRoot == uint256S("a71192f5fff635cd240db0f34a5662de6ba73787f96d6bf29e527b2f79272737"));
vSeeds.push_back(CDNSSeedData("redencoin1", "seed1.redencoin.info"));
vSeeds.push_back(CDNSSeedData("redencoin2", "seed2.redencoin.info"));
vSeeds.push_back(CDNSSeedData("redencoin3", "seed3.redencoin.info"));
vSeeds.push_back(CDNSSeedData("redencoin4", "seed4.redencoin.info"));
vSeeds.push_back(CDNSSeedData("dnsseed", "dnsseed.redencoin.info"));

//vSeeds.push_back(CDNSSeedData("redencoin1", "seed1.redencoin.info"));
//vSeeds.push_back(CDNSSeedData("redencoin2", "seed2.redencoin.info"));
//vSeeds.push_back(CDNSSeedData("redencoin3", "seed3.redencoin.info"));
vSeeds.push_back(CDNSSeedData("beardseed2", "redenseed2.bunkens.be"));
vSeeds.push_back(CDNSSeedData("beardseed1", "redenseed1.bunkens.be"));

//vSeeds.clear();
//vFixedSeeds.clear();
// Reden addresses start with 'R'
base58Prefixes[PUBKEY_ADDRESS] = std::vector<unsigned char>(1,60);
// Reden script addresses start with '7'
Expand All @@ -204,7 +206,7 @@ class CMainParams : public CChainParams {
strSporkPubKey = "04d9491a6cf40a2afaf51de3939eadca259a95843b637f82c772a5719bc64051409031803a1c33f1f9b14c24a2d6937fe5b76ffa99a9730aa27726f9934cabf7f4";
strMasternodePaymentsPubKey = "041fda8a1eff0a55d4d5c2d10f426e9c204d8faa228e3bbbaccd716a0db59bbfbe15dc17975f41e554ad551316b97586ddf5bec909a9fc3fc36c17a9611294fcf8";

/**checkpointData = (CCheckpointData) {
/*checkpointData = (CCheckpointData) {
boost::assign::map_list_of
( 0, uint256S("0x00000e1728b630fd83aecbc51546c7915fffb7d3c897b5fd8c4b14043070b7f0"))
( 1000, uint256S("0x00000040520462647ef6997ab360d95af29e5288d8bc393643357f8ff433c366"))
Expand All @@ -217,7 +219,15 @@ class CMainParams : public CChainParams {
10020, // * total number of transactions between genesis and last checkpoint
// (the tx=... number in the SetBestChain debug.log lines)
2800 // * estimated number of transactions per day after checkpoint
};**/
};*/
checkpointData = (CCheckpointData) {
boost::assign::map_list_of
( 0, uint256S("00000a8144601b679fc258d5aba342076e89e81573676eda958f75ff0a0a8561")),
1523764584, // * UNIX timestamp of last checkpoint block
0, // * total number of transactions between genesis and last checkpoint
// (the tx=... number in the SetBestChain debug.log lines)
500 // * estimated number of transactions per day after checkpoint
};
}
};
static CMainParams mainParams;
Expand Down Expand Up @@ -276,8 +286,9 @@ class CTestNetParams : public CChainParams {
genesis = CreateGenesisBlock(1513728000, 21635, 0x1e0ffff0, 1, 50 * COIN);

consensus.hashGenesisBlock = genesis.GetHash();
//assert(consensus.hashGenesisBlock == uint256S("0x0000000f350d9039575f6446584f4ae4317bed76aae26ef1f2381ff73f7cd68d"));
//assert(genesis.hashMerkleRoot == uint256S("0x33a98e8f8089165dc24358b01d52dd740011bdbffad052d51d3ac3588af2f487"));
// assert(consensus.hashGenesisBlock == uint256S("0x0000000f350d9039575f6446584f4ae4317bed76aae26ef1f2381ff73f7cd68d"));
// assert(genesis.hashMerkleRoot == uint256S("0x33a98e8f8089165dc24358b01d52dd740011bdbffad052d51d3ac3588af2f487"));


vFixedSeeds.clear();
vSeeds.clear();
Expand All @@ -297,7 +308,7 @@ class CTestNetParams : public CChainParams {

vFixedSeeds = std::vector<SeedSpec6>(pnSeed6_test, pnSeed6_test + ARRAYLEN(pnSeed6_test));

fMiningRequiresPeers = true;
fMiningRequiresPeers = false;
fDefaultConsistencyChecks = false;
fRequireStandard = false;
fMineBlocksOnDemand = false;
Expand Down
23 changes: 16 additions & 7 deletions src/chainparamsseeds.h
Original file line number Diff line number Diff line change
@@ -1,18 +1,27 @@
#ifndef BITCOIN_CHAINPARAMSSEEDS_H
#define BITCOIN_CHAINPARAMSSEEDS_H
#ifndef REDEN_CHAINPARAMSSEEDS_H
#define REDEN_CHAINPARAMSSEEDS_H
/**
* List of fixed seed nodes for the bitcoin network
* List of fixed seed nodes for the reden network
* AUTOGENERATED by contrib/seeds/generate-seeds.py
*
* Each line contains a 16-byte IPv6 address and a port.
* IPv4 as well as onion addresses are wrapped inside a IPv6 address accordingly.
*/
static SeedSpec6 pnSeed6_main[] = {
// {{0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xff,0xff,0xa5,0xe3,0xf7,0xb2}, 17817},
// {{0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xff,0xff,0x9f,0x59,0xfe,0x26}, 17817}
{{0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xff,0xff,0xa7,0x63,0xce,0x65}, 13058},
{{0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xff,0xff,0x9f,0x41,0x98,0x7d}, 13058},
{{0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xff,0xff,0x68,0xec,0x51,0x13}, 13058},
{{0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xff,0xff,0x2d,0x4c,0x7f,0xfc}, 13058},
{{0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xff,0xff,0x23,0xb2,0x0f,0xf3}, 13058},
{{0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xff,0xff,0x23,0xb2,0x0f,0xf3}, 13058}
};

static SeedSpec6 pnSeed6_test[] = {
// {{0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xff,0xff,0x2d,0x4c,0x5c,0xcf}, 17717}
{{0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xff,0xff,0xa7,0x63,0xce,0x65}, 13058},
{{0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xff,0xff,0x9f,0x41,0x98,0x7d}, 13058},
{{0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xff,0xff,0x68,0xec,0x51,0x13}, 13058},
{{0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xff,0xff,0x2d,0x4c,0x7f,0xfc}, 13058},
{{0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xff,0xff,0x23,0xb2,0x0f,0xf3}, 13058},
{{0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xff,0xff,0x23,0xb2,0x0f,0xf3}, 13058}
};
#endif // BITCOIN_CHAINPARAMSSEEDS_H
#endif // REDEN_CHAINPARAMSSEEDS_H
4 changes: 2 additions & 2 deletions src/config/reden-config.h
Original file line number Diff line number Diff line change
Expand Up @@ -399,10 +399,10 @@
/* #undef USE_COVERAGE */

/* Define if dbus support should be compiled in */
/* #undef USE_DBUS */
#define USE_DBUS 1

/* Define if QR support should be compiled in */
/* #undef USE_QRCODE */
#define USE_QRCODE 1

/* UPnP support not compiled if undefined, otherwise value (0 or 1) determines
default state */
Expand Down
2 changes: 1 addition & 1 deletion src/consensus/consensus.h
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ static const unsigned int MAX_BLOCK_SIZE = 1000000;
/** The maximum allowed number of signature check operations in a block (network rule) */
static const unsigned int MAX_BLOCK_SIGOPS = MAX_BLOCK_SIZE/50;
/** Coinbase transaction outputs can only be spent after this number of new blocks (network rule) */
static const int COINBASE_MATURITY = 100;
static const int COINBASE_MATURITY = 50;

/** Flags for nSequence and nLockTime locks */
enum {
Expand Down
9 changes: 6 additions & 3 deletions src/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1745,14 +1745,17 @@ NOTE: unlike bitcoin we are using PREVIOUS block height here,
CAmount GetBlockSubsidy(int nPrevBits, int nPrevHeight, const Consensus::Params& consensusParams, bool fSuperblockPartOnly)
{
if (nPrevHeight == 0) {
return 2369865 * COIN;
return 3400000 * COIN;
}
if (nPrevHeight < 800) {
return 0 * COIN;
}

CAmount nSubsidy = 50 * COIN;

// yearly decline of production by 20% per 3 months.
// yearly decline of production by 25% per 3 months.
for (int i = consensusParams.nSubsidyHalvingInterval; i <= nPrevHeight; i += consensusParams.nSubsidyHalvingInterval) {
nSubsidy -= nSubsidy * 0.20;
nSubsidy -= nSubsidy * 0.25;
}

return fSuperblockPartOnly ? 0 : nSubsidy;
Expand Down
8 changes: 4 additions & 4 deletions src/pow.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -142,12 +142,12 @@ unsigned int GetNextWorkRequired(const CBlockIndex* pindexLast, const CBlockHead

// mainnet/regtest share a configuration
if (Params().NetworkIDString() == CBaseChainParams::MAIN || Params().NetworkIDString() == CBaseChainParams::REGTEST) {
if (pindexLast->nHeight + 1 >= 2075) retarget = DIFF_DGW;
else retarget = DIFF_BTC;
if (pindexLast->nHeight + 1 >= 101) retarget = DIFF_DGW;
else retarget = DIFF_DGW;
// testnet -- we want a lot of coins in existance early on
} else {
if (pindexLast->nHeight + 1 >= 3000) retarget = DIFF_DGW;
else retarget = DIFF_BTC;
else retarget = DIFF_DGW;
}

// Default Bitcoin style retargeting
Expand Down Expand Up @@ -208,7 +208,7 @@ unsigned int GetNextWorkRequired(const CBlockIndex* pindexLast, const CBlockHead
// for DIFF_BTC only!
unsigned int CalculateNextWorkRequired(const CBlockIndex* pindexLast, int64_t nFirstBlockTime, const Consensus::Params& params)
{
if (params.fPowNoRetargeting)
if (params.fPowNoRetargeting || pindexLast->nHeight < 100)
return pindexLast->nBits;

// Limit adjustment step
Expand Down
4 changes: 2 additions & 2 deletions src/qt/bitcoinamountfield.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ class AmountSpinBox: public QAbstractSpinBox
public:
explicit AmountSpinBox(QWidget *parent):
QAbstractSpinBox(parent),
currentUnit(BitcoinUnits::REDEN),
currentUnit(BitcoinUnits::REDN),
singleStep(100000) // satoshis
{
setAlignment(Qt::AlignRight);
Expand Down Expand Up @@ -99,7 +99,7 @@ class AmountSpinBox: public QAbstractSpinBox

const QFontMetrics fm(fontMetrics());
int h = lineEdit()->minimumSizeHint().height();
int w = fm.width(BitcoinUnits::format(BitcoinUnits::REDEN, BitcoinUnits::maxMoney(), false, BitcoinUnits::separatorAlways));
int w = fm.width(BitcoinUnits::format(BitcoinUnits::REDN, BitcoinUnits::maxMoney(), false, BitcoinUnits::separatorAlways));
w += 2; // cursor blinking space

QStyleOptionSpinBox opt;
Expand Down
Loading

0 comments on commit 9950bef

Please sign in to comment.