From 11ae9f030e13d07c505a4d5477d592ddb4b3acf6 Mon Sep 17 00:00:00 2001 From: Christian Grothoff Date: Wed, 8 Apr 2020 16:56:33 +0200 Subject: fix sign api for to address #6164 --- src/transport/gnunet-communicator-udp.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'src/transport/gnunet-communicator-udp.c') diff --git a/src/transport/gnunet-communicator-udp.c b/src/transport/gnunet-communicator-udp.c index d767689b9..1542a7702 100644 --- a/src/transport/gnunet-communicator-udp.c +++ b/src/transport/gnunet-communicator-udp.c @@ -1533,7 +1533,7 @@ verify_confirmation (const struct GNUNET_CRYPTO_EcdhePublicKey *ephemeral, uhs.monotonic_time = uc->monotonic_time; return GNUNET_CRYPTO_eddsa_verify ( GNUNET_SIGNATURE_COMMUNICATOR_UDP_HANDSHAKE, - &uhs.purpose, + &uhs, &uc->sender_sig, &uc->sender.public_key); } @@ -1634,7 +1634,7 @@ sock_read (void *cls) GNUNET_CRYPTO_hash (&sa, salen, &uhs.h_address); if (GNUNET_OK == GNUNET_CRYPTO_eddsa_verify (GNUNET_SIGNATURE_COMMUNICATOR_UDP_BROADCAST, - &uhs.purpose, + &uhs, &ub->sender_sig, &ub->sender.public_key)) { @@ -1932,9 +1932,9 @@ mq_send (struct GNUNET_MQ_Handle *mq, uhs.receiver = receiver->target; GNUNET_CRYPTO_ecdhe_key_get_public (&epriv, &uhs.ephemeral); uhs.monotonic_time = uc.monotonic_time; - GNUNET_assert (GNUNET_OK == GNUNET_CRYPTO_eddsa_sign (my_private_key, - &uhs.purpose, - &uc.sender_sig)); + GNUNET_CRYPTO_eddsa_sign (my_private_key, + &uhs, + &uc.sender_sig); /* Leave space for kx */ dpos = sizeof(kx); /* Append encrypted uc to dgram */ @@ -2534,9 +2534,9 @@ iface_proc (void *cls, ubs.purpose.size = htonl (sizeof(ubs)); ubs.sender = my_identity; GNUNET_CRYPTO_hash (addr, addrlen, &ubs.h_address); - GNUNET_assert (GNUNET_OK == GNUNET_CRYPTO_eddsa_sign (my_private_key, - &ubs.purpose, - &bi->bcm.sender_sig)); + GNUNET_CRYPTO_eddsa_sign (my_private_key, + &ubs, + &bi->bcm.sender_sig); if (NULL != broadcast_addr) { bi->broadcast_task = GNUNET_SCHEDULER_add_now (&ifc_broadcast, bi); -- cgit v1.2.3