![]() |
|
Message-ID: <sqo7nqpr-151q-4sr4-1o40-r95r62179s29@vanv.qr> Date: Fri, 25 Apr 2025 09:46:15 +0200 (CEST) From: Jan Engelhardt <ej@...i.de> To: Florian Westphal <fw@...len.de> cc: Sunny73Cr <Sunny73Cr@...tonmail.com>, "netfilter-devel@...r.kernel.org" <netfilter-devel@...r.kernel.org>, oss-security@...ts.openwall.com Subject: Re: Trailing dot in Cygwin filenames [was: failed to clone iptables,ipset,nftables] On Friday 2025-04-25 08:22, Florian Westphal wrote: >Sunny73Cr <Sunny73Cr@...tonmail.com> wrote: >> error: invalid path 'src/json.' > >There is indeed a bogus file of that name, no idea >why its there or why cygwin git chokes on it. There is some prior record - https://github.com/libgit2/libgit2/issues/6968 "foo" and "foo." are equivalent in DOS, and there is a normalization phase from "foo." to "foo". This carried forward into contemporary Windows cmd.exe, explorer.exe (File Explorer), the usual file access APIs. echo abc >x echo def >y. creates "y" not "y." in cmd. But Cygwin does something unusual, it *actually* creates a file with the 2-char sequence "y.", through whatever means. Explorer *shows* it with the dot, but practially no application other than Cygwin can open it, because all normal APIs and fs lookup mechanisms are rummaging for "y" as per the earlier equivalance, and either 1. there is no file "y", so some programs can/may/will throw an error 2. or, come to think of it, there is an evil file (hi oss-security) [in cgwin] echo good >y echo evil >y. If you now try to open "y." with notepad.exe from Explorer, you always get the "good" variant. Only inside Cygwin, e.g. with cat.exe, can "y" be distinguished from "y.".
Powered by blists - more mailing lists
Please check out the Open Source Software Security Wiki, which is counterpart to this mailing list.
Confused about mailing lists and their use? Read about mailing lists on Wikipedia and check out these guidelines on proper formatting of your messages.