1
0
Fork 0
mirror of https://github.com/transmission/transmission synced 2024-12-26 01:27:28 +00:00
Commit graph

12480 commits

Author SHA1 Message Date
Mike Gelfand
627555f47b #4400, #5462: Fix Mac build by adding new crypto-utils files to Xcode project. 2014-12-05 23:41:09 +00:00
Mike Gelfand
42de056a4b #4400, #5462: Move SHA1/HEX helpers to crypto-utils
On a way to factoring out OpenSSL support to a standalone file to ease
addition of other crypto libraries support in the future, move helpers
providing SHA1/HEX conversion to crypto-utils.{c,h}.

Rename functions:
* tr_sha1_to_hex -> tr_binary_to_hex (add length argument),
* tr_hex_to_sha1 -> tr_hex_to_binary (add length argument).

Make tr_sha1_to_hex and tr_hex_to_sha1 wrappers around above functions.
2014-12-04 20:53:56 +00:00
Mike Gelfand
748f8a75d2 #4400, #5462: Move SSHA1 helpers to crypto-utils
On a way to factoring out OpenSSL support to a standalone file to ease
addition of other crypto libraries support in the future, move helpers
providing SSHA1 password generation and checking to crypto-utils.{c,h}.
2014-12-04 20:45:18 +00:00
Mike Gelfand
5c43b5c23c #4400, #5462: Move BASE64 helpers to crypto-utils
On a way to factoring out OpenSSL support to a standalone file to ease
addition of other crypto libraries support in the future, move helpers
providing BASE64 encoding and decoding to crypto-utils.{c,h}. OpenSSL-
related functionality is moved to crypto-utils-openssl.c.

Add new functions to be implemented by crypto backends:
* tr_base64_encode_impl - encode from binary to BASE64,
* tr_base64_decode_impl - decode from BASE64 to binary.

Change `tr_base64_encode` and `tr_base64_decode` functions to expect
non-negative input data length which is considered real and never adjusted.
To process null-terminated strings (which was achieved before by passing 0
or -1 as input data length), add new `tr_base64_encode_str` and
`tr_base64_decode_str` functions which do not accept input data length as
an argument but calculate it on their own.
2014-12-04 19:58:34 +00:00
Mike Gelfand
117ab3e8d2 #4400, #5462: Move DH helpers to crypto-utils
On a way to factoring out OpenSSL support to a standalone file to ease
addition of other crypto libraries support in the future, move helpers
providing DH key exchange to crypto-utils.{c,h}. OpenSSL-related
functionality (DH context management) is moved to crypto-utils-openssl.c.
Since we know in advance that DH secret key management code will be the
same for most of backends, implement common functionality in separate
crypto-utils-fallback.c.

Add new tr_dh_ctx_t and tr_dh_secret_t types and functions to be
implemented by crypto backends:
* tr_dh_new - allocate DH context,
* tr_dh_free - free the context,
* tr_dh_make_key - generate private/public keypair,
* tr_dh_agree - perform DH key exchange and generate secret key,
* tr_dh_secret_derive - calculate secret key hash,
* tr_dh_secret_free - free the secret key,
* tr_dh_align_key - align some DH key in the buffer allocated for it.

Make DH secret key not accessible in plain form outside the crypto
backend. This allows for implementations where the key is managed by
the underlying library and is not even exposed to our backend.
2014-12-04 19:18:08 +00:00
Mike Gelfand
7e23390fa2 #4400, #5462: Do not assert on input to SHA1 or RC4 if input length is 0. 2014-12-04 18:20:46 +00:00
Mike Gelfand
d424ed143e #4400, #5462: Move RC4 helpers to crypto-utils
On a way to factoring out OpenSSL support to a standalone file to ease
addition of other crypto libraries support in the future, move helpers
providing RC4 ciphering to crypto-utils.{c,h}. OpenSSL-related
functionality (RC4 context management) is moved to crypto-utils-openssl.c.

Add new tr_rc4_ctx_t type and functions to be implemented by crypto
backends:
* tr_rc4_new - allocate RC4 context,
* tr_rc4_free - free the context,
* tr_rc4_set_key - set cipher key,
* tr_rc4_process - cipher memory block.
2014-12-04 12:37:08 +00:00
Mike Gelfand
4cfe7e7ddb #4400, #5462: Move SHA1 helpers to crypto-utils
On a way to factoring out OpenSSL support to a standalone file to ease
addition of other crypto libraries support in the future, move helpers
providing SHA1 calculation to crypto-utils.{c,h}. OpenSSL-related
functionality (SHA1 context management) is moved to crypto-utils-openssl.c.

Add new tr_sha1_ctx_t type and functions to be implemented by crypto
backends:
* tr_sha1_init - allocate SHA1 context and and initialize it,
* tr_sha1_update - hash some [more] data,
* tr_sha1_final - finish hash calculation and free the context.

Add new files to CMakeLists.txt (leftover from previous commit) to fix
CMake-based configuration.
2014-12-04 12:13:59 +00:00
Mike Gelfand
f6f7bf8227 #4400, #5462: Move random helpers to crypto-utils
On a way to factoring out OpenSSL support to a standalone file to ease
addition of other crypto libraries support in the future, move helpers
providing random numbers/data generation to crypto-utils.{c,h}. OpenSSL-
related functionality (generation of cryptographically strong random
data) is moved to crypto-utils-openssl.c.

Rename functions to follow currently accepted style:
* tr_cryptoRandBuf -> tr_rand_buffer
* tr_cryptoRandInt -> tr_rand_int
* tr_cryptoWeakRandInt -> tr_rand_int_weak

Fix rare case of invalid value being returned from tr_rand_int. Return
value for abs(INT_MIN) may be undefined and thus negative, and so
tr_rand_int will return negative value which is incorrect (out of
requested and expected range).
2014-12-04 11:27:38 +00:00
Mike Gelfand
ecfa96bf38 Do not use target_include_directories which requires CMake 2.8.11 2014-12-02 20:42:33 +00:00
Mike Gelfand
b4a662ba37 Create QDBusConnection after QApplication has been initialized
Doing otherwise causes Qt warning "QDBusConnection: session D-Bus
connection created before QCoreApplication. Application may misbehave."
Also, don't try to do anything D-Bus-related if connection fails.
2014-12-01 21:05:44 +00:00
Mike Gelfand
3e43a308af Sync Qt translation files with current source code 2014-12-01 20:29:03 +00:00
Mike Gelfand
83c4edb008 #5828: Initial CMake build system support 2014-12-01 19:55:22 +00:00
Mike Gelfand
17769e2e2a #5077: Remove torrent file from watch directory even if "show options dialog" is not set (patch from rb07 + some improvements)
Refactor Session::addTorrent (add new method) to eliminate duplicate
code in options.cc and ensure that FileAdded object is being created
on torrent addition even with non-interactive workflow.
Move FileAdded class from options.{h,cc} to session.{h,cc}.
2014-12-01 19:24:07 +00:00
Mike Gelfand
13cad2fb55 #5722: Rename remaining WIN32 uses to _WIN32 2014-11-30 20:08:20 +00:00
Mike Gelfand
e30728367f #5771: Use true and false instead of 1 and 0 for bool variables (patch by ticamkq + additional fixes) 2014-11-30 19:38:47 +00:00
Mike Gelfand
10e59dbc90 #5800: Add Ukrainian translation to Qt client (patch by olexn) 2014-11-30 18:43:50 +00:00
Mike Gelfand
d6c32595a6 #5827: Improve torrent files tree updating performance
Do not unnecessarily emit dataChanged signals for items which didn't change.
Cache file item indices to speedup lookup.
As a bonus, this also fixes wrong file progress display in rare cases.
2014-11-30 18:12:28 +00:00
Jordan Lee
ed12ddb090 fix infinite loop in deleteLocalData(). 2014-11-10 01:39:14 +00:00
Mitchell Livingston
0d49daf36d Yosemite: slight sseparation between pause/resume buttons in the toolbar 2014-10-18 16:41:31 +00:00
Mitchell Livingston
2187da2351 drop all units on stats times 2014-10-18 15:09:44 +00:00
Mitchell Livingston
a7444a21b5 Yosemite: use NSDateComponentsFormatter instead of custom time string code 2014-10-17 05:12:00 +00:00
Mitchell Livingston
953780f38e Improve the looks a bit on Yosemite. The app must now be compiled with the 10.10 SDK. 2014-10-16 13:01:17 +00:00
Eric Petit
82cc420214 Fix make dist 2014-09-24 05:58:34 +00:00
Jordan Lee
c54f220fe8 add libtransmission/file.c 2014-09-21 18:08:56 +00:00
Jordan Lee
870041d92d (trunk) #4160: mike.dld patch: 4160-08-args.patch 2014-09-21 18:06:28 +00:00
Jordan Lee
be290162c2 (trunk) #4160: mike.dld patch: 4160-07-env.patch 2014-09-21 18:05:14 +00:00
Jordan Lee
3e4ceecf03 #4160: mike.dld patch: 4160-06-misc.patch 2014-09-21 18:03:13 +00:00
Jordan Lee
01196c8c4f mikedld patch: 4160-05b-file-fmt.patch 2014-09-21 18:01:36 +00:00
Jordan Lee
a59d3392b6 (trunk, libT) #4160: apply mike.dld's patch: 4160-05a-file-fmt.patch 2014-09-21 17:58:22 +00:00
Jordan Lee
90bbbaefc3 (trunk, libT) #4160: apply mike.dld's patch: 4160-05a-file-fmt.patch 2014-09-21 17:57:45 +00:00
Jordan Lee
d9d66e3e42 (trunk, libt) #4160 - the slow slog to catch trunk up to mike.dld's 4160 diff continues. This step applies 4160-04b-dir.patch, which replaces native file operations with the tr_sys_dir_*() portability wrappers added in the previous commit. 2014-09-21 17:55:39 +00:00
Jordan Lee
51a90d0da0 (trunk, libt) #4160 - the slow slog to catch trunk up to mike.dld's 4160 diff continues. This step applies 4160-04a-dir.patch, which adds tr_sys_dir_*() portability wrappers. 2014-09-21 17:52:36 +00:00
Jordan Lee
728957c46a (trunk, qt) #5774 'Alternative Speed Limits Scheduled Times broken in transmission-qt' -- fixed, plus more gratuitous c++11isms 2014-08-26 23:26:00 +00:00
Jordan Lee
b325bc0a16 (trunk) #5759 compilation error, undefined reference to sqrt 2014-08-20 17:14:17 +00:00
Jordan Lee
b33a7d4dc1 (trunk, libt) #4160 - the slow slog to catch trunk up to mike.dld's 4160 diff continues. This step applies 4160-03b-file.patch, which replaces native file operations with the tr_sys_file_*() portability wrappers added in r14321. 2014-07-28 04:13:38 +00:00
Jordan Lee
2c0276fc23 (trunk, daemon) #5743 'unknown option: -R': revert previous commit, sync manpage 2014-07-19 23:35:10 +00:00
Jordan Lee
b02e4222c3 (trunk, daemon) #5743 'unknown option: -R', fix suggested by silverhammermba 2014-07-19 23:32:20 +00:00
Jordan Lee
faba3219c1 (trunk, #5751) reduce ZLIB_MINIMUM from 1.2.5 to 1.2.3 for CentOS<7 support 2014-07-17 15:56:38 +00:00
Jordan Lee
ab24ef9fcb use pkg-config to get the zlib cflags/libs; remove obsolete zlib.m4 macro 2014-07-13 21:54:56 +00:00
Jordan Lee
2e3ffdc6ec since libz's been required in rpcimpl.c for ages and nobody's complained, remove the HAVE_ZLIB cruft for conditional-compiling with and without zlib. 2014-07-13 21:50:56 +00:00
Jordan Lee
c1beabfea6 (trunk, libT) #4160 'foreign character support' -- merge mike.dld's 4160-03a-file.platch, which introduces tr_sys_file_*() portability wrappers 2014-07-08 00:15:12 +00:00
Jordan Lee
0323639e57 (trunk, libT) #4160 'foreign character support' -- merge mike.dld's 4160-02b-path.patch, which updates the codebase to use the new tr_sys_path_*() portability wrappers introduced in 4160-02a 2014-07-08 00:08:43 +00:00
Jordan Lee
d7f4478679 (trunk, libT) #5735 'segfault iside node_alloc' -- fixed with patch by benjarobin 2014-07-06 20:06:45 +00:00
Mitchell Livingston
74e16f78bd bump to 2.84+ 2014-07-04 12:58:21 +00:00
Jordan Lee
a2898f2ee9 (trunk, libT) #5656 'Problems renaming files' -- fixed, patch by rb07 2014-07-04 03:23:27 +00:00
Mitchell Livingston
0e01879974 Use built-in _WIN32 macro instead of WIN32 2014-07-04 00:00:07 +00:00
Jordan Lee
d0695b7006 (trunk, qt) #5723: 'Simplify file tree icons drawing' -- patch by mike.dld 2014-07-03 23:12:50 +00:00
Jordan Lee
60a5c793d9 (trunk, libT) mike.dld's 4160-02a-path.patch: portability wrapper around file paths. 2014-07-03 21:58:39 +00:00
Mitchell Livingston
db39d4096e group upload and download size is too big on 10.9 2014-07-03 19:47:02 +00:00