Re: Dnssec is never enabled on recent master
On Tue, 22 Sep 2020 at 19:00, Sami Olmari wrote: > > This commit > https://github.com/openwrt/openwrt/commit/064dc1e81bc85f6ef8becc38854292853a59d2c2 > breaks all dnssec, it will never get enabled despite /etc/config/dhcp > enabling it. Reverting this commit made dnssec to work again. So this > needs either reverting, or some more elaborate fix. Should be fixed now with https://git.openwrt.org/7dc78d1d2893b672544e8c26026ce961a7248a82 . Sorry for the inconvenience and possible hazard exposed. It's a logic invert ;( Regards, yousong > > Additionally I got this message when troubleshooting this at irc: > "While at it, ask please to fix trust-anchor match too (it's not an > option, the option just contains that word at the end)" > > Thank you! > > -- > Sami Olmari > Oy Olmari Ab > Vaasa Hacklab ry ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
[PATCH 1/2] libopkg: remove support for "dist" config
The "dist" config option is legacy to imitate Debians repository structure. However this is never used within the OpenWrt ecosystem and can therefore be removed. Signed-off-by: Paul Spooren --- libopkg/opkg_conf.c | 32 +++- libopkg/opkg_conf.h | 1 - libopkg/pkg_hash.c | 25 - libopkg/pkg_hash.h | 1 - 4 files changed, 3 insertions(+), 56 deletions(-) diff --git a/libopkg/opkg_conf.c b/libopkg/opkg_conf.c index 38703ee..ee151f5 100644 --- a/libopkg/opkg_conf.c +++ b/libopkg/opkg_conf.c @@ -184,8 +184,7 @@ static int opkg_conf_set_option(const char *name, const char *value) static int opkg_conf_parse_file(const char *filename, -pkg_src_list_t * pkg_src_list, -pkg_src_list_t * dist_src_list) +pkg_src_list_t * pkg_src_list) { int line_num = 0; int err = 0; @@ -291,26 +290,6 @@ opkg_conf_parse_file(const char *filename, tmp_src_nv_pair_list for sake of symmetry.) */ if (strcmp(type, "option") == 0) { opkg_conf_set_option(name, value); - } else if (strcmp(type, "dist") == 0) { - if (!nv_pair_list_find - ((nv_pair_list_t *) dist_src_list, name)) { - pkg_src_list_append(dist_src_list, name, - value, extra, 0); - } else { - opkg_msg(ERROR, -"Duplicate dist declaration (%s %s). " -"Skipping.\n", name, value); - } - } else if (strcmp(type, "dist/gz") == 0) { - if (!nv_pair_list_find - ((nv_pair_list_t *) dist_src_list, name)) { - pkg_src_list_append(dist_src_list, name, - value, extra, 1); - } else { - opkg_msg(ERROR, -"Duplicate dist declaration (%s %s). " -"Skipping.\n", name, value); - } } else if (strcmp(type, "src") == 0) { if (!nv_pair_list_find ((nv_pair_list_t *) pkg_src_list, name)) { @@ -458,7 +437,6 @@ static int glob_errfunc(const char *epath, int eerrno) int opkg_conf_init(void) { pkg_src_list_init(&conf->pkg_src_list); - pkg_src_list_init(&conf->dist_src_list); pkg_dest_list_init(&conf->pkg_dest_list); pkg_dest_list_init(&conf->tmp_dest_list); nv_pair_list_init(&conf->arch_list); @@ -486,8 +464,7 @@ int opkg_conf_load(void) goto err0; } if (opkg_conf_parse_file(conf->conf_file, -&conf->pkg_src_list, -&conf->dist_src_list)) +&conf->pkg_src_list)) goto err1; } @@ -518,8 +495,7 @@ int opkg_conf_load(void) !strcmp(conf->conf_file, globbuf.gl_pathv[i])) continue; if (opkg_conf_parse_file(globbuf.gl_pathv[i], -&conf->pkg_src_list, -&conf->dist_src_list) < 0) { +&conf->pkg_src_list) < 0) { globfree(&globbuf); goto err1; } @@ -629,7 +605,6 @@ err2: } err1: pkg_src_list_deinit(&conf->pkg_src_list); - pkg_src_list_deinit(&conf->dist_src_list); pkg_dest_list_deinit(&conf->pkg_dest_list); nv_pair_list_deinit(&conf->arch_list); @@ -670,7 +645,6 @@ void opkg_conf_deinit(void) free(conf->conf_file); pkg_src_list_deinit(&conf->pkg_src_list); - pkg_src_list_deinit(&conf->dist_src_list); pkg_dest_list_deinit(&conf->pkg_dest_list); nv_pair_list_deinit(&conf->arch_list); diff --git a/libopkg/opkg_conf.h b/libopkg/opkg_conf.h index 91190b3..d38fd73 100644 --- a/libopkg/opkg_conf.h +++ b/libopkg/opkg_conf.h @@ -45,7 +45,6 @@ extern opkg_conf_t *conf; struct opkg_conf { pkg_src_list_t pkg_src_list; - pkg_src_list_t dist_src_list; pkg_dest_list_t pkg_dest_list; pkg_dest_list_t tmp_dest_list; nv_pair_list_t arch_list; diff --git a/libopkg/pkg_hash.c b/libopkg/pkg_hash.c index 52c64ff..bf971d7 100644 --- a/libopkg/pkg_hash.c +++ b/libopkg/pkg_hash
[PATCH 2/2] libopkg: remove "extra_data" option
The "extra_data" allowed to add an extra option behind a repository definition. This was only ever used to either ignore a specific feed by setting it to "__dummy__" or adding a sub-folder in the repository path, as done for Debian repositories. Instead of using "__dummy__" it is cleaner to "comment out" the specific repository and Debian repository structure is nowhere used in the OpenWrt ecosystem, therefore it seem save to remove "extra_data". Signed-off-by: Paul Spooren --- libopkg/opkg.c | 17 - libopkg/opkg_cmd.c | 20 libopkg/opkg_conf.c| 22 +++--- libopkg/pkg_src.c | 8 +--- libopkg/pkg_src.h | 3 +-- libopkg/pkg_src_list.c | 4 ++-- libopkg/pkg_src_list.h | 3 +-- 7 files changed, 16 insertions(+), 61 deletions(-) diff --git a/libopkg/opkg.c b/libopkg/opkg.c index 3583488..191e028 100644 --- a/libopkg/opkg.c +++ b/libopkg/opkg.c @@ -529,13 +529,8 @@ opkg_update_package_lists(opkg_progress_callback_t progress_callback, src = (pkg_src_t *) iter->data; - if (src->extra_data)/* debian style? */ - sprintf_alloc(&url, "%s/%s/%s", src->value, - src->extra_data, - src->gzip ? "Packages.gz" : "Packages"); - else - sprintf_alloc(&url, "%s/%s", src->value, - src->gzip ? "Packages.gz" : "Packages"); + sprintf_alloc(&url, "%s/%s", src->value, + src->gzip ? "Packages.gz" : "Packages"); sprintf_alloc(&list_file_name, "%s/%s", lists_dir, src->name); @@ -550,12 +545,8 @@ opkg_update_package_lists(opkg_progress_callback_t progress_callback, char *sig_file_name; /* download detached signitures to verify the package lists */ /* get the url for the sig file */ - if (src->extra_data)/* debian style? */ - sprintf_alloc(&url, "%s/%s/%s", src->value, - src->extra_data, "Packages.sig"); - else - sprintf_alloc(&url, "%s/%s", src->value, - "Packages.sig"); + sprintf_alloc(&url, "%s/%s", src->value, + "Packages.sig"); /* create filename for signature */ sprintf_alloc(&sig_file_name, "%s/%s.sig", lists_dir, diff --git a/libopkg/opkg_cmd.c b/libopkg/opkg_cmd.c index a329558..83e345e 100644 --- a/libopkg/opkg_cmd.c +++ b/libopkg/opkg_cmd.c @@ -117,16 +117,8 @@ static int opkg_update_cmd(int argc, char **argv) src = (pkg_src_t *) iter->data; - if (src->extra_data && strcmp(src->extra_data, "__dummy__ ")) - continue; - - if (src->extra_data)/* debian style? */ - sprintf_alloc(&url, "%s/%s/%s", src->value, - src->extra_data, - src->gzip ? "Packages.gz" : "Packages"); - else - sprintf_alloc(&url, "%s/%s", src->value, - src->gzip ? "Packages.gz" : "Packages"); + sprintf_alloc(&url, "%s/%s", src->value, + src->gzip ? "Packages.gz" : "Packages"); sprintf_alloc(&list_file_name, "%s/%s", lists_dir, src->name); pkglist_dl_error = 0; @@ -146,12 +138,8 @@ static int opkg_update_cmd(int argc, char **argv) if (pkglist_dl_error == 0 && conf->check_signature) { /* download detached signitures to verify the package lists */ /* get the url for the sig file */ - if (src->extra_data)/* debian style? */ - sprintf_alloc(&url, "%s/%s/%s", src->value, - src->extra_data, "Packages.sig"); - else - sprintf_alloc(&url, "%s/%s", src->value, - "Packages.sig"); + sprintf_alloc(&url, "%s/%s", src->value, + "Packages.sig"); /* create temporary file for it */ char *tmp_file_name; diff --git a/libopkg/opkg_conf.c b/libopkg/opkg_conf.c index ee151f5..5fe0be9 100644 --- a/libopkg/opkg_conf.c +++ b/libopkg/opkg_conf.c @@ -218,7 +218,7 @@ opkg_conf_parse_file(const char *filename, while (1) { char *line; - char *type, *name, *value, *extra; + char *type, *name, *value; line_num++; @@ -261,20 +261,6
Re: [PATCH V3 uhttpd] ubus: add new RESTful API
Hi Rafał! Am 23.09.20 um 23:37 schrieb Rafał Miłecki: > On 2020-09-23 23:33, Andre Valentin wrote: >> I'm experimenting again a bit with the new API. I subscribed to the >> hostapd events and saw that >> after some time the connection is still up, but now new events come in. >> How can I control timeout and make sure, that the subscription >> connections stays as long as >> possible online? > > Did you mean "no new events"? Please try: > [PATCH uhttpd] client: really close connection on timeout > https://patchwork.ozlabs.org/project/openwrt/patch/20200923104327.14812-1-zaj...@gmail.com/ Thanks for the hint. Will try it and come back. BTW, how long can such a subscription persist? Is it controlled with the "-e" switch? Kind regards, André smime.p7s Description: S/MIME Cryptographic Signature ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel