浏览代码

Works with decryptor, client extension. Need to fix up the IVs for both.

dettanym 6 年之前
父节点
当前提交
0e48f40658
共有 3 个文件被更改,包括 3 次插入5 次删除
  1. 1 3
      ProtobufLAInitiator.cpp
  2. 2 2
      SgxProtobufLAInitiator.cpp
  3. 二进制
      localattestation_decryption.so

+ 1 - 3
ProtobufLAInitiator.cpp

@@ -281,11 +281,9 @@ int decrypt_client_data_through_decryptor( unsigned char* ip_base64_client_publi
   printf("\n");
 
   // Decrypt data from decryptor
-/*  internal_return_status = aes_gcm_wrapper(0,  ciphertext_from_decryptor, ciphertext_from_decryptor_length,
+  internal_return_status = aes_gcm_wrapper(0,  ciphertext_from_decryptor, ciphertext_from_decryptor_length,
     op_plaintext, op_plaintext_length
   );
-*/
-    internal_return_status = 0x34; 
     free(ciphertext_from_decryptor); 
     return internal_return_status;
 

+ 2 - 2
SgxProtobufLAInitiator.cpp

@@ -123,7 +123,7 @@ uint32_t process_protobuf_dh_msg3(protobuf_sgx_dh_msg3_t& protobuf_msg3, uint32_
       ciphertext[counter + *ciphertext_length] = tag[counter];
     *ciphertext_length=*ciphertext_length + 16;
   }
-  if(return_status == 0)
-    aes_gcm_increment_iv_internal_call(iv);
+//  if(return_status == 0)
+//    aes_gcm_increment_iv_internal_call(iv);
   return return_status;
 }

二进制
localattestation_decryption.so