Social Icons

Saturday, February 02, 2019

Test Ether Faucet : "Hello world" kind SMART CONTRACT

1.       Smart Contracts are self-executing contractual states, stored on the blockchain, which nobody controls and therefore everyone can trust.Continuing ahead with the earlier post wherein we created few test ethers from the ropsten test network and then transferred few back to create some transactions.In this post we move further and create a small smart contract.

First move to https://faucet.metamask.io/

Once you connect the same with your account,your will find an open code by default.Since just the beginning,we simply delete and create a fresh new page to insert the contract code in as seen below :

 Blank page as seen below :



Find the code of the file faucet.sol

 copy the code...and save the file as faucet.sol
 code pasted

 Now the time to RUN
 Do a small change...amend the solidity program version like I have done to 5.1 and then also it asks to amend public to external
 Followed by submit
 Now time to deploy the same....
 











Wednesday, January 23, 2019

Transactions in METAMASK:Ropsten Test Network Ethereum

1. While at https://anupriti.blogspot.com/2019/01/metamask-extension-in-chromeinstallation.html we have installed metamask,now in this post we do a transaction of ethereum.While at the beginning learning stage we ideally should not be playing with real ethers,so there is a provision to get test ethers and do some dummy transactions to get a feel of how it actually works.

Firstly,we change the network choice from the Main Ethereum Network to Ropsten Test Network as seen in the screen shot below:
 Then we visit https://faucet.metamask.io/
 Simply request ether.I requested twice. :-)
 So,I got two ethers
In the transactions part,we see the links and while we click on any,we get to see the details of the transaction that reflect along with other details live from the ropsten test network explorer
 The transactions details as below :
 The details of Gas to be debited as seen below :
 So,now minus 1 ether and some gas,I am left with a rounded off 1 ether(not exactly one ether,its minus gas)
 The details seen in the Block explorer....as below

METAMASK extension in Chrome:Installation

MetaMask is a bridge that allows one to visit the distributed web of Ethereum in the browser. It allows anyone to run Ethereum dApps right in  browser without running a full Ethereum node.MetaMask includes a secure identity vault, providing a user interface to manage your identities on different sites and sign blockchain transactions.Below screen shots are self explanatory for installation of MetaMask in chrome browser.

Goto the extension link at google chrome store at https://chrome.google.com/webstore/category/extensions
 Search for MetaMask
 Add the extension as seen in the screen shot below
 Welcome screen of MetaMask
 Create your Password

 Click accept



Download your phrase and store it as deemed appropriate secret location,duly encrypted ...since this single phrase will be the key to fiddle with your ethers ahead


 Installation part complete

Sunday, January 13, 2019

How to install Graylog on Ubuntu 18.04.1 LTS ?

1.    Graylog2 is a powerful log management and analysis tool that has many use cases, from monitoring SSH logins and unusual activity to debugging applications. It is based on Elasticsearch, Java, MongoDB, and Scala.The installation is not exactly to say simple since a lot of integration goes behind involving different applications including Elasticsearch, Java, MongoDB, and Scala. But in few steps and little modifications in default configuration files,the same can be run with ease.

2.   Below are terminal commands with screen shots to achieve the same running

Firstly,the system that I m installing the GRAYLOG on ..the specs are as below

 Then coming to the root terminal...from where all the commands will be executed for installation.

$ apt update && apt upgrade

 Next we install the JDK module

$ apt install apt-transport-https uuid-runtime pwgen openjdk-8-jre-headless

 This is followed by installing ELASTICSEARCH

$ wget -qO - https://artifacts.elastic.co/GPG-KEY-elasticsearch | apt-key add -

 $ echo "deb https://artifacts.elastic.co/packages/5.x/apt stable main" | sudo tee -a /etc/apt/sources.list.d/elastic-5.x.list


Next we install
 $ apt update && apt install elasticsearch

This is followed by enabling the service and starting



$   systemctl enable elasticsearch
$   systemctl start elasticsearch

Amend cluster.name as graylog

 Followed by these lines at the EOF

script.inline: false
script.indexed: false
script.file: false
This is followed by

$ systemctl restart elasticsearch
 
Now install the key

$ apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv 2930ADAE8CAF5059EE73BB4B58712A2291FA4AD5 
 Then MANGODB repository

$ echo "deb [ arch=amd64,arm64 ] https://repo.mongodb.org/apt/ubuntu xenial/mongodb-org/3.6 multiverse" | sudo tee /etc/apt/sources.list.d/mongodb-org-3.6.list
 Install mongodb

$ apt update && apt install mongodb-org


$   systemctl start mongod
$    systemctl enable mongod

$ wget https://packages.graylog2.org/repo/packages/graylog-2.5-repository_latest.deb
$ dpkg -i graylog-2.5-repository_latest.deb
$ apt-get update
$ apt-get install graylog-server
 

After installation of the Graylog package is finished, we need to edit the configuration file to set our password in it and we do it using pwgen command 

$ pwgen -N 1 -s 96
 $ echo -n your_password | sha256sum
We place the above generated output in the conf file as seen below : 





Powered By Blogger