-
Notifications
You must be signed in to change notification settings - Fork 46
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Apache httpd demo #6563
Apache httpd demo #6563
Conversation
160b135
to
eaa3e56
Compare
…ery instrumented HTTP parser
TEST_CASE=$(basename "$file") | ||
if [[ ! -d results/"$TEST_CASE" ]]; then |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
When I was working on the httpd harness initially, there were some test cases that didn't process correctly, and I added this to avoid having to reprocess everything. I retained this functionality here because it would be useful if one had already done an evaluation over an existing corpus, then expanded the corpus and wanted to evaluate new test cases under the existing set of parsers. However, if new parsers were added below, unless the test case subdirectory is deleted, the new parsers would not be evaluated over that test case.
Scripts included:
tdag_pairs.sh
- takes a directory containing raw http requests, produces a directoryresults
containing a subdirectory per request. Each subdirectory contains a compressed TDAG corresponding to the evaluation of that request by whatever instrumented parsers are in examples/httpd.faw_tdag_pairs.sh
- convenience for producing pairs of TDAGs corresponding to FAW http test cases. (Definitely understand if we don't want this under version control, but I've been using it to gather results for cluster analysis.)Suggested testing:
cd /path/to/polytracker/examples/http/httpd ./example_httpd.sh /path/to/raw_http_request 56781
Expected result: produce
raw_http_request.tdag
, a TDAG corresponding to runningraw_http_request
through polytracker-instrumented httpd. Onpolytracker info --print-fd-headers raw_http_request.tdag
, the socket header's server port will be 56781. (The port number is an optional argument and defaults to 80.)cd /path/to/polytracker/examples/http ./faw_tdag_pairs.sh /path/to/FAW/test_files/http
Expected result: produces directory
results
, containing subdirectories for each request in the FAW's http corpus. Each subdirectory contains two compressed TDAGs corresponding to running that request through polytracker-instrumented picohttpparser and httpd (with the server listening on port 80, and corresponding socket FD header in the TDAGs).