From bcd4173e47de642dd5fa70e1d6019d542ecaf76c Mon Sep 17 00:00:00 2001 From: Eugene Crosser Date: Fri, 10 Nov 2017 02:27:01 +0100 Subject: [PATCH 1/1] check that old data exists when it is necessary --- authobj.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/authobj.c b/authobj.c index deba028..b4a1f2b 100644 --- a/authobj.c +++ b/authobj.c @@ -241,6 +241,10 @@ struct _auth_obj authobj(const char *userid, const char *password, struct _auth_obj new_ao = {0}; if (!secret || !secsize || !payload) { + if (!ablob || !blobsize) { + new_ao.err = "authobj: previous data not supplied"; + return new_ao; + } old_ao = parse_authobj(userid, password, oldnonce, secret, secsize, ablob, blobsize, fetch_key); -- 2.39.2