Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

issueasset RPC call: blind flag not working (issuance transaction is always blinded) #535

Closed
lclc opened this issue Mar 24, 2019 · 4 comments

Comments

@lclc
Copy link
Contributor

lclc commented Mar 24, 2019

When using the issueasset RPC method with the blinding parameter (parameter #3) set to false the issuance transaction should have the issuance amount public visible, but it isn't.

What behavior did you expect?
That the amount of issued tokens is visible on the blockchain for everyone (also for other nodes).
Or in other words: that the transaction amount isn't blinded.

How reliably can you reproduce the issue, what are the steps to do so?
This happens everytime.

Example:
ubuntu@Liquid:~$ ./liquid-cli issueasset 42 0 false { "txid": "8b6211b69758d5d2715c2a10fe5bbbdc596691538ff52901ddf6ba1baaff16be", "vin": 0, "entropy": "28ea6b183fff47dd5f5c65ea20c1559ae57fb8de2900f2fffbfc4af021128624", "asset": "9cf578635538d5f5151727f194c825a39b3057a4b1c7b906b4c4046ae79b2f92", "token": "b10fde25c230cda4433ca2aaa4453bcbab7fd4a077f5aaaab965cf9a527ff19b" }

getrawtransactions shows that the amount is blinded:

{
  "hex": "...",
  "txid": "8b6211b69758d5d2715c2a10fe5bbbdc596691538ff52901ddf6ba1baaff16be",
  "hash": "e61e6208a8c6994878741350fbb478a6b8a52f38b2f565e0ebaddb36042f4e3a",
  "withash": "9c1ad5aca7cd11817f191ce50f3f7cbd64a2602023d28b268155c189c7b3f4a5",
  "size": 6524,
  "vsize": 2026,
  "version": 2,
  "locktime": 230304,
  "vin": [
    {
      "txid": "0e545cac1caae31a8771bda59ffbca27484b2766a6f104606307c02bb13099ea",
      "vout": 1,
      "scriptSig": {
        "asm": "3044022024dc83992cbd9ff7ff426730597adc9b82f3129a006988759f876282ffde4dc202202e56a42a3d53a08d84dfd88896246c362307706f394747c1704dbdcdb4bc091a[ALL] 033e8175ee3924eaa52c1fdf567f0345ffb005f4656e1c3adfcacd0b21656053a1",
        "hex": "473044022024dc83992cbd9ff7ff426730597adc9b82f3129a006988759f876282ffde4dc202202e56a42a3d53a08d84dfd88896246c362307706f394747c1704dbdcdb4bc091a0121033e8175ee3924eaa52c1fdf567f0345ffb005f4656e1c3adfcacd0b21656053a1"
      },
      "is_pegin": false,
      "scriptWitness": [
      ],
      "pegin_witness": [
      ],
      "issuance": {
        "assetBlindingNonce": "0000000000000000000000000000000000000000000000000000000000000000",
        "assetEntropy": "28ea6b183fff47dd5f5c65ea20c1559ae57fb8de2900f2fffbfc4af021128624",
        "isreissuance": false,
        "token": "b10fde25c230cda4433ca2aaa4453bcbab7fd4a077f5aaaab965cf9a527ff19b",
        "asset": "9cf578635538d5f5151727f194c825a39b3057a4b1c7b906b4c4046ae79b2f92",
        "assetamount": 42.00000000
      },
      "sequence": 4294967294
    }
  ],
  "vout": [
    {
      "value-minimum": 0.00000001,
      "value-maximum": 687.19476736,
      "ct-exponent": 0,
      "ct-bits": 36,
      "amountcommitment": "08011db5851805572d0ed358d90ad00ee290ec560c0caeeb9703a3a896dc4d52e1",
      "assetcommitment": "0a11560906ac83bd115681a2230b652f4ca8b3d9a263bc8f8350ed25fbe520228e",
      "n": 0,
      "scriptPubKey": {
        "asm": "OP_DUP OP_HASH160 c86ec572663a002bbad77484177c6074e0a1ea8c OP_EQUALVERIFY OP_CHECKSIG",
        "hex": "76a914c86ec572663a002bbad77484177c6074e0a1ea8c88ac",
        "reqSigs": 1,
        "type": "pubkeyhash",
        "addresses": [
          "QFYAy5a85ni1FDVuUwREqega33Ngu9VhMk"
        ]
      }
    }, 
    {
      "value-minimum": 0.00000001,
      "value-maximum": 687.19476736,
      "ct-exponent": 0,
      "ct-bits": 36,
      "amountcommitment": "08ec15cc38ad11db252e5babd6ee72a9206351871b9da030211d091df6ff460ae6",
      "assetcommitment": "0b634512d2be57f256b2285f52d6264b2ab8c049adc96c459e418ca746fe7609f9",
      "n": 1,
      "scriptPubKey": {
        "asm": "OP_DUP OP_HASH160 8e3aca803163707843ad60c0be724eba9515077f OP_EQUALVERIFY OP_CHECKSIG",
        "hex": "76a9148e3aca803163707843ad60c0be724eba9515077f88ac",
        "reqSigs": 1,
        "type": "pubkeyhash",
        "addresses": [
          "QAERWJTWvFimRJTXzrNWuThiMkr3BqGYir"
        ]
      }
    }, 
    {
      "value": 0.00002027,
      "asset": "6f0279e9ed041c3d710a9f57d0c02928416460c4b722ae3457a11eec381c526d",
      "n": 2,
      "scriptPubKey": {
        "asm": "",
        "hex": "",
        "type": "fee"
      }
    }
  ]
}

Also the blockstream.info blockexplorer shows the amount as hidden: https://blockstream.info/liquid/tx/8b6211b69758d5d2715c2a10fe5bbbdc596691538ff52901ddf6ba1baaff16be

Version v3.14.1.23-72ae7d304

I quickly scrolled through the code but couldn't yet find the problem.

@instagibbs
Copy link
Collaborator

instagibbs commented Mar 24, 2019 via email

@lclc
Copy link
Contributor Author

lclc commented Mar 24, 2019

Sorry, I was confused for a moment. The amount is shown there.

@lclc lclc closed this as completed Mar 24, 2019
@instagibbs
Copy link
Collaborator

instagibbs commented Mar 24, 2019 via email

@instagibbs
Copy link
Collaborator

instagibbs commented Mar 24, 2019 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants