// - tell servlet we're expecting a file with a given ID
// - silently discard the packet without notifying anyone
// - actually, give the initiator a URL to post to w/ token?
// - servlet continues where the POSTed file left off
HttpSession httpSession = (HttpSession)initiatorSession;
HttpConnection httpConnection = (HttpConnection)httpSession.getConnection();
// does getServerName include port? is it the actual HTTP host name?
String transferPostUrl = "http://"+httpSession.getServerName()+"/fileupload.jsp";
IQ httpInfoIQ = new IQ(IQ.Type.set);
httpInfoIQ.setTo(initiator);
// FIXME this seems like gross misuse of error... make a custom packet extension.
httpInfoIQ.setError(new PacketError(PacketError.Condition.redirect, PacketError.Type.modify, transferPostUrl) );