Commit Graph

1123 Commits

Author SHA1 Message Date
csoler
01c0d2f0f1 finished conversion to RsNodeGroupId for file transfer and GUI 2016-07-05 23:49:43 -04:00
csoler
4ee9effc4e changed internal storage of groups of friend nodes so as to use an abstract ID instead of a string (phase 1 of local circles) 2016-07-04 23:55:48 -04:00
Cyril Soler
c15c979851 Merge pull request #426 from sehraf/pr-disable-dht-stunner
This patch set adds an option to use the DHT stunner to qmake
2016-06-27 17:17:28 +01:00
csoler
ff8667834b clear error queue before calling SSL_read()/SSL_write(), to avoid remaining errors to corrupt the next connection attempts and cause disconnections 2016-06-26 23:14:01 -04:00
csoler
31089d7a91 added auto-clean of pending data in pqistreamer after connection is closed, to avoid confusing the peer after re-connecting (probably not the cause of the SSL errors we see) 2016-06-25 19:12:47 +01:00
sehraf
5d962682e1 removed unused variable warnings 2016-06-21 14:02:52 +02:00
sehraf
4d2d825d5b add new option to qmake to enable dht stunner
removed dht stunner code when option is not set
2016-06-21 13:55:23 +02:00
Cyril Soler
90a27f4e81 Merge pull request #418 from sehraf/pr-improve-debug
This is the first set of patches to improve RS' logging functionality
2016-06-18 15:33:10 -04:00
sehraf
09afbbed5d switched to new rslog method 2016-06-18 13:00:15 +02:00
csoler
dbd78d2401 merged with upstream/master 2016-06-16 20:19:03 -04:00
csoler
6b74a8a1b6 added missing call to ssl_pendign in pqissludp. 2016-06-14 21:54:24 -04:00
csoler
8c44e69012 added output of items which doesnot serialise correctly in pqisslstore 2016-06-14 21:54:24 -04:00
csoler
972de42864 converted static variable to class member in pqihandler 2016-06-11 18:07:57 -04:00
Cyril Soler
248d0c42d3 Merge pull request #412 from csoler/v0.6-MaxUpRate
V0.6 max up rate
2016-06-11 17:58:08 -04:00
csoler
ef4455ac9c cleaned the MaxUpRate branch from unused code 2016-06-11 17:54:11 -04:00
csoler
8e75185060 made avgReadCount and avgSendCound to be uint32_t instead of floats, since they count bytes. Changes kb to 1024 instead of 1000 2016-06-11 17:21:04 -04:00
csoler
373d41bc63 added missing variable def after previous commit 2016-06-11 14:11:21 -04:00
csoler
23e8e932be added mutex proteciton around mAvgLastUpdate to avoid it being changed by the constructor 2016-06-11 09:50:22 -04:00
csoler
0d1d31a25f added mutex protection around pqistreamer::getRates, since float r/w are not necessarily atomic 2016-06-11 09:33:16 -04:00
csoler
83a143476e fixed bug in setting MaxRate values 2016-06-09 23:23:51 -04:00
csoler
f5ad8b49be moved node-wide options to node details 2016-06-09 23:13:07 -04:00
csoler
a4931edee0 fixed setting/getting maxrates using pgp id 2016-06-09 20:51:09 -04:00
csoler
a07805be1d moved bandwidth limits to the pgp level 2016-06-09 20:41:27 -04:00
csoler
38b86c37ab improved debug output for early address rejection 2016-06-09 18:12:04 -04:00
csoler
6b78275677 fixed bug in loading config file to set max rates 2016-06-08 22:54:40 -04:00
csoler
5a0fa66ac0 added proper talking between pqihandler and GUI for maxrates fixing 2016-06-08 22:44:28 -04:00
csoler
509266a25b removed some dead code 2016-06-07 22:38:24 -04:00
csoler
20b6745f70 added GUI and storage for max up/dn rates per peer 2016-06-07 21:48:22 -04:00
csoler
927f782bef pass over compiler warnings 2016-06-05 10:43:57 -04:00
csoler
53eb4dfb12 fixed compilation errors due to last merge operation 2016-06-02 21:21:18 -04:00
csoler
e2b5785eec merged PR403 with trunk 2016-06-02 21:15:51 -04:00
csoler
10e0254317 fixed a few things to correct PR403 2016-06-02 20:38:33 -04:00
Cyril Soler
2f4f44ee48 added early discarding of incoming connection attempt (before SSL handshake) for blacklisted IPs 2016-06-02 09:37:01 -04:00
sehraf
4f60c8cc9b libretroshare: fix comparison between signed and unsigned integer 2016-06-02 14:54:23 +02:00
sehraf
8b788b2aa8 libretroshare: fix member initialisation order 2016-06-02 14:54:16 +02:00
sehraf
cfc0e7071a libretroshare: remove unused variables 2016-06-02 14:54:07 +02:00
sehraf
bc23c2f7b9 add thread names for peers 2016-06-01 16:33:13 +02:00
sehraf
f16ee97093 add static thread names 2016-06-01 16:21:55 +02:00
Phenom
af5129c26d Fix Mutex in pqipersongrp for pqilistener by adding local Mutex. 2016-05-18 19:15:37 +02:00
Cyril Soler
f3aed813af added test over signature size to avoid possible memory corruption (Anonymous source) 2016-05-17 10:39:56 -04:00
Phenom
a1ece16f35 Fix uninitialized variables netsize, rsnetsize in p3netmgr.cc 2016-05-12 20:00:44 +02:00
Cyril Soler
e891e2be2e added missing check for ssl_connection that would cause crash when the ssl connection gets closed by another thread 2016-05-11 10:00:20 -04:00
csoler
b5ace406b9 attempt to fix socket problem on 32bits/64bits windows, by using the proper SOCKET type instead of int 2016-05-05 21:40:29 -04:00
csoler
ca003c5f9e added missing initialisation of deleted memory before calling realloc 2016-05-03 20:55:50 -04:00
csoler
aec8b4d27c fixed bug in counting of incoming data size for sliced packets 2016-05-02 18:10:39 -04:00
csoler
01605e5a59 updated description f packet slicing in comments section of pqistreamer 2016-04-30 11:19:21 -04:00
csoler
1f7a94d49e fixed bug causing crash in pqistreamer 2016-04-30 11:13:51 -04:00
csoler
4bdd464861 removed a few debug output and timer measurement 2016-04-29 18:53:25 -04:00
csoler
3bc3989e79 removed debug info for pqistreamer 2016-04-29 18:41:10 -04:00
csoler
654e0fc1d8 added missing call to SSL_pending, which caused decrypted data to wait in the SSL buffer when the bio is not receiving anything more 2016-04-29 17:53:21 -04:00
csoler
87764abe4c removed debug info in pqistreamer 2016-04-26 21:23:19 -04:00
csoler
153db5ca64 added on/off mechanism for packet slicing to ensure packward compatibility 2016-04-26 09:22:24 -04:00
csoler
3b685851d2 improved/simplified slicing protocol 2016-04-25 23:37:02 -04:00
csoler
dd81ce3bf3 using BinToHex to display mem blocks in pqistreamer debug 2016-04-25 22:50:41 -04:00
csoler
18e9e1c2db moerged with upstream/master 2016-04-24 21:29:55 -04:00
csoler
f62957534e fixed a few bugs in packet slicing in pqiQoS 2016-04-24 21:18:44 -04:00
csoler
a2c11f97c2 added packet reconstruction and deserialising 2016-04-24 13:43:34 -04:00
csoler
cad8c89746 added packet slicing in pqistreamer 2016-04-23 17:10:25 -04:00
csoler
10230dff6e added missing SSL shutdown when replacing existing connection 2016-04-22 16:50:43 -04:00
csoler
e82c217cd2 half-implemented packet slicing (QoS part done) 2016-04-20 22:42:09 -04:00
csoler
057249225e severely reduced packet grouping, which limited the effectiveness of QoS 2016-04-20 21:20:47 -04:00
csoler
fc725b03a8 added some debug info to pqistreamer 2016-04-19 22:04:30 -04:00
csoler
26af7c900e changed heart beat limit to a larger value. Apparently too tight a value causes disconnections due to packets being stuck sometimes (old bug) 2016-04-17 22:58:48 -04:00
Cyril Soler
a52bd98d4b fixed potential div by 0 in speed estimations. To be tested. 2016-04-11 10:10:10 -04:00
csoler
a5044bd71c improved calculation of speed in pqistreamer (was called before only when sending bytes), and prevented situation where no HB is received by the connection is not reset because last HB is 0, causing ghost connected peers in GUI 2016-04-09 14:48:05 -04:00
csoler
3554e48c7e output packet error with some details (inspired by Phenom-PR289) 2016-04-03 11:38:53 -04:00
csoler
9d9b790a3e exposed un-verified PGP signatures on GXS ids in GUI. Added auto-ban of GXS ids signed by a PGP ids that has already signed a large enough set of GXS ids. Still needs some GUI to change the threshold. 2016-04-02 16:14:18 -04:00
Phenom
c6f1cc4e63 Clear WebAPI when clear chat history in GUI.
Move notifyChatCleared call to p3ChatService
To maintain notify direction.
2016-03-31 22:52:53 +02:00
zeners
aca88308ea compatible to g++11 / QT5
method suggested by cyril
2016-03-29 21:22:14 +02:00
csoler
bb260696ce attempt at fixing negative bw rates in GUI that may pop up when an error is present in the SSL stream (e.g. when a peer disconnects/reconnects) 2016-03-02 19:00:51 -05:00
sehraf
dbdfdcd008 removed unused map lookups 2016-02-22 21:09:10 +01:00
sehraf
77166cbf13 impoved cleanup of unused locations 2016-02-22 16:41:31 +01:00
sehraf
4140969fcb added seperated limit for discovery (30 days) 2016-02-19 16:35:11 +01:00
sehraf
841299d077 discovery: don't remove new added locations too soon
was: removed after 10 min. or less - when no connection is established
now: removed after 1 day - when no connection is established
2016-02-16 20:33:38 +01:00
Cyril Soler
3ab7c89660 Merge pull request #279 from cavebeat/single_dh_op
added openSSL option SSL_OP_SINGLE_DH_USE regarding CVE-2016-0701
2016-02-14 13:33:27 -05:00
cave beat
9843c8381b added openSSL option SSL_OP_SINGLE_DH_USE regarding CVE-2016-0701
tl;dr The OpenSSL 1.0.2 releases suffer from a Key Recovery Attack on DH small subgroups. This issue got assigned CVE-2016-0701 with a severity of High and OpenSSL 1.0.2 users should upgrade to 1.0.2f. If an application is using DH configured with parameters based on primes that are not "safe" or not Lim-Lee (as the one in RFC 5114) and either Static DH ciphersuites are used or DHE ciphersuites with the default OpenSSL configuration (in particular SSL_OP_SINGLE_DH_USE is not set) then is vulnerable to this attack.
2016-02-14 18:49:37 +01:00
electron128
821c14426c remove dead code from RsNotify (old forum and channel read status changed notify) 2016-02-14 12:48:52 +01:00
electron128
63a8260cb9 change RsNotify to use RsGxsId for chat lobby events 2016-02-14 11:53:27 +01:00
csoler
3bc444b087 removed some debug info 2016-01-26 23:00:10 -05:00
csoler
39b3df964a fixed bug causing net reset when closing config 2016-01-25 22:39:20 -05:00
csoler
9b64b96811 fixed potential crash in pqisslstore 2016-01-23 13:04:02 -05:00
thunder2
748147f73b Fixed Windows compile. 2016-01-15 21:41:23 +01:00
Cyril Soler
96f3446aa7 added size limit to packet grouping 2016-01-13 11:13:23 -05:00
Cyril Soler
b56881e6d9 fixed windows compilation 2016-01-13 10:23:21 -05:00
csoler
d55993d1e4 removed two instances of malloc(0) captured by new rs_malloc funtion 2016-01-12 21:43:04 -05:00
csoler
d13526facd added a new method rs_malloc that checks its arguments and prints a stacktrace on error/weird call. Changed the code everywhere to use this instead of malloc. Removed some mallocs and replaced with RsTemporaryMemory 2016-01-12 21:10:11 -05:00
Cyril Soler
9fd0fc54cc fixed bandwidth measurement in pqistreamer 2016-01-05 11:44:05 -05:00
Gio
ed7f958f95 Add stacktrave.h, sanitize p3LinkMgrIMPL::retryConnectTCP avoid to look for port on null sockaddr_storage 2015-12-31 15:42:22 +01:00
csoler
8a41554754 fixed some leaking memory issues in loadList() methods, and also increased consistency by not returning non empty list with deleted items inside 2015-12-30 18:20:09 -05:00
csoler
48750cdb51 merged 2015-12-30 17:18:22 -05:00
Cyril Soler
ae16fc887d Merge pull request #229 from G10h4ck/master
Fix memory leak in getLocalAddresses
2015-12-30 17:13:27 -05:00
Gio
9c24203082 Fix memory leak in getLocalAddresses 2015-12-30 22:47:51 +01:00
csoler
cefa5d9f9e fixed missing SSL_free when a new connection replaces the existing one 2015-12-30 13:55:15 -05:00
csoler
aabfcb975c fixed missign initialisation of err in pqissludp.cc 2015-12-30 13:51:56 -05:00
csoler
682930938b merged PR 219 from Jolavilette+Phenom, with some minor modifications 2015-12-29 23:40:09 -05:00
csoler
2fe646c5cb merged PR 219 from Jolavilette+Phenom, with some minor modifications 2015-12-29 23:39:52 -05:00
Gio
3cfa22e35b Guard checkNetAddress debug, unary + comment clarification 2015-12-29 23:51:16 +01:00
Phenom
4521e8ee95 Fix pqihandler::UpdateRates() to get more accurate. 2015-12-28 13:48:26 +01:00
Gio
436f619fcb getLocalAddresses collects loopback address too 2015-12-21 17:34:53 +01:00
Gio
9d78bba3b8 Guard getLocalAddresses debug 2015-12-21 15:48:59 +01:00
Gio
ca1a9707ef Removed dead code 2015-12-21 15:31:47 +01:00
Gio
1b2fa3600a Adapted getLocalAddresses() includes for windows 2015-12-21 15:31:46 +01:00
Gio
5a541e7feb Removed unused getLocalInterfaces_ipv4 2015-12-21 09:10:00 +01:00
Gioacchino Mazzurco
747a03a0b9 Substitute getpreferredinterface flawed logic with simpler getLocalAddresses still just one address used at moment 2015-12-21 09:10:00 +01:00
csoler
ea137adc42 fixed compilation on OSX pb in pqistreamer 2015-12-20 19:07:04 -05:00
Cyril Soler
d50875b9bb Merge pull request #212 from csoler/v0.6-TrafficOptim
V0.6 traffic optim
2015-12-19 21:38:55 -05:00
csoler
141b799c9d removed debug info 2015-12-19 21:20:25 -05:00
Cyril Soler
124da6f3b7 Merge pull request #210 from G10h4ck/pqicleaning
[RFC] Made pqiperson more readable evidence some strange code
2015-12-19 21:12:57 -05:00
Gio
b2c27a1fed Made pqiperson more readable evidence some strange code 2015-12-19 22:10:07 +01:00
csoler
82d43eb8a0 fixed a few bugs in packet packing in pqistreamer. 2015-12-12 23:07:33 -05:00
csoler
f6a84aa4ad added packet packing in pqistreamer. To be tested for improvement in bw 2015-12-12 11:52:48 -05:00
csoler
9193d3579b merged with latest master before creating PR 2015-12-04 21:24:51 -05:00
csoler
81ab43beb9 fixed GUI update of avatars and status for distant chat. Updated backend for new model. Fixed a few bugs in serialisation 2015-11-30 00:02:44 -05:00
csoler
a2e0f4196b updated GUI for new distant chat 2015-11-26 20:40:06 -05:00
Cyril Soler
874f304cd2 Merge pull request #167 from G10h4ck/pqicleaning
Removed some cruft like mymethod(){return;} from pqi
2015-11-26 14:48:30 -05:00
electron128
413cee375c set buffer size for reading config signatures to the size of the computed signature. This fixes the load of the configuration for locations created after 8e6c7cd. 2015-11-06 19:50:59 +01:00
AsamK
0e2417dfd7 Hide debug messages from p3historymgr 2015-11-05 15:15:41 +01:00
Gio
8936dafe4d Remove unnecessary overloading from pqissllistener 2015-10-30 20:12:46 +01:00
Gio
bb7cfc6387 Remove more cruft 2015-10-30 09:42:33 +01:00
Gio
30e40470e2 Removed some cruft like mymethod(){return;} from pqi 2015-10-30 09:23:59 +01:00
Gioacchino Mazzurco
71073c19b6 Respect passed parameters in unix_socket 2015-10-23 10:53:31 +02:00
csoler
1d1904cae1 added missing memory clean calls in X509 certificate generation 2015-10-20 21:03:08 -04:00
Cyril Soler
24a685f5a2 Merge pull request #148 from G10h4ck/unsanelan
Removed flawed logic samenet/samesubnet
2015-10-20 18:03:06 -04:00
Sergei Reznikov
34758be52a Add Haiku support 2015-10-20 20:32:44 +03:00
Gio
16a5eed453 Removed flawed logic samenet/samesubnet you cannot determine if two ip are in the same subnet just from ips the internet is not just a bunch of /24 2015-10-17 10:27:49 +02:00
csoler
f1f722a767 added missing shutdown of non responsive socket that could leak FDs (suggested by GuessWho 2015-10-07 19:08:35 -04:00
csoler
39672b2df6 fixed typo causing non free of mutex_buf structure in pqissl.cc 2015-10-07 18:59:58 -04:00
Gio
e83ae76320 pqiconnect remove ni NULL pointer check as it would crash anyway for null pointer dereferencing before checking 2015-09-27 21:51:06 +02:00
Gio
28b9a443a2 Write in a sane way pqissl::connect_parameter 2015-09-27 21:51:06 +02:00
Gio
b16ecc89c8 Remove some garbage from pqissl 2015-09-27 15:38:31 +02:00
csoler
22d4893721 removed a few compilation warning that might cause compilation errors on some systems 2015-09-24 18:03:19 -04:00
Cyril Soler
0614a24bbb Merge pull request #111 from csoler/v0.6-ImprovedExtIPDetermination
Improved reliability of the determination of external address
2015-09-23 22:11:50 -04:00
csoler
24b3325792 Improved reliability of the determination of external address: removed DHT stunner from the pool, added mPeerMgr which vote is based on ext address most often reported by peer discovery 2015-09-23 21:45:15 -04:00
csoler
7293cd3afa updated ubuntu changelog 2015-09-21 22:58:58 -04:00
sehraf
6202e83c32 add default case to gui instead of falling back to tor labeling 2015-09-16 11:48:32 +02:00
sehraf
1dd3375c59 hide debug output 2015-09-15 17:14:55 +02:00
sehraf
d24b281948 optimizations
* reduced calls to mPeermgr
* use switch convenience
* small fixes
2015-09-15 17:10:48 +02:00
sehraf
bfcf43f0e1 fixed connection type detection and other small things 2015-09-15 16:18:46 +02:00
sehraf
6b87c38951 small fixes 2015-09-14 14:56:14 +02:00
sehraf
4b19e73975 added comments to functions 2015-09-14 09:56:43 +02:00
sehraf
0bc77d75ae added some error handling 2015-09-08 13:48:30 +02:00
sehraf
4fc6c73dd9 replaced some ifs with switch 2015-09-07 23:40:52 +02:00
sehraf
fed43450ae made server settings more generic and added i2p support 2015-09-07 23:01:24 +02:00
sehraf
95d6b06eb5 first working version 2015-09-07 21:34:10 +02:00
sehraf
ba74c04581 removed duplicated code, fixed compile, few additions 2015-09-07 21:34:10 +02:00
sehraf
c17d0e1498 add i2p support to libretroshare 2015-09-07 21:34:10 +02:00
AsamK
5dad1680e6 Implement history for distant chat
Uses the same history config as private chat
2015-08-28 01:29:34 +02:00
defnax
6e1a8fac10 Merge pull request #21 from AsamK/lobby_history
Store lobby history on disk
2015-08-27 18:43:28 +02:00
csoler
58d29c3ee2 fixed error message in pqissl::cansend() 2015-08-22 10:32:04 -04:00
csoler
2e08dde32b additional check for pqissl::sockfd before using it (patch from Jenster) 2015-08-15 10:09:16 -04:00