Example #1
0
 private void receiveEGTable() {
   int nBytes = (nBits - 1) / 8 + 1;
   try {
     for (int j = 0; j < nCols; j++)
       EGTable[j] = Utils.readBigInteger(nBytes * Wire.labelBitLength, ois);
   } catch (Exception e) {
     e.printStackTrace();
     System.exit(1);
   }
 }
Example #2
0
 private void receiveEGTable_EXT() {
   int nBytes = (nBits - 1) / 8 + 1;
   try {
     for (int j = 0; j < nCols; j++) {
       boolean temp = ois.readBoolean();
       if (temp) EGTable[j] = Utils.readBigInteger(nBytes * Wire.labelBitLength, ois);
       else EGTable[j] = null;
     }
   } catch (Exception e) {
     e.printStackTrace();
     System.exit(1);
   }
 }
  protected void execTransfer() throws Exception {
    sBitslbs = new BigInteger[sInputLen];

    for (int i = 0; i < sInputLen; i++) {
      int bytelength = (Wire.labelBitLength - 1) / 8 + 1;
      sBitslbs[i] = Utils.readBigInteger(bytelength, FindMinimumCommon.ois);
      // System.out.println(sBitslbs[i]);
    }
    // StopWatch.taskTimeStamp("receiving labels for peer's inputs");

    cBitslbs = new BigInteger[cInputLen];
    rcver.execProtocol(cBits);
    cBitslbs = rcver.getData();
    // StopWatch.taskTimeStamp("receiving labels for self's inputs");
  }