* [scarthgap][PATCH 0/1] lighttpd: fix trailing '/' on files in dirlisting @ 2026-01-20 15:57 fred.w.bacon 2026-01-20 15:57 ` [scarthgap][PATCH 1/1] lighttpd: Fix trailing slash on files in mod_dirlisting fred.w.bacon 0 siblings, 1 reply; 4+ messages in thread From: fred.w.bacon @ 2026-01-20 15:57 UTC (permalink / raw) To: openembedded-core; +Cc: Fred Bacon From: Fred Bacon <fred.w.bacon@gmail.com> Backporting an upstream bug fix for lighttpd's mod_dirlisting. Fred Bacon (1): lighttpd: Fix trailing slash on files in mod_dirlisting .../lighttpd/0001-mod_dirlisting.patch | 48 +++++++++++++++++++ .../lighttpd/lighttpd_1.4.74.bb | 1 + 2 files changed, 49 insertions(+) create mode 100644 meta/recipes-extended/lighttpd/lighttpd/0001-mod_dirlisting.patch ^ permalink raw reply [flat|nested] 4+ messages in thread
* [scarthgap][PATCH 1/1] lighttpd: Fix trailing slash on files in mod_dirlisting 2026-01-20 15:57 [scarthgap][PATCH 0/1] lighttpd: fix trailing '/' on files in dirlisting fred.w.bacon @ 2026-01-20 15:57 ` fred.w.bacon 2026-02-08 22:52 ` [OE-core] " Yoann Congal 0 siblings, 1 reply; 4+ messages in thread From: fred.w.bacon @ 2026-01-20 15:57 UTC (permalink / raw) To: openembedded-core; +Cc: Fred Bacon, Fred Bacon From: Fred Bacon <fred.w.bacon@gmail.com> Fixes [YOCTO #16128] Backport of upstream bug fix from lighttpd-1.4.75. Version 1.4.74 introduced a bug that would append a trailing slash to files in a directory listing. When the user attempts to download one of these files, the web browser could not save the file with a trailing slash. As a consequence, every web browser tested would generate a random character string for the saved file name. Upstream-Status: Backport [1.4.75] Signed-off-by: Fred Bacon <bacon@aerodyne.com> --- .../lighttpd/0001-mod_dirlisting.patch | 48 +++++++++++++++++++ .../lighttpd/lighttpd_1.4.74.bb | 1 + 2 files changed, 49 insertions(+) create mode 100644 meta/recipes-extended/lighttpd/lighttpd/0001-mod_dirlisting.patch diff --git a/meta/recipes-extended/lighttpd/lighttpd/0001-mod_dirlisting.patch b/meta/recipes-extended/lighttpd/lighttpd/0001-mod_dirlisting.patch new file mode 100644 index 0000000000..8afdc1ecd0 --- /dev/null +++ b/meta/recipes-extended/lighttpd/lighttpd/0001-mod_dirlisting.patch @@ -0,0 +1,48 @@ +From 3d400ce06dcb950a61363f87330324db244f4bac Mon Sep 17 00:00:00 2001 +From: Glenn Strauss <gstrauss@gluelogic.com> +Date: Thu, 29 Feb 2024 20:59:57 -0500 +Subject: [PATCH] [mod_dirlisting] fix suffix display of '/' on file (fixes + #3242) + +fix incorrect suffix display of '/' on files + +(regression in lighttpd 1.4.74) + +(thx guy) + +Upstream-Status: Backport [1.4.75] + +References: +[1] https://redmine.lighttpd.net/issues/3242 + +Signed-off-by: Glenn Strauss <gstrauss@gluelogic.com> +--- + src/mod_dirlisting.c | 11 ++++++++++- + 1 file changed, 10 insertions(+), 1 deletion(-) + +diff --git a/src/mod_dirlisting.c b/src/mod_dirlisting.c +index a3432211..2686cd3e 100644 +--- a/src/mod_dirlisting.c ++++ b/src/mod_dirlisting.c +@@ -1022,10 +1022,19 @@ static void http_list_directory_dirname(buffer * const out, const dirls_entry_t + buffer_append_string_len(out, CONST_STR_LEN("</td><td class=\"s\">- </td><td class=\"t\">Directory</td></tr>\n")); + } + ++static void http_list_file_ent(buffer * const out, const dirls_entry_t * const ent, const char * const name) { ++ buffer_append_string_encoded(out, name, ent->namelen, ENCODING_REL_URI_PART); ++ buffer_append_string_len(out, CONST_STR_LEN("\">")); ++ buffer_append_string_encoded(out, name, ent->namelen, ENCODING_MINIMAL_XML); ++ buffer_append_string_len(out, CONST_STR_LEN("</a></td><td class=\"m\">")); ++ ++ http_list_directory_mtime(out, ent); ++} ++ + static void http_list_directory_filename(buffer * const out, const dirls_entry_t * const ent, const char * const name, handler_ctx * const hctx) { + buffer_append_string_len(out, CONST_STR_LEN("<tr><td class=\"n\"><a href=\"")); + +- http_list_directory_ent(out, ent, name); ++ http_list_file_ent(out, ent, name); + + const buffer *content_type; + #if defined(HAVE_XATTR) || defined(HAVE_EXTATTR) /*(pass full path)*/ + diff --git a/meta/recipes-extended/lighttpd/lighttpd_1.4.74.bb b/meta/recipes-extended/lighttpd/lighttpd_1.4.74.bb index 7460d3d716..e48fd16514 100644 --- a/meta/recipes-extended/lighttpd/lighttpd_1.4.74.bb +++ b/meta/recipes-extended/lighttpd/lighttpd_1.4.74.bb @@ -14,6 +14,7 @@ SRC_URI = "http://download.lighttpd.net/lighttpd/releases-1.4.x/lighttpd-${PV}.t file://index.html.lighttpd \ file://lighttpd.conf \ file://lighttpd \ + file://0001-mod_dirlisting.patch \ " SRC_URI[sha256sum] = "5c08736e83088f7e019797159f306e88ec729abe976dc98fb3bed71b9d3e53b5" ^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [OE-core] [scarthgap][PATCH 1/1] lighttpd: Fix trailing slash on files in mod_dirlisting 2026-01-20 15:57 ` [scarthgap][PATCH 1/1] lighttpd: Fix trailing slash on files in mod_dirlisting fred.w.bacon @ 2026-02-08 22:52 ` Yoann Congal 2026-02-09 14:59 ` Fred Bacon 0 siblings, 1 reply; 4+ messages in thread From: Yoann Congal @ 2026-02-08 22:52 UTC (permalink / raw) To: fred.w.bacon, openembedded-core; +Cc: Fred Bacon Hello, Thanks for the patch, it looks good! Just 2 notes that I fixed: On Tue Jan 20, 2026 at 4:57 PM CET, Fred Bacon via lists.openembedded.org wrote: > From: Fred Bacon <fred.w.bacon@gmail.com> > > Fixes [YOCTO #16128] > > Backport of upstream bug fix from lighttpd-1.4.75. Version 1.4.74 introduced a bug that > would append a trailing slash to files in a directory listing. When the user attempts to > download one of these files, the web browser could not save the file with a trailing > slash. As a consequence, every web browser tested would generate a random character string > for the saved file name. > > Upstream-Status: Backport [1.4.75] That line in the commit message is useless, I removed it. > Signed-off-by: Fred Bacon <bacon@aerodyne.com> > --- > .../lighttpd/0001-mod_dirlisting.patch | 48 +++++++++++++++++++ > .../lighttpd/lighttpd_1.4.74.bb | 1 + > 2 files changed, 49 insertions(+) > create mode 100644 meta/recipes-extended/lighttpd/lighttpd/0001-mod_dirlisting.patch > > diff --git a/meta/recipes-extended/lighttpd/lighttpd/0001-mod_dirlisting.patch b/meta/recipes-extended/lighttpd/lighttpd/0001-mod_dirlisting.patch > new file mode 100644 > index 0000000000..8afdc1ecd0 > --- /dev/null > +++ b/meta/recipes-extended/lighttpd/lighttpd/0001-mod_dirlisting.patch > @@ -0,0 +1,48 @@ > +From 3d400ce06dcb950a61363f87330324db244f4bac Mon Sep 17 00:00:00 2001 > +From: Glenn Strauss <gstrauss@gluelogic.com> > +Date: Thu, 29 Feb 2024 20:59:57 -0500 > +Subject: [PATCH] [mod_dirlisting] fix suffix display of '/' on file (fixes > + #3242) > + > +fix incorrect suffix display of '/' on files > + > +(regression in lighttpd 1.4.74) > + > +(thx guy) > + > +Upstream-Status: Backport [1.4.75] We usually use the specific commit URL in patch. I replaced by: Upstream-Status: Backport [https://github.com/lighttpd/lighttpd1.4/commit/3d400ce06dcb950a61363f87330324db244f4bac] > + > +References: > +[1] https://redmine.lighttpd.net/issues/3242 > + > +Signed-off-by: Glenn Strauss <gstrauss@gluelogic.com> > +--- > + src/mod_dirlisting.c | 11 ++++++++++- > + 1 file changed, 10 insertions(+), 1 deletion(-) > + > +diff --git a/src/mod_dirlisting.c b/src/mod_dirlisting.c > +index a3432211..2686cd3e 100644 > +--- a/src/mod_dirlisting.c > ++++ b/src/mod_dirlisting.c > +@@ -1022,10 +1022,19 @@ static void http_list_directory_dirname(buffer * const out, const dirls_entry_t > + buffer_append_string_len(out, CONST_STR_LEN("</td><td class=\"s\">- </td><td class=\"t\">Directory</td></tr>\n")); > + } > + > ++static void http_list_file_ent(buffer * const out, const dirls_entry_t * const ent, const char * const name) { > ++ buffer_append_string_encoded(out, name, ent->namelen, ENCODING_REL_URI_PART); > ++ buffer_append_string_len(out, CONST_STR_LEN("\">")); > ++ buffer_append_string_encoded(out, name, ent->namelen, ENCODING_MINIMAL_XML); > ++ buffer_append_string_len(out, CONST_STR_LEN("</a></td><td class=\"m\">")); > ++ > ++ http_list_directory_mtime(out, ent); > ++} > ++ > + static void http_list_directory_filename(buffer * const out, const dirls_entry_t * const ent, const char * const name, handler_ctx * const hctx) { > + buffer_append_string_len(out, CONST_STR_LEN("<tr><td class=\"n\"><a href=\"")); > + > +- http_list_directory_ent(out, ent, name); > ++ http_list_file_ent(out, ent, name); > + > + const buffer *content_type; > + #if defined(HAVE_XATTR) || defined(HAVE_EXTATTR) /*(pass full path)*/ > + > diff --git a/meta/recipes-extended/lighttpd/lighttpd_1.4.74.bb b/meta/recipes-extended/lighttpd/lighttpd_1.4.74.bb > index 7460d3d716..e48fd16514 100644 > --- a/meta/recipes-extended/lighttpd/lighttpd_1.4.74.bb > +++ b/meta/recipes-extended/lighttpd/lighttpd_1.4.74.bb > @@ -14,6 +14,7 @@ SRC_URI = "http://download.lighttpd.net/lighttpd/releases-1.4.x/lighttpd-${PV}.t > file://index.html.lighttpd \ > file://lighttpd.conf \ > file://lighttpd \ > + file://0001-mod_dirlisting.patch \ > " > > SRC_URI[sha256sum] = "5c08736e83088f7e019797159f306e88ec729abe976dc98fb3bed71b9d3e53b5" -- Yoann Congal Smile ECS ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [OE-core] [scarthgap][PATCH 1/1] lighttpd: Fix trailing slash on files in mod_dirlisting 2026-02-08 22:52 ` [OE-core] " Yoann Congal @ 2026-02-09 14:59 ` Fred Bacon 0 siblings, 0 replies; 4+ messages in thread From: Fred Bacon @ 2026-02-09 14:59 UTC (permalink / raw) To: Yoann Congal, fred.w.bacon@gmail.com, openembedded-core@lists.openembedded.org [-- Attachment #1: Type: text/plain, Size: 5773 bytes --] Thanks for the feedback. I'll keep this information in mind if I ever need to submit something else. Fred ________________________________ From: Yoann Congal <yoann.congal@smile.fr> Sent: Sunday, February 8, 2026 5:52 PM To: fred.w.bacon@gmail.com <fred.w.bacon@gmail.com>; openembedded-core@lists.openembedded.org <openembedded-core@lists.openembedded.org> Cc: Fred Bacon <bacon@aerodyne.com> Subject: Re: [OE-core] [scarthgap][PATCH 1/1] lighttpd: Fix trailing slash on files in mod_dirlisting Hello, Thanks for the patch, it looks good! Just 2 notes that I fixed: On Tue Jan 20, 2026 at 4:57 PM CET, Fred Bacon via lists.openembedded.org wrote: > From: Fred Bacon <fred.w.bacon@gmail.com> > > Fixes [YOCTO #16128] > > Backport of upstream bug fix from lighttpd-1.4.75. Version 1.4.74 introduced a bug that > would append a trailing slash to files in a directory listing. When the user attempts to > download one of these files, the web browser could not save the file with a trailing > slash. As a consequence, every web browser tested would generate a random character string > for the saved file name. > > Upstream-Status: Backport [1.4.75] That line in the commit message is useless, I removed it. > Signed-off-by: Fred Bacon <bacon@aerodyne.com> > --- > .../lighttpd/0001-mod_dirlisting.patch | 48 +++++++++++++++++++ > .../lighttpd/lighttpd_1.4.74.bb | 1 + > 2 files changed, 49 insertions(+) > create mode 100644 meta/recipes-extended/lighttpd/lighttpd/0001-mod_dirlisting.patch > > diff --git a/meta/recipes-extended/lighttpd/lighttpd/0001-mod_dirlisting.patch b/meta/recipes-extended/lighttpd/lighttpd/0001-mod_dirlisting.patch > new file mode 100644 > index 0000000000..8afdc1ecd0 > --- /dev/null > +++ b/meta/recipes-extended/lighttpd/lighttpd/0001-mod_dirlisting.patch > @@ -0,0 +1,48 @@ > +From 3d400ce06dcb950a61363f87330324db244f4bac Mon Sep 17 00:00:00 2001 > +From: Glenn Strauss <gstrauss@gluelogic.com> > +Date: Thu, 29 Feb 2024 20:59:57 -0500 > +Subject: [PATCH] [mod_dirlisting] fix suffix display of '/' on file (fixes > + #3242) > + > +fix incorrect suffix display of '/' on files > + > +(regression in lighttpd 1.4.74) > + > +(thx guy) > + > +Upstream-Status: Backport [1.4.75] We usually use the specific commit URL in patch. I replaced by: Upstream-Status: Backport [https://us-east-2.protection.sophos.com?d=github.com&u=aHR0cHM6Ly9naXRodWIuY29tL2xpZ2h0dHBkL2xpZ2h0dHBkMS40L2NvbW1pdC8zZDQwMGNlMDZkY2I5NTBhNjEzNjNmODczMzAzMjRkYjI0NGY0YmFj&i=NWZlMzY0NmMyMDVjNjQwZTE1YzFlYTMy&t=cWQ0MFJiMld1WWhnN0M5TDJMSXVIcGNlWmRNWFkxM2R0SHFLRnUyQWxOdz0=&h=61b32fbd7bc247d290e51fb0840c81da&s=AVNPUEhUT0NFTkNSWVBUSVagGCZnv_3_2OOO_hLXi6h9pyzgZd-ebE3V8DGhWahvpQ] > + > +References: > +[1] https://us-east-2.protection.sophos.com?d=lighttpd.net&u=aHR0cHM6Ly9yZWRtaW5lLmxpZ2h0dHBkLm5ldC9pc3N1ZXMvMzI0Mg==&i=NWZlMzY0NmMyMDVjNjQwZTE1YzFlYTMy&t=WWlheW1sd0pPN0JJN3dnUCtwdzRFNU03Ny84ejJuV1JUWEJJTS8zWDJBRT0=&h=61b32fbd7bc247d290e51fb0840c81da&s=AVNPUEhUT0NFTkNSWVBUSVagGCZnv_3_2OOO_hLXi6h9pyzgZd-ebE3V8DGhWahvpQ > + > +Signed-off-by: Glenn Strauss <gstrauss@gluelogic.com> > +--- > + src/mod_dirlisting.c | 11 ++++++++++- > + 1 file changed, 10 insertions(+), 1 deletion(-) > + > +diff --git a/src/mod_dirlisting.c b/src/mod_dirlisting.c > +index a3432211..2686cd3e 100644 > +--- a/src/mod_dirlisting.c > ++++ b/src/mod_dirlisting.c > +@@ -1022,10 +1022,19 @@ static void http_list_directory_dirname(buffer * const out, const dirls_entry_t > + buffer_append_string_len(out, CONST_STR_LEN("</td><td class=\"s\">- </td><td class=\"t\">Directory</td></tr>\n")); > + } > + > ++static void http_list_file_ent(buffer * const out, const dirls_entry_t * const ent, const char * const name) { > ++ buffer_append_string_encoded(out, name, ent->namelen, ENCODING_REL_URI_PART); > ++ buffer_append_string_len(out, CONST_STR_LEN("\">")); > ++ buffer_append_string_encoded(out, name, ent->namelen, ENCODING_MINIMAL_XML); > ++ buffer_append_string_len(out, CONST_STR_LEN("</a></td><td class=\"m\">")); > ++ > ++ http_list_directory_mtime(out, ent); > ++} > ++ > + static void http_list_directory_filename(buffer * const out, const dirls_entry_t * const ent, const char * const name, handler_ctx * const hctx) { > + buffer_append_string_len(out, CONST_STR_LEN("<tr><td class=\"n\"><a href=\"")); > + > +- http_list_directory_ent(out, ent, name); > ++ http_list_file_ent(out, ent, name); > + > + const buffer *content_type; > + #if defined(HAVE_XATTR) || defined(HAVE_EXTATTR) /*(pass full path)*/ > + > diff --git a/meta/recipes-extended/lighttpd/lighttpd_1.4.74.bb b/meta/recipes-extended/lighttpd/lighttpd_1.4.74.bb > index 7460d3d716..e48fd16514 100644 > --- a/meta/recipes-extended/lighttpd/lighttpd_1.4.74.bb > +++ b/meta/recipes-extended/lighttpd/lighttpd_1.4.74.bb > @@ -14,6 +14,7 @@ SRC_URI = "https://us-east-2.protection.sophos.com?d=lighttpd.net&u=aHR0cDovL2Rvd25sb2FkLmxpZ2h0dHBkLm5ldC9saWdodHRwZC9yZWxlYXNlcy0xLjQueC9saWdodHRwZC0ke1BWfS50&i=NWZlMzY0NmMyMDVjNjQwZTE1YzFlYTMy&t=dHlnZy81SyszMXNrclVhaVZaWTFFN3VndkVVWGllenM0ZStiVHYvNHY1VT0=&h=61b32fbd7bc247d290e51fb0840c81da&s=AVNPUEhUT0NFTkNSWVBUSVagGCZnv_3_2OOO_hLXi6h9pyzgZd-ebE3V8DGhWahvpQ > file://index.html.lighttpd \ > file://lighttpd.conf \ > file://lighttpd \ > + file://0001-mod_dirlisting.patch \ > " > > SRC_URI[sha256sum] = "5c08736e83088f7e019797159f306e88ec729abe976dc98fb3bed71b9d3e53b5" -- Yoann Congal Smile ECS Caution:This message originated from outside of Aerodyne. Do not follow links or open files unless you are confident that this message is legitimate. [-- Attachment #2: Type: text/html, Size: 9386 bytes --] ^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2026-02-09 15:16 UTC | newest] Thread overview: 4+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2026-01-20 15:57 [scarthgap][PATCH 0/1] lighttpd: fix trailing '/' on files in dirlisting fred.w.bacon 2026-01-20 15:57 ` [scarthgap][PATCH 1/1] lighttpd: Fix trailing slash on files in mod_dirlisting fred.w.bacon 2026-02-08 22:52 ` [OE-core] " Yoann Congal 2026-02-09 14:59 ` Fred Bacon
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox