From patchwork Sat Jan 14 16:16:22 2006 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Klaus Schmidinger X-Patchwork-Id: 12157 Received: from tiger.cadsoft.de ([217.7.101.210]) by www.linuxtv.org with esmtp (Exim 4.50) id 1Exo4p-000432-Da for vdr@linuxtv.org; Sat, 14 Jan 2006 17:16:27 +0100 Received: from raven.cadsoft.de (raven.cadsoft.de [217.7.101.211]) by tiger.cadsoft.de (8.13.4/8.13.4) with ESMTP id k0EGGQox029973 for ; Sat, 14 Jan 2006 17:16:26 +0100 Received: from [192.168.100.10] (hawk.cadsoft.de [192.168.100.10]) by raven.cadsoft.de (8.13.3/8.13.3) with ESMTP id k0EGGPnh019699 for ; Sat, 14 Jan 2006 17:16:26 +0100 Message-ID: <43C923D6.9040506@cadsoft.de> Date: Sat, 14 Jan 2006 17:16:22 +0100 From: Klaus Schmidinger Organization: CadSoft Computer GmbH User-Agent: Mozilla Thunderbird 1.0.6 (X11/20050716) X-Accept-Language: en MIME-Version: 1.0 To: vdr@linuxtv.org Subject: Re: [vdr] vdr 1.3.38: SVDRP grab filename References: <43C8E3F0.8010108@cadsoft.de> <43C900A0.2050005@cadsoft.de> In-Reply-To: X-Greylist: Sender DNS name whitelisted, not delayed by milter-greylist-2.0.2 (tiger.cadsoft.de [217.7.101.210]); Sat, 14 Jan 2006 17:16:26 +0100 (CET) X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-2.0 (raven.cadsoft.de [192.168.1.1]); Sat, 14 Jan 2006 17:16:26 +0100 (CET) X-BeenThere: vdr@linuxtv.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: VDR Mailing List List-Id: VDR Mailing List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 14 Jan 2006 16:16:27 -0000 Status: O X-Status: X-Keywords: X-UID: 7195 Stefan Huelswitt wrote: > On 14 Jan 2006 Klaus Schmidinger wrote: > >>Stefan Huelswitt wrote: >> >>>Actualy it allows overwriting files with no extention only. >>> >>>I find it convinient to be backward compatible. >>>As the whole operation is limited to the grab directory anyways, >>>security considerations are negligible IMHO. >> >>And what's the point in writing to a file without an extension? > > > For me the point was, that vdradmin uses a grab file without > extention since ever. vdr 1.3.38 broke that. > > I think it's a good idea to behave in a backward compatible way > whenever possible. > > Jut my 2 cents. Ok, since there have been no other voices on this, and personally I don't really care, I've removed the entire 'else' clause, since Jpeg is true by default: However, this still doesn't allow names with '.' that don't end in one of the known extensions. But then again I would assume that programs connecting to an SVDRP port will switch to using the base64 encoded data sent over the port. Klaus --- svdrp.c 2006/01/14 14:55:52 1.92 +++ svdrp.c 2006/01/14 16:08:20 @@ -683,10 +683,6 @@ } else if (strcmp(FileName, "-") == 0) FileName = NULL; - else { - Reply(501, "Missing filename extension in \"%s\"", FileName); - return; - } // image quality (and obsolete type): if ((p = strtok_r(NULL, delim, &strtok_next)) != NULL) { if (strcasecmp(p, "JPEG") == 0 || strcasecmp(p, "PNM") == 0) {