Demo Discussion
Forum Config Examples Contributions Vulnerabilities
  Discussion forum about ELOG  Not logged in ELOG logo
icon4.gif   wrong handling of attachment names, posted by Emiliano Gabrielli on Wed Mar 23 11:29:51 2005 
    icon4.gif   Re: wrong handling of attachment names, posted by Emiliano Gabrielli on Wed Mar 23 12:54:51 2005 
    icon4.gif   Re: wrong handling of attachment names, posted by Stefan Ritt on Wed Mar 23 20:35:55 2005 back 42.jpg
       icon4.gif   Re: wrong handling of attachment names, posted by Emiliano Gabrielli on Thu Mar 24 10:51:10 2005 
          icon2.gif   Re: wrong handling of attachment names, posted by Stefan Ritt on Fri Mar 25 00:33:51 2005 
    icon8.gif   Re: wrong handling of attachment names, posted by Emiliano Gabrielli on Thu Mar 24 13:40:27 2005 elog_trace.txt
       icon2.gif   Re: wrong handling of attachment names, posted by Stefan Ritt on Fri Mar 25 00:30:57 2005 
          icon2.gif   Re: wrong handling of attachment names, posted by Emiliano Gabrielli on Tue Mar 29 11:49:29 2005 
          icon12.gif   Re: wrong handling of attachment names, posted by Emiliano Gabrielli on Tue Mar 29 16:21:32 2005 
Message ID: 1004     Entry time: Wed Mar 23 11:29:51 2005     Reply to this: 1005   1007   1019
Icon: Warning  Author: Emiliano Gabrielli  Author Email: AlberT@SuperAlberT.it 
Category: Bug report  OS: Linux  ELOG Version: r1592 
Subject: wrong handling of attachment names 
When an attached image name contains a space in its filename and attachment
display is enabled elog builds a wrong url to the image:

http://arcolog.roma2.infn.it:8080/ARCO/050309_170709/peeling+002.jpg

instead of the correct one:

http://arcolog.roma2.infn.it:8080/ARCO/050309_170709_peeling+002.jpg

The more annoing thing is that elogs hangs on this. a strace shows a select
on fd n°3 and 5 that loops forever (returning a timeout error):

send(4, "<141>Mar 23 11:36:25 elogd[22189"..., 35, 0) = 35
rt_sigaction(SIGPIPE, {SIG_IGN}, NULL, 8) = 0
select(1024, [3 5], NULL, NULL, {1, 0}) = 0 (Timeout)
select(1024, [3 5], NULL, NULL, {1, 0}) = 0 (Timeout)


May be the better solution is, after fixing the bug for backward
compatibility with already uploaded images, to implement a forced characters
substitution at upload time, replacing spaces and every character not in a
"allowed chars" list with an underscore
ELOG V3.1.5-fe60aaf