#642374 xauth: Doesn't seem to handle concurrency [SEC=UNCLASSIFIED]

Package:
xauth
Source:
xauth
Description:
X authentication utility
Submitter:
Tim Connors
Date:
2011-09-22 00:57:04 UTC
Severity:
normal
#642374#5
Date:
2011-09-22 00:38:28 UTC
From:
To:
for run in `seq 1 10`
do
    ssh -X -l <my user> <server> "xload" &
done

/usr/bin/xauth:  error in locking authority file /home/<user>/.Xauthority
X11 connection rejected because of wrong authentication.



A sleep 0.1 though lets it through (most of the time, but like all
race conditions, this is a deeply evil hack).  One suspects xauth
shouldn't just fail immediately if it can't hardlink the lockfile.
Act more like procmail's lockfile utility, and back off a bit while
retrying.