Commit Graph

19 Commits

Author SHA1 Message Date
William O'Beirne cb92f59e57 Electron Ledger + Trezor Support (#1836)
* Initial scaffold of enclave

* Cleanup types

* Add comments

* Do not truncate errors, pretty output

* Introduce helpers for sagas

* Update yarn lock

* Convert enclave into its own lib. Implement client and server.

* Check in progress

* Initial types

* Remove unused lib

* Finish types

* cleanup

* Switch over to using electron protocol, remove code thats no longer necessary

* Refactor Ledger and Trezor wallets to provide all functionality via libs. Run chain code generation thru Enclave.

* Check in trezor work

* Transaction signing

* Message signing

* Display address

* Fix deallocation of trezor

* Adjust API

* Remove unused getAddresses

* Fix imports and filenames to cooperate with internal typings

* Fix type uncertainty

* Add persistent message to Ledger unlock.

* Update ledger help link to kb

* Convert ledger over to updated libs

* Fix jest config

* Enclave README

* Unnecessary assertion

* Adjust tip

* Type ledger errors

* Reduce enclave client code.

* No default exports

* l18n user facing enclave errors

* Reduce repeated enclave code by splitting it into its own wallet lib. Fix some types

* tslint

* Reduce repeated enclave code by splitting it into its own wallet lib. Fix some types and error messages.

* Electron TREZOR Support (#1946)

* Type trezor connect.

* Check in trezor code

* Implement TREZOR wallet

* Convert TREZOR to use enclave class like Ledger.

* Switch to mycrypto fork of trezor lib. Remove unused dependencies.

* remove unnecessary window attachment

* tslint
2018-06-15 18:25:29 -05:00
Daniel Ternyak b58e278ac5
Exclude components from coverage reports (#1774)
* add 'components' and 'containers' dirs to coverage excluded paths

* add vendor and spec to excluded coverage paths

* trigger mycryptobuild
2018-05-13 13:32:45 -05:00
HenryNguyen5 a71c5daec0 Ignore dist for jest tests (#1737) 2018-05-09 19:32:43 -05:00
HenryNguyen5 682b75b07d Fix jest tests (#1534)
* Fix jest tests with different fetch lib

* Make exact dep version
2018-04-16 17:23:03 -05:00
HenryNguyen5 8b051c13a2 Add coverage reporting with coveralls (#1459) 2018-04-05 20:51:48 -05:00
William O'Beirne 5d41a7f774 Remove all LESS code (#1348)
* Checking in removal process.

* Final removal of all SCSS

* Remove unnecessary test

* tscheck
2018-03-20 15:08:57 -05:00
James Prado 81d4444dff Add regex for BIP44 Strings (#1035)
* Add regex check for BIP44 paths

* Add tests for BIP44 regex

* Remove '/config' from excluded paths in jest

* update path

* Update Validator tests & remove old dPathRegex tests

* Test hardcoded dpaths
2018-02-26 19:20:41 -06:00
William O'Beirne df52521c17 MEW-01-009 & MEW-01-010: Electron security fixes (#910)
* Handle opening of external links in electron. Minor refactor of window code.

* Convert updates from in-app modal to electron dialogs. Remove in-app code and preload bridge.

* Refine new window blocking. Re-enable tsconfig to look at electron-app.

* Clean up shared

* Whoops, wrong protocol format
2018-01-26 13:53:51 -06:00
William O'Beirne 182eaa4329 Electron App (#854)
* Basic webpack build started.

* Get build working with electron-packager. Not fully satisfied, might investigate electron-builder.

* Custom title bar

* Rewrite all webpack configs to use common function. Organize webpack utils. Split into multiple dist folders.

* Replace electron build with electron-builder. Leave around packager for a bit.

* Check in progress on updater.

* Update modal flow.

* Fix tscheck.

* Adjust publish info.

* Arbitrary version bump.

* Bump version again.

* 5.0.2 bump fix autodownload.

* 5.0.2 bump again, readd dmg

* 5.0.3 bump

* Turn auto update back off. Log errors. Revert versions.

* Add os-specific builds. Improve update failure.

* Open external links in browser in electron.

* Remove custom title bar temporarily.

* Add info about the update download to the modal.

* Turn off development changes.

* Take the postBuild sorting script and move it into a webpack config.

* Initial conversion to typescript and electron-webpack.

* Switch from electron-webpack back to custom config, clean up unused code, typify electron bridge.

* Better typing for bridge.

* Remove unnecessary file.

* Reminify.

* Add shared folder resolving to jest config.

* Add enum to electron events
2018-01-22 17:38:06 -06:00
aitrean af2e0b69e1 Web Worker Decrypt (#680)
1. Attempt an empty password every time a keystore is uploaded.
2. Delegate scrypt decryption (ie ethereumjs-wallet.fromV3) to its own web worker and interface with it through an async typescript function that gets handled in the wallet saga. This keeps the UI unblocked when scrypt takes a long time to decrypt.
3. Add logic to show a spinner x number of milliseconds after file upload so the user will understand when a wallet is being decrypted.
2018-01-11 00:44:13 -06:00
Daniel Ternyak 7e154175f7
Address Derivation (CI) (#529)
* improve derivation-checking performance by batching docker calls; move into spec dir

* remove npm command to run derivation-checking; create 'int-test' (integration) command and hook up into jest

* add integration testing to CI; configure docker / docker image (dternyak/eth-priv-to-addr) in CI

* docker build -> docker pull

* use travis build matrix to group tests and improve build times

* remove int-test call

* attempt travis 'job' with all tests running in parallel

* remove typo

* attempt travis 'job' with all tests running in parallel (round 2)

* organize integration tests

* refactor/cleanup

* refactor/address comments
2017-12-05 22:24:40 -08:00
Eddie Wang 980366694c RPC Error Handling (#384)
* create ensureOkResponse and check against RPC responses

* Merge with develop branch

* added single unit test

* main nodes added

* getBalance method

* remove console.log

* minor conflict fix - readd polyfill to integration test

* added two more method tests

* seperate rpcnode from extended classes

* fixes etherscan

* added all tests

* revert files with only formatting changes

* remove console.logs - still need to update snapshot before tests will pass

* updated snapshot due to RpcNode fixes for Infura and Etherscan nodes

* added RpcNodeTest config so we don't rely on constants in code

* undo formatting changes

* Multiple fixes to error handling tokens.

* Fixed TSC errors

* Minor styling edit - change async func to promise

* changed shape of tokenBalances

* change balance type back to stricter TokenValue type

* remove package.json change and include test for error state.

* minor change removing unneeded line of code

* added longer timeout for api

* update snapshot
2017-11-29 23:35:17 -06:00
James Prado 70a2b3ca9a Update Jest & Enzyme, Add snapshot tests (#307)
* Add disclaimer modal to footer

* Remove duplicate code & unnecessary styles

* Fix formatting noise

* remove un-used css style

* Fix tslint error & add media query for modals

* Nest Media Query

* Update Jest & Enzyme, Add snapshot tests

* Fix tslint errors in /spec, Update mock localstorage

* Update types in tests, Fix tslint error

* Specify module versions for browser

* Update sendTransaction snapshot
2017-10-24 19:17:26 -07:00
HenryNguyen5 5d4b36d453 Migrate to Typescript (#224)
* Refactor babel/types

* Refactor entry point

* Refactor actions

* Refactor api

* Full project refactor -- Broad type fixing sweep

* - completely fix merge conflicts
- handle various type errors

* Add tslint to package.json

* Dependency cleanup

* Fix module resolution

* Work on type definitions for untyped libs

* progress commit

* Add more definition typing

* various type additions

* Add unit types

* Fix sagaiterator  + unit types

* various types added

* additional type additions

* Fix typing on Sagas

* remove flowfixmes; swap translate for translateRaw

* Get rid of contracts - awaiting Henry's contract PR

* Remove contracts from routing

* Fix most of actions/reducers

* refactor actions directory structure

* fix reducer action type imports

* Fix most of type errors pre-actions refactor

* fix action creator imports in containers

* Refactor more

* Refactor index of actions

* fix action imports; use module level index export

* package-lock.json updated

* Use action types in props

* Type up action creators

* Fix most of connect errors

* Typefixing progress

* More types

* Fix run-time errors

* Caching improvements for webpack

* Remove path resolve from webpack

* Update non-breaking packages to latest version

* Fix token typing

* Remove unused color code

* Fix wallet decrypt dispatch

* Set redux-form related props/functions to ANY, since we're stripping it out later on

* Revert BigNumber.js package changes

* Extend window to custom object for Perf

* Format Navigation

* Typecase keystore errors as any (since we shouldnt touch this)

* Push wallet context fix

* - find/replace value->payload in swap
- properly type swap state properties
- extract inline reducer into reducer function

* - type local storage retrieved items as generic

* - bind all RPCClient methods with fat arrow

* - reformat

* Change to enums for constants

* Change state into any

* Fix swap errors

* ensure that seconds are passed into state as integers

* Fix rest of errors

* use parseInt explicitly instead of type coercion

* Fix derivation-checker, remove flow command, add tslint command, add tslint-react, tell travis to use tslint instead of flow.

* Whoops, remove those tests.

* Remove unsupported (yet) config option.

* Fix precommit to target ts and tsx files.

* Fix some errors, ignore some silly rules.

* Revert jest to v19, use ts-jest and make all tests typescript. Fixes all but one.

* Get rid of saga tests

* Fix tslint errors
2017-09-24 19:06:28 -07:00
crptm 9a65a49d0b invalid pkey message 2017-07-04 16:19:04 +04:00
crptm 8696213e91 fix test 2017-07-04 06:42:52 +04:00
crptm 1602e19214 support translations markup 2017-05-26 02:05:11 +04:00
crptm c4d7738e14 translations alias for jest 2017-05-25 04:17:27 +04:00
Daniel Ternyak dcba1c00ea create default jest config 2017-04-12 00:01:02 -05:00