aboutsummaryrefslogtreecommitdiffstats
path: root/protocols/jabber/s5bytestream.c
Commit message (Collapse)AuthorAgeLines
* Use NI_MAXHOST rather than HOST_NAME_MAX for host lengths.Jelmer Vernooij2016-12-31-1/+1
| | | | | | | This constant is always available and meant to be used with getnameinfo(). This fixes the build on Debian GNU/kFreeBSD.
* Fix some clang static analyzer warningsdequis2016-12-26-3/+3
| | | | Nothing interesting.
* jabber: Fix leak in jabber_si_set_proxiesdequis2016-03-20-0/+2
|
* typofix - https://github.com/vlajos/misspell_fixerVeres Lajos2015-08-07-2/+2
|
* jabber/s5bytestream: add G_GNUC_PRINTF to jabber_bs_abortdequis2015-06-28-1/+1
|
* s5bytestream: fix segfault (cleanup before trying next streamhost)dequis2015-02-22-14/+27
| | | | | | | | | | | | | | | | | | | | | | | | This segfault happened when none of the available streamhosts can be connected to - or if at least one of them fails to connect. Before this commit, it can be reproduced reliably by setting the "proxy" setting of the account to nonsense, for example, this is what i used: proxy.example.org,1.2.3.4,7777;proxy.example.com,173.194.42.65,80 jabber_bs_recv_handshake_abort() calls jabber_bs_recv_handshake(), which is supposed to restart the handshake with the next streamhost. And it replaced bt->tf->watch_out, which held an event ID, with a newer event ID. So the replaced event ID doesn't get removed, and it gets called again when its socket is closed by the timeout - and by the time that happens, the memory is free()'d already. Boom. The patch is simple - created jabber_bs_remove_events() to cleanup those events, and use it before any code that expects to restart the cycle. So basically the same as doing b_event_remove(bt->tf->watch_out). I hope there aren't more bugs like this in this code.
* s5bytestream: refactor some copypasted code into functionsdequis2015-02-22-89/+47
| | | | | | | | | - get_ft_by_sid() - generate_pseudoaddr() (also uses g_compute_checksum_for_string() to make the code shorter) - jabber_streamhost_new() Behavior should be the same.
* Reindent everything to K&R style with tabsIndent2015-02-20-586/+596
| | | | | | | Used uncrustify, with the configuration file in ./doc/uncrustify.cfg Commit author set to "Indent <please@skip.me>" so that it's easier to skip while doing git blame.
* Some more g_source_remove warning fixesdequis2014-10-27-0/+6
| | | | | - http_incoming_data calling itself - jabber_bs_free_transfer calling jabber_si_free_transfer
* Killed careless use of strcpy(). Luckily these are only a risk on publicWilmer van der Gaast2011-10-30-3/+4
| | | | | servers.
* Take the local address from the IM/IRC connection when setting up a listeningWilmer van der Gaast2010-07-25-1/+1
| | | | | socket for file transfers.
* Fixed crash on failed Jabber file transfers.Wilmer van der Gaast2010-07-22-1/+0
|
* Merging killerbee stuff, bringing all the bleeding-edge stuff together.Wilmer van der Gaast2010-06-07-7/+7
|\
| * Merging libpurple branch into killerbee. It's fairly usable already, andWilmer van der Gaast2010-06-06-7/+7
| |\ | | | | | | | | | | | | | | | Debian packaging is now properly separated. This also picks up a load of stuff from mainline it seems.
| | * GAIM_INPUT_* were renamed, at last.Wilmer van der Gaast2010-05-25-7/+7
| | |
* | | Merging a Jabber ft bugfix.Wilmer van der Gaast2010-04-11-4/+5
|\| |
| * | Fixing a bug in s5bytestream code to deal with incomplete SOCKS5 messagesWilmer van der Gaast2010-04-11-4/+5
| |/ | | | | | | | | and my rewrite of the bs_peek function.
* / Including DCC stuff again, with a wonderful extra layer of abstraction.Wilmer van der Gaast2010-04-11-7/+7
|/ | | | | | | Some hooks are missing so sending files doesn't work yet. Receiving also still seems to have some issues. On the plus side, at least the MSN/Jabber modules work again.
* Fixed jabber_bs_peek() to deal with incomplete packets as well.Wilmer van der Gaast2010-03-21-10/+21
|
* Some compiler warning fixes and renamed "transfers" command to justWilmer van der Gaast2010-03-18-1/+1
| | | | | "transfer" since all root commands are singular so far.
* More small fixes. (NULL derefs and s/close/disconnect/)Wilmer van der Gaast2010-03-18-2/+3
|
* Small cleanup. The max_packet_size variable doesn't seem to be readWilmer van der Gaast2010-03-17-1/+1
| | | | | anywhere, and reworked string handling in ft_listen() a little bit.
* Added conf entries and lib/ftutil.[ch].ulim2008-08-12-71/+16
| | | | | | | | | | ft_listen = <IP-A>:<Port-A>;<IP-B>:<Port-B> to specify listening addresses for the bitlbee<->client connection and the bitlbee<->IM peer connection, respectively. ft_max_size should be obvious. ft_max_kbps should limit the kilobits per second per transfer (not implemented yet).
* moved some stuff around in preperation for MSN merge.ulim2008-08-04-7/+7
| | | | | | * both ends (proto&dcc) need to finish a transfer now for it to be finished * moved throughput calc. and some messages to dcc (no need to implement in protocols)
* Added an account setting 'proxy'.ulim2008-07-22-24/+77
| | | | | | | | | | Note that this is only used for sending. The default <local>;<auto> means let the receiver try a direct connection first and then the proxy discovered from the server (if any). If you know you're firewalled you can remove the <local>. If you want to provide your own proxy try something like "<local>;JID,HOST,PORT". E.g. "<local>;proxy.somewhere.org,123.123.123.123,7777".
* added a #define for AI_NUMERICSERV in s5bytestream.c (missing in ulibc).ulim2008-06-02-0/+4
|
* Added textual SOCKS5 error messages.ulim2008-06-02-2/+21
|
* SOCKS5 bytestream related changes.ulim2008-05-06-4/+22
| | | | | | * allow the SOCKS5 server to not include the pseudo address in its reply(including it is an rfc-style SHOULD in XEP-0065) * ignore if the SOCKS5 server's reply is too short (as is the one from the jabber.cz proxy [apparently using the proxy65 code])
* ulibc support, fixes "Invalid SOCKS5 Connect message" problemulim2008-05-04-1/+15
|
* more verbose error loggingulim2008-04-14-5/+6
|
* some fixes related to connection timeoutulim2008-02-20-3/+21
|
* sending via proxykenobi2007-12-18-74/+224
|
* Send and receive seems to work now! Also adopted the new buffering strategy,ulim2007-12-04-62/+75
| | | | | only one buffer of 2k per transfer now.
* Intermediate commit. Sending seems to work. TODOs:ulim2007-12-03-0/+906
* move from out_of_data to is_writable, eliminate buffers * implement "transfers reject [id]" * documentation in commands.xml * implement throughput and cummulative throughput boundaries * feature discovery before sending * implement sending over a proxy (proxy discovery, socks5 client handshake for sending, activate message) * integrate toxik-mek-ft