开发者

Downloading from HTTPS

开发者 https://www.devze.com 2023-03-25 11:52 出处:网络
I\'ll keep it simple: I\'d like to download a file via HTTPS; methods I\'ve tried haven\'t worked (Network.HTT开发者_开发百科P.Wget, Network.Curl, Network.Download).

I'll keep it simple:

I'd like to download a file via HTTPS; methods I've tried haven't worked (Network.HTT开发者_开发百科P.Wget, Network.Curl, Network.Download).

Suggestions?

Thanks!


See the http-enumerator, it works with SSL as well as enumerator/iteratee IO (with the enumerator package). Hence you can pipe it into attoparsec via attoparsec-iterator and efficiently parse the data.


This question comes up every once in a while:

The solution I use currently is:

import Network.HTTP.Conduit
import qualified Data.ByteString.Lazy as L

main = simpleHttp "https://www.noisebridge.net/wiki/Noisebridge" >>= L.putStr

There is also an explanation of how to post with http-conduit in the link as well as a few answers with other methods.

0

精彩评论

暂无评论...
验证码 换一张
取 消