{"id":291,"date":"2013-10-07T21:14:39","date_gmt":"2013-10-07T21:14:39","guid":{"rendered":"http:\/\/dollarunderscore.azurewebsites.net\/?p=291"},"modified":"2019-04-26T10:09:30","modified_gmt":"2019-04-26T08:09:30","slug":"parsing-windows-dns-debug-log","status":"publish","type":"post","link":"https:\/\/p0wershell.com\/?p=291","title":{"rendered":"Parsing Windows DNS Debug log&#8230;"},"content":{"rendered":"<p>Every now and then I need to be able to parse a DNS debug log, it&#8217;s useful in many different scenarios. I wrote an advanced function to help me with this, specify a file name or pipe log lines (or file names) to it and it will return a properly formatted object.<\/p>\n<p>Be aware that I only added some of the different date formats I could find, so verify that it works for your server.<\/p>\n<p>Some dumps (with IP and hostnames masked):<br \/>\n<a href=\"https:\/\/p0wershell.com\/wp-content\/uploads\/2013\/10\/dnslogparser_masked1.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-301\" src=\"https:\/\/p0wershell.com\/wp-content\/uploads\/2013\/10\/dnslogparser_masked1.jpg\" alt=\"dnslogparser_masked1\" width=\"997\" height=\"678\" srcset=\"https:\/\/p0wershell.com\/wp-content\/uploads\/2013\/10\/dnslogparser_masked1.jpg 997w, https:\/\/p0wershell.com\/wp-content\/uploads\/2013\/10\/dnslogparser_masked1-300x204.jpg 300w, https:\/\/p0wershell.com\/wp-content\/uploads\/2013\/10\/dnslogparser_masked1-624x424.jpg 624w\" sizes=\"(max-width: 997px) 100vw, 997px\" \/><\/a><\/p>\n<p><a href=\"https:\/\/p0wershell.com\/wp-content\/uploads\/2013\/10\/dnslogparser_masked2.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-311\" src=\"https:\/\/p0wershell.com\/wp-content\/uploads\/2013\/10\/dnslogparser_masked2.jpg\" alt=\"dnslogparser_masked2\" width=\"997\" height=\"678\" srcset=\"https:\/\/p0wershell.com\/wp-content\/uploads\/2013\/10\/dnslogparser_masked2.jpg 997w, https:\/\/p0wershell.com\/wp-content\/uploads\/2013\/10\/dnslogparser_masked2-300x204.jpg 300w, https:\/\/p0wershell.com\/wp-content\/uploads\/2013\/10\/dnslogparser_masked2-624x424.jpg 624w\" sizes=\"(max-width: 997px) 100vw, 997px\" \/><\/a><\/p>\n<p><em><strong>Code is available <a title=\"DNS Debug Log Reader\" href=\"https:\/\/p0wershell.com\/wp-content\/uploads\/2017\/06\/Reading-DNS-Debug-logs.ps1_.txt\" target=\"_blank\">here<\/a>.<\/strong><\/em> (updated 2016-01-11)<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Every now and then I need to be able to parse a DNS debug log, it&#8217;s useful in many different scenarios. I wrote an advanced function to help me with this, specify a file name or pipe log lines (or file names) to it and it will return a properly formatted object. Be aware that [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"jetpack_post_was_ever_published":false,"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":false,"jetpack_social_options":{"image_generator_settings":{"template":"highway","enabled":false}}},"categories":[201,21],"tags":[211,1101,221],"jetpack_publicize_connections":[],"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"jetpack_shortlink":"https:\/\/wp.me\/p3Zj0A-4H","_links":{"self":[{"href":"https:\/\/p0wershell.com\/index.php?rest_route=\/wp\/v2\/posts\/291"}],"collection":[{"href":"https:\/\/p0wershell.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/p0wershell.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/p0wershell.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/p0wershell.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=291"}],"version-history":[{"count":1,"href":"https:\/\/p0wershell.com\/index.php?rest_route=\/wp\/v2\/posts\/291\/revisions"}],"predecessor-version":[{"id":7331,"href":"https:\/\/p0wershell.com\/index.php?rest_route=\/wp\/v2\/posts\/291\/revisions\/7331"}],"wp:attachment":[{"href":"https:\/\/p0wershell.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=291"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/p0wershell.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=291"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/p0wershell.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=291"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}