Skip to content

Instantly share code, notes, and snippets.

View maxidev's full-sized avatar

Maxi maxidev

View GitHub Profile
@maxidev
maxidev / walletGen.js
Created October 15, 2014 02:34
Wallet Generation Code for JCC 2014 Presentation.
// Bitcoin in Depth: A Cryptographycal Journey
// JCC 2014
//Importo librerías
var bitcoin = require('bitcoinjs-lib');
var colors = require('colors');
//Creo el par clave pública/privada usando
//criptografía asimétrica, particularmente Curva Elíptica
var key = bitcoin.ECKey.makeRandom();
Verifying that +maxidev is my openname (Bitcoin username). https://onename.io/maxidev
upstream project {
server 22.22.22.2:3000;
server 22.22.22.3:3000;
server 22.22.22.5:3000;
}
server {
listen 80;
location / {
@maxidev
maxidev / txvalue.js
Last active August 29, 2015 14:16
Determine TX value using Chain's getTransaction method.
var getValues = function(hash, callback) {
var is_input_info, is_output_info;
var is_input = false;
var is_output = false;
var satoshi = 100000000;
for (var j = 0; j < hash.inputs.length; j++){
for (var k = 0; k < hash.inputs[j].addresses.length; k++){
if(hash.inputs[j].addresses[k] == wallet){

Keybase proof

I hereby claim:

  • I am maxidev on github.
  • I am maxidev (https://keybase.io/maxidev) on keybase.
  • I have a public key whose fingerprint is 2A35 5B4B 58E4 3223 C611 2F20 0DFF EC9C E4D9 92DB

To claim this, I am signing this object:

server {
listen 80;
server_name website.com;
location / {
proxy_pass http://localhost:1337;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection 'upgrade';
proxy_set_header Host $host;

Keybase proof

I hereby claim:

  • I am maxidev on github.
  • I am maxidev (https://keybase.io/maxidev) on keybase.
  • I have a public key whose fingerprint is 9849 3304 C8EC C9C1 0DFB 293C 8A97 C544 5008 4A4D

To claim this, I am signing this object:

@maxidev
maxidev / mongo_backup.sh
Last active May 23, 2017 20:31 — forked from sheharyarn/mongo_backup.sh
Mongodump Shell Script for Cronjob
#!/bin/bash
MONGO_DATABASE="your_db_name"
APP_NAME="your_app_name"
MONGO_HOST="127.0.0.1"
MONGO_PORT="27017"
TIMESTAMP=`date +%F-%H%M`
MONGODUMP_PATH="/usr/bin/mongodump"
BACKUPS_DIR="/home/username/backups/$APP_NAME"
@maxidev
maxidev / project-bitsign.js
Created January 31, 2018 01:11
How to integrate Bitsign library into your project
//Require Bitsign's library
const bitsignjs = require('bitsignjs');
//Instantiate the library with your access token
let api = bitsignjs.init('<your_token>');
@maxidev
maxidev / status.js
Created January 31, 2018 01:17
Blockchain Status call
//Require Bitsign's library
const bitsignjs = require('bitsignjs');
//Instantiate the library with your access token
let api = bitsignjs.init('d2..83');
api.eth.status().then(data => console.log(data));