{"id":20350,"date":"2021-02-15T22:02:57","date_gmt":"2021-02-15T22:02:57","guid":{"rendered":"http:\/\/www.devopsschool.com\/blog\/?p=20350"},"modified":"2021-02-15T22:08:35","modified_gmt":"2021-02-15T22:08:35","slug":"how-to-save-http-requests-headers-methods-and-body-to-a-file","status":"publish","type":"post","link":"https:\/\/www.devopsschool.com\/blog\/how-to-save-http-requests-headers-methods-and-body-to-a-file\/","title":{"rendered":"How to save HTTP requests headers, methods and body to a file?"},"content":{"rendered":"\n<h2 class=\"wp-block-heading\">Method 1 &#8211; Using mod_log_forensic apache Module<\/h2>\n\n\n\n<p><strong>Step 1 &#8211; Check if mod_log_forensic module is enabled or not<\/strong><\/p>\n\n\n<pre class=\"wp-block-code\"><span><code class=\"hljs\">$ .\/httpd -M | grep mod_log_forensic<\/code><\/span><\/pre>\n\n\n<p><strong>Step 2 &#8211; Enable mod_log_forensic module using following lines in httpd.conf<\/strong><\/p>\n\n\n\n<script src=\"https:\/\/gist.github.com\/devops-school\/5a028465a52d5dd9a18eb98e45c9d89b.js\"><\/script>\n\n\n\n<h2 class=\"wp-block-heading\">Method 2 &#8211; Using PHP Script<\/h2>\n\n\n\n<script src=\"https:\/\/gist.github.com\/devops-school\/35f6c36cbb60663ac1fabe821b09b529.js\"><\/script>\n","protected":false},"excerpt":{"rendered":"<p>Method 1 &#8211; Using mod_log_forensic apache Module Step 1 &#8211; Check if mod_log_forensic module is enabled or not Step 2 &#8211; Enable mod_log_forensic module using following lines in httpd.conf Method&#8230; <\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_joinchat":[],"footnotes":""},"categories":[2],"tags":[],"class_list":["post-20350","post","type-post","status-publish","format-standard","hentry","category-uncategorised"],"_links":{"self":[{"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/posts\/20350","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/comments?post=20350"}],"version-history":[{"count":2,"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/posts\/20350\/revisions"}],"predecessor-version":[{"id":20353,"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/posts\/20350\/revisions\/20353"}],"wp:attachment":[{"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/media?parent=20350"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/categories?post=20350"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/tags?post=20350"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}