HTTPHack 2.3 - Send\Receive custom HTTP messages ------------------------------------------------ Released 10th May 2010. (C) John Payne, 2010. 1. Introduction 2. Usage 3. Files 4. HTTP Persistency 5. About 6. License INTRODUCTION ----------------- HTTPHack allows you to send\receive HTTP messages using raw HTTP. It operates in two modes, either client or server mode which is defined by the command line arguments passed to the program. When using client mode, specify the target hostname or IP, and port number. You can also specify an optional filename which will be used as the network request. Note that the contents of this file isn't analysed by HTTPHack, it's up to you to ensure it's valid HTTP. -------------------------------------------------------------- NOTE: HTTPHack will add the HTTP delimiter (CR-LF) to the end of the file to instruct the server to stop reading. Do not include your own CR-LF ("\r\n") on the end of each line within this file. -------------------------------------------------------------- Server mode is used to act as a *very* crude HTTP server. Specify the port number and optional filename containing the HTTP response and HTTPHack will reply to any HTTP request (valid or not) using the contents of the file. Note that Server mode requires the client send the CR-LF before responding to input, this makes it pretty useless for other protocols at this time (except maybe ICAP). Note: If your request is a POST request, HTTPHack may add an extra newline. This shouldn't cause issues in most circumstances. USAGE --------------------- HTTPHack.exe [mode] (-c | -s) -c Client Mode -s Server Mode HTTPHack.exe -c [Request File] HTTPHack.exe -s [Response File] Request\Response file is optional, if omitted, the following is used: Client Mode: GET / HTTP/1.0 Host: User-Agent: HTTPHack/v, (Friendly HTTP Testing Tool) Server Mode: HTTP/1.0 200 OK Server: HTTPHack/v, (Friendly HTTP Testing Tool) Content-Length: 6 Connection: Close \r\n Hello! FILES --------------------- HTTPHack is packed with the following: HTTPHack.exe - Main executable serpentSocketDLL.dll - Socket functions DLL startCMD.bat - Batch file to open CMD prompt in current directory (for lazy folk) ChangeLog - Brief mention of changes README - This file TODO - Issues being addressed in next release HTTP PERSISTENCY --------------------- HTTPHack 2.x will tolerate HTTP persistency. If a server responds but leaves the connection open, HTTPHack will FIN\ACK the connection after 5 seconds of inactivity. This means that you can send HTTP/1.1 requests, but should the server stop responding for longer than 5 seconds, you may not receive the entire response. You can ensure HTTPHack returns immediately by using either HTTP/1.0 or the 'Connection: Close' header, or if the server FIN\ACK's immediately, HTTPHack will also close the socket. ABOUT --------------------- HTTPHack is a testing tool only (and a work in progress). A basic understanding of the HTTP protocol is advised. Written by John Payne. Report bugs to . http://httphack.the-serpent.co.uk HTTPHack was compiled using Visual C++ Express Edition 2008. LICENSE --------------------- This software is provided free of charge, with the following conditions: - Please do not decompile, reverse engineer or attempt to obtain the source code (it's my hard work, dammit). - Redistribution is permitted providing the entire package (including this file) is packaged without changes. HTTPHack is currently propriety, however may become open source once it's worthy, this means it may also be portable to Linux. Use at your own risk, this software comes with no warranties, or guarantees that will work in your environment. ---------------------- See ChangeLog for enhancements\progress. TODO file contains known bugs\due fixes.