Skip to content

Commit

Permalink
Merge pull request KomodoPlatform#572 from Asherda/release-v1.2.2-3
Browse files Browse the repository at this point in the history
Release v1.2.2-3
  • Loading branch information
Asherda authored Apr 11, 2024
2 parents d45ce54 + aa53dc0 commit f400715
Show file tree
Hide file tree
Showing 13 changed files with 70 additions and 7 deletions.
2 changes: 1 addition & 1 deletion .gitlab-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ stages:
########################################################################################################################
variables:

VERSION: 1.2.2-2
VERSION: 1.2.2-3

VERUS_CLI_ARM64_LINUX: Verus-CLI-Linux-v${VERSION}-arm64.tar.gz
VERUS_CLI_LINUX_X86_64: Verus-CLI-Linux-v${VERSION}-x86_64.tar.gz
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@

## VerusCoin version 1.2.2-2
## VerusCoin version 1.2.2-3

Arguably the world's most advanced technology, zero knowledge privacy enabled, multi-chain blockchain protocol, Verus Public Blockchains as a Service (PBaaS) combines Sapling zero knowledge technology with an intelligent, multi-chain, provable protocol, using interchain smart transactions. Verus PBaaS also enables merge mining and cross-chain staking with a completely original, combined proof of stake/proof of work consensus algorithm, Proof of Power, that can be mined on CPUs and mobile phones, and also solves the nothing at stake problem. With this and its approach towards CPU mining and ASICs, Verus Coin strives to be one of the most naturally decentralizing and attack resistant blockchain networks in existence.

Expand Down
2 changes: 1 addition & 1 deletion doc/man/verus-cli/linux/README.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@

VerusCoin Command Line Tools v1.2.2-2
VerusCoin Command Line Tools v1.2.2-3

Contents:
verusd - VerusCoin daemon
Expand Down
2 changes: 1 addition & 1 deletion doc/man/verus-cli/mac/README.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@

VerusCoin Command Line Tools v1.2.2-2
VerusCoin Command Line Tools v1.2.2-3

Contents:
verusd - VerusCoin daemon.
Expand Down
2 changes: 1 addition & 1 deletion doc/man/verus-cli/windows/README.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@

VerusCoin Command Line Tools v1.2.2-2
VerusCoin Command Line Tools v1.2.2-3

Contents:
verusd.exe - VerusCoin daemon
Expand Down
2 changes: 1 addition & 1 deletion src/deprecation.h
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
// * Shut down 52 weeks' worth of blocks after the estimated release block height.
// * A warning is shown during the 2 months' worth of blocks prior to shut down.

static const int APPROX_RELEASE_HEIGHT = 2991000;
static const int APPROX_RELEASE_HEIGHT = 3000000;

static const int WEEKS_UNTIL_DEPRECATION = 52;
static const int DEPRECATION_HEIGHT = APPROX_RELEASE_HEIGHT + (WEEKS_UNTIL_DEPRECATION * 7 * 60 * 24);
Expand Down
33 changes: 33 additions & 0 deletions src/pbaas/pbaas.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -6325,6 +6325,16 @@ void CConnectedChains::CheckOracleUpgrades()
}

CUpgradeDescriptor oneUpgrade;

// compatible with vARRR update notarization modulo reset, even if no
// or different oracle used
if (IsVerusMainnetActive() &&
height >= vARRRUpdateHeight(false) &&
(height - vARRRUpdateHeight(false)) < 800)
{
activeUpgradesByKey[ResetNotarizationModuloKey()] = CUpgradeDescriptor(ResetNotarizationModuloKey(), 16908802, 3000000, 0);
}

if (upgradeData.size())
{
for (auto &oneUpgrade : upgradeData)
Expand Down Expand Up @@ -6505,6 +6515,29 @@ bool CConnectedChains::vARRRUpdateEnabled(uint32_t height) const
return height >= vARRRUpdateHeight(false);
}

uint160 CConnectedChains::vARRRChainID() const
{
static uint160 vARRRID = GetDestinationID(DecodeDestination("iExBJfZYK7KREDpuhj6PzZBzqMAKaFg7d2"));
return vARRRID;
}

bool CConnectedChains::ForceIdentityUpgrade(uint32_t height) const
{
if (vARRRChainID() != ASSETCHAINS_CHAINID || height >= 18250)
{
return true;
}

auto iiuIt = ConnectedChains.activeUpgradesByKey.find(ConnectedChains.ForceIdentityUpgradeKey());
if (iiuIt != ConnectedChains.activeUpgradesByKey.end() &&
height >= iiuIt->second.upgradeBlockHeight)
{
return true;
}

return false;
}

bool CConnectedChains::ConfigureEthBridge(bool callToCheck)
{
// first time through, we initialize the VETH gateway config file
Expand Down
14 changes: 14 additions & 0 deletions src/pbaas/pbaas.h
Original file line number Diff line number Diff line change
Expand Up @@ -1222,6 +1222,8 @@ class CConnectedChains
bool AutoArbitrageEnabled(uint32_t height) const;
uint32_t vARRRUpdateHeight(bool getVerusHeight) const;
bool vARRRUpdateEnabled(uint32_t height) const;
uint160 vARRRChainID() const;
bool ForceIdentityUpgrade(uint32_t height) const;

std::vector<CCurrencyDefinition> GetMergeMinedChains()
{
Expand Down Expand Up @@ -1305,6 +1307,18 @@ class CConnectedChains
return key;
}

static std::string ForceIdentityUpgradeKeyName()
{
return "vrsc::system.upgradedata.forceidentityupgrade";
}

static uint160 ForceIdentityUpgradeKey()
{
static uint160 nameSpace;
static uint160 key = CVDXF_Data::GetDataKey(ForceIdentityUpgradeKeyName(), nameSpace);
return key;
}

static std::string DisablePBaaSCrossChainKeyName()
{
return "vrsc::system.upgradedata.disablepbaascrosschain";
Expand Down
5 changes: 5 additions & 0 deletions src/pbaas/reserves.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3889,6 +3889,11 @@ bool CReserveTransfer::GetTxOut(const CCurrencyDefinition &sourceSystem,
return false;
}

if (ConnectedChains.ForceIdentityUpgrade(height))
{
importedID.UpgradeVersion(height);
}

// check for collisions and if not present, make an ID output
bool idCollision = false, currencyCollision = false;

Expand Down
5 changes: 5 additions & 0 deletions src/rpc/misc.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -735,6 +735,11 @@ uint256 HashFile(const std::string &filepath, CNativeHashWriter &ss)

uint256 HashFile(const std::string &filepath)
{
if (!GetBoolArg("-enablefileencryption", true))
{
throw JSONRPCError(RPC_INVALID_PARAMETER, "Cannot read file: " + filepath + " for data output");
}

CNativeHashWriter hw(CCurrencyDefinition::EHashTypes::HASH_SHA256);
return HashFile(filepath, hw);
}
Expand Down
2 changes: 2 additions & 0 deletions src/rpc/pbaasrpc.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -15629,6 +15629,8 @@ bool CConnectedChains::GetNotaryIDs(const CRPCChainData notaryChain,
oneDef.contentMultiMap.clear();
}

oneDef.UpgradeVersion(1);

{
identities[oneDef.GetID()] = oneDef;
}
Expand Down
2 changes: 1 addition & 1 deletion src/version.h
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,6 @@ static const int MEMPOOL_GD_VERSION = 60002;
static const int NO_BLOOM_VERSION = 170004;

#define KOMODO_VERSION "0.2.1"
#define VERUS_VERSION "1.2.2-2"
#define VERUS_VERSION "1.2.2-3"

#endif // BITCOIN_VERSION_H
4 changes: 4 additions & 0 deletions src/wallet/rpcwallet.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1423,6 +1423,10 @@ size_t GetDataMessage(const UniValue &uni, CVDXF::EHashTypes hashType, std::vect
}
else if (!strFileName.empty())
{
if (!GetBoolArg("-enablefileencryption", false))
{
throw JSONRPCError(RPC_INVALID_PARAMETER, "Cannot read file: " + strFileName + " for data output");
}
int bytesRead = FileToVector(strFileName, dataVec, MAX_TX_SIZE_AFTER_SAPLING >> 1);
if (!bytesRead)
{
Expand Down

0 comments on commit f400715

Please sign in to comment.