You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi there,
Some URL have a response with header "Content-Type: application/octet-stream". Should I process it as an attachment?
After some digs, The Attachment only handle specific response which define in rfc-2183.
the : attachmentHandler_.isAttachment(webResponse)
will return False when we have "application/octet-stream".
I found org.htmlunit.HttpWebConnection.downloadContent() will be called: public static DownloadedContent downloadContent(final InputStream is, final int maxInMemory)
It will download the response content.
If I DON'T want HtmlUnit to download big content( e.g. https://dg.10000gd.tech:12348/shmfile/100 ), what should I do?
I want to block download action if a resource lager than 20MB to save on bandwidth.