More debugging: If I send connect, request data (a short XML text which the server is looking for), then connect again, The data comes through.
Note: I am watching in a packet sniffer and I never see the policy file come across any port, though I am able to connect. Note2: if I remove the nullbyte from the perl code no data ever appears. -puzzled John