X-Recipient: archive-cygwin AT delorie DOT com DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org B8562384780B DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cygwin.com; s=default; t=1624924820; bh=NkKKNMPIsnTF3mnu/8Ddm14FWatzfi1eJVrmDAYGDkQ=; h=Date:To:In-Reply-To:References:Subject:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To: From; b=Nq0oV9nmQs/6Z90Wvy+pZq/ix45rlWFQMS1iwMEeRTRIWw1bc5TedwaDYFwX+Hi// kubC9RoqzOC9f5v49Ec3B9MXpzZWsYp1bs9DXG9VaD0QSPY5pRPnJsXiSEEruKc8iG z2frdeaZ4sr8hppBsgIn+pIBkA+T3XcQeXNePhK8= X-Original-To: cygwin AT cygwin DOT com Delivered-To: cygwin AT cygwin DOT com DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 532473848411 X-SONIC-DKIM-SIGN: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048; t=1624924785; bh=myy7VH0a5PfW0fHUg/kvIVBZ58Uc6LFblRiS6wQBThB=; h=X-Sonic-MF:Date:From:To:Subject:From:Subject; b=Oiwwp9QYf4S+lqal6Qji6gCsqSdfWYKSOuGphjF2T86DVKMFDgwN4nTIGthJgOjjTe6/U1nkowZ99R5GzSJ0aiNeM49qHFS+4tAkGMjklp3C0f1Zw5ynWB6i10AhEolFNrL/YPQdzpDcAE2y+sYiyr7icqlm2VzYXKQV9WoGYqFmZi3/8qA2nzQ6FjgLH2GJl5DWXEN1YycApicZC64b3krriJu8FW2l1QOfmaJqi5jy6uL9U/VHYgniy+mvqJyD9yuoh3dMKUlxBIxp7yM8BIB5v8xo+3UfQE4gMnuZGelzD3ZopFMmulCYP9CGaDmAKlwSiTbKBY4e3uylbZgzmw== X-YMail-OSG: AMRNBrMVM1kDM2RC2dHHrCBMK98OKT9L4BMEEMp_IsFosZXHInPBMw1brUGoQTl tf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3IvyGAjLkSwxw3nfkIkEY9BItibM2IajqVbdjhHm8N4gTqIqKfwGH o5aFlaE04wV.m_BhYuNkj6.hQxiENKW3Fw7dT.TB.7BDIN.GGzUN4.V.sED6IG9_IJ4_9HAgC6mb AtNzPqncvxQJcfpd4Wyq_hrzJSerlxRrFSFffaKgmBtgV4kthtBqrsBULLQ7f49whzSt_Qc7o6ae KMVod6I4nWoGq71FTflzCTUiaXNVYYttw45di7QjvMnKGsehtcg6685jcAViN.8jQWmcT5Zh4lff ZA4d30KTjEkEcJuKdPOw4jXoWxyGJHySWjk887QaEOnSXxW9Gl_iL.IjHWstbi_UkXBkYPKlGF2X .LkPwZMOBFbEl X-Sonic-MF: Date: Mon, 28 Jun 2021 23:57:41 +0000 (UTC) To: "cygwin AT cygwin DOT com" , David Oppenheim Message-ID: <1714177064.2738894.1624924661209@mail.yahoo.com> In-Reply-To: <20210629084746.Horde.EOaX4JftYZgseWRQhFJQPhx@optimation.com.au> References: <20210629084746 DOT Horde DOT EOaX4JftYZgseWRQhFJQPhx AT optimation DOT com DOT au> Subject: Re: Difficult getting pure-ftpd to work under Cygwin on Windows 10, esp anonymous ftp MIME-Version: 1.0 X-Mailer: WebService/1.1.18469 YMailNorrin X-Spam-Status: No, score=0.0 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, FREEMAIL_FROM, HTML_MESSAGE, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=unavailable autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on server2.sourceware.org X-Content-Filtered-By: Mailman/MimeDel 2.1.29 X-BeenThere: cygwin AT cygwin DOT com X-Mailman-Version: 2.1.29 Precedence: list List-Id: General Cygwin discussions and problem reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , From: matthew patton via Cygwin Reply-To: matthew patton Content-Type: text/plain; charset="utf-8" Errors-To: cygwin-bounces+archive-cygwin=delorie DOT com AT cygwin DOT com Sender: "Cygwin" Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from base64 to 8bit by delorie.com id 15T00LsC028416 have you tried applying the notable permissions from this to your 'ftp' windows user?https://docs.microsoft.com/en-us/windows/security/threat-protection/security-policy-settings/user-rights-assignment On Monday, June 28, 2021, 06:48:18 PM EDT, David Oppenheim wrote: I have debugged various obstacles getting logins to pure-ftpd to work under Cygwin on Windows 10 (Home edition 20H2 on this particular PC), especially getting anonymous ftp to login successfully. My pure-ftpd is version 1.0.46-1 as downloaded by the Cygwin installer. There are problems with how it looks up username/password, with it calling seteuid(), and sometimes with pathnames for the user's home directory, and the user's shell. This is particularly fraught if you try to use  anonymous ftp. My solution is a simple recipe, albeit limited but fine for personal or small group use ... technical problem details after this recipe. I hope this helps anyone else trying to get it to work ! --- recipe for setting up pure-ftpd on Cygwin Set up pure-ftp passwd file first with pure-pw -f filename.passwd then convert to puredb format with    pure-pw mkdb filename.pdb -f  filename.passwd Note that sometimes pure-pw and/or pure-ftpd imply a /etc prefix for  the filename, seems that's overridden if you use an absolute pathname. Run pure-ftpd as you. From the ftp client login as you with the puredb file password not the Windows password. Your starting directory once logged in will be the homne directory as set up in the puredb entry for your username ... probably /home/yourloginname (as viewed from inside Cygwin). --- end recipe Re anonymous login ... Internally pure-ftpd translates "anonymous" to "ftp" Anonymous login is not checked in the -l puredb file, it does a getpwnam() call, so "ftp" ** must ** be a user in Windows Needs /home/ftp (pathname from inside Cygwin) and perhaps ~/home/ftp for user running pure-ftpd For any ftp login, if the ftp username is not the same as the Windows user running pure-ftpd, pure-ftpd fails on seteuid() ... see Windows event logger (or Cygwin syslog if that's installed), the ftp client sees "Unable to set up secure anonymous FTP" This happens even if running pure-ftpd from Explorer by "Run as Administrator" So for anonymous login you have to run pure-ftpd as Windows user ftp More generally, because of that seteuid issue, if you want to ftp login as uuu then you need to run pure-ftpd as Windows user uuu ... although having uuu in a pure-pw database permits the password to be different from the Windows login password. Nb: if you run pure-ftpd directly from Explorer (incl "Run as Administrator") the place it looks for the home directory may be ./ or the Windows user's home (C:\Users\uuu) and I have also seen failures setting user shell because it's looking for e.g. /bin/bash somewhere else. -- Problem reports:      https://cygwin.com/problems.html FAQ:                  https://cygwin.com/faq/ Documentation:        https://cygwin.com/docs.html Unsubscribe info:    https://cygwin.com/ml/#unsubscribe-simple -- Problem reports: https://cygwin.com/problems.html FAQ: https://cygwin.com/faq/ Documentation: https://cygwin.com/docs.html Unsubscribe info: https://cygwin.com/ml/#unsubscribe-simple