Lets take a look at a new tool available to Lenny & Sid:
apt-get source acon
int main(int argc,char **argv)
{
int i,tty,useunicode=0;
char *fontf=0,*translationf=0,*keymapf=0;
get_ids();
set_user_id();
/*Read configure file if no input options*/
if(argc<2)
{
char *env;
FILE *fp;
char font[300],translation[300],keymap[300];
char tmp[300];
font[0]=translation[0]=keymap[0]=0;
if((env=getenv("HOME")))
sprintf(tmp,"%s/.acon.conf",env);
else
strcpy(tmp,"/etc/acon.conf");
Hmmm. Nice use of the environment there. I wonder what permissions the binary has:
skx@gold:~$ ls -l /usr/bin/acon -rwsr-xr-x 1 root root 48672 2008-06-09 10:50 /usr/bin/acon
setuid(0) - just say no.
ObTitle: Blackadder II
I saw the bug, but I'm scared of the code. e.g. the my_system call.
Still it does look like permissions are dropped prior to that being invoked.
Helmut
Nion you're probably right.
I was updating my list of Setuid/setgid binaries in the archive and this package contained one near the top of the list. (Full list on gluck in ~skx/).
I started being shocked at the code. Then I saw the CVE assignment and rememembered we'd had a discussion.
I personally believe this package:
I know that there were patches, but the application as a whole is not written in a secure fashion - and to require setuid(0) privileges just makes me scared.
I failed to add a date to this entry, so each time I rebuilt the blog (to add the comments), it was marked as "new".
Thanks for pointing it out to me, I've fixed it now.