ton-evm-bridge 0.0.1-security → 2.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of ton-evm-bridge might be problematic. Click here for more details.

Files changed (65) hide show
  1. package/.editorconfig +13 -0
  2. package/.eslintrc.js +16 -0
  3. package/.github/ISSUE_TEMPLATE/bug_report.yaml +108 -0
  4. package/.nvmrc +1 -0
  5. package/.prettierrc +4 -0
  6. package/@types/global.d.ts +1 -0
  7. package/@types/params.d.ts +24 -0
  8. package/@types/tonweb.d.ts +44 -0
  9. package/LICENSE +674 -0
  10. package/README.md +71 -5
  11. package/assets/WTON.json +1 -0
  12. package/assets/pics/arrow.svg +44 -0
  13. package/assets/pics/done.svg +38 -0
  14. package/assets/pics/link.svg +15 -0
  15. package/assets/pics/swap.svg +331 -0
  16. package/assets/styles/reboot.css +163 -0
  17. package/components/BridgeProcessor.vue +977 -0
  18. package/docs/.nojekyll +0 -0
  19. package/docs/200.html +9 -0
  20. package/docs/_nuxt/1f2ac62.js +1 -0
  21. package/docs/_nuxt/1f2ac62.js.br +0 -0
  22. package/docs/_nuxt/1f2ac62.js.gz +0 -0
  23. package/docs/_nuxt/5cc51a5.js +1 -0
  24. package/docs/_nuxt/5cc51a5.js.br +0 -0
  25. package/docs/_nuxt/5cc51a5.js.gz +0 -0
  26. package/docs/_nuxt/7767db0.js +2 -0
  27. package/docs/_nuxt/7767db0.js.br +0 -0
  28. package/docs/_nuxt/7767db0.js.gz +0 -0
  29. package/docs/_nuxt/9ead974.js +2 -0
  30. package/docs/_nuxt/9ead974.js.br +0 -0
  31. package/docs/_nuxt/9ead974.js.gz +0 -0
  32. package/docs/_nuxt/LICENSES +98 -0
  33. package/docs/_nuxt/a46cdc5.js +1 -0
  34. package/docs/_nuxt/a46cdc5.js.br +0 -0
  35. package/docs/_nuxt/a46cdc5.js.gz +0 -0
  36. package/docs/_nuxt/b3f7827.js +1 -0
  37. package/docs/_nuxt/b3f7827.js.br +0 -0
  38. package/docs/_nuxt/b3f7827.js.gz +0 -0
  39. package/docs/_nuxt/b5d388d.js +1 -0
  40. package/docs/_nuxt/b5d388d.js.br +0 -0
  41. package/docs/_nuxt/b5d388d.js.gz +0 -0
  42. package/docs/_nuxt/fe8ca79.js +2 -0
  43. package/docs/_nuxt/fe8ca79.js.br +0 -0
  44. package/docs/_nuxt/fe8ca79.js.gz +0 -0
  45. package/docs/_nuxt/img/arrow.69e1e70.svg +44 -0
  46. package/docs/_nuxt/img/arrow.69e1e70.svg.br +0 -0
  47. package/docs/_nuxt/img/arrow.69e1e70.svg.gz +0 -0
  48. package/docs/_nuxt/img/swap.b8b4b2f.svg +331 -0
  49. package/docs/_nuxt/img/swap.b8b4b2f.svg.br +0 -0
  50. package/docs/_nuxt/img/swap.b8b4b2f.svg.gz +0 -0
  51. package/docs/favicon.ico +0 -0
  52. package/docs/index.html +9 -0
  53. package/index.js +66 -0
  54. package/lang/en/bridge.json +105 -0
  55. package/lang/en-US.js +7 -0
  56. package/layouts/default.vue +53 -0
  57. package/modules/i18n.js +44 -0
  58. package/nuxt.config.js +73 -0
  59. package/package.json +61 -6
  60. package/pages/index.vue +635 -0
  61. package/static/favicon.ico +0 -0
  62. package/tsconfig.json +39 -0
  63. package/utils/constants.ts +65 -0
  64. package/utils/helpers.ts +37 -0
  65. package/vue-shim.d.ts +4 -0
package/.editorconfig ADDED
@@ -0,0 +1,13 @@
1
+ # editorconfig.org
2
+ root = true
3
+
4
+ [*]
5
+ indent_style = space
6
+ indent_size = 4
7
+ end_of_line = lf
8
+ charset = utf-8
9
+ trim_trailing_whitespace = true
10
+ insert_final_newline = true
11
+
12
+ [*.md]
13
+ trim_trailing_whitespace = false
package/.eslintrc.js ADDED
@@ -0,0 +1,16 @@
1
+ module.exports = {
2
+ root: true,
3
+ env: {
4
+ browser: true,
5
+ node: true
6
+ },
7
+ extends: [
8
+ '@nuxtjs/eslint-config-typescript',
9
+ 'plugin:nuxt/recommended',
10
+ 'prettier'
11
+ ],
12
+ plugins: [
13
+ ],
14
+ // add your custom rules here
15
+ rules: {}
16
+ }
@@ -0,0 +1,108 @@
1
+ name: Bug Report
2
+ description: Report of critical bug such as UX inconsistencies, logical contradictions and functional shortcomings.
3
+ labels: 'Bug Report'
4
+ body:
5
+ - type: dropdown
6
+ id: bug_type
7
+ attributes:
8
+ label: Bug Type
9
+ description: Select the bug type
10
+ options:
11
+ - Functional
12
+ - UX
13
+ - UI
14
+ - Performance
15
+ - Security
16
+ - Localization
17
+ - Other
18
+ validations:
19
+ required: true
20
+ - type: textarea
21
+ id: reproduction-steps
22
+ attributes:
23
+ label: Reproduction steps
24
+ description: Steps to reproduce a bug (you are welcome to attach screenshots here)
25
+ placeholder: 1. Click diamond 2. HODL
26
+ validations:
27
+ required: true
28
+ - type: textarea
29
+ id: actual-result
30
+ attributes:
31
+ label: Actual result
32
+ description: What was seen
33
+ placeholder: When action is done, something happens
34
+ validations:
35
+ required: true
36
+ - type: textarea
37
+ id: expected-result
38
+ attributes:
39
+ label: Expected result
40
+ description: What was expected
41
+ placeholder: When action is done, nothing happens
42
+ validations:
43
+ required: true
44
+ - type: dropdown
45
+ id: suggested-severity
46
+ attributes:
47
+ label: Suggested Severity
48
+ description: Severity of the bug
49
+ options:
50
+ - Vulnerability
51
+ - Critical
52
+ - High
53
+ - Medium
54
+ - Low
55
+ validations:
56
+ required: true
57
+ # - type: dropdown
58
+ # id: browsers
59
+ # attributes:
60
+ # label: "Browsers"
61
+ # description: What browsers are you seeing the problem on ?
62
+ # multiple: true
63
+ # options:
64
+ # - Chrome
65
+ # - Safari
66
+ # - Firefox
67
+ # - Microsoft Edge
68
+ # - Brave
69
+ # validations:
70
+ # required: false
71
+ # - type: dropdown
72
+ # id: os
73
+ # attributes:
74
+ # label: "OS"
75
+ # description: What is the impacted environment ?
76
+ # multiple: true
77
+ # options:
78
+ # - Windows
79
+ # - Linux
80
+ # - Mac
81
+ # validations:
82
+ # required: false
83
+ - type: textarea
84
+ id: device
85
+ attributes:
86
+ label: Device
87
+ description: Information about device
88
+ value: |
89
+ Desktop (please complete the following information):
90
+ - OS: [e.g. iOS]
91
+ - Browser [e.g. chrome, safari]
92
+ - Version [e.g. 22]
93
+
94
+ Smartphone (please complete the following information):
95
+ - Device: [e.g. iPhone6]
96
+ - OS: [e.g. iOS8.1]
97
+ - Browser [e.g. stock browser, safari]
98
+ - Version [e.g. 22]
99
+ validations:
100
+ required: true
101
+ - type: textarea
102
+ id: additional-context
103
+ attributes:
104
+ label: Additional Context
105
+ description: Add any other context about the problem here. You can also attach any extra screenshots or screencasts here.
106
+ placeholder: e.g. device was rooted
107
+ validations:
108
+ required: false
package/.nvmrc ADDED
@@ -0,0 +1 @@
1
+ 15.11.0
package/.prettierrc ADDED
@@ -0,0 +1,4 @@
1
+ {
2
+ "semi": false,
3
+ "singleQuote": true
4
+ }
@@ -0,0 +1 @@
1
+ declare var ethereum: any;
@@ -0,0 +1,24 @@
1
+ interface IParamsNetwork {
2
+ getGasUrl: string,
3
+ explorerUrl: string,
4
+ wTonAddress: string,
5
+ tonBridgeAddress: string,
6
+ tonCollectorAddress: string,
7
+ tonMultisigAddress: string,
8
+ tonCenterUrl: string,
9
+ chainId: number,
10
+ blocksConfirmations: number,
11
+ defaultGwei: number,
12
+ coinsPerGweiTo: number,
13
+ coinsPerGweiFrom: number
14
+ }
15
+
16
+ interface IParams {
17
+ tonTransferUrl: string,
18
+ networks: {
19
+ [key: string]: {
20
+ main: IParamsNetwork,
21
+ test: IParamsNetwork
22
+ }
23
+ }
24
+ }
@@ -0,0 +1,44 @@
1
+ declare module "tonweb" {
2
+ import { BN } from 'types-bn'
3
+
4
+ declare class Address {
5
+ constructor(anyForm: string | Address)
6
+ static isValid(anyForm: string | Address): boolean
7
+ toString(isUserFriendly?: boolean, isUrlSafe?: boolean, isBounceable?: boolean, isTestOnly?: boolean): string
8
+ hashPart: Uint8Array
9
+ wc: number
10
+ }
11
+
12
+ declare class HttpProvider {
13
+ constructor(host?: string, options?: {apiKey: string})
14
+ sendImpl(apiUrl: string, request: any): Promise<any>
15
+ send(method: string, params: any): Promise<any>
16
+ getAddressInfo(address: string): Promise<any>
17
+ getExtendedAddressInfo(address: string): Promise<any>
18
+ getWalletInfo(address: string): Promise<any>
19
+ getTransactions(address: string, limit?: number, lt?: number, hash?: string, to_lt?: number, archival?: boolean): Promise<any[]>
20
+ getBalance(address: string): Promise<any>
21
+ sendBoc(base64: string): Promise<any>
22
+ sendQuery(query: any): Promise<any>
23
+ getEstimateFee(query: any): Promise<any>
24
+ call(address: string, method: string | number, params?: any[][]): Promise<any>
25
+ }
26
+
27
+ declare class TonWeb {
28
+ constructor(provider: HttpProvider)
29
+ provider: HttpProvider
30
+
31
+ static utils: {
32
+ BN: typeof BN,
33
+ Address: typeof Address,
34
+ base64ToBytes(base64: string): Uint8Array,
35
+ bytesToHex(buffer: Uint8Array): string
36
+ }
37
+
38
+ static Address: typeof Address
39
+ static boc: any // TODO
40
+ static HttpProvider: typeof HttpProvider
41
+ }
42
+
43
+ export default TonWeb;
44
+ }