Date: Tue, 22 Mar 2005 08:54:01 +0100 (CET) From: Florian Hars <hars@bik-gmbh.de> To: FreeBSD-gnats-submit@FreeBSD.org Subject: ports/79114: stunnel calls execvp with broken arguments Message-ID: <200503220754.j2M7s1eG039736@grisu.bik-gmbh.de> Resent-Message-ID: <200503220800.j2M80G4e076348@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
>Number: 79114 >Category: ports >Synopsis: stunnel calls execvp with broken arguments >Confidential: no >Severity: serious >Priority: medium >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Tue Mar 22 08:00:16 GMT 2005 >Closed-Date: >Last-Modified: >Originator: Charlie & >Release: FreeBSD 5.3-RELEASE i386 >Organization: >Environment: System: FreeBSD grisu.bik-gmbh.de 5.3-RELEASE FreeBSD 5.3-RELEASE #0: Fri Nov 5 04:19:18 UTC 2004 root@harlow.cse.buffalo.edu:/usr/obj/usr/src/sys/GENERIC i386 >Description: If execargs is not given in stunnel.conf, stunnel calls execvp with a NULL pointer as its second argument, which makes execvp fail with EFAIL. >How-To-Repeat: I wrapped popa3d with stunnel, which worked on 4.x (modulo the spurious broken connection errors I filed a while ago) without execargs in stunnel.conf. I copied my configuration, and now every connection attempt leads to stunnel[13279]: /usr/local/libexec/popa3d: Bad address (14) >Fix: execargs should be mandatory (and checked on startup), or something like the following should be done in client.c: if (NULL == c->opt->execargs) { char *args[] = {c->opt->execname, NULL}; execvp(c->opt->execname, args); } else { execvp(c->opt->execname, c->opt->execargs); } >Release-Note: >Audit-Trail: >Unformatted:
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200503220754.j2M7s1eG039736>