FS#22839 - [xloadimage] 4.1-9 leaks x resources causing DoS situation

Attached to Project: Community Packages
Opened by Leonidas Arvanitis (larvan) - Thursday, 10 February 2011, 12:02 GMT
Last edited by Sergej Pupykin (sergej) - Friday, 11 February 2011, 12:14 GMT
Task Type Bug Report
Category Packages
Status Closed
Assigned To Sergej Pupykin (sergej)
Architecture x86_64
Severity Critical
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

Description:
When xloadimage is used to set the root window background it leaves "junk X clients" open
causing the server to become full after some runs and no longer let other windows open (DoS situation on X).
Very easy to hit the cap after some time with applications that set the bg many times, like xscreensavers or conky.


Additional info:
* xloadimage version: 4.1-9 from community repo
* xorg-xserver version: 1.9.4-1
* arch: x86_64
* attached output of "xrestop -b -m 1"

I think this is the same issue or related to the one reported in Debian here:
http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=325689
and they seem to have fixed it.


Steps to reproduce:
1. Count X clients with xrestop:
$ echo $((`xrestop -b -m 1 | wc -l` / 16))

2. Set root bg with xloadimage or xsetbg:
$ xloadimage -onroot /path/to/image.jpg

3. Repeat steps 1 and 2 a couple of times and watch X clients increasing with each run.

4. Repeat enough times and the X clients list gets full (255) leading to the following error when new X apps try to start:
"Maximum number of clients reachedMaximum number of clients reachedError: cannot open display: :0"
   xrestop (30.8 KiB)
This task depends upon

Closed by  Sergej Pupykin (sergej)
Friday, 11 February 2011, 12:14 GMT
Reason for closing:  Fixed
Additional comments about closing:  try 10th pkgrel

Loading...