Giter Club home page Giter Club logo

elementsproject.github.io's People

Contributors

andreabonel avatar dgpv avatar erikdesmedt avatar lclc avatar lucasmoten avatar mword avatar philippem avatar romanz avatar shesek avatar stevenroose avatar wintercooled avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

elementsproject.github.io's Issues

Inconsistent info about unblinded address prefixes

https://elementsproject.org/elements-code-tutorial/confidential-transactions:

In the Elements protocol blinded addresses start with “CTE” and unblinded addresses start with a “2”,

https://elementsproject.org/features/confidential-transactions/addresses:

As you can see the unconfidential P2PKH address starts with a Q. P2SH start with H

Maybe the info about "2" prefix is out of date ?

Also it is not clear from the pages if it is possible to have multisignature confidential address. It would be good to include info if it is possible and if not, why.

Address prefix is not CTE any more

e.g. getnewaddress returns something like:
AzpkfveJCn2frbBWqxFBTsbkDWfNAUo1Q3zSU7Fyt8VQ9FdRFFZvk5sGJSWk2AGnxYmyoxwFexuWebku

In the confidential-transactions page we refer to:

"In the Elements protocol blinded addresses start with “CTE” and unblinded addresses start with a “2”, so we can see that the address we have just generated for Bob is indeed a blinded, confidential address."

...which now appears to be incorrect.

Spendable coins and "Anyone can spend"

On elements tutorial: Basic operations

Explanation on "Anyone-can-spend" was great, especially for users who have not done bitcoin script..
However paragrah below is not so clear to me:

Let’s drain the “anyone-can-spend” values and send half the assets to a new address generated by each Elements node. We’ll also need to generate more than 100 blocks so that the coins are spendable (a requirement of the maturity rule for spending coinbase rewards):

Any reason for picking 100 blocks and not 1 block?
What is "the maturity rule for spending coinbase rewards" referring to?

make install but then refer to non-installed binaries

Site says to make install in the setting up elements page but then in setting up environment the alias links point o the elements src make output.
Probably can just remove make install then, tidier for updates etc.

Challenges following the tutorial

I'm attempting to set this up in a virtual machine following the tutorial. My VM is allocated ample storage and memory and running Ubuntu 20.04.2 LTS as the underlying operating system. The PPA repository for installing Bitcoin no longer seems to work, so I went ahead and installed Bitcoin from https://bitcoincore.org/bin/bitcoin-core-0.21.1/bitcoin-0.21.1-x86_64-linux-gnu.tar.gz, checking sha256 and signatures.

After installing Elements and setting up work environment, the following commands fail as there is no wallet, as one is not created by default.

Give them a few seconds to start up and then check they are running:

e1-cli getwalletinfo
e2-cli getwalletinfo

To get past this, I simply create wallets for both

e1-cli createwallet ""
e2-cli createwallet ""

And also for bitcoin

b-cli createwallet ""

Advancing forward in the tutorial to the next page, Using Elements to perform basic operations. From the tutorial the expectation is for the wallets to show 21 million bitcoin due to anyone can spend. But the balance is 0. With no balance on regtest, I can't proceed with sending to addresses generated by elements due to Insufficient funds.

So then since this is regtest, I do this to get 5000 coins available, and more in the immature balance

b-cli -generate 200

This doesn't help get access to initialfreecoins but may be viable to use for pegin

Simplify. Attempting just the standalone

The same is true if I take bitcoin out of the equation. Using just the standalone blockchain guidance found here: https://elementsproject.org/elements-code-tutorial/blockchain

# Args
STANDALONEARGS=("-validatepegin=0" "-defaultpeggedassetname=newasset" "-initialfreecoins=100000000000000" "-initialreissuancetokens=200000000")

# Startup 
e1-dae ${STANDALONEARGS[@]}

# Have to create wallet before viewing it
e1-cli createwallet ""

# Has zero balance, but shows asset name as `newasset` as anticipated
e1-cli getwalletinfo

# Look at transaction in first block from startup initialfreecoins
tx1=`e1-cli getblock $(e1-cli getblockhash 0) | jq -r .tx[1]`
e1-cli decoderawtransaction `e1-cli getrawtransaction $tx1`

I can see the 1,000,000 newasset created in vout, as well as the 2 for reissuance.

How can I claim the coins to the wallet to test with?

RPC Docs menu item cause page shift

When you select RPC Docs the page content shifts.

I think this is because it uses a different div (class page and not class post). But this is also probably related to the index files being .html but containing markdown and not .md files.

Typo in namespace - MVC dotnet web application

Tutorial mentions to paste:


using System;

namespace ExampleMVC.Models
{
    public class ExampleNodeInfo
    {
        public string Balance { get; set; }
        
        public string Message { get; set; }
        //Add whatever other properties you want here
    }
}

Had to change to:

using System;

namespace ElementsMVC.Models
{
    public class ExampleNodeInfo
    {
        public string Balance { get; set; }
        
        public string Message { get; set; }
        //Add whatever other properties you want here
    }
}

Otherwise dotnet would not run with error:
Controllers/HomeController.cs(31,25): error CS0246: The type or namespace name 'ExampleNodeInfo' could not be found (are you missing a using directive or an assembly reference?)

features/confidential-transactions shows values for CT_BITS=32, but now CT_BITS is 52

https://github.com/ElementsProject/elementsproject.github.io/blame/master/features/confidential-transactions/index.md#L93-L95

The values in the referenced lines refer to old parameters, now (after ElementsProject/elements#834 was merged) CT_BITS allow to cover the whole range of 21M expressible on Bitcoin. Also, as I understand, min_value for a long time was 1, allowing to blind values from 1 satoshi (https://github.com/ElementsProject/elements/blob/95602ec21f0b3ec4a58f36bbc1c53bb757c97701/src/blind.cpp#L184)

TLS Certificate invalid: www.elementsproject.org

The current Let's Encrypt TLS certificate for www.elementsproject.org is issued to www.blockstream.com and is throwing errors in Chrome, Safari, curl and presumably other browsers. Tested on macOS.

curl -v https://www.elementsproject.org/
*   Trying 35.193.30.29...
* Connected to www.elementsproject.org (35.193.30.29) port 443 (#0)
* ALPN, offering http/1.1
* Cipher selection: ALL:!EXPORT:!EXPORT40:!EXPORT56:!aNULL:!LOW:!RC4:@STRENGTH
* successfully set certificate verify locations:
*   CAfile: /opt/local/share/curl/curl-ca-bundle.crt
  CApath: none
* TLSv1.2 (OUT), TLS header, Certificate Status (22):
* TLSv1.2 (OUT), TLS handshake, Client hello (1):
* TLSv1.2 (IN), TLS handshake, Server hello (2):
* TLSv1.2 (IN), TLS handshake, Certificate (11):
* TLSv1.2 (IN), TLS handshake, Server key exchange (12):
* TLSv1.2 (IN), TLS handshake, Server finished (14):
* TLSv1.2 (OUT), TLS handshake, Client key exchange (16):
* TLSv1.2 (OUT), TLS change cipher, Client hello (1):
* TLSv1.2 (OUT), TLS handshake, Finished (20):
* TLSv1.2 (IN), TLS change cipher, Client hello (1):
* TLSv1.2 (IN), TLS handshake, Finished (20):
* SSL connection using TLSv1.2 / ECDHE-RSA-AES256-GCM-SHA384
* ALPN, server accepted to use http/1.1
* Server certificate:
* 	 subject: CN=www.blockstream.com
* 	 start date: 2018-12-01 19:00:10 GMT
* 	 expire date: 2019-03-01 19:00:10 GMT
* 	 subjectAltName does not match www.elementsproject.org
* SSL: no alternative certificate subject name matches target host name 'www.elementsproject.org'
* Closing connection 0
* TLSv1.2 (OUT), TLS alert, Client hello (1):
curl: (51) SSL: no alternative certificate subject name matches target host name 'www.elementsproject.org'

https://www.elementsproject.org - invalid certificate for www.blockstream.com.

Serial Number: 03 B2 9A FE 11 E9 0C 25 09 41 BA CF 68 D7 09 50 83 2A

https://elementsproject.org - valid cert

Serial Number: 03 78 2B 25 D1 DC 36 E6 4C FA DA 0C 6B CA 05 C8 79 C1

echo command missing to display output for signature property - Block signing

Again no big deal but for clarify I would change below.


Checking the output of that:

COMPLETE=$(echo $BLOCKRESULT | jq '.complete' | tr -d '"')
SIGNBLOCK=$(echo $BLOCKRESULT | jq '.hex' | tr -d '"')

We see a result of “True” for the “complete” property as we have signatures from enough keys to satisfy the 2 of 2 requirement. So “complete” in this context means “has enough signatures for the ‘n of m’ multi-sig to be valid”.

Now submit the block, it doesn’t matter who does this as long as they have a signed and valid block hex (which we have stored in the ‘SIGNBLOCK” variable from the results of calling “combineblocksigs”):

e2-cli submitblock $SIGNBLOCK


Checking the output of that:

COMPLETE=$(echo $BLOCKRESULT | jq '.complete' | tr -d '"')
echo $COMPLETE

We see a result of “True” for the “complete” property as we have signatures from enough keys to satisfy the 2 of 2 requirement. So “complete” in this context means “has enough signatures for the ‘n of m’ multi-sig to be valid”.

Now extract and submit the block, it doesn’t matter who does this as long as they have a signed and valid block hex (which we have stored in the ‘SIGNBLOCK” variable from the results of calling “combineblocksigs”):

e2-cli submitblock $SIGNBLOCK
SIGNBLOCK=$(echo $BLOCKRESULT | jq '.hex' | tr -d '"')

Tidy dependancies

we don't need qt5 dependancies and should ./configure using --without-gui flag really.

I can't actually build elements from source at the minute - which is another issue I will log elsewhere

generate depreciated in v0.18

Will have to either change elements asset_tutorial elements.conf to include
deprecatedrpc=generate
or add -deprecatedrpc=generate to e1-dae and e2-dae start up here. (prefer both to be sure)

Sample wallet address hardcoded in tutorial script - Issuing Assets

In script runtutorial.sh a sample address is hardcoded which will result in line not working.

###### ASSETS #######

e1-cli getwalletinfo

e1-cli getwalletinfo bitcoin

e1-cli dumpassetlabels

e1-cli getwalletinfo b2e15d0d7a0c94e4e2ce0fe6e8691b9e451377f6e46e8045a86f7c4b5d4f0f23

Could be changed to

###### ASSETS #######

e1-cli getwalletinfo

e1-cli getwalletinfo bitcoin

e1-cli dumpassetlabels

e1-cli getwalletinfo $(e1-cli dumpassetlabels | jq '.bitcoin' | tr -d '"')

Some features on homepage do not link to a description.

The following do not link to any details:

Schnorr Signature Validation
Signature Covers Value

Are descriptions needed?

Also - things like Confidential Transactions link to tutorial explanations and not their own page, which could be useful.

Sendtoaddress cli command generates a string, not clear what it is

No biggie but when sending an asset to e.g Bob as part of tutorial : issuing-assets
A string is generated, would be nice to know what it is

 e1-cli sendtoaddress $E2DEMOADD 10 "" "" false Prepaid-Credit-Mobile
**cc6408d0070bc87898fd4df2dc88f90a9660d901920391d7fdf74645f5b87f92**

Same comment when you use generate command

e1-cli generate 1
[
  "**512356e0179a3f122ee2fb7626e89ac2130d78b3584985ab28da1ec0fad4fdac**"
]

Add features page for CT, AI etc.

Add a new features page with sublinks to give brief overview of:

asset-issuance
confidential-transactions
deterministic-pegs
signed-blocks

opcodes?

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.