{"id":359,"date":"2008-11-28T18:22:10","date_gmt":"2008-11-28T22:22:10","guid":{"rendered":"http:\/\/blogs.law.harvard.edu\/zeroday\/?p=359"},"modified":"2008-11-28T18:22:10","modified_gmt":"2008-11-28T22:22:10","slug":"hpricot-workaround-for-aspx-viewstate","status":"publish","type":"post","link":"https:\/\/archive.blogs.harvard.edu\/zeroday\/2008\/11\/28\/hpricot-workaround-for-aspx-viewstate\/","title":{"rendered":"Hpricot Workaround for ASPX viewstate"},"content":{"rendered":"<p>I&#8217;ve switched over to Hpricot for HTML parsing in my various ruby projects.  This was a long time coming and the performance is impressive.  I happened to catch a page with ASPX viewstate on it and was faced with the following error:<\/p>\n<blockquote><p>ran out of buffer space on element<\/p><\/blockquote>\n<p>There are various <a href=\"http:\/\/www.peterkrantz.com\/2007\/mechanize-on-aspnet\/\">pages out there which detail the work around<\/a> and the rumor is that the memory cap is to ensure that the script doesn&#8217;t end up consuming everything on the machine.  The work around is as follows:<\/p>\n<p><code>Hpricot.buffer_size = 262144 <\/code><\/p>\n","protected":false},"excerpt":{"rendered":"<p>I&#8217;ve switched over to Hpricot for HTML parsing in my various ruby projects. This was a long time coming and the performance is impressive. I happened to catch a page with ASPX viewstate on it and was faced with the following error: ran out of buffer space on element There are various pages out there [&hellip;]<\/p>\n","protected":false},"author":214,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[272],"tags":[],"class_list":["post-359","post","type-post","status-publish","format-standard","hentry","category-digital-warfare"],"jetpack_featured_media_url":"","_links":{"self":[{"href":"https:\/\/archive.blogs.harvard.edu\/zeroday\/wp-json\/wp\/v2\/posts\/359","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/archive.blogs.harvard.edu\/zeroday\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/archive.blogs.harvard.edu\/zeroday\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/archive.blogs.harvard.edu\/zeroday\/wp-json\/wp\/v2\/users\/214"}],"replies":[{"embeddable":true,"href":"https:\/\/archive.blogs.harvard.edu\/zeroday\/wp-json\/wp\/v2\/comments?post=359"}],"version-history":[{"count":0,"href":"https:\/\/archive.blogs.harvard.edu\/zeroday\/wp-json\/wp\/v2\/posts\/359\/revisions"}],"wp:attachment":[{"href":"https:\/\/archive.blogs.harvard.edu\/zeroday\/wp-json\/wp\/v2\/media?parent=359"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/archive.blogs.harvard.edu\/zeroday\/wp-json\/wp\/v2\/categories?post=359"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/archive.blogs.harvard.edu\/zeroday\/wp-json\/wp\/v2\/tags?post=359"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}