Demo Discussion
Forum Config Examples Contributions Vulnerabilities
  Discussion forum about ELOG, Page 689 of 806  Not logged in ELOG logo
New entries since:Thu Jan 1 01:00:00 1970
ID Date Icon Author Author Email Category OS ELOG Version Subject
  1011   Thu Mar 24 11:00:59 2005 Smile Emiliano GabrielliAlberT@SuperAlberT.itBug reportLinux Re: Crash with Protect Selection page = 1
> > Using 2.5.8, if I set "Protect Selection page" to 1, then elogd seg faults
> > as soon as it is accessed.
> 
> Thanks for reporting this bug. I fixed it and committed the change to CVS.
> 
> - Stefan

wow, who's Speedy Gonzales ?!? :-P
  1010   Thu Mar 24 10:51:10 2005 Warning Emiliano GabrielliAlberT@SuperAlberT.itBug reportLinuxr1592Re: 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
> 
> This is on purpose. If you want to save an attachment locally and right click on
> the attachment, and select "Save link as..." in your browser, then the default
> file name is taken from the link. If your original file namw was "peeling
> 002.jpg", then you want again the same name, and not "050309_170709_peeling
> 002.jpg, because you would have to delete the date/time part of the file name
> each time which would be annoying. That's why I have chosen to put an artificial
> "/" between the date/time and the original file name. On the elog side, it's
> converted correctly back to the file name.
> 

yes I notice this after posting :-) sorry

> The problem with blanks in attachment names I could not reproduce. See this
> post, which contains an attachment with a blank in it. As you can see, this does
> not crash the server. 

Ok I can confirm this.
The problem arises, for me, when upgrading to the new version of elog having yes
some old entries with attached filenames containing spaces and/or uppercase extensions.

It seems that uploading files with spaces in the name *now* works well... so the
problem should be somewhere in the handling of existing attachments, not rised when
the attachment is uploaded with the current version of elog ... it's quite strange
  1009   Thu Mar 24 10:39:00 2005 Smile Stefan Rittstefan.ritt@psi.chBug reportLinux Re: Crash with Protect Selection page = 1
> Using 2.5.8, if I set "Protect Selection page" to 1, then elogd seg faults
> as soon as it is accessed.

Thanks for reporting this bug. I fixed it and committed the change to CVS.

- Stefan
  1008   Thu Mar 24 10:31:01 2005 Angy Stephen A. Woodsaw@jlab.orgBug reportLinux Crash with Protect Selection page = 1
Using 2.5.8, if I set "Protect Selection page" to 1, then elogd seg faults
as soon as it is accessed.

Under 2.5.7, a login page will come up, and the logbook will work, but only
if a valid username/password is given.  If an invalid login is given, then
elogd crashes.  We have a cron job that periodically restarts elogd if it is
has crashed.

Steve

[global]
logbook tabs = 0
port = 8080
Protect Selection page = 1
Password file = user.info
Admin user = saw
 
  1007   Wed Mar 23 20:35:55 2005 Warning Stefan Rittstefan.ritt@psi.chBug reportLinuxr1592Re: 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

This is on purpose. If you want to save an attachment locally and right click on
the attachment, and select "Save link as..." in your browser, then the default
file name is taken from the link. If your original file namw was "peeling
002.jpg", then you want again the same name, and not "050309_170709_peeling
002.jpg, because you would have to delete the date/time part of the file name
each time which would be annoying. That's why I have chosen to put an artificial
"/" between the date/time and the original file name. On the elog side, it's
converted correctly back to the file name.

The problem with blanks in attachment names I could not reproduce. See this
post, which contains an attachment with a blank in it. As you can see, this does
not crash the server. 
Attachment 1: back 42.jpg
back 42.jpg
  1006   Wed Mar 23 16:44:32 2005 Agree Recai Oktasroktas@omu.edu.trInfoLinux Re: New Debian package (2.5.8+r1592) -- needs testing
> It seems to work nice to me.
> Just another suggestion: I think it would be better to insert a commented out
> example for all allowed parameters in the distributed  /etc/default/elog

Thanks for the test.  Please note that, /etc/default/elog is partially auto
created during the installation.  All options except PIDFILE and CONFFILE are
currently listed (as configured or commented out).  If you didn't see these
options (after the update), there must be a problem.   Did you mean the lack of
PIDFILE and CONFFILE in the default file?
  1005   Wed Mar 23 12:54:51 2005 Warning Emiliano GabrielliAlberT@SuperAlberT.itBug reportLinuxr1592Re: 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

A correction:
the url generated is correct, infact modifing by hand the names of the files and
the "Attachment:" entry in the .log all works fine

the same problem happens if the filename is, for example foo.JPG and not foo.jpg :
http://arcolog.roma2.infn.it:8080/ARCO/050221_171508/Graph3.JPG
loops forever

http://arcolog.roma2.infn.it:8080/ARCO/050221_171508/Graph3.jpg
works correctly


so, elog does not like spaces in filename and/or uppercase extensions. the
solution is, IMHO, to sanify the uploaded filename at uploading time :-)
  1004   Wed Mar 23 11:29:51 2005 Warning Emiliano GabrielliAlberT@SuperAlberT.itBug reportLinuxr1592wrong 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-3fb85fa6