@inco/lightning 0.10.0-devnet-2 → 0.11.0-testnet-1
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.
- package/manifest.yaml +23 -0
- package/package.json +1 -1
- package/src/IncoLightning.sol +1 -3
- package/src/IncoVerifier.sol +1 -3
- package/src/Lib.alphanet.sol +19 -0
- package/src/Lib.demonet.sol +19 -0
- package/src/Lib.devnet.sol +19 -0
- package/src/Lib.sol +20 -1
- package/src/Lib.template.sol +19 -0
- package/src/Lib.testnet.sol +20 -1
- package/src/Types.sol +0 -1
- package/src/libs/incoLightning_alphanet_v0_297966649.sol +19 -0
- package/src/libs/incoLightning_alphanet_v1_725458969.sol +19 -0
- package/src/libs/incoLightning_alphanet_v2_976644394.sol +19 -0
- package/src/libs/incoLightning_demonet_v0_863421733.sol +19 -0
- package/src/libs/incoLightning_demonet_v2_467437523.sol +19 -0
- package/src/libs/incoLightning_devnet_v0_340846814.sol +19 -0
- package/src/libs/incoLightning_devnet_v10_266391127.sol +19 -0
- package/src/libs/incoLightning_devnet_v1_904635675.sol +19 -0
- package/src/libs/incoLightning_devnet_v2_295237520.sol +19 -0
- package/src/libs/incoLightning_devnet_v3_976859633.sol +19 -0
- package/src/libs/incoLightning_devnet_v4_409204766.sol +19 -0
- package/src/libs/incoLightning_devnet_v5_203964628.sol +19 -0
- package/src/libs/incoLightning_devnet_v6_281949651.sol +19 -0
- package/src/libs/incoLightning_devnet_v7_24560427.sol +19 -0
- package/src/libs/incoLightning_devnet_v8_985328058.sol +19 -0
- package/src/libs/incoLightning_devnet_v9_269218568.sol +19 -0
- package/src/libs/incoLightning_testnet_v0_183408998.sol +19 -0
- package/src/libs/incoLightning_testnet_v11_340321378.sol +1242 -0
- package/src/libs/incoLightning_testnet_v2_889158349.sol +19 -0
- package/src/lightning-parts/EncryptedOperations.sol +2 -9
- package/src/lightning-parts/primitives/EListHandleMetadata.sol +6 -6
- package/src/lightning-parts/primitives/HandleGeneration.sol +3 -10
- package/src/lightning-parts/primitives/HandleMetadata.sol +10 -10
- package/src/lightning-parts/test/HandleMetadata.t.sol +22 -40
- package/src/test/IncoTest.sol +2 -3
- package/src/test/TestLib.t.sol +65 -0
- package/src/version/IncoLightningConfig.sol +1 -1
|
@@ -801,6 +801,13 @@ library e {
|
|
|
801
801
|
inco.allow(eaddress.unwrap(a), to);
|
|
802
802
|
}
|
|
803
803
|
|
|
804
|
+
/// @notice Allows an address to access an elist
|
|
805
|
+
/// @param a The elist
|
|
806
|
+
/// @param to The address to allow
|
|
807
|
+
function allow(elist a, address to) internal {
|
|
808
|
+
inco.allow(elist.unwrap(a), to);
|
|
809
|
+
}
|
|
810
|
+
|
|
804
811
|
/// @notice Reveals an encrypted uint256
|
|
805
812
|
/// @param a The encrypted uint256
|
|
806
813
|
function reveal(euint256 a) internal {
|
|
@@ -819,6 +826,12 @@ library e {
|
|
|
819
826
|
inco.reveal(eaddress.unwrap(a));
|
|
820
827
|
}
|
|
821
828
|
|
|
829
|
+
/// @notice Reveals an elist (makes all elements publicly readable without wallet authentication)
|
|
830
|
+
/// @param a The elist
|
|
831
|
+
function reveal(elist a) internal {
|
|
832
|
+
inco.reveal(elist.unwrap(a));
|
|
833
|
+
}
|
|
834
|
+
|
|
822
835
|
/// @notice Verifies a decryption attestation for a euint256
|
|
823
836
|
/// @param handle The encrypted handle
|
|
824
837
|
/// @param value The claimed decrypted value
|
|
@@ -857,6 +870,12 @@ library e {
|
|
|
857
870
|
allow(a, address(this));
|
|
858
871
|
}
|
|
859
872
|
|
|
873
|
+
/// @notice Allows this contract to access an elist
|
|
874
|
+
/// @param a The elist
|
|
875
|
+
function allowThis(elist a) internal {
|
|
876
|
+
allow(a, address(this));
|
|
877
|
+
}
|
|
878
|
+
|
|
860
879
|
/// @notice Checks if a user is allowed to access an encrypted uint256
|
|
861
880
|
/// @param user The address to check
|
|
862
881
|
/// @param a The encrypted uint256
|
|
@@ -801,6 +801,13 @@ library e {
|
|
|
801
801
|
inco.allow(eaddress.unwrap(a), to);
|
|
802
802
|
}
|
|
803
803
|
|
|
804
|
+
/// @notice Allows an address to access an elist
|
|
805
|
+
/// @param a The elist
|
|
806
|
+
/// @param to The address to allow
|
|
807
|
+
function allow(elist a, address to) internal {
|
|
808
|
+
inco.allow(elist.unwrap(a), to);
|
|
809
|
+
}
|
|
810
|
+
|
|
804
811
|
/// @notice Reveals an encrypted uint256
|
|
805
812
|
/// @param a The encrypted uint256
|
|
806
813
|
function reveal(euint256 a) internal {
|
|
@@ -819,6 +826,12 @@ library e {
|
|
|
819
826
|
inco.reveal(eaddress.unwrap(a));
|
|
820
827
|
}
|
|
821
828
|
|
|
829
|
+
/// @notice Reveals an elist (makes all elements publicly readable without wallet authentication)
|
|
830
|
+
/// @param a The elist
|
|
831
|
+
function reveal(elist a) internal {
|
|
832
|
+
inco.reveal(elist.unwrap(a));
|
|
833
|
+
}
|
|
834
|
+
|
|
822
835
|
/// @notice Verifies a decryption attestation for a euint256
|
|
823
836
|
/// @param handle The encrypted handle
|
|
824
837
|
/// @param value The claimed decrypted value
|
|
@@ -857,6 +870,12 @@ library e {
|
|
|
857
870
|
allow(a, address(this));
|
|
858
871
|
}
|
|
859
872
|
|
|
873
|
+
/// @notice Allows this contract to access an elist
|
|
874
|
+
/// @param a The elist
|
|
875
|
+
function allowThis(elist a) internal {
|
|
876
|
+
allow(a, address(this));
|
|
877
|
+
}
|
|
878
|
+
|
|
860
879
|
/// @notice Checks if a user is allowed to access an encrypted uint256
|
|
861
880
|
/// @param user The address to check
|
|
862
881
|
/// @param a The encrypted uint256
|
|
@@ -801,6 +801,13 @@ library e {
|
|
|
801
801
|
inco.allow(eaddress.unwrap(a), to);
|
|
802
802
|
}
|
|
803
803
|
|
|
804
|
+
/// @notice Allows an address to access an elist
|
|
805
|
+
/// @param a The elist
|
|
806
|
+
/// @param to The address to allow
|
|
807
|
+
function allow(elist a, address to) internal {
|
|
808
|
+
inco.allow(elist.unwrap(a), to);
|
|
809
|
+
}
|
|
810
|
+
|
|
804
811
|
/// @notice Reveals an encrypted uint256
|
|
805
812
|
/// @param a The encrypted uint256
|
|
806
813
|
function reveal(euint256 a) internal {
|
|
@@ -819,6 +826,12 @@ library e {
|
|
|
819
826
|
inco.reveal(eaddress.unwrap(a));
|
|
820
827
|
}
|
|
821
828
|
|
|
829
|
+
/// @notice Reveals an elist (makes all elements publicly readable without wallet authentication)
|
|
830
|
+
/// @param a The elist
|
|
831
|
+
function reveal(elist a) internal {
|
|
832
|
+
inco.reveal(elist.unwrap(a));
|
|
833
|
+
}
|
|
834
|
+
|
|
822
835
|
/// @notice Verifies a decryption attestation for a euint256
|
|
823
836
|
/// @param handle The encrypted handle
|
|
824
837
|
/// @param value The claimed decrypted value
|
|
@@ -857,6 +870,12 @@ library e {
|
|
|
857
870
|
allow(a, address(this));
|
|
858
871
|
}
|
|
859
872
|
|
|
873
|
+
/// @notice Allows this contract to access an elist
|
|
874
|
+
/// @param a The elist
|
|
875
|
+
function allowThis(elist a) internal {
|
|
876
|
+
allow(a, address(this));
|
|
877
|
+
}
|
|
878
|
+
|
|
860
879
|
/// @notice Checks if a user is allowed to access an encrypted uint256
|
|
861
880
|
/// @param user The address to check
|
|
862
881
|
/// @param a The encrypted uint256
|
|
@@ -801,6 +801,13 @@ library e {
|
|
|
801
801
|
inco.allow(eaddress.unwrap(a), to);
|
|
802
802
|
}
|
|
803
803
|
|
|
804
|
+
/// @notice Allows an address to access an elist
|
|
805
|
+
/// @param a The elist
|
|
806
|
+
/// @param to The address to allow
|
|
807
|
+
function allow(elist a, address to) internal {
|
|
808
|
+
inco.allow(elist.unwrap(a), to);
|
|
809
|
+
}
|
|
810
|
+
|
|
804
811
|
/// @notice Reveals an encrypted uint256
|
|
805
812
|
/// @param a The encrypted uint256
|
|
806
813
|
function reveal(euint256 a) internal {
|
|
@@ -819,6 +826,12 @@ library e {
|
|
|
819
826
|
inco.reveal(eaddress.unwrap(a));
|
|
820
827
|
}
|
|
821
828
|
|
|
829
|
+
/// @notice Reveals an elist (makes all elements publicly readable without wallet authentication)
|
|
830
|
+
/// @param a The elist
|
|
831
|
+
function reveal(elist a) internal {
|
|
832
|
+
inco.reveal(elist.unwrap(a));
|
|
833
|
+
}
|
|
834
|
+
|
|
822
835
|
/// @notice Verifies a decryption attestation for a euint256
|
|
823
836
|
/// @param handle The encrypted handle
|
|
824
837
|
/// @param value The claimed decrypted value
|
|
@@ -857,6 +870,12 @@ library e {
|
|
|
857
870
|
allow(a, address(this));
|
|
858
871
|
}
|
|
859
872
|
|
|
873
|
+
/// @notice Allows this contract to access an elist
|
|
874
|
+
/// @param a The elist
|
|
875
|
+
function allowThis(elist a) internal {
|
|
876
|
+
allow(a, address(this));
|
|
877
|
+
}
|
|
878
|
+
|
|
860
879
|
/// @notice Checks if a user is allowed to access an encrypted uint256
|
|
861
880
|
/// @param user The address to check
|
|
862
881
|
/// @param a The encrypted uint256
|
|
@@ -801,6 +801,13 @@ library e {
|
|
|
801
801
|
inco.allow(eaddress.unwrap(a), to);
|
|
802
802
|
}
|
|
803
803
|
|
|
804
|
+
/// @notice Allows an address to access an elist
|
|
805
|
+
/// @param a The elist
|
|
806
|
+
/// @param to The address to allow
|
|
807
|
+
function allow(elist a, address to) internal {
|
|
808
|
+
inco.allow(elist.unwrap(a), to);
|
|
809
|
+
}
|
|
810
|
+
|
|
804
811
|
/// @notice Reveals an encrypted uint256
|
|
805
812
|
/// @param a The encrypted uint256
|
|
806
813
|
function reveal(euint256 a) internal {
|
|
@@ -819,6 +826,12 @@ library e {
|
|
|
819
826
|
inco.reveal(eaddress.unwrap(a));
|
|
820
827
|
}
|
|
821
828
|
|
|
829
|
+
/// @notice Reveals an elist (makes all elements publicly readable without wallet authentication)
|
|
830
|
+
/// @param a The elist
|
|
831
|
+
function reveal(elist a) internal {
|
|
832
|
+
inco.reveal(elist.unwrap(a));
|
|
833
|
+
}
|
|
834
|
+
|
|
822
835
|
/// @notice Verifies a decryption attestation for a euint256
|
|
823
836
|
/// @param handle The encrypted handle
|
|
824
837
|
/// @param value The claimed decrypted value
|
|
@@ -857,6 +870,12 @@ library e {
|
|
|
857
870
|
allow(a, address(this));
|
|
858
871
|
}
|
|
859
872
|
|
|
873
|
+
/// @notice Allows this contract to access an elist
|
|
874
|
+
/// @param a The elist
|
|
875
|
+
function allowThis(elist a) internal {
|
|
876
|
+
allow(a, address(this));
|
|
877
|
+
}
|
|
878
|
+
|
|
860
879
|
/// @notice Checks if a user is allowed to access an encrypted uint256
|
|
861
880
|
/// @param user The address to check
|
|
862
881
|
/// @param a The encrypted uint256
|
|
@@ -801,6 +801,13 @@ library e {
|
|
|
801
801
|
inco.allow(eaddress.unwrap(a), to);
|
|
802
802
|
}
|
|
803
803
|
|
|
804
|
+
/// @notice Allows an address to access an elist
|
|
805
|
+
/// @param a The elist
|
|
806
|
+
/// @param to The address to allow
|
|
807
|
+
function allow(elist a, address to) internal {
|
|
808
|
+
inco.allow(elist.unwrap(a), to);
|
|
809
|
+
}
|
|
810
|
+
|
|
804
811
|
/// @notice Reveals an encrypted uint256
|
|
805
812
|
/// @param a The encrypted uint256
|
|
806
813
|
function reveal(euint256 a) internal {
|
|
@@ -819,6 +826,12 @@ library e {
|
|
|
819
826
|
inco.reveal(eaddress.unwrap(a));
|
|
820
827
|
}
|
|
821
828
|
|
|
829
|
+
/// @notice Reveals an elist (makes all elements publicly readable without wallet authentication)
|
|
830
|
+
/// @param a The elist
|
|
831
|
+
function reveal(elist a) internal {
|
|
832
|
+
inco.reveal(elist.unwrap(a));
|
|
833
|
+
}
|
|
834
|
+
|
|
822
835
|
/// @notice Verifies a decryption attestation for a euint256
|
|
823
836
|
/// @param handle The encrypted handle
|
|
824
837
|
/// @param value The claimed decrypted value
|
|
@@ -857,6 +870,12 @@ library e {
|
|
|
857
870
|
allow(a, address(this));
|
|
858
871
|
}
|
|
859
872
|
|
|
873
|
+
/// @notice Allows this contract to access an elist
|
|
874
|
+
/// @param a The elist
|
|
875
|
+
function allowThis(elist a) internal {
|
|
876
|
+
allow(a, address(this));
|
|
877
|
+
}
|
|
878
|
+
|
|
860
879
|
/// @notice Checks if a user is allowed to access an encrypted uint256
|
|
861
880
|
/// @param user The address to check
|
|
862
881
|
/// @param a The encrypted uint256
|
|
@@ -801,6 +801,13 @@ library e {
|
|
|
801
801
|
inco.allow(eaddress.unwrap(a), to);
|
|
802
802
|
}
|
|
803
803
|
|
|
804
|
+
/// @notice Allows an address to access an elist
|
|
805
|
+
/// @param a The elist
|
|
806
|
+
/// @param to The address to allow
|
|
807
|
+
function allow(elist a, address to) internal {
|
|
808
|
+
inco.allow(elist.unwrap(a), to);
|
|
809
|
+
}
|
|
810
|
+
|
|
804
811
|
/// @notice Reveals an encrypted uint256
|
|
805
812
|
/// @param a The encrypted uint256
|
|
806
813
|
function reveal(euint256 a) internal {
|
|
@@ -819,6 +826,12 @@ library e {
|
|
|
819
826
|
inco.reveal(eaddress.unwrap(a));
|
|
820
827
|
}
|
|
821
828
|
|
|
829
|
+
/// @notice Reveals an elist (makes all elements publicly readable without wallet authentication)
|
|
830
|
+
/// @param a The elist
|
|
831
|
+
function reveal(elist a) internal {
|
|
832
|
+
inco.reveal(elist.unwrap(a));
|
|
833
|
+
}
|
|
834
|
+
|
|
822
835
|
/// @notice Verifies a decryption attestation for a euint256
|
|
823
836
|
/// @param handle The encrypted handle
|
|
824
837
|
/// @param value The claimed decrypted value
|
|
@@ -857,6 +870,12 @@ library e {
|
|
|
857
870
|
allow(a, address(this));
|
|
858
871
|
}
|
|
859
872
|
|
|
873
|
+
/// @notice Allows this contract to access an elist
|
|
874
|
+
/// @param a The elist
|
|
875
|
+
function allowThis(elist a) internal {
|
|
876
|
+
allow(a, address(this));
|
|
877
|
+
}
|
|
878
|
+
|
|
860
879
|
/// @notice Checks if a user is allowed to access an encrypted uint256
|
|
861
880
|
/// @param user The address to check
|
|
862
881
|
/// @param a The encrypted uint256
|
|
@@ -801,6 +801,13 @@ library e {
|
|
|
801
801
|
inco.allow(eaddress.unwrap(a), to);
|
|
802
802
|
}
|
|
803
803
|
|
|
804
|
+
/// @notice Allows an address to access an elist
|
|
805
|
+
/// @param a The elist
|
|
806
|
+
/// @param to The address to allow
|
|
807
|
+
function allow(elist a, address to) internal {
|
|
808
|
+
inco.allow(elist.unwrap(a), to);
|
|
809
|
+
}
|
|
810
|
+
|
|
804
811
|
/// @notice Reveals an encrypted uint256
|
|
805
812
|
/// @param a The encrypted uint256
|
|
806
813
|
function reveal(euint256 a) internal {
|
|
@@ -819,6 +826,12 @@ library e {
|
|
|
819
826
|
inco.reveal(eaddress.unwrap(a));
|
|
820
827
|
}
|
|
821
828
|
|
|
829
|
+
/// @notice Reveals an elist (makes all elements publicly readable without wallet authentication)
|
|
830
|
+
/// @param a The elist
|
|
831
|
+
function reveal(elist a) internal {
|
|
832
|
+
inco.reveal(elist.unwrap(a));
|
|
833
|
+
}
|
|
834
|
+
|
|
822
835
|
/// @notice Verifies a decryption attestation for a euint256
|
|
823
836
|
/// @param handle The encrypted handle
|
|
824
837
|
/// @param value The claimed decrypted value
|
|
@@ -857,6 +870,12 @@ library e {
|
|
|
857
870
|
allow(a, address(this));
|
|
858
871
|
}
|
|
859
872
|
|
|
873
|
+
/// @notice Allows this contract to access an elist
|
|
874
|
+
/// @param a The elist
|
|
875
|
+
function allowThis(elist a) internal {
|
|
876
|
+
allow(a, address(this));
|
|
877
|
+
}
|
|
878
|
+
|
|
860
879
|
/// @notice Checks if a user is allowed to access an encrypted uint256
|
|
861
880
|
/// @param user The address to check
|
|
862
881
|
/// @param a The encrypted uint256
|
|
@@ -801,6 +801,13 @@ library e {
|
|
|
801
801
|
inco.allow(eaddress.unwrap(a), to);
|
|
802
802
|
}
|
|
803
803
|
|
|
804
|
+
/// @notice Allows an address to access an elist
|
|
805
|
+
/// @param a The elist
|
|
806
|
+
/// @param to The address to allow
|
|
807
|
+
function allow(elist a, address to) internal {
|
|
808
|
+
inco.allow(elist.unwrap(a), to);
|
|
809
|
+
}
|
|
810
|
+
|
|
804
811
|
/// @notice Reveals an encrypted uint256
|
|
805
812
|
/// @param a The encrypted uint256
|
|
806
813
|
function reveal(euint256 a) internal {
|
|
@@ -819,6 +826,12 @@ library e {
|
|
|
819
826
|
inco.reveal(eaddress.unwrap(a));
|
|
820
827
|
}
|
|
821
828
|
|
|
829
|
+
/// @notice Reveals an elist (makes all elements publicly readable without wallet authentication)
|
|
830
|
+
/// @param a The elist
|
|
831
|
+
function reveal(elist a) internal {
|
|
832
|
+
inco.reveal(elist.unwrap(a));
|
|
833
|
+
}
|
|
834
|
+
|
|
822
835
|
/// @notice Verifies a decryption attestation for a euint256
|
|
823
836
|
/// @param handle The encrypted handle
|
|
824
837
|
/// @param value The claimed decrypted value
|
|
@@ -857,6 +870,12 @@ library e {
|
|
|
857
870
|
allow(a, address(this));
|
|
858
871
|
}
|
|
859
872
|
|
|
873
|
+
/// @notice Allows this contract to access an elist
|
|
874
|
+
/// @param a The elist
|
|
875
|
+
function allowThis(elist a) internal {
|
|
876
|
+
allow(a, address(this));
|
|
877
|
+
}
|
|
878
|
+
|
|
860
879
|
/// @notice Checks if a user is allowed to access an encrypted uint256
|
|
861
880
|
/// @param user The address to check
|
|
862
881
|
/// @param a The encrypted uint256
|