If you don't want to go the whole hog with XML processing...
Let's assume you've got the file all read into a single string $xml.
I could assume that all the tags are always in the same order, but I won't. I will assume though that there is only ever one of each per file.
This also assumes that tags don't get nested any more than shown. One of the reasons that things like the expat parser were built is that this sort of thing can quickly get hairy.
First, remove the <XMLDATA> tags.
$xml=preg_replace('|</?XMLDATA>|i','',$xml);
Then match the contents of all the other tags.
preg_match_all('|<(.?)>(.?)</|is',$xml,$matches);
for($i=0; $i<count($matches[0]); $i++)
{
$evalstr = '$'.strtolower($matches[1][$i])."='".$matches[2][$i]."';";
eval($evalstr);
}
And this'll give you
$msidsn, $login, etc. to do with as you please.
Generating the return data is trivial - it's just text.