Browse Source

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

dettanym 5 years ago
parent
commit
0e48f40658
3 changed files with 3 additions and 5 deletions
  1. 1 3
      ProtobufLAInitiator.cpp
  2. 2 2
      SgxProtobufLAInitiator.cpp
  3. BIN
      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;
 }

BIN
localattestation_decryption.so