Code Monkey home page Code Monkey logo

openbank's Introduction

OpenBank

OpenBank is a Laravel based web application that you can use to keep track of your BitCoin public keys, your total balance and so forth. All the data is collected in realtime and will be shown to you on its web interface.

Screenshot

This is a screenshot of my instance running on a Raspberry Pi.

Screenshot

Safe

The database only stores the password you're using to access your OpenBank instance and your public keys, no sensitive data will be leaked even if compromised. Moreover if you install it on a Raspberry Pi running on your home network, you won't leak your ip address to a third entity.

How does it work

All data is updated in realtime using two different API, one job will get the current price every minute using the bitcoinaverage.com API while your total balance is updated using the blockonomics.co API.

IMPORTANT NOTE ABOUT XPUB

If you're adding an xPub key with more than 50 addresses bound to it, you'll need to get an API key from blockonomics and put it in your settings panel. Make sure you add all your addresses/keys to the wallet watcher service or else it will appear with 0 balance.

Installation

1. Checkout this git repository to your server.
git clone https://github.com/evilsocket/openbank.git
2. Install dependencies.

For details about installing composer see Getcomposer.org.

 cd openbank
 composer install
3. Setup environment.

Copy .env.example to .env and edit to your needs.

4. Fix permissions.

Make sure the storage directory is writable for your web server.

5. Initialize database.
php artisan key:generate
php artisan migrate
php artisan db:seed --class=CurrenciesTableSeeder
6. Create the cronjob

Install the needed cronjob:

*/1 * * * * /usr/bin/php /var/www/openbank/www/artisan schedule:run
7. Register.

Open OpenBank in your browser, register your account and enjoy.

Sample NGINX Configuration

server {
  listen       80;
  server_name  ~^(\w*)\.?openbank\.io$;

  root /var/www/openbank.io/www/public;
  access_log /var/www/openbank.io/access.log;
  error_log /var/www/openbank.io/error.log;

  index index.php index.html index.htm;

  location / {
    try_files $uri $uri/ /index.php$is_args$args;
  }


  location ~ \.php$
  {
    try_files $uri /index.php =404;
    fastcgi_pass 127.0.0.1:9000;
    fastcgi_index index.php;
    fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
    fastcgi_param PATH_INFO $fastcgi_script_name;
    include /etc/nginx/fastcgi_params;
  }
}

Sample Apache .htaccess Configuration

RewriteEngine On

<IfModule mod_rewrite.c>
    <IfModule mod_negotiation.c>
        Options -MultiViews
    </IfModule>

    RewriteEngine On
    RewriteCond %{THE_REQUEST} ^GET\ /public/ [NC]
    RewriteRule ^public/(.*)$ $1 [L,R=301,NE]

    RewriteRule ^(.*)$ public/$1 [L,NC]
    #RewriteRule ^((?!public/).*)$ public/$1 [L,NC]
</IfModule>

<Files  ~ "\.env$">
	Order allow,deny
	Deny from all
</Files>

License

This software is released under the GNU 3 license.
Copyleft of Simone 'evilsocket' Margaritelli
https://www.evilsocket.net

openbank's People

Contributors

blackout314 avatar evilsocket avatar xqus avatar

Watchers

 avatar  avatar

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.