Esempio n. 1
0
	public void sendXHeader() throws IOException
	{
		StringBuffer header1 = new StringBuffer();
		StringBuffer header2 = new StringBuffer();
		int lengthOfXA = param.getRandomLengthOfXA();
		int lengthOfXB = param.getRandomLengthOfXB();
		for (int i=0 ; i<lengthOfXA ; i++) 
		{
			header1.append(Misc.getRandomByte());
		}
		for (int i=0 ; i<lengthOfXB ; i++) 
		{
			header2.append(Misc.getRandomByte());
		}
		socket.getOutputStream().write(("X-" + header1.toString() + ": " + header2.toString() + "\r\n").getBytes());
		socket.getOutputStream().flush();
	}
Esempio n. 2
0
	public void sendPOSTBodyRandomByte() throws IOException
	{
		socket.getOutputStream().write(Misc.getRandomByte());
		socket.getOutputStream().flush();
	}