add XDR support