Giter Club home page Giter Club logo

Comments (4)

Goro2030 avatar Goro2030 commented on August 30, 2024 1

@yerkobits can you close this issue already?

from prosusmoney.

yerkobits avatar yerkobits commented on August 30, 2024

Prosus-Money forked itself (2016) and the old blockchain was copied manually to the new folder. This was always a security system to prevent "network hijacking."
The experiment worked. It is time to integrate these blocks into the block generation algorithm of the new Prosus-Money.

from prosusmoney.

yerkobits avatar yerkobits commented on August 30, 2024

/src/Daemon/Daemon.cpp

//std::string config_folder = "blockchain";

#include <stdio.h>  // fopen(), fwrite(), fclose()
//los siguientes archivos se obtuvieron ejecutando: xxd -i binario.dat cabecera.h
#include "genesisBlockindexes.h"
    //extern const char blockindexes_dat[];
    //extern const size_t blockindexes_dat_len;
#include "genesisBlocks.h"
    //extern const char blocks_dat[];
    //extern const size_t blocks_dat_len;

FILE *archivo1;
FILE *archivo2;
archivo1 = fopen( (config_folder+"/"+"blockindexes.dat").c_str(), "rb+");
archivo2 = fopen( (config_folder+"/"+"blocks.dat").c_str(), "rb+");
if ( (archivo1 == NULL) && (archivo2 == NULL) ) {
logger(INFO, BRIGHT_WHITE) << "blockchain-file not found, creating genesis data...";
}


if(archivo1 == NULL) { // si archivo no existe, es creado.
    archivo1 = fopen( (config_folder+"/"+"blockindexes.dat").c_str(), "w");
    fwrite(blockindexes_dat, 1, blockindexes_dat_len, archivo1);
    fclose(archivo1);
}
if(archivo2 == NULL) { 
    archivo2 = fopen( (config_folder+"/"+"blocks.dat").c_str(), "w");
    fwrite(blocks_dat, 1, blocks_dat_len, archivo2);
    fclose(archivo2);
}

from prosusmoney.

yerkobits avatar yerkobits commented on August 30, 2024

Prosus Money v0.7.2-gui

from prosusmoney.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.