Bug 18000 - esound wont always obey $ESPEAKER
Bug#: 18000 Product:  Gentoo Linux Version: 1.4_rc2 Platform: All
OS/Version: Linux Status: RESOLVED Severity: normal Priority: P2
Resolution: FIXED Assigned To: gnome@gentoo.org Reported By: taviso@gentoo.org
Component: GNOME
URL: 
Summary: esound wont always obey $ESPEAKER
Keywords:  
Status Whiteboard: 
Opened: 2003-03-22 09:40 0000
Description:   Opened: 2003-03-22 09:40 0000
Theres a typo in esdlib.c, which means that under certain circumstances output
to esd in applications linked with libesound wont always go where you want.

Reproduce:

1) Setup two machines with sound, one running esd with -public -tcp 
2) On the machine NOT running esd, try playing something (eg with xmms) with
ESPEAKER set, or with "use remote host" checked. It should work.
3) Now on that same machine, start a local esd, and repeat - xmms will play to
the local daemon, whether you have ESPEAKER or "play on remote host" set.

A typo means that every host is thought to be localhost, so esd trys to connect
via local unix sockets before trying tcp, a good idea if it really is local -
but if you also have a local esd unix socket - it wont do what you want! 

Ive tried reporting this on bugzilla.gnome.org, but its not responding right now
- i'll do it when it gets back up. (I had already searched for the bug, its not
there)

the attatched one-liner patch fixes it for me.

Im not sure if there are security implications for this, eg stealing a users
sound by planting a UNIX socket where esd expects to find it...

------- Comment #1 From Tavis Ormandy (RETIRED) 2003-03-22 09:41:13 0000 -------
Created an attachment (id=9695) [details]
Not all hosts are localhost.

one-liner fix.

------- Comment #2 From Tavis Ormandy (RETIRED) 2003-03-22 09:46:46 0000 -------
Created an attachment (id=9696) [details]
arg, lets try that again.

------- Comment #3 From foser (RETIRED) 2003-04-25 09:46:49 0000 -------
have you reported this to gnome.org bugzilla already ? got a bugno ?

The fix looks fairly obvious to me, see no reason to assume it's going to be a security risk.

------- Comment #4 From Tavis Ormandy (RETIRED) 2003-04-25 17:07:53 0000 -------
#108954 

no reply from maintainers.

------- Comment #5 From foser (RETIRED) 2003-05-14 09:02:14 0000 -------
i think esound is pretty unmaintained. I don't even know why they do the double
check !host || *host  . But then i haven't looked at the source really.

anoyone anything to say before i add this ?

------- Comment #6 From Tavis Ormandy (RETIRED) 2003-06-10 02:15:40 0000 -------
a gnome developer has reponded that this has been fixed in cvs. 

------- Comment #7 From Tavis Ormandy (RETIRED) 2003-06-10 10:24:16 0000 -------
esound-0.2.29-r1.ebuild includes the patch, Thanks!