Git Product home page Git Product logo

5l1v3r1 / dotnet-core-blockchain-payment-solution Goto Github PK

View Code? Open in Web Editor NEW

This project forked from dpedwards/dotnet-core-blockchain-payment-solution

0.0 1.0 0.0 7.87 MB

.NET Core Blockchain Network & Blockchain Client + Xamarin Mobile Wallet App + QR Code based Payment Shop with wallet generator, transaction transmission, transaction over view, and wallet functionalities

License: MIT License

C# 31.34% HTML 16.41% CSS 1.41% JavaScript 50.83% Batchfile 0.02%

dotnet-core-blockchain-payment-solution's Introduction

LICENSE .NET Core Xamarin .NET Windows Forms Tip Me via PayPal

A blockchain is a growing list of records, called blocks. The blocks are linked using cryptography and each block contains a cryptographic hash of the previous block, transaction data, and a timestamp.

Projects

  • BlockChain
  • BlockChain Client
  • BlockchainPaymentShop
  • XamarinWallet
  • ProxyServer

Notable features

  • cryptography
  • process of creating blocks
  • process of chaining blocks
  • network & mining
  • wallet generator
  • make transaction
  • view transactions
  • wallet transactions
  • QR Code generator
  • unlock videos with mobile wallet by scanning QR Code and paying cryptocurrency on blockchain
  • proxy server
  • etc.

Notes to test the blockchain based payment system

There are 5 projects in this repository:

I. Blockchain

  1. Start a new instance of the BlockChain project in Visual Studio 2017+ from the BlockChain Payment Solution.
  • Blockchain is listening on localhost port 63385

You can edit the public and private key in CryptoCurrency.cs class:

  • Fixed blockchain public key for easy testing: 18jp31DcT3n5vsYHGVhhQa2qsvEve4EUoQ
  • Fixed blockchain private key for easy testing: L3aq7WPiSois3N7GxTr6ZSXMNdfbAZWNebiYvKK5hAUBCijk95rL

Edit client access in Startup.cs class by changing the policy:

Blockchain Pictures

Mine:

Add Node:

Blockchain Overview:

II. Blockchain Client

  1. Start a new instance of the BlockChain Client project in Visual Studio 2017+ if you want to generate new public or private keys, make transactions, view transactions by the blockchain listening on localhost port 63385 or show wallet transactions by adding a new public key.
  • Blockchain Client is listening on localhost port 3582.

Blockchain Client Pictures

Wallet Generator:

Make Transaction:

View Transactions:

Wallet Transactions:

III. Proxy Server

  1. Start a new instance of the Proxy Server in Visual Studio and select the IP Address on your running machine you execute these projects. You can check the correct IP Address by cmd ipconfig -all in Windows for example. The External Port must run on port 5000 and the Internal Port on port 1587.

Proxy Server Picture

3.1 Next access the URL in your browser on the IP Address of your running machine you execute these projects and add the port 5000. This URL will access by the running instances. For example: http://xxx.xxx.xxx.xxx:5000

IV. BlockChainPaymentShop

  1. Edit the applicationhost.config file in dotnet-core-blockchain-advanced\BlockChainPayment\.vs\config\ path and edit the following bindings by your own IP Address set by the Proxy Server in section 3:
    <binding protocol="http" bindingInformation="*:1587:localhost" />
    <binding protocol="http" bindingInformation="*:1587:xxx.xxx.xxx.xxx" />
!Edit the URI in Index.cshtml and QrGenerate.cshtml file in the BlockChainPaymentShop with the IP Address from your workmachine but don't change the ports 5000 or 43211!

Index.cshtml file:

QrGenerator.cshtml

Scan QR Code by XamarinWallet Android app to unlock a video:

Generate QR Code:

V. XamarinWallet Android mobile app

  1. Last activate the Android Developer features on your Android smartphone hardware and connect physically with a USB cable to your machine you running these projects. 5.1 Enable USB debugging option on your Android device. 5.2 Debug the XamarinWallet app in Visual Studio 2017+ with a USB cable connection to your workstation. 5.3 An instance of the mobile app should run on your Android device. 5.3.1 Next save the Public and the Private Keys by enter the SAVE button in the UI. A notification that the keys are updated should be shown. 5.3.2 Tab to the QR SCAN UI and enter the SCAN QR CODE button. 5.3.3 Now scan a QR Code from the BlockChainPaymentShop URL http://xxx.xxx.xxx:5000 with your Android smartphone hardware and enter the PAY button to pay over the blockchain payment system to unlock a video.

Update Public and Private Keys:

Activate cam and scan QR Code:

Unlock BlockChainPaymentShop videos:

If you enjoy this project, please consider supporting me for developing and maintaining it.

Support via PayPal

  • Support via ETH 0x331fa09bf9eb218b4c15de7e8bcdc5a83f34140f
  • Support via BTC 13KUoie3wnJtKVQ9bvmYuGX5Z2cdBmpstd
  • Support via XVG DNbzsWuRJ85nBRUYtY7muCVxSKQNKXMgk4

Contributing

Having trouble working with the project? Found a typo in the documentation? Interested in adding a feature or fixing a bug? Then by all means submit an issue or pull request. If this is your first pull request, it may be helpful to read up on the GitHub Flow first.

Pull Requests

When submitting a pull request:

  1. Clone the repo.
  2. Create a branch off of master and give it a meaningful name (e.g. my-awesome-new-feature).
  3. Open a pull request on GitHub and describe the feature or fix.

Credits

Creator

Davain Pablo Edwards

Requirements

Packages:

BlockChain Project

BlockChainClient Project

Xamarin-Wallet Project

BlockChainPaymentShop Project

ProxyServer Project


License

MIT License

Copyright (c) 2019 Davain Pablo Edwards

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

dotnet-core-blockchain-payment-solution's People

Contributors

dpedwards avatar

Watchers

 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.