From patchwork Fri Nov 17 14:12:24 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: James Prestwood X-Patchwork-Id: 13458991 Received: from mail-pf1-f182.google.com (mail-pf1-f182.google.com [209.85.210.182]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 71CD8328AF for ; Fri, 17 Nov 2023 14:12:31 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="LCKuDLjD" Received: by mail-pf1-f182.google.com with SMTP id d2e1a72fcca58-6b709048f32so1866162b3a.0 for ; Fri, 17 Nov 2023 06:12:31 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1700230350; x=1700835150; darn=lists.linux.dev; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=5gmWj6X7RSE29Em8B+Z/0I5UE5yMatrN+9iIGBbc4/g=; b=LCKuDLjDU6SHxE7j2PfYj2dNz/iJPkGbGC1JFYDDMvxvlffVyboUFPx9udCkFsjbP0 Vbymz7li0L0FLT9coYKdqlESNMU9wH2cAFb6V6TQzGAyEe92SVIW7SZvMwfNEu5DpXe3 WqdhdjR/0xu4UR0A2UkVvMYE2rsPhn1C321dvVGD7Y9XVq63P0NrFUk03A7FD3MpMAy9 lsRFMvlA6tRe9lReLP4Ub1sODzIwx1or/rEfIp636SauI3DsXadVHAc7BQD8cPWDyZMS QXiG2XBfIs53cmKcTDOb4FC+Zi+wHgc3Hrm7vfFXOj2UI24tFatRYJj4DcdwdKHUf5+a 0sWQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1700230350; x=1700835150; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=5gmWj6X7RSE29Em8B+Z/0I5UE5yMatrN+9iIGBbc4/g=; b=s/4OYiz1VSI45xgHUJLOUfAg21ARkWX53FgQhE3YHHr+H5TQTQKtwAZRD6nyswjynS Crkp8AadsqdmOEqMzRPjr++lz4+UtXKvDgLxabY33K/WI4ggxvBY4JLUeLgCM8KlxUbW WE4puxgzgoNjoqEakxesle0rII3LoeH9hy//dv7olZ2R/EM/O9/G0AWRdXVZHvEDc39Y 9HcA1jwi5XgzdL83zeu+ZDK6CtnBfwEGLl9S1PfgObQERhUTHkyHmaArfwoDDjhhJWLF /1JC1iL6tqQjrrZhy7klI4FZZXoRZa6lWJWi/WrG1kG7yQ454rDy2dHfkrUx8xDXa5UR snNw== X-Gm-Message-State: AOJu0YxjVPiEmJFRPZRacp7GkxIKPbtMJzm/ZNYLwzsmrtG5xJFl5yW6 JHzWj1dLK9+2jd496+QmvzXMmnItswVIUg== X-Google-Smtp-Source: AGHT+IGcA+SHBwjGq3K6KCMMvQIH+KHVB4ClmFiuw+kCkKMvsVJ/fWT0G/EYdW2hK0nI5dqlxNlFJQ== X-Received: by 2002:a05:6a00:ad1:b0:6c9:9e11:859d with SMTP id c17-20020a056a000ad100b006c99e11859dmr11019861pfl.1.1700230350127; Fri, 17 Nov 2023 06:12:30 -0800 (PST) Received: from LOCLAP699.. ([50.39.172.77]) by smtp.gmail.com with ESMTPSA id t24-20020aa79398000000b006c4db182074sm1447897pfe.196.2023.11.17.06.12.29 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 17 Nov 2023 06:12:29 -0800 (PST) From: James Prestwood To: iwd@lists.linux.dev Cc: James Prestwood Subject: [PATCH 1/4] dpp-util: add support for 3rd party JSON fields Date: Fri, 17 Nov 2023 06:12:24 -0800 Message-Id: <20231117141227.60722-1-prestwoj@gmail.com> X-Mailer: git-send-email 2.34.1 Precedence: bulk X-Mailing-List: iwd@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 The DPP spec allows 3rd party fields in the DPP configuration object (section 4.5.2). IWD can take advantage of this (when configuring another IWD supplicant) to communicate additional profile options that may be required for the network. The new configuration member will be called "/net/connman/iwd" and will be an object containing settings specific to IWD. More settings could be added here if needed but for now only the following are defined: { send_hostname: true/false, hidden: true/false } These correspond to the following network profile settings: [IPv4].SendHostname [Settings].Hidden --- src/dpp-util.c | 69 +++++++++++++++++++++++++++++++++++++++++++++++--- src/dpp-util.h | 4 +++ 2 files changed, 70 insertions(+), 3 deletions(-) RFC->v1: * Decided to make this not configurable with an option. Any supplicant should support 3rd party fields existing (even if they don't parse them) and the two settings here will only improve the experience. diff --git a/src/dpp-util.c b/src/dpp-util.c index cadc6437..c805b14a 100644 --- a/src/dpp-util.c +++ b/src/dpp-util.c @@ -144,6 +144,40 @@ static uint32_t dpp_parse_akm(char *akms) return akm_out; } +static bool dpp_parse_extra_options(struct dpp_configuration *config, + struct json_iter *extra) +{ + struct json_iter host_val; + struct json_iter hidden_val; + bool hostname = false; + bool hidden = false; + + if (!json_iter_parse(extra, + JSON_OPTIONAL("send_hostname", JSON_PRIMITIVE, + &host_val), + JSON_OPTIONAL("hidden", JSON_PRIMITIVE, &hidden_val), + JSON_UNDEFINED)) + return false; + + /* + * The values are optional in order to support backwards compatibility + * if more are added, but if the key does exist require the type + * matches and fail otherwise. + */ + if (json_iter_is_valid(&host_val) && + !json_iter_get_boolean(&host_val, &hostname)) + return false; + + if (json_iter_is_valid(&hidden_val) && + !json_iter_get_boolean(&hidden_val, &hidden)) + return false; + + config->send_hostname = hostname; + config->hidden = hidden; + + return true; +} + /* * TODO: This handles the most basic configuration. i.e. a configuration object * with ssid/passphrase/akm. @@ -156,6 +190,7 @@ struct dpp_configuration *dpp_parse_configuration_object(const char *json, struct json_iter iter; struct json_iter discovery; struct json_iter cred; + struct json_iter extra; _auto_(l_free) char *tech = NULL; _auto_(l_free) char *ssid = NULL; _auto_(l_free) char *akm = NULL; @@ -172,6 +207,7 @@ struct dpp_configuration *dpp_parse_configuration_object(const char *json, JSON_MANDATORY("wi-fi_tech", JSON_STRING, &tech), JSON_MANDATORY("discovery", JSON_OBJECT, &discovery), JSON_MANDATORY("cred", JSON_OBJECT, &cred), + JSON_OPTIONAL("/net/connman/iwd", JSON_OBJECT, &extra), JSON_UNDEFINED)) goto free_contents; @@ -210,6 +246,11 @@ struct dpp_configuration *dpp_parse_configuration_object(const char *json, if (!config->akm_suites) goto free_config; + if (json_iter_is_valid(&extra)) { + if (!dpp_parse_extra_options(config, &extra)) + l_warn("Extra settings failed to parse!"); + } + json_contents_free(c); return config; @@ -258,10 +299,20 @@ char *dpp_configuration_to_json(struct dpp_configuration *config) config->psk); return l_strdup_printf("{\"wi-fi_tech\":\"infra\"," - "\"discovery\":{\"ssid\":\"%s\"}," - "\"cred\":{\"akm\":\"%s\",%s}}", + "\"discovery\":{" + "\"ssid\":\"%s\"" + "}," + "\"cred\":{" + "\"akm\":\"%s\",%s" + "}," + "\"/net/connman/iwd\":{" + "\"send_hostname\":%s," + "\"hidden\":%s}" + "}", ssid, dpp_akm_to_string(config->akm_suites), - pass_or_psk); + pass_or_psk, + config->send_hostname ? "true" : "false", + config->hidden ? "true" : "false"); } struct dpp_configuration *dpp_configuration_new( @@ -273,6 +324,8 @@ struct dpp_configuration *dpp_configuration_new( _auto_(l_free) char *passphrase = NULL; _auto_(l_free) char *psk = NULL; size_t ssid_len = strlen(ssid); + bool send_hostname; + bool hidden; if (!l_settings_has_group(settings, "Security")) return NULL; @@ -299,6 +352,16 @@ struct dpp_configuration *dpp_configuration_new( config->akm_suites = akm_suite; + if (!l_settings_get_bool(settings, "IPv4", "SendHostname", + &send_hostname)) + send_hostname = false; + + if (!l_settings_get_bool(settings, "Settings", "Hidden", &hidden)) + hidden = false; + + config->send_hostname = send_hostname; + config->hidden = hidden; + return config; } diff --git a/src/dpp-util.h b/src/dpp-util.h index 0724ee44..dc8a894b 100644 --- a/src/dpp-util.h +++ b/src/dpp-util.h @@ -117,6 +117,10 @@ struct dpp_configuration { uint32_t akm_suites; char *passphrase; char *psk; /* hex string */ + + /* "3rd party extensions" only applicable for two IWD peers */ + bool send_hostname : 1; + bool hidden : 1; }; struct dpp_configuration *dpp_parse_configuration_object(const char *json, From patchwork Fri Nov 17 14:12:25 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: James Prestwood X-Patchwork-Id: 13458990 Received: from mail-pf1-f170.google.com (mail-pf1-f170.google.com [209.85.210.170]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 6F5AD328CB for ; Fri, 17 Nov 2023 14:12:32 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="OHkQW7+m" Received: by mail-pf1-f170.google.com with SMTP id d2e1a72fcca58-6be0277c05bso1875399b3a.0 for ; Fri, 17 Nov 2023 06:12:32 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1700230351; x=1700835151; darn=lists.linux.dev; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=WOd+VfNw2Gn2g/y6YZ1nP1jtX18jztzEBXbLWPoDRFY=; b=OHkQW7+mDfHTFe4CVa8EqgEUTH/Vms8Ecp+IEogHajnWq6WLfI4JEDMoK3yEJVs8uB WUl1EsY7YwEnyDVRAOrd9sz8XbqfRCgrc4x5PyHs6HGk6AzrgVBD0ts5QY8BADWX8xgy C1OURgTh9bfn3o9ecI3hqMItTIus3LekFuss3xLu2WwQ2UUBpG7ER8TB5X1O3dNZa0dc liRK6Kam9dXqDDEN9EeF1Bynlq6JiA0Zxvr2OfWgu5cTkwelqIr6jh6Ln4U5r4LisrDy /joRXTmd3/j88upCPztfbfEF3XsSX/MCAEqJQs5qAqgvZ7nACddHGWlfe70b/RcHuJal 0M3Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1700230351; x=1700835151; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=WOd+VfNw2Gn2g/y6YZ1nP1jtX18jztzEBXbLWPoDRFY=; b=aNepOQLtI+U3kjYHlcZoHqtfhLOu4Fgg0UFS9NBb4yepgURRXBON/oOpmOif+3zGXV OJZBN6KeOiSueSVMzGDL0lhIGPSclE9TSXl2U3lT4m76z5yRUy9R7jd6KKhNweuevsJd Sj2QlJXM7AGvVO5AjduMTSj9INzAX/GP34Lc8lvL4kfqmrQH3i/L6AOVgFqwrdAsGB3c zT2AkkOJjv2M2x3gF5i8zc4/YoCIBplePkqsy2lCgYy2CSdzXDWQ+ii/HjPn0YvclXs4 1ob6NfTewBzYNNTGUYWITN9MVVQRETos9HIiXY7IshDAvBNmqaa0DlXmYQ3HLusKv6X/ E2TQ== X-Gm-Message-State: AOJu0Yzxow+a+URGCJZAQGjIhoxzwYkOUhXf/5x/Vpb0aImRykNljCKp PhsTn8KsRZetLQvqoflCensW0WH8r4VZZw== X-Google-Smtp-Source: AGHT+IFl5cbS20n7GrU2K1sbCnYImBXFTcQjhyF2Os6lbCCs6WAu0gHGwLmK/OGPj15yu0rglsn2kg== X-Received: by 2002:a05:6a00:bef:b0:6be:2e07:5c5c with SMTP id x47-20020a056a000bef00b006be2e075c5cmr15695703pfu.20.1700230351505; Fri, 17 Nov 2023 06:12:31 -0800 (PST) Received: from LOCLAP699.. ([50.39.172.77]) by smtp.gmail.com with ESMTPSA id t24-20020aa79398000000b006c4db182074sm1447897pfe.196.2023.11.17.06.12.30 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 17 Nov 2023 06:12:30 -0800 (PST) From: James Prestwood To: iwd@lists.linux.dev Cc: James Prestwood Subject: [PATCH 2/4] dpp: include 3rd party settings in network profile Date: Fri, 17 Nov 2023 06:12:25 -0800 Message-Id: <20231117141227.60722-2-prestwoj@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231117141227.60722-1-prestwoj@gmail.com> References: <20231117141227.60722-1-prestwoj@gmail.com> Precedence: bulk X-Mailing-List: iwd@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 If the configuration object contained IWD's 3rd party settings set those into the network profile. --- src/dpp.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/dpp.c b/src/dpp.c index f8d76805..0064187b 100644 --- a/src/dpp.c +++ b/src/dpp.c @@ -837,6 +837,12 @@ static void dpp_write_config(struct dpp_configuration *config, network_set_psk(network, psk); } + if (config->send_hostname) + l_settings_set_bool(settings, "IPv4", "SendHostname", true); + + if (config->hidden) + l_settings_set_bool(settings, "Settings", "Hidden", true); + l_debug("Storing credential for '%s(%s)'", config->ssid, security_to_str(SECURITY_PSK)); storage_network_sync(SECURITY_PSK, config->ssid, settings); From patchwork Fri Nov 17 14:12:26 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: James Prestwood X-Patchwork-Id: 13458992 Received: from mail-pf1-f170.google.com (mail-pf1-f170.google.com [209.85.210.170]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 3058734CF1 for ; Fri, 17 Nov 2023 14:12:33 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="f+baRH76" Received: by mail-pf1-f170.google.com with SMTP id d2e1a72fcca58-6c431ca7826so1865391b3a.0 for ; Fri, 17 Nov 2023 06:12:32 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1700230352; x=1700835152; darn=lists.linux.dev; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=ZNqI475HOit2RPlWZellSZ1sJnbM27dbXgbDlmEptVk=; b=f+baRH76xJP4IqiFVHFGx9gu1rmrfM3yPfhXnbxJ8XQZFDrxYFm4ZdBzoSkQs6lLo+ sCCGdycKXgDTPcbWgxQCCJ4Z5g7mkqzBiR0g90631xMAnelM+6dWu1kwNZMAMIRl7ett ol+vncXSCPyj2734fJZ/9ojcXx3YaDkUaav7Zsy6c8lzb+MsSehjXnj2AEGKbtQET1x/ +QxPrvd9eAs7f0aBNaZDGfekLJC71kXp5fCXLXTYdIYZKQbrmRODiBh6E6lHfDgdW3vf R9AblBTrI5x2p0p6xaz7b5a1VeCRLOrBQO7Q/61GTJvwZUa+sLH+Llg1MRy6X11unsWb /9mw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1700230352; x=1700835152; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=ZNqI475HOit2RPlWZellSZ1sJnbM27dbXgbDlmEptVk=; b=JDwGAawIgS4NcRRL576Nqx5hLNL1vE1fygbLeN+3uF1BhE+2uiha7l2gETJz+wbyD5 vkvBtuLc0k+4ke6pHP3eoKdnKC0HRSZ4zljIV7Q3UsHBQ1oyFfMUrV6ZEfzv8MfVvvBD /0b/wQ8m1tBPNll2XUC/WPw9B5hxW/0Mo5aYoiHXbKZ1GRvIgnHzx8X/k9/68pOSWLUm LmH7O5CRbsM+ATIXHWQJS91rsSyq7/NWCPR2tPS3lfovoh73kDv67/G0R74HbO2psHr6 muiJuzLaO3lGJFOqUBBl1m+EDl3d2zqv3fXvqwsKZV399CrtlxNoFj6xBQ8fxN5bUJvX AFxw== X-Gm-Message-State: AOJu0YwcK6dqu8yU4FW5XWPe4NnX2v0ICMfNcLfp47zUd+T4/bFKcWFz HDP6R1IMA73cUmx1lJ+BQ2RKjDZugJZwPQ== X-Google-Smtp-Source: AGHT+IFCcAKp1eTX7XP2YE/i9PcwC8r+xK1fa+5M89lgJ6CJIw/xkIiWsy1YGMxCLVTT/CV4Cusabw== X-Received: by 2002:a05:6a00:179f:b0:69b:5395:59a8 with SMTP id s31-20020a056a00179f00b0069b539559a8mr21176123pfg.34.1700230352323; Fri, 17 Nov 2023 06:12:32 -0800 (PST) Received: from LOCLAP699.. ([50.39.172.77]) by smtp.gmail.com with ESMTPSA id t24-20020aa79398000000b006c4db182074sm1447897pfe.196.2023.11.17.06.12.31 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 17 Nov 2023 06:12:31 -0800 (PST) From: James Prestwood To: iwd@lists.linux.dev Cc: James Prestwood Subject: [PATCH 3/4] auto-t: add checks for DPP 3rd party settings Date: Fri, 17 Nov 2023 06:12:26 -0800 Message-Id: <20231117141227.60722-3-prestwoj@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231117141227.60722-1-prestwoj@gmail.com> References: <20231117141227.60722-1-prestwoj@gmail.com> Precedence: bulk X-Mailing-List: iwd@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Ensure the newly configured profile contains the additional SendHostname setting that the configurator sends. --- autotests/testDPP/pkex_test.py | 6 ++++++ autotests/testDPP/ssidCCMP.psk | 9 --------- 2 files changed, 6 insertions(+), 9 deletions(-) diff --git a/autotests/testDPP/pkex_test.py b/autotests/testDPP/pkex_test.py index 6c5cf054..9e0b5dd8 100644 --- a/autotests/testDPP/pkex_test.py +++ b/autotests/testDPP/pkex_test.py @@ -168,6 +168,12 @@ class Test(unittest.TestCase): condition = 'obj.state == DeviceState.connected' self.wd.wait_for_object_condition(self.device[1], condition) + # Check additional settings were carried over + with open('/tmp/ns0/ssidCCMP.psk', 'r') as f: + settings = f.read() + + self.assertIn("SendHostname=true", settings) + def test_pkex_configurator_with_agent(self): self.start_iwd_pkex_configurator(self.device[0], agent=True) diff --git a/autotests/testDPP/ssidCCMP.psk b/autotests/testDPP/ssidCCMP.psk index d428fd34..a82324c8 100644 --- a/autotests/testDPP/ssidCCMP.psk +++ b/autotests/testDPP/ssidCCMP.psk @@ -1,14 +1,5 @@ [Security] Passphrase=secret123 -[DeviceProvisioning] -SharedCode=secret123 -SharedCodeIdentifier=test -ExactConfig=true - [IPv4] SendHostname=true - -[Settings] -AutoConnect=true -Hidden=false From patchwork Fri Nov 17 14:12:27 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: James Prestwood X-Patchwork-Id: 13458993 Received: from mail-pf1-f169.google.com (mail-pf1-f169.google.com [209.85.210.169]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id D7A4B3589F for ; Fri, 17 Nov 2023 14:12:34 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="Xnn1a8Qd" Received: by mail-pf1-f169.google.com with SMTP id d2e1a72fcca58-6bd73395bceso1559004b3a.0 for ; Fri, 17 Nov 2023 06:12:34 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1700230354; x=1700835154; darn=lists.linux.dev; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=1TIbmc3qi2diqB6wEOamgw2jycsqy3NdYwPTYKpMHmo=; b=Xnn1a8QdrvpYCdaUuexIXlYU/9T2f6+DhGFfYSUGfyDbLBPuf8pk/qM2INz+NtlXeG sf0/AeF/KlVnwfOvu85FNqhNrPaT7RlH4qxPojnHaEDufum/Ygj6OmaSWXh+H7Ygvh1F 6CtXNbmpyiOyHaAmfGvzDLbuV7a8YhyOl0QOjsRcbvPk1z9RD8DH1+CC+EwgHqEos8C6 20mS8dZIJkm+o0gGjENI1Obg9njXtxB35Sq/s8POd7UoMp6A253GZ9u1bR6C0C5qMOuL SkSwLopuuYASsP6/A62JGILR0T5VdmGhQukKLSQJPUXFsD+wJethH2Dbl3tNdIm/1QzY DUBg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1700230354; x=1700835154; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=1TIbmc3qi2diqB6wEOamgw2jycsqy3NdYwPTYKpMHmo=; b=cn/QsXKe2X52TtT2Ku7GV2Zz3Nk/Nn7TsCNtBuIc1Fsr97GrECM30BH6sDGsm2kXz9 W2SKmaShLrwBvaiY51qV6WvANY8cb/2HuPqh+E563RV2eQqEnJLCxl9kz5lAa8YY5vJZ hJTQRZIuCwKlPxAlv2tNzIm1uO+JxiNSqjpXtCQ99psGHrUhAoppQOzJaiPPYiUaN45E qbeIvhndfJobGoXfpm3/eb1cxfZDraCCdzL6BHDeWpYTQ22B4IaeoSr90ae5TZ7P/m20 W6qdyTcGydyhHMbwAViAbVeyVIpuOCqZCXGH+PzT0cN0T4CFahXH2eo1mUcjIKDH3rGu PHuQ== X-Gm-Message-State: AOJu0YydiGl5Iq7+QYYq3s0szYt9nEVsLoLLEDpHINEgRk0adkOWT7pd ls0WxaQFtYJKjifKK3BXk246gyZDxaaYyg== X-Google-Smtp-Source: AGHT+IEBquh1muETuKrDw5rqHhHeiq3JNx5PmuOEn6Qu1RkdHQ4p1GEAMZxRFBf9rVf/kWbGnpo/fA== X-Received: by 2002:a05:6a20:9389:b0:13f:13cb:bc50 with SMTP id x9-20020a056a20938900b0013f13cbbc50mr7568424pzh.25.1700230353150; Fri, 17 Nov 2023 06:12:33 -0800 (PST) Received: from LOCLAP699.. ([50.39.172.77]) by smtp.gmail.com with ESMTPSA id t24-20020aa79398000000b006c4db182074sm1447897pfe.196.2023.11.17.06.12.32 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 17 Nov 2023 06:12:32 -0800 (PST) From: James Prestwood To: iwd@lists.linux.dev Cc: James Prestwood Subject: [PATCH 4/4] json: fix comment typo, "json_object_is_valid" Date: Fri, 17 Nov 2023 06:12:27 -0800 Message-Id: <20231117141227.60722-4-prestwoj@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231117141227.60722-1-prestwoj@gmail.com> References: <20231117141227.60722-1-prestwoj@gmail.com> Precedence: bulk X-Mailing-List: iwd@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 This should be json_iter_is_valid. --- src/json.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/json.h b/src/json.h index 713ab56f..feb85d67 100644 --- a/src/json.h +++ b/src/json.h @@ -85,7 +85,7 @@ void json_iter_init(struct json_iter *iter, struct json_contents *c); * other types are encountered. * * JSON_OPTIONAL string values will point to NULL if not found - * JSON_OPTIONAL objects/primitives can be checked with json_object_is_valid. + * JSON_OPTIONAL objects/primitives can be checked with json_iter_is_valid. */ bool json_iter_parse(struct json_iter *iter, enum json_type type, ...);