Hi @ladnir, I'm encountering difficulties while implementing a comparison and would appreciate your guidance.
My proposed approach for comparing two secret-shared si64Matrix a and b:
1.Compute c = a - b
2.Apply toBinaryMatrix conversion to c
3.Extract MSB
4.Perform bitInjection
Could you confirm if this workflow is fundamentally correct for implementing a secure comparison? When executing toBinaryMatrix, I encounter the error:
party 1 next 1213 mode=server?:1 name 12
party 1 prev 1212 mode=server?:0 name 01
party 1 start
network receive error01._autoName_0 ): End of file
at /home/ubuntu-14900k/Desktop/aby3/thirdparty/libOTe/cryptoTools/cryptoTools/Network/Channel.cpp:818
~~~~~~~~~~~~~~~~ Runtime not empty!!! ~~~~~~~~~~~~~~~~
End of file
My code is:
IOService ios;
Sh3Encryptor enc;
Sh3Evaluator eval;
Sh3Runtime runtime;
Sh3Converter convt;
setup(partyIdx, ios, enc, eval, runtime);
u64 row = 1;
u64 col = 1;
eMatrix<i64> plainMatrix(row, col);
for (u64 i = 0; i < row; ++i)
for (u64 j = 0; j < col; ++j)
plainMatrix(i, j) = 5;
si64Matrix sharedMatrixA(row, col);
if (partyIdx == 0)
enc.localIntMatrix(runtime, plainMatrix, sharedMatrixA).get();
else
enc.remoteIntMatrix(runtime, sharedMatrixA).get();
sbMatrix sharedMatrixB(sharedMatrixA.rows(), sharedMatrixA.cols() * 64);
Sh3Task mulTask = convt.toBinaryMatrix(runtime, sharedMatrixA, sharedMatrixB);
mulTask.get();
return 0;
What could be causing this runtime error? Are there specific preconditions for using toBinaryMatrix that I might have missed?
BTW, does ABY3 natively support malicious security settings? If not, should I implement additional checks?
Thank you for your time and expertise!
Hi @ladnir, I'm encountering difficulties while implementing a comparison and would appreciate your guidance.
My proposed approach for comparing two secret-shared
si64Matrixa and b:1.Compute c = a - b
2.Apply
toBinaryMatrixconversion to c3.Extract MSB
4.Perform
bitInjectionCould you confirm if this workflow is fundamentally correct for implementing a secure comparison? When executing
toBinaryMatrix, I encounter the error:My code is:
What could be causing this runtime error? Are there specific preconditions for using
toBinaryMatrixthat I might have missed?BTW, does ABY3 natively support malicious security settings? If not, should I implement additional checks?
Thank you for your time and expertise!