Xirvik
9f6731b4e2
Address review: tighten untrusted safelist and remove set_trusted
2026-03-23 15:11:07 +01:00
Xirvik
d935e0ffe9
Address review feedback: explicit mark_safe whitelist and rpc trust flow
2026-03-23 15:11:07 +01:00
Xirvik
f767053297
Mark safe commands with flag_untrusted_safe for whitelist enforcement
...
Annotate all commands that web UIs (ruTorrent) need for normal torrent
management with _U macro variants, which set flag_untrusted_safe.
Commands not marked are blocked by default for untrusted connections.
Safe commands include:
- d.* download getters, state, priorities, custom fields, start/stop
- f.* file getters, priority control
- p.* peer getters, disconnect, ban/snub
- t.* tracker getters, enable/disable
- throttle.* rate getters/setters, peer limits
- network.* read-only queries (getters safe, setters blocked)
- view.list, view.size, view.filter_all, ui.current_view
- load.*, download_list, d.multicall2, d.multicall.filtered
- convert.*, branch/if/and/or/not/cat/value/print
- system.* version/time/status queries (read-only)
- choke_group.* read-only queries
- method.has_key, method.const, method.list_keys, method.get, strings.*
- group.*.view, group.*.ratio.min/max/upload (dynamic, via flag propagation)
Blocked by default (not marked):
- execute*, method.insert/set/redirect, schedule*, import
- log.*, file.append, network.scgi.open_*, view.filter/sort/event_*
- system.shutdown, system.env, group.insert, choke_group.insert
- All user-defined commands (via method.insert)
2026-03-23 15:11:07 +01:00
Jari Sundell
b233e24465
Deprecated rak::path_expand.
2026-01-08 23:27:53 +09:00
Jari Sundell
a8b6a47054
Removed deprecated rak errno and file headers.
2026-01-04 03:22:02 +09:00
Jari Sundell
48f82c17c2
Remove deprecated no-target flags for commands.
2025-09-20 17:27:26 +09:00
Rosen Penev
0948b5f86a
clang-tidy: convert loops to range based
...
Signed-off-by: Rosen Penev <rosenp@gmail.com >
2025-06-19 09:57:21 +02:00
Jari Sundell
9d5b769d78
Removed/replaced deprecated commands (execute/schedule/schedule_remove) and removed global lock in ExecFile.
2025-05-05 16:55:38 +09:00
Jari Sundell
1f01b7e94d
Fix various macos issues.
2025-01-28 00:18:41 +09:00
rakshasa
d514e525ca
Minor fixes.
2025-01-20 14:49:18 +01:00
pyroscope
b2b723f248
close_low_diskspace.normal: use proper namespace (std)
2025-01-20 14:49:18 +01:00
pyroscope
e3ab913f9a
new method close_low_diskspace.normal
...
Skip downloads with prio=3 (high) when checking for disk space
2025-01-20 14:49:18 +01:00
stickz
e7fc891f11
cleanup: Changes for c++17
...
This cleanup adjusts the rTorrent code to comply with c++17 standard. It also simplifies various parts of the code.
2025-01-18 20:15:20 +01:00
pyroscope
885836f68b
add 'd.multicall.filtered' command
2018-06-15 00:40:00 +02:00
Ryan
eb5443bbad
Add load.raw_start_verbose
...
Fixes #289 .
2015-05-04 19:21:25 -04:00
rakshasa
dc8e786d58
Merge branch 'master' into c++11
...
Conflicts:
src/command_dynamic.cc
src/command_events.cc
src/command_groups.cc
src/command_ip.cc
src/command_network.cc
2014-06-18 00:44:36 +09:00
rakshasa
3b39f37f49
C++11 compatibility fixes.
2014-05-13 23:36:37 +09:00
rakshasa
1e4739c862
Merge branch 'master' into xirvik
2013-08-26 23:17:56 +09:00
rakshasa
529eda5aab
Converted sigc++ slots to std::tr1::function.
2013-08-24 00:14:25 +09:00
rakshasa
9c2745ecb3
Added missing return value to watched command.
2012-04-10 15:38:07 +09:00
rakshasa
9aa54d2344
Added 'directory.watch.added'.
2012-03-29 23:04:17 +09:00
rakshasa
bb75f06c6d
Replaced std::placeholders with tr1::placholders.
2012-03-21 01:24:35 +09:00
rakshasa
04acc8a0af
Converted std::bind calls to tr1::bind.
2012-03-21 01:22:25 +09:00
rakshasa
1b4d8f9626
Removed old thread test code.
2012-02-16 15:08:30 +09:00
Jari Sundell
9a9dcb88f7
Merge branch 'master' into c++11
2011-11-26 01:44:52 +09:00
Jari Sundell
7b150ec834
Made d.multicall safe for deletion of downloads.
2011-11-25 02:21:44 +09:00
Jari Sundell
58727fe7fd
Fixed compiler issues with gcc-4.6 c++0x.
2011-11-18 17:28:50 +09:00
rakshasa
4d313e6353
Updated copyright information.
...
git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1301 e378c898-3ddf-0310-93e7-cc216c733640
2011-10-09 06:30:14 +00:00
rakshasa
4914d798f1
* Changing push_log calls to the new logging facility.
...
git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1284 e378c898-3ddf-0310-93e7-cc216c733640
2011-09-21 05:07:06 +00:00
rakshasa
6f71a8c1b1
* Added 'p.is_unwanted' and 'p.is_preferred' commands.
...
* Removed std::tr1:: in favor of std:: using namespace.
git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1202 e378c898-3ddf-0310-93e7-cc216c733640
2011-04-07 08:41:16 +00:00
rakshasa
7b2fae35d5
* Allow inlining functions in commands with parantheses, e.g:
...
print = (convert.time,(system.time))
schedule2 = test_print_2,2,2,((print,"current ",((convert.time,((system.time))))))
Multiple parantheses need to be used in schedule to ensure the command doesn't get evaluated at the time of calling schedule.
git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1191 e378c898-3ddf-0310-93e7-cc216c733640
2011-02-12 12:20:09 +00:00
rakshasa
49f61eeda3
* Added separate '-I' and '-K' switches, the former is for testing rtorrent code, the latter for webui's.
...
git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1178 e378c898-3ddf-0310-93e7-cc216c733640
2010-10-05 23:49:06 +00:00
rakshasa
56e126d8a0
* Fixed more redirects to work properly with old webui's.
...
git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1175 e378c898-3ddf-0310-93e7-cc216c733640
2010-10-03 10:47:36 +00:00
rakshasa
9bc5470243
* Renamed old 'load*' commands to 'load.*' in order to allow deprecated generic command redirects to be defined.
...
git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1174 e378c898-3ddf-0310-93e7-cc216c733640
2010-09-18 11:32:33 +00:00
rakshasa
b530d35d94
* More work on rpc::object_storage and moving simple functions over to it.
...
git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1165 e378c898-3ddf-0310-93e7-cc216c733640
2010-04-28 15:19:18 +00:00
rakshasa
9362453391
* Added a missing READ_PORT case to a switch in handshake.cc.
...
* Stuff.
git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1164 e378c898-3ddf-0310-93e7-cc216c733640
2010-04-19 19:52:42 +00:00
rakshasa
74bae32243
* Fixed more redirected commands.
...
* Cleaned up the Command stack implementation.
* Added framework for object_storage class that will hold variables and user-defined command lists.
git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1162 e378c898-3ddf-0310-93e7-cc216c733640
2010-04-11 14:19:27 +00:00
rakshasa
d17fa0c684
* Renamed 'check_hash' and added a redirect.
...
* Added proper torrent::Object stack type in rpc::Command.
git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1160 e378c898-3ddf-0310-93e7-cc216c733640
2010-04-07 08:49:12 +00:00
rakshasa
4b9c4d5bbe
* More cleanups of commands.
...
* Don't install the out-of-date man page.
git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1159 e378c898-3ddf-0310-93e7-cc216c733640
2010-04-04 19:15:01 +00:00
rakshasa
4e4540e60f
* Removed old Command classes.
...
* Redirects can now be made efficiently using rpc::CommandMap::create_redirect or "methods.redirect=new_key,dest_key".
git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1155 e378c898-3ddf-0310-93e7-cc216c733640
2010-03-28 18:09:09 +00:00
rakshasa
10f665e9c6
* Last of the commands converted, cleanup remaining.
...
git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1154 e378c898-3ddf-0310-93e7-cc216c733640
2010-03-27 16:35:15 +00:00
rakshasa
bc96dbfa2d
* Modified the fallocate configure check so it will fail if 'fallocate' can't be found.
...
* Changed more commands to the new format.
git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1153 e378c898-3ddf-0310-93e7-cc216c733640
2010-03-24 20:23:48 +00:00
rakshasa
83e993a1eb
* Added missing command_new_slot.{cc,h} files.
...
* Converted more commands.
git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1150 e378c898-3ddf-0310-93e7-cc216c733640
2010-03-21 09:45:45 +00:00
rakshasa
c5e839287d
* Cleaned up torrent/download.h.
...
* Removed raw_value as it is redundant.
git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1145 e378c898-3ddf-0310-93e7-cc216c733640
2010-03-15 18:31:50 +00:00
rakshasa
44e77016a9
* Renamed 'system.method.*' to 'method.*'.
...
git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1139 e378c898-3ddf-0310-93e7-cc216c733640
2010-03-03 13:45:34 +00:00
rakshasa
3cae3d37be
* Cleaning up command names. The deprecated commands will be redirected.
...
git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1131 e378c898-3ddf-0310-93e7-cc216c733640
2010-02-16 17:29:53 +00:00
rakshasa
b635f8c852
* More work on threading.
...
git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1112 e378c898-3ddf-0310-93e7-cc216c733640
2009-12-12 21:30:52 +00:00
rakshasa
63af7078a3
* Include locally available chunks in the "chunks seen" statistics for completed/distributed copies. Patch by Josef Drexler.
...
* Added 'd.get_bitfield' command for retrieving the bitfield in hex format. Patch by Thomas Rosner. (PD)
* Fixed include headers for gcc-4.4.0. Patch by 'kloeri'.
* Switched a 'long long' with 'int64_t' in xmlrpc.cc to avoid incompatible types for some systems.
git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1092 e378c898-3ddf-0310-93e7-cc216c733640
2009-05-14 13:07:47 +00:00
rakshasa
7600a51039
* Fix potential buffer overflows in case snprintf buffer is too
...
small. Patch by Josef Drexler.
* Added 'view.persistance' command that makes downloads inserted into
that view persist across sessions. Only call on user-created views.
* Added 'ratio.*' commands that call the 'group.seeding.ratio.*'
equivalents.
git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1080 e378c898-3ddf-0310-93e7-cc216c733640
2008-11-16 07:54:45 +00:00
rakshasa
de8a11c4fd
* Added 'system.method.get', 'ui.current_view.set' and 'group.insert'
...
commands.
* Enabled different ratio settings for different groups of
downloads.
git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1079 e378c898-3ddf-0310-93e7-cc216c733640
2008-11-10 18:52:36 +00:00