@inco/lightning 0.1.20 → 0.1.29

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.
Files changed (28) hide show
  1. package/CHANGELOG.md +4 -0
  2. package/README.md +32 -0
  3. package/dumps/incoLightning_0_1_25__861473222.dump.json +1 -0
  4. package/dumps/incoLightning_0_1_25__861473222.env +15 -0
  5. package/dumps/incoLightning_0_1_26__18043964.dump.json +1 -0
  6. package/dumps/incoLightning_0_1_26__18043964.env +15 -0
  7. package/dumps/incoLightning_0_1_26__444235330.dump.json +1 -0
  8. package/dumps/incoLightning_0_1_26__444235330.env +15 -0
  9. package/dumps/incoLightning_0_1_27__125335042.dump.json +1 -0
  10. package/dumps/incoLightning_0_1_27__125335042.env +14 -0
  11. package/dumps/incoLightning_0_1_27__558243565.dump.json +1 -0
  12. package/dumps/incoLightning_0_1_27__558243565.env +14 -0
  13. package/dumps/incoLightning_0_1_29__183408998.dump.json +1 -0
  14. package/dumps/incoLightning_0_1_29__183408998.env +14 -0
  15. package/dumps/incoLightning_0_1_29__340846814.dump.json +1 -0
  16. package/dumps/incoLightning_0_1_29__340846814.env +14 -0
  17. package/manifest.yaml +258 -0
  18. package/package.json +5 -4
  19. package/src/Lib.sol +1 -1
  20. package/src/libs/incoLightning_0_1_25__861473222.sol +389 -0
  21. package/src/libs/incoLightning_0_1_26__18043964.sol +389 -0
  22. package/src/libs/incoLightning_0_1_26__444235330.sol +389 -0
  23. package/src/libs/incoLightning_0_1_27__125335042.sol +389 -0
  24. package/src/libs/incoLightning_0_1_27__558243565.sol +389 -0
  25. package/src/libs/incoLightning_0_1_29__183408998.sol +389 -0
  26. package/src/libs/incoLightning_0_1_29__340846814.sol +389 -0
  27. package/src/test/IncoTest.sol +2 -1
  28. package/src/version/IncoLightningConfig.sol +1 -1
@@ -0,0 +1,14 @@
1
+ DEPLOYER_ADDRESS=0x8202D2D747784Cb7D48868E44C42C4bf162a70BC
2
+ STATE_DUMP=incoLightning_0_1_29__340846814.dump.json
3
+ ADD_TWO_ADDRESS=0x974BE82A144E3d1F8F9f13b8436eA16aB5044B89
4
+ EXECUTOR_ADDRESS=0x3B22be60Ae699933959CA3cE147C96caa88Ccd3D
5
+ ECIES_PUBLIC_KEY=0x03dd6c92eae96934c5a4a0d653b79d0e4366f40c562f2f8751fd5a130fa6c7ceba
6
+ CALLBACK_ADDRESS=0xd3851617feBf3174D8F469CA93dee9F177D74ae6
7
+ SENDER_ADDRESS=0xDa28fDD933999185611183c5442d9d2eA4908Ec7
8
+ SENDER_PRIVATE_KEY=0x23856416fc7d1035e9c10a97cf62d032a69d51f63846f54c86983fc4b8784d2c
9
+ COVALIDATOR_ECIES_PRIVATE_KEY=0x03420130f4a37fc1c1f26e0c66560badefe5022922d8c6587df07c5f86908da5
10
+ COVALIDATOR_CALLBACK_PRIVATE_KEY=0x8077e893434f3119ec0bd29eb4c7fbf27e13e70eb6c07b46e76cc06d5f0086a9
11
+ COVALIDATOR_ACL_ADDR=0x3B22be60Ae699933959CA3cE147C96caa88Ccd3D
12
+ COVALIDATOR_INCO_EXECUTOR_ADDR=0x3B22be60Ae699933959CA3cE147C96caa88Ccd3D
13
+ COVALIDATOR_DECRYPTION_HANDLER_ADDR=0x3B22be60Ae699933959CA3cE147C96caa88Ccd3D
14
+
package/manifest.yaml ADDED
@@ -0,0 +1,258 @@
1
+ incoLightning_0_1_29__183408998:
2
+ release:
3
+ name: incoLightning_0_1_29__183408998
4
+ executorAddress: "0x63D8135aF4D393B1dB43B649010c8D3EE19FC9fd"
5
+ deployer: "0x8202D2D747784Cb7D48868E44C42C4bf162a70BC"
6
+ pepper: testnet
7
+ version:
8
+ major: 0
9
+ minor: 1
10
+ patch: 29
11
+ shortSalt: "183408998"
12
+ salt: "0x8202d2d747784cb7d48868e44c42c4bf162a70bc00d75ffa0caf0797c3f12d66"
13
+ deployments:
14
+ - decryptSigner: "0x000000000000000000000000000000000000baBe"
15
+ eciesPublicKey: "0x000000000000000000000000000000000000000000000000000000000000\
16
+ 000000000000000000000000000000000000000000000000000000000000000000babe"
17
+ chainId: "7311099111"
18
+ blockNumber: "1"
19
+ chainName: Inco Release Chain
20
+ active: true
21
+ deployDate: 2025-04-22T16:02:38.372Z
22
+ commit: v3-28-g93c05a49-dirty
23
+ addTwoAddress: "0x04461CD161001BC484C55D253F744462A6eADc10"
24
+ - decryptSigner: "0xA8822DE8910f66D3d03F1eAfe2C0141dBc327Ee0"
25
+ eciesPublicKey: "0x048a582d29083c2f3fefe024bf4dd9ab913ab8973716977da5f01106e0b8\
26
+ 4095b1e647a9e377175fcb66bda05087c93b05e1fd53a704d0914bb23a0b2a69e9f235"
27
+ chainId: "10143"
28
+ blockNumber: "13464615"
29
+ chainName: Monad Testnet
30
+ active: true
31
+ deployDate: 2025-04-22T16:01:14.380Z
32
+ commit: v3-28-g93c05a49-dirty
33
+ addTwoAddress: "0x3E0Aa45e4BD7E86093460A302803298a0EE7155a"
34
+ - decryptSigner: "0xA8822DE8910f66D3d03F1eAfe2C0141dBc327Ee0"
35
+ eciesPublicKey: "0x048a582d29083c2f3fefe024bf4dd9ab913ab8973716977da5f01106e0b8\
36
+ 4095b1e647a9e377175fcb66bda05087c93b05e1fd53a704d0914bb23a0b2a69e9f235"
37
+ chainId: "84532"
38
+ blockNumber: "24784654"
39
+ chainName: Base Sepolia
40
+ active: true
41
+ deployDate: 2025-04-22T16:00:02.028Z
42
+ commit: v3-28-g93c05a49-dirty
43
+ addTwoAddress: "0xF10E6B2ddd168D105546f39E1Ba64004E4FbeF10"
44
+ incoLightning_0_1_29__340846814:
45
+ release:
46
+ name: incoLightning_0_1_29__340846814
47
+ executorAddress: "0x3B22be60Ae699933959CA3cE147C96caa88Ccd3D"
48
+ deployer: "0x8202D2D747784Cb7D48868E44C42C4bf162a70BC"
49
+ pepper: devnet
50
+ version:
51
+ major: 0
52
+ minor: 1
53
+ patch: 29
54
+ shortSalt: "340846814"
55
+ salt: "0x8202d2d747784cb7d48868e44c42c4bf162a70bc00b001d6742fded0dd599ede"
56
+ deployments:
57
+ - decryptSigner: "0x000000000000000000000000000000000000baBe"
58
+ eciesPublicKey: "0x000000000000000000000000000000000000000000000000000000000000\
59
+ 000000000000000000000000000000000000000000000000000000000000000000babe"
60
+ chainId: "7311099111"
61
+ blockNumber: "1"
62
+ chainName: Inco Release Chain
63
+ active: true
64
+ deployDate: 2025-04-22T15:59:01.071Z
65
+ commit: v3-28-g93c05a49-dirty
66
+ addTwoAddress: "0x04461CD161001BC484C55D253F744462A6eADc10"
67
+ - decryptSigner: "0xA8822DE8910f66D3d03F1eAfe2C0141dBc327Ee0"
68
+ eciesPublicKey: "0x048a582d29083c2f3fefe024bf4dd9ab913ab8973716977da5f01106e0b8\
69
+ 4095b1e647a9e377175fcb66bda05087c93b05e1fd53a704d0914bb23a0b2a69e9f235"
70
+ chainId: "10143"
71
+ blockNumber: "13464197"
72
+ chainName: Monad Testnet
73
+ active: true
74
+ deployDate: 2025-04-22T15:57:26.862Z
75
+ commit: v3-28-g93c05a49-dirty
76
+ addTwoAddress: "0x6A23b79203F1Db95947423291C8177B144DDE372"
77
+ - decryptSigner: "0xA8822DE8910f66D3d03F1eAfe2C0141dBc327Ee0"
78
+ eciesPublicKey: "0x048a582d29083c2f3fefe024bf4dd9ab913ab8973716977da5f01106e0b8\
79
+ 4095b1e647a9e377175fcb66bda05087c93b05e1fd53a704d0914bb23a0b2a69e9f235"
80
+ chainId: "84532"
81
+ blockNumber: "24784527"
82
+ chainName: Base Sepolia
83
+ active: true
84
+ deployDate: 2025-04-22T15:55:47.828Z
85
+ commit: v3-28-g93c05a49-dirty
86
+ addTwoAddress: "0x1A98fB1f7E57C0648b1d2A7DEA6e126C302A7e93"
87
+ incoLightning_0_1_27__558243565:
88
+ release:
89
+ name: incoLightning_0_1_27__558243565
90
+ executorAddress: "0x595dc0fA68e7847aC1b1d52a56A1551ad0e38472"
91
+ deployer: "0x8202D2D747784Cb7D48868E44C42C4bf162a70BC"
92
+ pepper: testnet
93
+ version:
94
+ major: 0
95
+ minor: 1
96
+ patch: 27
97
+ shortSalt: "558243565"
98
+ salt: "0x8202d2d747784cb7d48868e44c42c4bf162a70bc008f0e1b154a58f3ce49d6ed"
99
+ deployments:
100
+ - decryptSigner: "0x000000000000000000000000000000000000baBe"
101
+ eciesPublicKey: "0x000000000000000000000000000000000000000000000000000000000000\
102
+ 000000000000000000000000000000000000000000000000000000000000000000babe"
103
+ chainId: "7311099111"
104
+ blockNumber: "1"
105
+ chainName: Inco Release Chain
106
+ active: true
107
+ deployDate: 2025-04-22T14:57:24.620Z
108
+ commit: v3-28-g652cc4a1-dirty
109
+ addTwoAddress: "0x04461CD161001BC484C55D253F744462A6eADc10"
110
+ - decryptSigner: "0xA8822DE8910f66D3d03F1eAfe2C0141dBc327Ee0"
111
+ eciesPublicKey: "0x048a582d29083c2f3fefe024bf4dd9ab913ab8973716977da5f01106e0b8\
112
+ 4095b1e647a9e377175fcb66bda05087c93b05e1fd53a704d0914bb23a0b2a69e9f235"
113
+ chainId: "10143"
114
+ blockNumber: "13457424"
115
+ chainName: Monad Testnet
116
+ active: true
117
+ deployDate: 2025-04-22T14:57:15.486Z
118
+ commit: v3-28-g652cc4a1-dirty
119
+ addTwoAddress: "0xbbf1f797b5e132b72f4a45E1923cBb0BFeca80FA"
120
+ - decryptSigner: "0xA8822DE8910f66D3d03F1eAfe2C0141dBc327Ee0"
121
+ eciesPublicKey: "0x048a582d29083c2f3fefe024bf4dd9ab913ab8973716977da5f01106e0b8\
122
+ 4095b1e647a9e377175fcb66bda05087c93b05e1fd53a704d0914bb23a0b2a69e9f235"
123
+ chainId: "84532"
124
+ blockNumber: "24782764"
125
+ chainName: Base Sepolia
126
+ active: true
127
+ deployDate: 2025-04-22T14:57:02.375Z
128
+ commit: v3-28-g652cc4a1
129
+ addTwoAddress: "0x0c6320A91ec6BA7d42B4f079132fD71A90C12e22"
130
+ incoLightning_0_1_27__125335042:
131
+ release:
132
+ name: incoLightning_0_1_27__125335042
133
+ executorAddress: "0x902B77583C7C5df71C95114707C4974A8d5Dff9D"
134
+ deployer: "0x8202D2D747784Cb7D48868E44C42C4bf162a70BC"
135
+ pepper: devnet
136
+ version:
137
+ major: 0
138
+ minor: 1
139
+ patch: 27
140
+ shortSalt: "125335042"
141
+ salt: "0x8202d2d747784cb7d48868e44c42c4bf162a70bc003343825a7e951afb24c202"
142
+ deployments:
143
+ - decryptSigner: "0x000000000000000000000000000000000000baBe"
144
+ eciesPublicKey: "0x000000000000000000000000000000000000000000000000000000000000\
145
+ 000000000000000000000000000000000000000000000000000000000000000000babe"
146
+ chainId: "7311099111"
147
+ blockNumber: "1"
148
+ chainName: Inco Release Chain
149
+ active: true
150
+ deployDate: 2025-04-22T14:35:10.281Z
151
+ commit: v3-27-ge3d04b6a-dirty
152
+ addTwoAddress: "0x04461CD161001BC484C55D253F744462A6eADc10"
153
+ - decryptSigner: "0xA8822DE8910f66D3d03F1eAfe2C0141dBc327Ee0"
154
+ eciesPublicKey: "0x048a582d29083c2f3fefe024bf4dd9ab913ab8973716977da5f01106e0b8\
155
+ 4095b1e647a9e377175fcb66bda05087c93b05e1fd53a704d0914bb23a0b2a69e9f235"
156
+ chainId: "10143"
157
+ blockNumber: "13454931"
158
+ chainName: Monad Testnet
159
+ active: true
160
+ deployDate: 2025-04-22T14:35:02.958Z
161
+ commit: v3-27-ge3d04b6a-dirty
162
+ addTwoAddress: "0xC1ee708D522B8b0743B5C5309AeD6b6b4C4102a6"
163
+ - decryptSigner: "0xA8822DE8910f66D3d03F1eAfe2C0141dBc327Ee0"
164
+ eciesPublicKey: "0x048a582d29083c2f3fefe024bf4dd9ab913ab8973716977da5f01106e0b8\
165
+ 4095b1e647a9e377175fcb66bda05087c93b05e1fd53a704d0914bb23a0b2a69e9f235"
166
+ chainId: "84532"
167
+ blockNumber: "24782097"
168
+ chainName: Base Sepolia
169
+ active: true
170
+ deployDate: 2025-04-22T14:34:47.565Z
171
+ commit: v3-27-ge3d04b6a-dirty
172
+ addTwoAddress: "0xAac318ca07FCA665c4d27A7e9e8FB65B89AfAC83"
173
+ incoLightning_0_1_26__18043964:
174
+ release:
175
+ name: incoLightning_0_1_26__18043964
176
+ executorAddress: "0x69Ef6a59f9eE2d6f3b49eA3F79bcF1553512DF0e"
177
+ deployer: "0x8202D2D747784Cb7D48868E44C42C4bf162a70BC"
178
+ pepper: testnet
179
+ version:
180
+ major: 0
181
+ minor: 1
182
+ patch: 26
183
+ shortSalt: "18043964"
184
+ salt: "0x8202d2d747784cb7d48868e44c42c4bf162a70bc00858064cb0f58c7ef7a843c"
185
+ deployments:
186
+ - decryptSigner: "0x000000000000000000000000000000000000baBe"
187
+ eciesPublicKey: "0x000000000000000000000000000000000000000000000000000000000000\
188
+ 000000000000000000000000000000000000000000000000000000000000000000babe"
189
+ chainId: "7311099111"
190
+ blockNumber: "1"
191
+ chainName: Inco Release Chain
192
+ active: true
193
+ deployDate: 2025-04-22T12:14:50.447Z
194
+ commit: v3-26-g623cec72-dirty
195
+ addTwoAddress: "0x70fC34B18B12E945cb2204FA77E5f8e1581890C3"
196
+ - decryptSigner: "0xA8822DE8910f66D3d03F1eAfe2C0141dBc327Ee0"
197
+ eciesPublicKey: "0x048a582d29083c2f3fefe024bf4dd9ab913ab8973716977da5f01106e0b8\
198
+ 4095b1e647a9e377175fcb66bda05087c93b05e1fd53a704d0914bb23a0b2a69e9f235"
199
+ chainId: "10143"
200
+ blockNumber: "13439069"
201
+ chainName: Monad Testnet
202
+ active: true
203
+ deployDate: 2025-04-22T12:14:42.391Z
204
+ commit: v3-26-g623cec72-dirty
205
+ addTwoAddress: "0x4A49112FB866F6d5D05845D264b430cD3bbAb9f6"
206
+ - decryptSigner: "0xA8822DE8910f66D3d03F1eAfe2C0141dBc327Ee0"
207
+ eciesPublicKey: "0x048a582d29083c2f3fefe024bf4dd9ab913ab8973716977da5f01106e0b8\
208
+ 4095b1e647a9e377175fcb66bda05087c93b05e1fd53a704d0914bb23a0b2a69e9f235"
209
+ chainId: "84532"
210
+ blockNumber: "24777885"
211
+ chainName: Base Sepolia
212
+ active: true
213
+ deployDate: 2025-04-22T12:14:25.354Z
214
+ commit: v3-26-g623cec72-dirty
215
+ addTwoAddress: "0x2b5E34844997681168049783D30CD84B5962cb50"
216
+ incoLightning_0_1_26__444235330:
217
+ release:
218
+ name: incoLightning_0_1_26__444235330
219
+ executorAddress: "0xdc8eD938ff2eB900bD5f86A88555a9f1956994fC"
220
+ deployer: "0x8202D2D747784Cb7D48868E44C42C4bf162a70BC"
221
+ pepper: devnet
222
+ version:
223
+ major: 0
224
+ minor: 1
225
+ patch: 26
226
+ shortSalt: "444235330"
227
+ salt: "0x8202d2d747784cb7d48868e44c42c4bf162a70bc001bab4c5927c52fbea0d042"
228
+ deployments:
229
+ - decryptSigner: "0x000000000000000000000000000000000000baBe"
230
+ eciesPublicKey: "0x000000000000000000000000000000000000000000000000000000000000\
231
+ 000000000000000000000000000000000000000000000000000000000000000000babe"
232
+ chainId: "7311099111"
233
+ blockNumber: "1"
234
+ chainName: Inco Release Chain
235
+ active: true
236
+ deployDate: 2025-04-22T09:11:15.398Z
237
+ commit: v3-24-gc9716e6c-dirty
238
+ addTwoAddress: "0x70fC34B18B12E945cb2204FA77E5f8e1581890C3"
239
+ - decryptSigner: "0xA8822DE8910f66D3d03F1eAfe2C0141dBc327Ee0"
240
+ eciesPublicKey: "0x048a582d29083c2f3fefe024bf4dd9ab913ab8973716977da5f01106e0b8\
241
+ 4095b1e647a9e377175fcb66bda05087c93b05e1fd53a704d0914bb23a0b2a69e9f235"
242
+ chainId: "10143"
243
+ blockNumber: "13418528"
244
+ chainName: Monad Testnet
245
+ active: true
246
+ deployDate: 2025-04-22T09:11:06.223Z
247
+ commit: v3-24-gc9716e6c-dirty
248
+ addTwoAddress: "0xfeE9C1E41b2268a4ad8EaDA35f510b8d89Cd041c"
249
+ - decryptSigner: "0xA8822DE8910f66D3d03F1eAfe2C0141dBc327Ee0"
250
+ eciesPublicKey: "0x048a582d29083c2f3fefe024bf4dd9ab913ab8973716977da5f01106e0b8\
251
+ 4095b1e647a9e377175fcb66bda05087c93b05e1fd53a704d0914bb23a0b2a69e9f235"
252
+ chainId: "84532"
253
+ blockNumber: "24772369"
254
+ chainName: Base Sepolia
255
+ active: true
256
+ deployDate: 2025-04-22T09:10:33.275Z
257
+ commit: v3-24-gc9716e6c-dirty
258
+ addTwoAddress: "0xeEa387f7c866A81c2AF532D9ed48c60F179C9827"
package/package.json CHANGED
@@ -1,18 +1,19 @@
1
1
  {
2
2
  "name": "@inco/lightning",
3
- "version": "0.1.20",
3
+ "version": "0.1.29",
4
4
  "repository": "https://github.com/Inco-fhevm/inco-monorepo",
5
5
  "files": [
6
6
  "src/",
7
7
  "foundry.toml",
8
8
  "dumps/",
9
9
  "CHANGELOG.md",
10
- "remappings.txt"
10
+ "remappings.txt",
11
+ "foundry.toml",
12
+ "manifest.yaml"
11
13
  ],
12
14
  "scripts": {
13
- "generate:libraries": "bun run ../pega/lib/deployment/cmd/generate-libraries.ts",
14
15
  "publish:github": "bun publish --registry=https://npm.pkg.github.com",
15
- "publish:npm": "bun publish --access public"
16
+ "generate:libraries": "bun run ../pega/lib/deployment/cmd/generate-libraries.ts"
16
17
  },
17
18
  "dependencies": {
18
19
  "@openzeppelin/contracts": "^5.2.0",
package/src/Lib.sol CHANGED
@@ -8,7 +8,7 @@ pragma solidity ^0.8;
8
8
  import "./IncoLightning.sol";
9
9
  import { ebool, euint256, ETypes } from "./Types.sol";
10
10
 
11
- IncoLightning constant inco = IncoLightning(0xc3c81F7Bf86Af7ed3a5f5Bb1924A063a1c126cDd);
11
+ IncoLightning constant inco = IncoLightning(0x63D8135aF4D393B1dB43B649010c8D3EE19FC9fd);
12
12
  address constant deployedBy = 0x8202D2D747784Cb7D48868E44C42C4bf162a70BC;
13
13
  uint256 constant defaultDecryptionDelayLimit = 2 hours;
14
14
 
@@ -0,0 +1,389 @@
1
+ // AUTOGENERATED FILE. DO NOT EDIT.
2
+ // This file was generated by the IncoLightning library generator.
3
+ // The original template is located at Lib.template.sol
4
+
5
+ /// SPDX-License-Identifier: No License
6
+ pragma solidity ^0.8;
7
+
8
+ import "../IncoLightning.sol";
9
+ import { ebool, euint256, ETypes } from "../Types.sol";
10
+
11
+ IncoLightning constant inco = IncoLightning(0xbfb55e2E217edAD49910C3E8c411FbdD4bF9aaA5);
12
+ address constant deployedBy = 0x8202D2D747784Cb7D48868E44C42C4bf162a70BC;
13
+ uint256 constant defaultDecryptionDelayLimit = 2 hours;
14
+
15
+ library e {
16
+ function sanitize(euint256 a) internal returns (euint256) {
17
+ if (euint256.unwrap(a) == bytes32(0)) {
18
+ return asEuint256(0);
19
+ }
20
+ return a;
21
+ }
22
+
23
+ function sanitize(ebool a) internal returns (ebool) {
24
+ if (ebool.unwrap(a) == bytes32(0)) {
25
+ return asEbool(false);
26
+ }
27
+ return a;
28
+ }
29
+
30
+ function s(euint256 a) internal returns (euint256) {
31
+ return sanitize(a);
32
+ }
33
+
34
+ function s(ebool a) internal returns (ebool) {
35
+ return sanitize(a);
36
+ }
37
+
38
+ function add(euint256 a, euint256 b) internal returns (euint256) {
39
+ return inco.eAdd(s(a), s(b));
40
+ }
41
+
42
+ function add(euint256 a, uint256 b) internal returns (euint256) {
43
+ return inco.eAdd(s(a), asEuint256(b));
44
+ }
45
+
46
+ function add(uint256 a, euint256 b) internal returns (euint256) {
47
+ return inco.eAdd(asEuint256(a), s(b));
48
+ }
49
+
50
+ function sub(euint256 a, euint256 b) internal returns (euint256) {
51
+ return inco.eSub(s(a), s(b));
52
+ }
53
+
54
+ function sub(euint256 a, uint256 b) internal returns (euint256) {
55
+ return inco.eSub(s(a), asEuint256(b));
56
+ }
57
+
58
+ function sub(uint256 a, euint256 b) internal returns (euint256) {
59
+ return inco.eSub(asEuint256(a), s(b));
60
+ }
61
+
62
+ function mul(euint256 a, euint256 b) internal returns (euint256) {
63
+ return inco.eMul(s(a), s(b));
64
+ }
65
+
66
+ function mul(euint256 a, uint256 b) internal returns (euint256) {
67
+ return inco.eMul(s(a), asEuint256(b));
68
+ }
69
+
70
+ function mul(uint256 a, euint256 b) internal returns (euint256) {
71
+ return inco.eMul(asEuint256(a), s(b));
72
+ }
73
+
74
+ function div(euint256 a, euint256 b) internal returns (euint256) {
75
+ return inco.eDiv(s(a), s(b));
76
+ }
77
+
78
+ function div(euint256 a, uint256 b) internal returns (euint256) {
79
+ return inco.eDiv(s(a), asEuint256(b));
80
+ }
81
+
82
+ function div(uint256 a, euint256 b) internal returns (euint256) {
83
+ return inco.eDiv(asEuint256(a), s(b));
84
+ }
85
+
86
+ function rem(euint256 a, euint256 b) internal returns (euint256) {
87
+ return inco.eRem(s(a), s(b));
88
+ }
89
+
90
+ function rem(euint256 a, uint256 b) internal returns (euint256) {
91
+ return inco.eRem(s(a), asEuint256(b));
92
+ }
93
+
94
+ function rem(uint256 a, euint256 b) internal returns (euint256) {
95
+ return inco.eRem(asEuint256(a), s(b));
96
+ }
97
+
98
+ function and(euint256 a, euint256 b) internal returns (euint256) {
99
+ return euint256.wrap(inco.eBitAnd(euint256.unwrap(s(a)), euint256.unwrap(s(b))));
100
+ }
101
+
102
+ function and(euint256 a, uint256 b) internal returns (euint256) {
103
+ return euint256.wrap(inco.eBitAnd(euint256.unwrap(s(a)), euint256.unwrap(asEuint256(b))));
104
+ }
105
+
106
+ function and(uint256 a, euint256 b) internal returns (euint256) {
107
+ return euint256.wrap(inco.eBitAnd(euint256.unwrap(asEuint256(a)), euint256.unwrap(s(b))));
108
+ }
109
+
110
+ function and(ebool a, ebool b) internal returns (ebool) {
111
+ return ebool.wrap(inco.eBitAnd(ebool.unwrap(s(a)), ebool.unwrap(s(b))));
112
+ }
113
+
114
+ function and(ebool a, bool b) internal returns (ebool) {
115
+ return ebool.wrap(inco.eBitAnd(ebool.unwrap(s(a)), ebool.unwrap(asEbool(b))));
116
+ }
117
+
118
+ function and(bool a, ebool b) internal returns (ebool) {
119
+ return ebool.wrap(inco.eBitAnd(ebool.unwrap(asEbool(a)), ebool.unwrap(s(b))));
120
+ }
121
+
122
+ function or(euint256 a, euint256 b) internal returns (euint256) {
123
+ return euint256.wrap(inco.eBitOr(euint256.unwrap(s(a)), euint256.unwrap(s(b))));
124
+ }
125
+
126
+ function or(euint256 a, uint256 b) internal returns (euint256) {
127
+ return euint256.wrap(inco.eBitOr(euint256.unwrap(s(a)), euint256.unwrap(asEuint256(b))));
128
+ }
129
+
130
+ function or(uint256 a, euint256 b) internal returns (euint256) {
131
+ return euint256.wrap(inco.eBitOr(euint256.unwrap(asEuint256(a)), euint256.unwrap(s(b))));
132
+ }
133
+
134
+ function or(ebool a, ebool b) internal returns (ebool) {
135
+ return ebool.wrap(inco.eBitOr(ebool.unwrap(s(a)), ebool.unwrap(s(b))));
136
+ }
137
+
138
+ function or(ebool a, bool b) internal returns (ebool) {
139
+ return ebool.wrap(inco.eBitOr(ebool.unwrap(s(a)), ebool.unwrap(asEbool(b))));
140
+ }
141
+
142
+ function or(bool a, ebool b) internal returns (ebool) {
143
+ return ebool.wrap(inco.eBitOr(ebool.unwrap(asEbool(a)), ebool.unwrap(s(b))));
144
+ }
145
+
146
+ function xor(euint256 a, euint256 b) internal returns (euint256) {
147
+ return euint256.wrap(inco.eBitXor(euint256.unwrap(s(a)), euint256.unwrap(s(b))));
148
+ }
149
+
150
+ function xor(euint256 a, uint256 b) internal returns (euint256) {
151
+ return euint256.wrap(inco.eBitXor(euint256.unwrap(s(a)), euint256.unwrap(asEuint256(b))));
152
+ }
153
+
154
+ function xor(uint256 a, euint256 b) internal returns (euint256) {
155
+ return euint256.wrap(inco.eBitXor(euint256.unwrap(asEuint256(a)), euint256.unwrap(s(b))));
156
+ }
157
+
158
+ function xor(ebool a, ebool b) internal returns (ebool) {
159
+ return ebool.wrap(inco.eBitXor(ebool.unwrap(s(a)), ebool.unwrap(s(b))));
160
+ }
161
+
162
+ function xor(ebool a, bool b) internal returns (ebool) {
163
+ return ebool.wrap(inco.eBitXor(ebool.unwrap(s(a)), ebool.unwrap(asEbool(b))));
164
+ }
165
+
166
+ function xor(bool a, ebool b) internal returns (ebool) {
167
+ return ebool.wrap(inco.eBitXor(ebool.unwrap(asEbool(a)), ebool.unwrap(s(b))));
168
+ }
169
+
170
+ function shl(euint256 a, euint256 b) internal returns (euint256) {
171
+ return inco.eShl(s(a), s(b));
172
+ }
173
+
174
+ function shl(euint256 a, uint256 b) internal returns (euint256) {
175
+ return inco.eShl(s(a), asEuint256(b));
176
+ }
177
+
178
+ function shl(uint256 a, euint256 b) internal returns (euint256) {
179
+ return inco.eShl(asEuint256(a), s(b));
180
+ }
181
+
182
+ function shr(euint256 a, euint256 b) internal returns (euint256) {
183
+ return inco.eShr(s(a), s(b));
184
+ }
185
+
186
+ function shr(euint256 a, uint256 b) internal returns (euint256) {
187
+ return inco.eShr(s(a), asEuint256(b));
188
+ }
189
+
190
+ function shr(uint256 a, euint256 b) internal returns (euint256) {
191
+ return inco.eShr(asEuint256(a), s(b));
192
+ }
193
+
194
+ function rotl(euint256 a, euint256 b) internal returns (euint256) {
195
+ return inco.eRotl(s(a), s(b));
196
+ }
197
+
198
+ function rotl(euint256 a, uint256 b) internal returns (euint256) {
199
+ return inco.eRotl(s(a), asEuint256(b));
200
+ }
201
+
202
+ function rotl(uint256 a, euint256 b) internal returns (euint256) {
203
+ return inco.eRotl(asEuint256(a), s(b));
204
+ }
205
+
206
+ function rotr(euint256 a, euint256 b) internal returns (euint256) {
207
+ return inco.eRotr(s(a), s(b));
208
+ }
209
+
210
+ function rotr(euint256 a, uint256 b) internal returns (euint256) {
211
+ return inco.eRotr(s(a), asEuint256(b));
212
+ }
213
+
214
+ function rotr(uint256 a, euint256 b) internal returns (euint256) {
215
+ return inco.eRotr(asEuint256(a), s(b));
216
+ }
217
+
218
+ function eq(euint256 a, euint256 b) internal returns (ebool) {
219
+ return inco.eEq(s(a), s(b));
220
+ }
221
+
222
+ function eq(euint256 a, uint256 b) internal returns (ebool) {
223
+ return inco.eEq(s(a), asEuint256(b));
224
+ }
225
+
226
+ function eq(uint256 a, euint256 b) internal returns (ebool) {
227
+ return inco.eEq(asEuint256(a), s(b));
228
+ }
229
+
230
+ function ne(euint256 a, euint256 b) internal returns (ebool) {
231
+ return inco.eNe(s(a), s(b));
232
+ }
233
+
234
+ function ne(euint256 a, uint256 b) internal returns (ebool) {
235
+ return inco.eNe(s(a), asEuint256(b));
236
+ }
237
+
238
+ function ne(uint256 a, euint256 b) internal returns (ebool) {
239
+ return inco.eNe(asEuint256(a), s(b));
240
+ }
241
+
242
+ function ge(euint256 a, euint256 b) internal returns (ebool) {
243
+ return inco.eGe(s(a), s(b));
244
+ }
245
+
246
+ function ge(euint256 a, uint256 b) internal returns (ebool) {
247
+ return inco.eGe(s(a), asEuint256(b));
248
+ }
249
+
250
+ function ge(uint256 a, euint256 b) internal returns (ebool) {
251
+ return inco.eGe(asEuint256(a), s(b));
252
+ }
253
+
254
+ function gt(euint256 a, euint256 b) internal returns (ebool) {
255
+ return inco.eGt(s(a), s(b));
256
+ }
257
+
258
+ function gt(euint256 a, uint256 b) internal returns (ebool) {
259
+ return inco.eGt(s(a), asEuint256(b));
260
+ }
261
+
262
+ function gt(uint256 a, euint256 b) internal returns (ebool) {
263
+ return inco.eGt(asEuint256(a), s(b));
264
+ }
265
+
266
+ function le(euint256 a, euint256 b) internal returns (ebool) {
267
+ return inco.eLe(s(a), s(b));
268
+ }
269
+
270
+ function le(euint256 a, uint256 b) internal returns (ebool) {
271
+ return inco.eLe(s(a), asEuint256(b));
272
+ }
273
+
274
+ function le(uint256 a, euint256 b) internal returns (ebool) {
275
+ return inco.eLe(asEuint256(a), s(b));
276
+ }
277
+
278
+ function lt(euint256 a, euint256 b) internal returns (ebool) {
279
+ return inco.eLt(s(a), s(b));
280
+ }
281
+
282
+ function lt(euint256 a, uint256 b) internal returns (ebool) {
283
+ return inco.eLt(s(a), asEuint256(b));
284
+ }
285
+
286
+ function lt(uint256 a, euint256 b) internal returns (ebool) {
287
+ return inco.eLt(asEuint256(a), s(b));
288
+ }
289
+
290
+ function min(euint256 a, euint256 b) internal returns (euint256) {
291
+ return inco.eMin(s(a), s(b));
292
+ }
293
+
294
+ function min(euint256 a, uint256 b) internal returns (euint256) {
295
+ return inco.eMin(s(a), asEuint256(b));
296
+ }
297
+
298
+ function min(uint256 a, euint256 b) internal returns (euint256) {
299
+ return inco.eMin(asEuint256(a), s(b));
300
+ }
301
+
302
+ function max(euint256 a, euint256 b) internal returns (euint256) {
303
+ return inco.eMax(s(a), s(b));
304
+ }
305
+
306
+ function max(euint256 a, uint256 b) internal returns (euint256) {
307
+ return inco.eMax(s(a), asEuint256(b));
308
+ }
309
+
310
+ function max(uint256 a, euint256 b) internal returns (euint256) {
311
+ return inco.eMax(asEuint256(a), s(b));
312
+ }
313
+
314
+ function not(ebool a) internal returns (ebool) {
315
+ return inco.eNot(s(a));
316
+ }
317
+
318
+ function rand() internal returns (euint256) {
319
+ return euint256.wrap(inco.eRand(ETypes.Uint256));
320
+ }
321
+
322
+ function randBounded(uint256 upperBound) internal returns (euint256) {
323
+ return euint256.wrap(inco.eRandBounded(euint256.unwrap(asEuint256(upperBound)), ETypes.Uint256));
324
+ }
325
+
326
+ function randBounded(euint256 upperBound) internal returns (euint256) {
327
+ return euint256.wrap(inco.eRandBounded(euint256.unwrap(s(upperBound)), ETypes.Uint256));
328
+ }
329
+
330
+ function asEuint256(uint256 a) internal returns (euint256) {
331
+ return inco.asEuint256(a);
332
+ }
333
+
334
+ function asEbool(bool a) internal returns (ebool) {
335
+ return inco.asEbool(a);
336
+ }
337
+
338
+ function asEbool(euint256 a) internal returns (ebool) {
339
+ return ebool.wrap(inco.eCast(euint256.unwrap(a), ETypes.Bool));
340
+ }
341
+
342
+ function asEuint256(ebool a) internal returns (euint256) {
343
+ return euint256.wrap(inco.eCast(ebool.unwrap(a), ETypes.Uint256));
344
+ }
345
+
346
+ function newEuint256(bytes memory ciphertext, address user) internal returns (euint256) {
347
+ return inco.newEuint256(ciphertext, user);
348
+ }
349
+
350
+ function newEbool(bytes memory ciphertext, address user) internal returns (ebool) {
351
+ return inco.newEbool(ciphertext, user);
352
+ }
353
+
354
+ function allow(euint256 a, address to) internal {
355
+ inco.allow(euint256.unwrap(a), to);
356
+ }
357
+
358
+ function allow(ebool a, address to) internal {
359
+ inco.allow(ebool.unwrap(a), to);
360
+ }
361
+
362
+ function allowThis(euint256 a) internal {
363
+ allow(a, address(this));
364
+ }
365
+
366
+ function allowThis(ebool a) internal {
367
+ allow(a, address(this));
368
+ }
369
+
370
+ function isAllowed(address user, euint256 a) internal view returns (bool) {
371
+ return inco.isAllowed(euint256.unwrap(a), user);
372
+ }
373
+
374
+ function select(ebool control, euint256 ifTrue, euint256 ifFalse) internal returns (euint256) {
375
+ return euint256.wrap(inco.eIfThenElse(s(control), euint256.unwrap(s(ifTrue)), euint256.unwrap(s(ifFalse))));
376
+ }
377
+
378
+ function select(ebool control, ebool ifTrue, ebool ifFalse) internal returns (ebool) {
379
+ return ebool.wrap(inco.eIfThenElse(s(control), ebool.unwrap(s(ifTrue)), ebool.unwrap(s(ifFalse))));
380
+ }
381
+
382
+ function requestDecryption(euint256 a, bytes4 callbackSelector, bytes memory callbackData) internal returns (uint256 requestId) {
383
+ requestId = inco.requestDecryption(callbackSelector, block.timestamp + defaultDecryptionDelayLimit, euint256.unwrap(s(a)), callbackData);
384
+ }
385
+
386
+ function requestDecryption(ebool a, bytes4 callbackSelector, bytes memory callbackData) internal returns (uint256 requestId) {
387
+ requestId = inco.requestDecryption(callbackSelector, block.timestamp + defaultDecryptionDelayLimit, ebool.unwrap(s(a)), callbackData);
388
+ }
389
+ }