fork from http://sourceforge.net/projects/xrdua/