Git Product home page Git Product logo

keeper-wallet / keeper-wallet-extension Goto Github PK

View Code? Open in Web Editor NEW
66.0 14.0 44.0 63.66 MB

Your entry point to the Waves blockchain and Waves-powered web services

Home Page: https://keeper-wallet.app

License: Other

JavaScript 0.78% TypeScript 92.14% Stylus 2.53% CSS 4.52% EJS 0.03%
browser-extension blockchain dapp-developers blockchain-wallet cryptocurrency-wallet crypto-wallet cryptocurrencies

keeper-wallet-extension's People

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  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  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

keeper-wallet-extension's Issues

[BUG] Failed to construct URL

Describe the bug
A clear and concise description of what the bug is.

When interacting with a canvas, I am seeing that error in the console + the code injected can break some canvas application I am interacting with

To Reproduce
Steps to reproduce the behavior:

  1. Go to 'http://draw.io/'
  2. Add a svg image element to the canvas
  3. Double click the element on the canvas
  4. See error

Expected behavior
A clear and concise description of what you expected to happen.

I can see that this is coming from the checkForPaymentApiLink function which is checking the href property which exists in a element but also in the SVGAnimatedString element.

Screenshots
If applicable, add screenshots to help explain your problem.

Desktop (please complete the following information):

  • OS: OSX
  • Browser/JVM chrome
  • Version 1.2.1

Additional context
Add any other context about the problem here.

[QUESTION] - where are the chainID settings?

I'm trying to use the Waves Keeper wallet for a custom (permissioned) clone of Waves. The custom options, although present in the code, don't appear to be visible in the interface.

Is it possible to override the chainID of 1 in the wallet anywhere? I can change the network byte for the mainnet from W to some other character in the code, but I can't see anywhere that I can specify that the first byte of the public address key should be something other than 0x01.

Wallet button points to obsolete client

Describe the bug
Clicking on button WALLET in Waves Keeper forwards to the obsolete client. Please change it to waves.exchange.

To Reproduce

  1. Enter WAVES Keeper
  2. Click on 'Wallet'
  3. You are redirected to obsolete client

Expected behavior
Should redirect to waves.exchange.

Screenshots

Desktop (please complete the following information):

  • OS: WINDOWS 10
  • Browser: Bravo
  • Version: Version 1.1.20 Chromium: 79.0.3945.74 (Official Build) (64-bit)

[BUG] Repeated "premature close" errors when using wallet

Describe the bug
The extension raises premature close error when clicking outside the wallet extension pane

To Reproduce
Steps to reproduce the behavior:

  1. open waves keeper and set up an account
  2. go to chrome://extensions and keep an eye on the Waves extension pane
  3. when on the account pane, click anywhere outside the extension pane so it disappears
  4. an error button appears inthe extension pane, click on it
  5. see the screenshot below for the error

Expected behavior
Extensions should not raise errors during normal operation.

Screenshots
image

Environment
Waves Keeper 2.0.0 zip download
Linux 5.11.0-43-generic #47~20.04.2-Ubuntu SMP Mon Dec 13 11:06:56 UTC 2021 x86_64 x86_64 x86_64 GNU/Linux
Brave V1.33.106 and Chrome Version 96.0.4664.110 (Official Build) (64-bit)

Is auth method returning signed data?

The auth API docs says that auth will return signed data in a field named signature.

I called WAVES KEEPER API auth() to authorize users on my website
but if i print the return data on console i get the following. I don't see any signature field.

Code to authorize is:

function startApp(state)
            {
                const authData = { 
                    data: "testtest",
                };
                
                WavesKeeper.auth(authData)
                    .then(auth => { 
                        console.log(auth);
                       ....                     
                    }).catch(error => {
                        console.error(error); // displaying the result on the console
                        /*...processing errors */
                    })
            }   

Output:

statistics: 200 {
 initialized: true,
 locked: false,
 account: {
  …},
 network: {
  …},
 messages: Array(6),
 …
}
account: address: "3P......"
balance: {
 available: "2468518915",
 leasedOut: "0",
 network: "mainnet"
}
name: "Blackbot"
network: "mainnet"
networkCode: "W"
publicKey: "7qwuz....."
type: "seed"
__proto__: Objectconstructor: ƒ Object() hasOwnProperty: ƒ hasOwnProperty() isPrototypeOf: ƒ isPrototypeOf() propertyIsEnumerable: ƒ propertyIsEnumerable() toLocaleString: ƒ toLocaleString() toString: ƒ toString() valueOf: ƒ valueOf() __defineGetter__: ƒ __defineGetter__() __defineSetter__: ƒ __defineSetter__() __lookupGetter__: ƒ __lookupGetter__() __lookupSetter__: ƒ __lookupSetter__() get __proto__: ƒ __proto__() set __proto__: ƒ __proto__() initialized: truelocked: falsemessages: (6)[{
 …}, {
 …}, {
 …}, {
 …}, {
 …}, {
 …}] 0: id: "b35061e0-1612-4352-81a9-82bf9d2530e2"
status: "signed"
__proto__: Object1: {
 id: "ad38c2f6-2e02-4830-91f6-7feabbbb581f",
 status: "signed"
}
2: {
 id: "e0a97def-d888-4f33-9a1b-dd12f8e3ba77",
 status: "signed"
}
3: {
 id: "1e940681-2299-487a-91c6-e3dcdbbb5b2b",
 status: "signed"
}
4: {
 id: "be367a0f-1bb3-413d-85bf-38de17999092",
 status: "signed"
}
5: {
 id: "eb3e47b2-afbd-4ab8-8a3e-97c942647ace",
 status: "signed"
}
length: 6 __proto__: Array(0) network: {
 code: "W",
 server: "https://nodes.wavesplatform.com/",
 matcher: "https://matcher.wavesplatform.com/"
}
code: "W"
matcher: "https://matcher.wavesplatform.com/"
server: "https://nodes.wavesplatform.com/"
__proto__: ObjecttxVersion: {
 3: Array(1),
 4: Array(1),
 5: Array(1),
 6: Array(1),
 7: Array(2),
 8: Array(1),
 9: Array(1),
 10: Array(1),
 11: Array(1),
 12: Array(1),
 13: Array(1),
 14: Array(1),
 15: Array(1),
 16: Array(1),
 1000: Array(1),
 1001: Array(1),
 1002: Array(2),
 1003: Array(1),
 1004: Array(1)
}
3: Array(1) 

Другие токены

Было бы не плохо что бы была возможность добавлять другие токены на платформе wavesplatform и всеми ими управлять.

без этого приложение не полноценно.

Launch error

Step:

  1. npm install
  2. npm run start
    image
    image

OriginController not found in directory
How to solve the problem and run?

[BUG]

Keeper does not accept this network matcher https://testnet.waves.exchange/api/v1/forward/matcher/matcher

Describe the bug
A clear and concise description of what the bug is.

To Reproduce
Steps to reproduce the behavior:

  1. Go to '...'
  2. Click on '....'
  3. Scroll down to '....'
  4. See error

Expected behavior
A clear and concise description of what you expected to happen.

Screenshots
If applicable, add screenshots to help explain your problem.

Desktop (please complete the following information):

  • OS: [e.g. Debian/Ubuntu/iOS]
  • Browser/JVM [e.g. chrome, safari]
  • Version [e.g. 22]

Additional context
Add any other context about the problem here.

[BUG] i18n useSuspense error

Describe the bug
The extension raises a "react-i18next:: It seems you are still using the old wait option, you may migrate to the new useSuspense behaviour." warning when a new account is created.

To Reproduce
Steps to reproduce the behavior:

  1. download and build waves.keeper-2.0.0
  2. install from chrome://extensions in developer mode
  3. add pasword and check t&c boxes
  4. create new account
  5. see an "Error" button appear in the Waves Keeper pane in the extensions page, and click on it
  6. the error is "react-i18next:: It seems you are still using the old wait option, you may migrate to the new useSuspense behaviour."

You can also see the error in the console if you inspect Waves Keeper while running it.

Expected behavior
No errors or warnings to be raised when an account is created

Screenshots
image

Environment
Waves Keeper 2.0.0 zip download
Linux 5.11.0-43-generic #47~20.04.2-Ubuntu SMP Mon Dec 13 11:06:56 UTC 2021 x86_64 x86_64 x86_64 GNU/Linux
Brave V1.33.106 and Chrome Version 96.0.4664.110 (Official Build) (64-bit)

Dependency Dashboard

This issue lists Renovate updates and detected dependencies. Read the Dependency Dashboard docs to learn more.

Rate-Limited

These updates are currently rate-limited. Click on a checkbox below to force their creation now.

  • chore(deps): update dependency @pmmmwh/react-refresh-webpack-plugin to v0.5.13
  • chore(deps): update dependency @types/color-hash to v1.0.5
  • chore(deps): update dependency @types/prismjs to v1.26.3
  • chore(deps): update dependency @types/qrcode to v1.5.5
  • chore(deps): update dependency @types/react-transition-group to v4.4.10
  • chore(deps): update dependency @types/redux-logger to v3.0.13
  • chore(deps): update dependency @types/w3c-web-usb to v1.0.10
  • chore(deps): update dependency @types/webextension-polyfill to v0.10.7
  • chore(deps): update dependency postcss-loader to v7.3.4
  • chore(deps): update dependency rimraf to v5.0.5
  • chore(deps): update dependency source-map-loader to v4.0.2
  • chore(deps): update dependency stylelint-order to v6.0.4
  • chore(deps): update dependency zip-a-folder to v2.0.2
  • fix(deps): update dependency amazon-cognito-identity-js to v6.3.12
  • fix(deps): update dependency react-redux to v8.1.3
  • fix(deps): update dependency react-virtualized-auto-sizer to v1.0.24 (react-virtualized-auto-sizer, @types/react-virtualized-auto-sizer)
  • fix(deps): update dependency react-window to v1.8.10 (react-window, @types/react-window)
  • fix(deps): update dependency tiny-invariant to v1.3.3
  • chore(deps): update dependency @ledgerhq/hw-transport-webusb to v6.28.6
  • chore(deps): update dependency @types/node to v18.19.31
  • chore(deps): update dependency browserslist to v4.23.0
  • chore(deps): update dependency css-loader to v6.11.0
  • chore(deps): update dependency esbuild to ^0.20.0
  • chore(deps): update dependency esbuild-register to v3.5.0
  • chore(deps): update dependency eslint to v8.57.0
  • chore(deps): update dependency eslint-plugin-mocha to v10.4.3
  • chore(deps): update dependency expect-webdriverio to v4.13.0
  • chore(deps): update dependency html-webpack-plugin to v5.6.0
  • chore(deps): update dependency lightningcss to v1.24.1
  • chore(deps): update dependency mini-css-extract-plugin to v2.9.0
  • chore(deps): update dependency mocha to v10.4.0 (mocha, @types/mocha)
  • chore(deps): update dependency postcss-preset-env to v9.5.9
  • chore(deps): update dependency prettier to v3.2.5
  • chore(deps): update dependency react-router-dom to v6.23.0
  • chore(deps): update dependency stylelint to v15.11.0
  • chore(deps): update dependency webextension-polyfill to ^0.11.0
  • chore(deps): update dependency webpack to v5.91.0
  • chore(deps): update dependency webpack-bundle-analyzer to v4.10.2
  • chore(deps): update react monorepo (@types/react, @types/react-dom, react, react-dom, react-refresh)
  • chore(deps): update styfle/cancel-workflow-action action to v0.12.1
  • fix(deps): update dependency @waves/protobuf-serialization to v1.5.2
  • fix(deps): update dependency @waves/ts-types to v1.2.0
  • fix(deps): update dependency clsx to v2.1.1
  • fix(deps): update dependency i18next-resources-to-backend to v1.2.1
  • chore(deps): update actions/setup-node action to v4
  • chore(deps): update actions/upload-artifact action to v4
  • chore(deps): update dependency @faergeek/eslint-config to v6
  • chore(deps): update dependency @size-limit/file to v11
  • chore(deps): update dependency copy-webpack-plugin to v12
  • chore(deps): update dependency css-loader to v7
  • chore(deps): update dependency css-minimizer-webpack-plugin to v6
  • chore(deps): update dependency dotenv-flow to v4
  • chore(deps): update dependency eslint to v9
  • chore(deps): update dependency node to v20 (node, @types/node)
  • chore(deps): update dependency postcss-loader to v8
  • chore(deps): update dependency redux-thunk to v3
  • chore(deps): update dependency size-limit to v11
  • chore(deps): update dependency source-map-loader to v5
  • chore(deps): update dependency stylelint to v16
  • chore(deps): update dependency stylus-loader to v8
  • chore(deps): update dependency zip-a-folder to v3
  • chore(deps): update github/codeql-action action to v3
  • chore(deps): update softprops/action-gh-release action to v2
  • fix(deps): update dependency debounce to v2
  • fix(deps): update dependency nanoid to v5
  • fix(deps): update dependency react-i18next to v14
  • fix(deps): update dependency react-redux to v9
  • fix(deps): update dependency redux to v5
  • 🔐 Create all rate-limited PRs at once 🔐

Open

These updates have all been created already. Click a checkbox below to force a retry/rebase of any.

Ignored or Blocked

These are blocked by an existing closed PR and will not be recreated unless you click a checkbox below.

Detected dependencies

docker-compose
docker-compose.arm.yml
docker-compose.yml
github-actions
.github/workflows/checks.yml
  • styfle/cancel-workflow-action 0.11.0
  • actions/checkout v3
  • actions/setup-node v3
.github/workflows/codeql.yml
  • actions/checkout v3
  • github/codeql-action v2
  • github/codeql-action v2
  • github/codeql-action v2
.github/workflows/merge.yml
  • styfle/cancel-workflow-action 0.11.0
  • Keeper-Wallet/jira-action v1
.github/workflows/prepare-release.yml
  • actions/checkout v3
  • actions/setup-node v3
  • getsentry/action-release v1
  • softprops/action-gh-release v1
.github/workflows/pull-migrations.yml
  • actions/checkout v3
.github/workflows/release.yml
  • styfle/cancel-workflow-action 0.11.0
  • Keeper-Wallet/jira-action v1
.github/workflows/size-limit.yml
  • styfle/cancel-workflow-action 0.11.0
  • actions/checkout v3
  • actions/setup-node v3
  • andresz1/size-limit-action v1
.github/workflows/tests.yml
  • styfle/cancel-workflow-action 0.11.0
  • actions/checkout v3
  • actions/setup-node v3
  • actions/upload-artifact v3
.github/workflows/update-tests.yml
  • styfle/cancel-workflow-action 0.11.0
  • actions/checkout v3
  • actions/setup-node v3
  • actions/checkout v3
  • actions/setup-node v3
  • actions/upload-artifact v3
npm
package.json
  • @ethereumjs/util 8.0.3
  • @keeper-wallet/waves-crypto ^3.0.0
  • @popperjs/core ^2.11.0
  • @sentry/browser ^7.26.0
  • @waves-domains/client ^0.3.0
  • @waves/bignumber ^1.0.0
  • @waves/data-entities ^2.0.4
  • @waves/marshall ^0.14.0
  • @waves/parse-json-bignumber ^1.0.3
  • @waves/protobuf-serialization ^1.4.3
  • @waves/ts-types ^1.0.12
  • amazon-cognito-identity-js ^6.0.0
  • buffer ^4.9.2
  • clsx ^2.0.0
  • color-hash ^2.0.1
  • copy-to-clipboard ^3.3.1
  • debounce ^1.2.1
  • detect-browser ^5.3.0
  • events ^3.3.0
  • fast-equals ^5.0.0
  • i18next ^20.6.1
  • i18next-resources-to-backend ^1.0.0
  • identity-img ^2.0.0
  • long ^5.2.0
  • nanoid ^4.0.0
  • obs-store ^4.0.0
  • prismjs ^1.29.0
  • qrcode ^1.4.4
  • react ^18.2.0
  • react-dom ^18.2.0
  • react-i18next ^11.16.7
  • react-imask 6.4.2
  • react-popper ^2.2.5
  • react-redux ^8.0.0
  • react-transition-group ^4.4.2
  • react-virtualized-auto-sizer ^1.0.6
  • react-window ^1.8.6
  • redux ^4.1.1
  • stream-browserify ^3.0.0
  • tiny-invariant ^1.3.1
  • util ^0.12.5
  • wonka ^6.3.1
  • @babel/core ^7.18.9
  • @babel/preset-env ^7.18.9
  • @babel/preset-react ^7.18.6
  • @babel/preset-typescript ^7.18.6
  • @faergeek/eslint-config ^5.0.142
  • @faergeek/tiny-browser-hmr-webpack-plugin ^1.0.3
  • @keeper-wallet/swap-client ^0.2.0
  • @ledgerhq/hw-transport-webusb ^6.24.1
  • @pmmmwh/react-refresh-webpack-plugin ^0.5.9
  • @size-limit/file ^8.1.0
  • @testing-library/webdriverio ^3.2.0
  • @types/color-hash ^1.0.2
  • @types/mocha ^10.0.0
  • @types/node ^18.0.0
  • @types/prismjs ^1.26.0
  • @types/qrcode ^1.4.2
  • @types/react-dom ^18.0.0
  • @types/react-transition-group ^4.4.3
  • @types/react-virtualized-auto-sizer ^1.0.1
  • @types/react-window ^1.8.5
  • @types/redux-logger ^3.0.9
  • @types/w3c-web-usb ^1.0.5
  • @types/webextension-polyfill ^0.10.0
  • @waves/ledger ^4.0.0
  • babel-loader ^9.0.0
  • babel-plugin-prismjs ^2.1.0
  • browserslist ^4.21.2
  • copy-webpack-plugin ^11.0.0
  • css-loader ^6.7.1
  • css-minimizer-webpack-plugin ^5.0.0
  • del ^7.0.0
  • dotenv-flow ^3.2.0
  • esbuild ^0.19.0
  • esbuild-register ^3.4.1
  • eslint ^8.28.0
  • eslint-plugin-mocha ^10.1.0
  • expect-webdriverio 4.1.3
  • html-webpack-plugin ^5.5.0
  • lightningcss ^1.16.1
  • mini-css-extract-plugin ^2.6.1
  • mocha ^10.0.0
  • postcss ^8.4.19
  • postcss-loader ^7.0.1
  • postcss-normalize ^10.0.1
  • postcss-preset-env ^9.0.0
  • prettier ^3.0.0
  • react-refresh ^0.14.0
  • react-router-dom ^6.4.0
  • redux-logger ^3.0.6
  • redux-thunk ^2.4.1
  • rimraf ^5.0.0
  • size-limit ^8.1.0
  • source-map-loader ^4.0.1
  • stylelint ^15.0.0
  • stylelint-order ^6.0.0
  • stylus ^0.59.0
  • stylus-loader ^7.0.0
  • typescript ^4.7.4
  • wait-for-expect ^3.0.2
  • webdriverio ^7.25.1
  • webextension-polyfill ^0.10.0
  • webpack ^5.73.0
  • webpack-bundle-analyzer ^4.7.0
  • webpack-cli ^5.0.0
  • zip-a-folder ^2.0.0
  • @types/react ^18.0.0
nvm
.nvmrc
  • node 19

  • Check this box to trigger a request for Renovate to run again on this repository

[BUG] Balances don't update

Describe the bug
A clear and concise description of what the bug is.
After making a transaction, balances do not update

To Reproduce
Steps to reproduce the behavior:

receive waves on your account

Expected behavior
A clear and concise description of what you expected to happen.

balance in your account should update
at least have a refresh button to manually trigger this

Screenshots
If applicable, add screenshots to help explain your problem.

Environment

  • Version of ProviderKeeper: [e.g. "1.0.0"]
    2.13.7
  • OS: [e.g. "Windows 10 / macOS Big Sur / Ubuntu Bionic Beaver / iOS 15"]
    latest Mac ventura 13.4
  • Browser version: [e.g. "Google Chrome Version 93.0.4577.63 (Official Build) (x86_64)"]
    Chrome Version 114.0.5735.90 (Official Build) (arm64)

Additional context
Add any other context about the problem here.

[FEATURE] Мануал по сборке расширения из исходных кодов

Аbstract
Добавить в README инструкцию по сборке расширения CRX из исходных файлов.

Motivation and Purposes
Возможность использовать локально собранное расширение, в том числе отказаться от возможности автоматического обновления расширения.

Specification
Пошаговая инструкция, позволяющая собрать CRX файл.

Backwards Compatibility
Полная совместимость с предыдущими версиями.

Examples and Implementation

getting Error while creating signAndPublishOrder using waveskeeper extension.

Hi Waveskeeper Team,

As per the github and waves documentation instruction i try to to create signAndpublishOrder but it throws the following error. i don't know why am getting this error i tried to solve but i can't rectified that error. so please provide me a solution for this problem.

js script:
WavesKeeper.signAndPublishOrder({ type: 1002, data: { matcherPublicKey: "7kPFrHDiGw1rCm7LPszuECwWYL3dMf6iMifLRDJQZMzy", orderType: "buy", expiration: Date.now() + 100000, amount: { tokens: "0.000361", assetId: "DWgwcZTMhSvnyYCoWLRUXXSH1RSkzThXLJhww9gwkqdn" }, price: { tokens: "1", assetId: "WAVES" }, matcherFee: { tokens: "0.03", assetId: "WAVES" } } }).then((tx) => { console.log("order placed succesfull !!!"); }).catch((error) => { console.error("Something went wrong", error); }); }

Error:
"Error: The DWgwcZTMhSvnyYCoWLRUXXSH1RSkzThXLJhww9gwkqdn-WAVES asset pair should be reversed"

Thanks

[BUG] Unable to import from Keystore file as wallet disappears

Describe the bug
If you go to the create a new account pane and choose import keystore file, when you click on Browse, although a file select dialog appears, the wallet pane disappears. On returning to the wallet the selected file is not remembered.

As a result it is not possible to load a keystore file.

To Reproduce
Steps to reproduce the behavior:

  1. Go to create account
  2. Click on Keystore File
  3. Select a file
  4. Wallet pane disappears and you can't continue

Expected behavior
Wallet should stay visible during file select.

Screenshots
N/A

Environment
Please complete the following information.

Waves Keeper 2.0.0 zip download
Linux 5.11.0-43-generic #47~20.04.2-Ubuntu SMP Mon Dec 13 11:06:56 UTC 2021 x86_64 x86_64 x86_64 GNU/Linux
Brave V1.33.106 and Chrome Version 96.0.4664.110 (Official Build) (64-bit)

Manifest V3

Аbstract
I've been working on a fork of Waves Keeper. We've been unable to publish it, because Chrome Store has stopped accepting new extensions using Manifest V2. I'm trying to modify Waves Keeper to support Manifest V3, but i am unable to make it work properly.

In Manifest V3 background pages have been replaced by Service Workers. Chrome automatically shuts off Service Worker after 5 minutes after activating regardless of activity.

Examples and Implementation

Changes in manifest file look like this:

{
  "manifest_version": 3,
  "background": {
      "service_worker": "background.js"
  },
  "content_scripts": [
      {
          "matches": ["http://*/*", "https://*/*"],
          "js": ["contentscript.js"],
          "run_at": "document_start",
          "all_frames": true
      }
  ],
  "web_accessible_resources": [
      {
          "resources": ["inpage.js"],
          "matches": ["http://*/*", "https://*/*"]
      }
  ]
}

I've been able to reconnect to Service Worker when Chrome shuts it off, but after reconnecting in-page API stops receiving public state updates. I am unable to figure out why that happens.

Implementation of connection between Service Worker and in-page API:

// contentscript.js

function setupConnection() {
    const pageStream = new WindowPostMessageStream({
        name: 'waves_keeper_content',
        target: 'waves_keeper_page',
    });

    const connectToPort = () => {
        const pluginPort = extension.runtime.connect({ name: 'contentscript' });
        const pluginStream = new PortStream(pluginPort);

        pageStream.pipe(pluginStream).pipe(pageStream);

        const disconnectHandler = (port) => {
            port.onDisconnect.removeListener(disconnectHandler);

            pageStream.unpipe(pluginStream);
            pluginStream.unpipe(pageStream);

            pluginStream.destroy();
            connectToPort();
        };

        pluginPort.onDisconnect.addListener(disconnectHandler);
    };

    connectToPort();
}

I would greatly appreciate any pointers on how to resolve this issue.

Revise Permissions Control

Аbstract
With the ability for a user to block out an entire domain, an accidental rejection on the initial auth leads to an undesirable UX. Especially for users unfamiliar with Waves Keeper.

Motivation and Purposes
It'd be nice if we did not have to teach users how to re-enable permissions for a domain. This seems like an unnecessarily overreaching security feature and ultimately creates room for user error rather than protecting them. Consider these points:

  • If a user does not actually want to use a dapp, they will not visit that domain. How many scenarios include a user denying a domain to communicate with their Waves Keeper, but also wish to remain on the site for other reasons? I would say virtually zero.
  • If a dapp's front end is badly designed, to the point a user would have to reject the domain, they probably should just navigate elsewhere.
  • There are many other ways to protect agains potential abuse

Solution

  • Domains are authorized by default, but with low limits on sign requests, messages, etc.
  • If a domain meets those limits, then an auth/reject prompt arises.

Backwards Compatibility
This would be cleanly backwards compatible, and improve the UX for dapps

Examples and Implementation
Other browser wallets experience this same problem. However, I see this as a trait of nascent software rather than necessary security features.

Subscriptions for regular transactions

Subscriptions for regular transactions.

There are a lot of use cases when you want to make regular payments and you do not want to visit any website every time.

Background

  1. For instance, I want to make a service like patreon.com using only blockchain, as a backend and payment processor. It will allow to make a webpage with information about your project and have DONATE button. When a user clicks that button I want to subscribe his for regular payments for every month or on some events like new podcast episode(an oracle needed).

  2. I have some service with a subscription model (like digitalocean.com for example). I do not want to visit this site every month to pay for the service. I definitely will forget about it and miss payment day. Sure I can create an event in my calendar. but it would be better if Waves Keeper can notify me that it is a payday I will just approve the transaction.

In both cases, when a user clicks a button Waves Keeper appears and shows two things one after another:

  1. Transaction details
  2. Subscription details

Constraints and Assumptions

It is a bad idea to make transactions automatically, so it is much better just to show a notification and popup with transaction details for every payment period.
In order to sync subscriptions and not to lose your data when you change your device, subscriptions can be stored in data transactions like plain JSON.

Design Changes

Waves Keeper should be able to show the list of subscriptions and buttons to remove any of them. This fnuctionality could also be useful in mobile apps.

API

The easiest way for external developers to work with a subscription may look like below:

Waves.subscribe({
  tx: {
     // transaction details here
  },
  meta: {
    period: 2592000, //in seconds, maybe it should look like '1s/1m/1d/1mm' etc.
    description: 'Your cool subscription',
    url: 'example.com',
    address: '3P...'
  }
})

Questions

  1. Should Waves Keeper provide an API to remove subscription? (of course only subscriptions for current website)
  2. Should Waves Keeper allow to send any type of transactions or only transfers? (I think it can allow sending all types).

[BUG] Unable to decrypt Messages

Describe the bug
Unable to decrypt messages using a test account and public key from KeeperWallet.publicState().account.publicKey get {message:'invalid key'} instead

To Reproduce
Open console
Type KeeperWallet.decryptMessage('encryptedMessage', "publicKEY", "encoding phrase").then(console.log)

Expected behavior
I expected to get a response with decrypted message instead i keep getting the error response {message: "invalid key"}

Screenshots
If applicable, add screenshots to help explain your problem.

Environment
Please complete the following information.

  • Version of ProviderKeeper: 2.13.7
  • OS: Windows
  • Browser version: Chromium Version 108.0.5357.0 (Developer Build) (64-bit)

Additional context
Not sure if this makes a difference, but I was using a Testnet account and was running the app from localhost.

[BUG] @bable/polyfill error

Describe the bug
If the inspect page is open on console while using the wallet, the following warning is seen:

ui.js?9fa45892bcecf24d5477:29 @babel/polyfill is loaded more than once on this page. This is probably not desirable/intended and may have consequences if different versions of the polyfills are applied sequentially. If you do need to load the polyfill more than once, use @babel/polyfill/noConflict instead to bypass the warning.

To Reproduce
Open the wallet
Right-click and select "inspect"
In the pop-up, select console
Observe the error message

Expected behavior
There should be no warnings or errors visible on inspect

Screenshots
If applicable, add screenshots to help explain your problem.

Environment
Please complete the following information.

  • Version of ProviderKeeper: 1.5.2
  • OS: [e.g. Ubuntu 20.04
  • Browser version: Version 1.32.115 Chromium: 96.0.4664.93 (Official Build) (64-bit)

Additional context
Add any other context about the problem here.

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.