Date: Thu, 8 Apr 2004 07:59:46 -0700 (PDT) From: Greg Panula <greg.panula@lexisnexis.com> To: freebsd-gnats-submit@FreeBSD.org Subject: misc/65326: jftpgw errors out with "Could not change the EUID to 65534: Operation not permitted" Message-ID: <200404081459.i38Exk8F098859@www.freebsd.org> Resent-Message-ID: <200404081500.i38F0Tfx051987@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
>Number: 65326 >Category: misc >Synopsis: jftpgw errors out with "Could not change the EUID to 65534: Operation not permitted" >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Thu Apr 08 08:00:28 PDT 2004 >Closed-Date: >Last-Modified: >Originator: Greg Panula >Release: 4.9-RELASE >Organization: >Environment: FreeBSD proxy-01.lng-mpls.com 4.9-RELEASE-p4 FreeBSD 4.9-RELEASE-p4 #1: Wed Apr 7 04:43:38 CDT 2004 pang@proxy-01:/usr/obj/usr/src/sys/PROXY-01 i386 >Description: jftpgw errors out with "Could not change the EUID to 65534" when making use of the "runasuser" feature. >How-To-Repeat: make && make install /usr/local/sbin/jftpgw -f /usr/local/etc/jftpgw.conf.sample >Fix: Patch util.c to use setreuid instead of setuid -------------->8----------------- --- util.c.orig Thu Apr 8 09:52:20 2004 +++ util.c Thu Apr 8 09:54:15 2004 @@ -249,21 +249,11 @@ return -1; } if (what == EUID) { -#ifdef HAVE_SETEUID - i = seteuid(uid); -#else - /* HP-UX does not know seteuid() */ i = setreuid(-1, uid); -#endif } else if (what == UID) { i = setuid(uid); } else if (what == EGID) { -#ifdef HAVE_SETEGID - i = setegid(gid); -#else - /* HP-UX does not know setegid() */ i = setregid(-1, gid); -#endif } else if (what == GID) { i = setgid(gid); } ------------------------8<------------------- >Release-Note: >Audit-Trail: >Unformatted:
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200404081459.i38Exk8F098859>