GNUNET_CONTAINER_DLL_insert_tail (vrh->cred_chain_head,
vrh->cred_chain_tail,
cr_entry);
- /*if(GNUNET_OK != GNUNET_CRYPTO_ecdsa_verify(GNUNET_SIGNATURE_PURPOSE_CREDENTIAL,
+ if(GNUNET_OK != GNUNET_CRYPTO_ecdsa_verify(GNUNET_SIGNATURE_PURPOSE_CREDENTIAL,
&crd->purpose,
&crd->sig,
&crd->issuer_key))
GNUNET_log (GNUNET_ERROR_TYPE_WARNING,
"Invalid credential found\n");
continue;
- }*/
+ }
if (0 != memcmp (&crd->issuer_key,
&vrh->issuer_key,
sizeof (struct GNUNET_CRYPTO_EcdsaPublicKey)))
cred->sig = *sig;
cred->expiration = GNUNET_htonll (etime_abs.abs_value_us);
cred->purpose.purpose = htonl (GNUNET_SIGNATURE_PURPOSE_CREDENTIAL);
- cred->purpose.size = strlen (name) + 1 + sizeof (struct GNUNET_CRYPTO_EccSignaturePurpose) +
- sizeof (struct GNUNET_CRYPTO_EcdsaPublicKey) + sizeof (uint64_t);
+ cred->purpose.size = htonl (strlen (name) + 1 + sizeof (struct GNUNET_CRYPTO_EccSignaturePurpose) +
+ sizeof (struct GNUNET_CRYPTO_EcdsaPublicKey) + sizeof (uint64_t));
GNUNET_free (sig);
GNUNET_memcpy (&cred[1],
name,
which timeout &> /dev/null && DO_TIMEOUT="timeout 30"
-gnunet-arm -s -c test_credential_lookup.conf
+#gnunet-arm -s -c test_credential_lookup.conf
gnunet-identity -C testissuer -c test_credential_lookup.conf
gnunet-identity -C testsubject -c test_credential_lookup.conf
then
exit 0
else
- echo "FAIL: Failed to verify credential $RES_IP."
+ echo "FAIL: Failed to verify credential."
exit 1
fi