git/list[1] front-page[2] threads[3] people[4] search[5] about
 

[RFC 0/3] imap-send curl tunnelling support

From
Nicolas Morey-Chaisemartin <nicolas@morey-chaisemartin.com>
Date
Aug 24, 2017, 08:00 UTC
Message-ID
<e11d4449-8377-dbd7-3ad5-441baf7446b6@morey-chaisemartin.com>
In-Reply-To
<20170823214349.k4ayl2urqepch7p4@sigill.intra.peff.net>
Le 23/08/2017 à 23:43, Jeff King a écrit :
Show 16 quoted lines
> On Mon, Aug 21, 2017 at 09:34:19AM +0200, Nicolas Morey-Chaisemartin wrote:
>
>>>> It appears curl do not support the PREAUTH tag.
>>> Too bad. IMHO preauth is the main reason to use a tunnel in the first
>>> place.
>> It shouldn't be too hard to add support for this in curl.
>> If it's the main usecase, it'll simply means the curl tunnelling
>> should be disabled by default for older curl (in this case, meaning
>> every version until it gets supported) versions.
> Yes, I agree. I was hoping when we started this discussion that we were
> more ready to switch to curl-by-default. But sadly, that isn't close to
> being the case. But hopefully we can at least end up with logic that
> lets us use it in the easy cases (no tunneling) and falls back in the
> harder ones.
>
> -Peff

I opened a bug upstream and they already fixed this. https://github.com/curl/curl/pull/1820

At least bleeding edge curl user should be able to use this. I'm not sure where to go with these patches now.

1) There does not seem to be an easy/clean workaround for the lack of socketpair on windows.
Fidling with a loopback AF_UNIX?AF_LOCAL socket should work but it means creating a socket file somewhere which pulls a lot of potential issues (where to put it ? Post-mortem cleanup ? Parallel imap-send ?)
2) The PREAUTH support won't largely be available  for a while (curl, release, distro, etc.)
- If this is the main use case, it does not make much sense to puch curl; tunneling support without this. I could push the code and only enable the curl tunneling for the next curl release ?
  Meaning no one (or close to no one) would use this until some later
  This also means very little testing (apart from mine) until the next curl version gets widely available
- If this is not the main case (or at least the non PREAUTH is important enough), it would make sense to get this changes in.
  But it would probably need some more to code to either fallback to legacy mode when curl failed (due to PREAUTH) or detect PREAUTH and directly use the legacy mode.
Nicolas
Previous: Jeff KingNext: Jeff King
Message 15 of 22 in “[RFC 0/3] imap-send curl tunnelling support”
  1. Nicolas Morey-ChaisemartinAug 9, 2017
  2. 1/3 imap-send: move tunnel setup to its own functionNicolas Morey-Chaisemartin, Aug 9, 2017
  3. 3/3 imap_send: add support for curl over tunnelNicolas Morey-Chaisemartin, Aug 9, 2017
  4. 2/3 imap-send: use a socketpair instead of pipe to communicate with the tunnelNicolas Morey-Chaisemartin, Aug 9, 2017
  5. Nicolas Morey-ChaisemartinAug 15, 2017
  6. Stefan BellerAug 15, 2017
  7. Johannes SchindelinAug 16, 2017
  8. Nicolas Morey-ChaisemartinAug 21, 2017
  9. Johannes SixtAug 22, 2017
  10. Nicolas Morey-ChaisemartinAug 22, 2017
  11. Johannes SchindelinAug 23, 2017
  12. Jeff KingAug 16, 2017
  13. Nicolas Morey-ChaisemartinAug 21, 2017
  14. Jeff KingAug 23, 2017
  15. Nicolas Morey-ChaisemartinAug 24, 2017
  16. Jeff KingAug 24, 2017
  17. Daniel StenbergAug 24, 2017
  18. Jeff KingAug 24, 2017
  19. Daniel StenbergAug 24, 2017
  20. Nicolas Morey-ChaisemartinAug 24, 2017
  21. Jeff KingAug 24, 2017
  22. Jeff KingAug 16, 2017

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.