eiwd

no dbus iwd with iwctl functionality
git clone https://git.daat.foo/repos/eiwd.git
Log | Files | Refs | Submodules | README | LICENSE

commit ab929012529420f1a29c9e17990ad23500aa16a9
parent 7b1e1497b751311b56220889561509ba8f699759
Author: James Prestwood <prestwoj@gmail.com>
Date:   Wed, 16 Oct 2019 15:29:50 -0700

owe: check for error return getting shared_secret

Diffstat:
Msrc/owe.c | 4+++-
1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/src/owe.c b/src/owe.c @@ -165,9 +165,11 @@ static bool owe_compute_keys(struct owe_sm *owe, const void *public_key, l_ecc_point_free(other_public); nbytes = l_ecc_scalar_get_data(shared_secret, ss_buf, sizeof(ss_buf)); - l_ecc_scalar_free(shared_secret); + if (nbytes < 0) + return false; + ptr += l_ecc_point_get_x(owe->public_key, ptr, sizeof(key)); memcpy(ptr, public_key, nbytes); ptr += nbytes;