Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 2 Oct 2015 09:32:25 -0700
From:      Adrian Chadd <adrian.chadd@gmail.com>
To:        Rakshith Venkatesh <vrock28@gmail.com>
Cc:        Julian Elischer <julian@freebsd.org>, FreeBSD Filesystems <freebsd-fs@freebsd.org>,  "freebsd-hackers@freebsd.org" <freebsd-hackers@freebsd.org>
Subject:   Re: LibCURL in Kernel
Message-ID:  <CAJ-Vmo=BShHdtqyo-mv7WwVWP4Ek8xpmFDsD30L5kuLdFufTiw@mail.gmail.com>
In-Reply-To: <CANw0z%2BXJc2QXahT3MduptBKVwEV64wjcSnv%2BFZSWechLCu=Kqg@mail.gmail.com>
References:  <CANw0z%2BUQaOHbVWjkvS8ujCb-0oboFvWsno1Hkj%2BgLFW3r%2Bnx5g@mail.gmail.com> <560E06FA.3020702@freebsd.org> <CANw0z%2BXJc2QXahT3MduptBKVwEV64wjcSnv%2BFZSWechLCu=Kqg@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
I tried this a long time ago (don't ask.) The biggest gotchas:

* the socket code wasn't as nice to use from kernel land as it is today; and
* the existing http libraries out there mostly expect you have
infinite stack space, which in kernel land you don't. :(

I eventually had the company allow me to write my own thin HTTP client
layer in kernel space to do it, because trying to leverage an existing
one ended up causing constant panics due to the stack space thing.


-adrian


On 1 October 2015 at 22:25, Rakshith Venkatesh <vrock28@gmail.com> wrote:
> I am actually not looking for full curl functionality. My aim is to back up
> data from native file system to a s3 backend from kernel. I have a very
> thin userspace where its not straight forward to deploy apps.I saw libs3
> and most of the already existing utilities use libcurl library to send Http
> requests.
> On 02-Oct-2015 9:54 am, "Julian Elischer" <julian@freebsd.org> wrote:
>
>> On 10/2/15 12:29 AM, Rakshith Venkatesh wrote:
>>
>>> Hi,
>>>
>>> I wanted to know if there is any library which does the job of libCURL in
>>> FreeBSD kernel. I know libCURL is a user-space library but was looking for
>>> something similar in kernel. Porting is one option but i think it surely
>>> will not be a straight forward thing.
>>>
>>> Any leads on the above query would be great!
>>>
>>
>> there was work to write an http daemon using netgraph..
>> I know that's the opposite side of the same transfer but it does poitn to
>> how it could be done.
>> All the hooks are in place to allow one to write a netgraph node that can
>> attach to netgraph socket nodes.
>> what you would do with the data when you get it is a different thing..
>>
>> tell us a bit more about your requirements.
>>
>>
>>>
>>> Thanks,
>>>
>>> Rakshith
>>> _______________________________________________
>>> freebsd-hackers@freebsd.org mailing list
>>> https://lists.freebsd.org/mailman/listinfo/freebsd-hackers
>>> To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.org
>>> "
>>>
>>>
>>
> _______________________________________________
> freebsd-hackers@freebsd.org mailing list
> https://lists.freebsd.org/mailman/listinfo/freebsd-hackers
> To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.org"



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CAJ-Vmo=BShHdtqyo-mv7WwVWP4Ek8xpmFDsD30L5kuLdFufTiw>