Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

'Execute script' isn't working on windows #405

Closed
hulekgre opened this issue Sep 17, 2017 · 33 comments
Closed

'Execute script' isn't working on windows #405

hulekgre opened this issue Sep 17, 2017 · 33 comments

Comments

@hulekgre
Copy link

I just want to execute a .bat with a command line, just like it works in basically any other bitorrent client available.

@dakotalightning
Copy link

dakotalightning commented Dec 8, 2017

bump

I'm having the same issue. Does anyone have any ideas on how to get this to work?

Base on a quick search and my assumption, it looks like it isn't implemented.
https://github.com/transmission/transmission/search?utf8=%E2%9C%93&q=SCRIPT_TORRENT_DONE_FILENAME&type=

@mikedld
Copy link
Member

mikedld commented Dec 8, 2017

Sorry I didn't notice this before. The issue has been fixed in recent nightly builds (30c7c05). If you can, please try it out (x64, x86) and report back.

@dakotalightning
Copy link

Is there a log I can check to see if the script has failed?

@mikedld
Copy link
Member

mikedld commented Dec 13, 2017

You could start the daemon with -e/--logfile option to get the log file.

@opicron
Copy link

opicron commented Dec 21, 2017

Tried the latest build. Script is not executed after download here.

@mikedld
Copy link
Member

mikedld commented Jan 26, 2018

Any more details guys?
@dakotalightning is it working for you?
@opicron what does your script look like? how do you know that it's not executed?

@slokhorst
Copy link
Contributor

slokhorst commented Jan 27, 2018

Just tested the Qt client from transmission-2.93+-r94be7dbd9b-x64.msi and it worked just fine.

Edit: also tried daemon, worked fine as well. (I had some trouble running the daemon with --logfile, so I used transmission-daemon.exe -f instead. output: Calling script "test.bat")

@fabionar
Copy link

fabionar commented Mar 4, 2018

@mikedld Not working on Transmission 2.93+ (96926a8)

@slokhorst
Copy link
Contributor

@fabionar are you using the Qt client?

@fabionar
Copy link

fabionar commented Mar 4, 2018

@slokhorst https://build.transmissionbt.com/job/trunk-win32/lastBuild/arch=x64,label=pepito-win10/artifact/build-x64/dist/msi/transmission-2.93+-r96926a8337-x64.msi
I'm not sure if I understand what you're saying. But I haven't installed anything but this link.

@slokhorst
Copy link
Contributor

slokhorst commented Mar 4, 2018

@fabionar in the installation wizard, you have to choose which components you want to install. The default is the Qt client only so you probably have that.

What does your script look like? Does it work for a simple .bat file like this?

echo test >> %userprofile%\desktop\log.txt

@mikedld
Copy link
Member

mikedld commented Oct 4, 2018

Closing this for the lack of response assuming it's fixed in master. If it's still not working please provide more information e.g. what @slokhorst asks.

@mikedld mikedld closed this as completed Oct 4, 2018
@opicron
Copy link

opicron commented Feb 1, 2019

I cant test in the latest nighly build because ssl servers are not connecting in that build. It doesnt work on the default download 64bit.

@thiagoalz
Copy link

thiagoalz commented Mar 10, 2019

Not working for me.
Tested with 2.94 x64.

Log says Calling script "C:\PathToScript\SimpleScript.bat"

but the script(That should only write hello to a file) is not executed.

@mikedld
Copy link
Member

mikedld commented Mar 10, 2019

@thiagoalz please test the latest nightly at the links above (#405 (comment)). The milestone is explicitly set to 3.00, 2.94 doesn't contain the fix.

@thiagoalz
Copy link

Oh.. sorry about that. I thought it was on 2.94 because of the dates (commit is 2017 X release is 2018 ).
But ok, going to try nightly and return here.

@thiagoalz
Copy link

thiagoalz commented Mar 10, 2019

Same thing :/
Used Build 185 (03/03/2019 14:20:09).
Log says [2019-03-10 18:20:01.482] MytorrentName Calling script "PathTo.Bat"
But bat did not run

@mikedld
Copy link
Member

mikedld commented Mar 10, 2019

What is the exact contents of your batch script? What is the expected behavior? How do you know that it "did not run"?

@thiagoalz
Copy link

It just writes "hello" to a file.
Running it directly it works perfectly.
Running after a torrent finishes nothing happens

@mikedld
Copy link
Member

mikedld commented Mar 10, 2019

Please provide the exact contents of the script...

@thiagoalz
Copy link

thiagoalz commented Mar 12, 2019

I've tried some different options (any of them worked)
The one im using now is like this:

@echo off
echo MyTest - "%TR_TORRENT_DIR%\%TR_TORRENT_NAME%" > D:\Downloads\zlegendas\output2.txt

@thiagoalz
Copy link

thiagoalz commented Mar 12, 2019

Running it directly, the file is like this (as expected):

MyTest - "\" 

"Running" on torrent finish, file is empty.

@samkatakouzinos
Copy link

samkatakouzinos commented Mar 12, 2019

Have installed and run as deamon from x64 file from #405 (comment).

installation file: transmission-2.94+-ra440981571-x64.msi

settings.json entries:

    "script-torrent-done-enabled": true,
    "script-torrent-done-filename": "C:\\ProgramData\\NZBGet\\scripts\\nzbToMedia\\TorrentToMedia.py",

log entries (log-debug):

[2019-03-12 15:42:02.505] Saved "C:\Windows\ServiceProfiles\LocalService\AppData\Local\transmission-daemon\Resume\b51ef3d700a8ec82e77a770ceaaee4f8f2fa64c3.resume" (C:\Transmission\Jenkins\workspace\trunk-win32\arch\x64\label\pepito-win10\libtransmission\variant.c:1199)
[2019-03-12 15:42:02.505] INXS - The Years 1979-1997 (320) Calling script "C:\ProgramData\NZBGet\scripts\nzbToMedia\TorrentToMedia.py" (C:\Transmission\Jenkins\workspace\trunk-win32\arch\x64\label\pepito-win10\libtransmission\torrent.c:2263)
[2019-03-12 15:42:02.505] INXS - The Years 1979-1997 (320) Error executing script "C:\ProgramData\NZBGet\scripts\nzbToMedia\TorrentToMedia.py" (193): Call to CreateProcess() failed: %1 is not a valid Win32 application. (C:\Transmission\Jenkins\workspace\trunk-win32\arch\x64\label\pepito-win10\libtransmission\torrent.c:2269)
[2019-03-12 15:44:03.503] Saved "C:\Windows\ServiceProfiles\LocalService\AppData\Local\transmission-daemon\stats.json" (C:\Transmission\Jenkins\workspace\trunk-win32\arch\x64\label\pepito-win10\libtransmission\variant.c:1199)

@samkatakouzinos
Copy link

Seems that

CreateProcess requires you to provide an executable file. If you wish to be able to open any file with its associated application then you need ShellExecute rather than CreateProcess.
reference

Q: Would you be willing to implement a ShellExecute test version? This may allow scripts interpreters to run the script (Python, Powershell, CMD, other).

@mikedld
Copy link
Member

mikedld commented Mar 12, 2019

@samkatakouzinos, Running Python scripts directly is currently not supported; only .exe, .bat, or .cmd could be used (or at least were tested). Using ShellExecute is not possible as it doesn't allow for customization of environment of the command being started and that's how we pass all the good stuff to the scripts. Supporting running other types of scripts (directly) is something we want, but not as part of this issue here anyway.

@samkatakouzinos
Copy link

samkatakouzinos commented Mar 12, 2019

I see.

static void append_app_launcher_arguments(enum tr_app_type app_type, char** args)

Do you see a problem if I call a batch file (*.bat) that calls python to execute a script?

@thiagoalz
Copy link

thiagoalz commented Mar 12, 2019

Do you see a problem if I call a batch file (*.bat) that calls python to execute a script?

That was exactly what I was trying to do. Once it didn't work, I moved to a simpler script to check execution end noticed that even just a echo is not running.

@mikedld
Copy link
Member

mikedld commented Mar 12, 2019

I've just verified and script execution is still working as expected in latest builds. Expectations may vary though, so here's what you may want to bear in mind:

  • To reiterate, only .exe, .bat, and .cmd are currently officially supported/tested.
  • When installing the daemon, it's set up to run under Local Service account. This is a limited account that doesn't have access to all the files on your disk, and these limitations apply to any processes it launches including the scripts you specify in settings.json. In particular, Local Service will most probably NOT have access to the files in your home folder (and thus may not be able to read the script file if you put it there). Solutions include (but aren't limited to) putting the script into a folder that daemon is specifically granted access to, and/or reconfiguring the service to run under your user account (or even a separate user account); the latter may not stick between updates, I didn't test but I have a feeling.
  • This is mostly a continuation of the above: whether you're using the daemon or the Qt client, the script you're running may not have access to the directory you're trying to create files in (including via output redirection) due to access permissions.
  • When writing a script,
    • start with a very basic version, e.g. echo a few words to a file in a folder writable by Everyone; put the script into a folder readable by Everyone;
    • don't assume you know what current working directory is at the beginning of the script: either use absolute paths or do an explicit cd ... (using absolute path, again) beforehand; even if you're used to working directory being "inherited" by child processes, it's not the case here (and you shouldn't know Transmission's current working directory anyway); using environment variables in paths is okay (but see below) if the final resolved path is absolute;
    • don't assume that the environment you're manually testing the script in to be the same as the one Transmission is setting up to run your script; add a set > C:\Path\To\Script.log line to your test script to see what variables are actually present, and what their values are (you may be surprised by e.g. PATH; adding where toolname > C:\Path\To\Script.log sometimes helps);
    • not directly related, but if you feel like you're writing a lot of stuff into the log file but getting little actual output, quickly scan through your script code to check if you're using > (truncate) and >> (append) output redirections properly.
  • When editing settings.json manually to specify script path,
    • make sure you're double-quoting the value and doubling the backslashes (i.e. writing "C:\\Path\\To\\Script.cmd" and not "C:\Path\To\Script.cmd"); using forward slashes (i.e. writing "C:/Path/To/Script.cmd") and mixing styles (i.e. writing "C:\\Path\\To/Script.cmd") is acceptable if you're tired;
    • official builds aren't using Cygwin or anything, so paths like "/cygdrive/c/path/to/script.cmd" (or whatever) will not be recognized;
    • script-torrent-done-filename value needs to contain a single absolute path, not a command with arguments.

The above may be incomplete but should hopefully save you a few hours/days. Looking forward to putting this somewhere in docs (help welcome).

P.S. I recognize that troubleshooting may be harder than we'd all like when something goes wrong (same on *NIX really). PRs and ideas to somehow improve that are welcome.

P.P.S. Happy scripting.

@thiagoalz
Copy link

Ya man.... You nailed it!
First, your tips are gold. I already spent 2 days discovering them one by one!
Second.... I`had tried everything I could with permissions and nothing...Once I changed the user running the service... Bingo!

Another tip for those trying this now... after I changed the user running the service I had to reconfigure settings.json!

All perfect now!
Thanks alot for the help!

@samkatakouzinos
Copy link

@thiagoalz that's a great result and promising news for me.
May you share your script here for me to study?

I'm taking baby steps to see where I'm failing.
Echoing and appending (>>) work.
I'm having trouble with calling python with a script.
Also with using parameters such as "set >> %~dpn0.output.log" which I expected to create a log file where the batch file resides but instead created a file named ~dpn0.output.log under c drive.

Appreciate any advice from all.

My efforts below;

batch file contents
rem CD /d "%~dp0"
rem python3.exe .\nzbToMedia\nzbToLidarr.py 
echo " " >> c:\nzbToLidarr.output2.txt
echo " " >> c:\nzbToLidarr.output2.txt
echo "=========" >> c:\nzbToLidarr.output2.txt
echo "~dp0 = " %~dp0 >> c:\nzbToLidarr.output2.txt
%~dp0 >> c:\nzbToLidarr.output2.txt
echo "where python3.exe = " where python3.exe >> c:\nzbToLidarr.output2.txt
where python3.exe >> c:\nzbToLidarr.output2.txt
rem echo %~dp0 >> c:\nzbToLidarr.output2.txt
echo MyTest - "%TR_TORRENT_DIR%\%TR_TORRENT_NAME%" >> c:\nzbToLidarr.output2.txt
set >> c:\nzbToLidarr.output2.txt
echo MyTest - "%TR_TORRENT_DIR%\%TR_TORRENT_NAME%" >> %~dpn0.output.log
set >> %~dpn0.output.log
python3.exe .\nzbToMedia\nzbToLidarr.py 
c:\nzbToLidarr.output2.txt content
" " 
" " 
"=========" 
"~dp0 = " ~dp0 
"where python3.exe = " where python3.exe 
C:\ProgramData\Python\3\python3.exe
MyTest - "C:\WINDOWS\ServiceProfiles\LocalService\Downloads\transmissionbt\music\David Gray - Gold in a Brass Age (2019) [320]" 
ALLUSERSPROFILE=C:\ProgramData
APPDATA=C:\Users\b19680703\AppData\Roaming
asl.log=Destination=file
ChocolateyInstall=C:\ProgramData\chocolatey
ChocolateyLastPathUpdate=Sun Mar 10 17:12:16 2019
CommonProgramFiles=C:\Program Files\Common Files
CommonProgramFiles(x86)=C:\Program Files (x86)\Common Files
CommonProgramW6432=C:\Program Files\Common Files
COMPUTERNAME=SKG-DV-003
ComSpec=C:\WINDOWS\system32\cmd.exe
D3DGEARPATH=c:\program files (x86)\iracing
DriverData=C:\Windows\System32\Drivers\DriverData
INTEL_DEV_REDIST=C:\Program Files (x86)\Common Files\Intel\Shared Libraries\
LIBTHAI_DICTDIR=C:\Program Files\GIMP 2\share\libthai
LOCALAPPDATA=C:\Users\b19680703\AppData\Local
MIC_LD_LIBRARY_PATH=C:\Program Files (x86)\Common Files\Intel\Shared Libraries\compiler\lib\mic
NDI_RUNTIME_DIR_V2=C:\Program Files\NewTek\NewTek NDI Redist\v3
NDI_RUNTIME_DIR_V3=C:\Program Files\NewTek\NewTek NDI Redist\v3
NUMBER_OF_PROCESSORS=8
OneDrive=C:\Users\b19680703\OneDrive
OneDriveConsumer=C:\Users\b19680703\OneDrive
OS=Windows_NT
Path=C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0\;C:\WINDOWS\System32\OpenSSH\;C:\programdata\Python\2\;C:\programdata\Python\2\Scripts;C:\ProgramData\Python\3\;C:\ProgramData\Python\3\Scripts\;C:\Program Files (x86)\Common Files\Oracle\Java\javapath;C:\ProgramData\DockerDesktop\version-bin;C:\Program Files\Docker\Docker\Resources\bin;C:\Program Files (x86)\NVIDIA Corporation\PhysX\Common;C:\Program Files (x86)\Common Files\Intel\Shared Libraries\redist\intel64\compiler;C:\Program Files\Intel\WiFi\bin\;C:\Program Files\Common Files\Intel\WirelessCommon\;c:\program files (x86)\iracing;C:\Program Files\nodejs\;C:\ProgramData\chocolatey\bin;C:\ProgramData\Boxstarter;C:\Program Files\Calibre2\;C:\Program Files\PuTTY\;C:\Program Files\MariaDB 10.2\bin;C:\Program Files\Microsoft VS Code\bin;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0\;C:\WINDOWS\System32\OpenSSH\;C:\Program Files\TortoiseSVN\bin;C:\Program Files (x86)\Streamlink\bin;C:\Program Files\Git\cmd;C:\Program Files\TortoiseGit\bin;C:\Python27;C:\Users\b19680703\AppData\Local\Microsoft\WindowsApps;C:\Users\b19680703\AppData\Local\atom\bin;C:\Program Files\Oracle\VirtualBox;C:\Users\b19680703\AppData\Roaming\npm;%USERPROFILE%\AppData\Local\Microsoft\WindowsApps
PATHEXT=.COM;.EXE;.BAT;.CMD;.VBS;.VBE;.JS;.JSE;.WSF;.WSH;.MSC;.PY;.PYW
PROCESSOR_ARCHITECTURE=AMD64
PROCESSOR_IDENTIFIER=Intel64 Family 6 Model 58 Stepping 9, GenuineIntel
PROCESSOR_LEVEL=6
PROCESSOR_REVISION=3a09
ProgramData=C:\ProgramData
ProgramFiles=C:\Program Files
ProgramFiles(x86)=C:\Program Files (x86)
ProgramW6432=C:\Program Files
PROMPT=$P$G
PSModulePath=C:\Users\b19680703\Documents\WindowsPowerShell\Modules
PUBLIC=C:\Users\Public
SystemDrive=C:
SystemRoot=C:\WINDOWS
TEMP=C:\Users\b19680703\AppData\Local\Temp
TMP=C:\Users\b19680703\AppData\Local\Temp
TR_APP_VERSION=2.94+
TR_TIME_LOCALTIME=Thu Mar 14 19:48:05 2019
TR_TORRENT_DIR=C:\WINDOWS\ServiceProfiles\LocalService\Downloads\transmissionbt\music
TR_TORRENT_HASH=bda94086dd335f6025484a4d942f713c71d71443
TR_TORRENT_ID=10
TR_TORRENT_NAME=David Gray - Gold in a Brass Age (2019) [320]
USERDOMAIN=SKG-DV-003
USERNAME=b19680703
USERPROFILE=C:\Users\b19680703
VBOX_MSI_INSTALL_PATH=C:\Program Files\Oracle\VirtualBox\
windir=C:\WINDOWS

@thiagoalz
Copy link

Sure
This is the script Im using now:

@echo off
::Transmission vars
::* TR_APP_VERSION
::* TR_TIME_LOCALTIME
::* TR_TORRENT_DIR
::* TR_TORRENT_HASH
::* TR_TORRENT_ID
::* TR_TORRENT_NAME


IF [%TR_TORRENT_NAME%]==[] (
	echo Baixando Legendas em: "D:\Downloads\series"
	python D:\Downloads\zlegendas\OpenSubtitlesDownload.py "D:\Downloads\series"
	echo Baixando Legendas em: "D:\Downloads\torrents"
	python D:\Downloads\zlegendas\OpenSubtitlesDownload.py "D:\Downloads\torrents"
) ELSE (
	echo Baixando Legendas em: "%TR_TORRENT_DIR%\%TR_TORRENT_NAME%" > D:\Downloads\zlegendas\outputTransmission.txt
	python D:\Downloads\zlegendas\OpenSubtitlesDownload.py "%TR_TORRENT_DIR%\%TR_TORRENT_NAME%" >> D:\Downloads\zlegendas\outputTransmission.txt
)

TIMEOUT 10

@samkatakouzinos
Copy link

Sure
This is the script Im using now:

Thank you, very useful.

@sergeevabc
Copy link

transmission-cli 2.77 (for Windows 7) throws error as follows
error executing script "stop_cli.cmd": No such file or directory
The command was transmission-cli.exe -f stop_cli.cmd -w . magnet:?xt=urn:btih:...

netbsd-srcmastr pushed a commit to NetBSD/pkgsrc that referenced this issue Jul 13, 2020
### All Platforms
- Allow the RPC server to listen on an IPv6 address ([#161](transmission/transmission#161))
- Change `TR_CURL_SSL_VERIFY` to `TR_CURL_SSL_NO_VERIFY` and enable verification by default ([#334](transmission/transmission#334))
- Go back to using hash as base name for resume and torrent files (those stored in configuration directory) ([#122](transmission/transmission#122))
- Handle "fields" argument in "session-get" RPC request; if "fields" array is present in arguments, only return session fields specified; otherwise return all the fields as before
- Limit the number of incorrect authentication attempts in embedded web server to 100 to prevent brute-force attacks ([#371](transmission/transmission#371))
- Set idle seed limit range to 1..40320 (4 weeks tops) in all clients ([#212](transmission/transmission#212))
- Add Peer ID for Xfplay, PicoTorrent, Free Download Manager, Folx, Baidu Netdisk torrent clients ([#256](transmission/transmission#256), [#285](transmission/transmission#285), [#355](transmission/transmission#355), [#363](transmission/transmission#363), [#386](transmission/transmission#386))
- Announce `INT64_MAX` as size left if the value is unknown (helps with e.g. Amazon S3 trackers) ([#250](transmission/transmission#250))
- Add `TCP_FASTOPEN` support (should result in slight speedup) ([#184](transmission/transmission#184))
- Improve ToS handling on IPv6 connections ([#128](transmission/transmission#128), [#341](transmission/transmission#341), [#360](transmission/transmission#360), [#692](transmission/transmission#692), [#737](transmission/transmission#737))
- Abort handshake if establishing DH shared secret fails (leads to crash) ([#27](transmission/transmission#27))
- Don't switch trackers while announcing (leads to crash) ([#297](transmission/transmission#297))
- Improve completion scripts execution and error handling; add support for .cmd and .bat files on Windows ([#405](transmission/transmission#405))
- Maintain a "session ID" file (in temporary directory) to better detect whether session is local or remote; return the ID as part of "session-get" response (TRAC-5348, [#861](transmission/transmission#861))
- Change torrent location even if no data move is needed ([#35](transmission/transmission#35))
- Support CIDR-notated blocklists ([#230](transmission/transmission#230), [#741](transmission/transmission#741))
- Update the resume file before running scripts ([#825](transmission/transmission#825))
- Make multiscrape limits adaptive ([#837](transmission/transmission#837))
- Add labels support to libtransmission and transmission-remote ([#822](transmission/transmission#822))
- Parse `session-id` header case-insensitively ([#765](transmission/transmission#765))
- Sanitize suspicious path components instead of rejecting them ([#62](transmission/transmission#62), [#294](transmission/transmission#294))
- Load CA certs from system store on Windows / OpenSSL ([#446](transmission/transmission#446))
- Add support for mbedtls (formely polarssl) and wolfssl (formely cyassl), LibreSSL ([#115](transmission/transmission#115), [#116](transmission/transmission#116), [#284](transmission/transmission#284), [#486](transmission/transmission#486), [#524](transmission/transmission#524), [#570](transmission/transmission#570))
- Fix building against OpenSSL 1.1.0+ ([#24](transmission/transmission#24))
- Fix quota support for uClibc-ng 1.0.18+ and DragonFly BSD ([#42](transmission/transmission#42), [#58](transmission/transmission#58), [#312](transmission/transmission#312))
- Fix a number of memory leaks (magnet loading, session shutdown, bencoded data parsing) ([#56](transmission/transmission#56))
- Bump miniupnpc version to 2.0.20170509 ([#347](transmission/transmission#347))
- CMake-related improvements (Ninja generator, libappindicator, systemd, Solaris and macOS) ([#72](transmission/transmission#72), [#96](transmission/transmission#96), [#117](transmission/transmission#117), [#118](transmission/transmission#118), [#133](transmission/transmission#133), [#191](transmission/transmission#191))
- Switch to submodules to manage (most of) third-party dependencies
- Fail installation on Windows if UCRT is not installed

### Mac Client
- Bump minimum macOS version to 10.10
- Dark Mode support ([#644](transmission/transmission#644), [#722](transmission/transmission#722), [#757](transmission/transmission#757), [#779](transmission/transmission#779), [#788](transmission/transmission#788))
- Remove Growl support, notification center is always used ([#387](transmission/transmission#387))
- Fix autoupdate on High Sierra and up by bumping the Sparkle version ([#121](transmission/transmission#121), [#600](transmission/transmission#600))
- Transition to ARC ([#336](transmission/transmission#336))
- Use proper UTF-8 encoding (with macOS-specific normalization) when setting download/incomplete directory and completion script paths ([#11](transmission/transmission#11))
- Fix uncaught exception when dragging multiple items between groups ([#51](transmission/transmission#51))
- Add flat variants of status icons for message log ([#134](transmission/transmission#134))
- Optimize image resources size ([#304](transmission/transmission#304), [#429](transmission/transmission#429))
- Update file icon when file name changes ([#37](transmission/transmission#37))
- Update translations

### GTK+ Client
- Add queue up/down hotkeys ([#158](transmission/transmission#158))
- Modernize the .desktop file ([#162](transmission/transmission#162))
- Add AppData file ([#224](transmission/transmission#224))
- Add symbolic icon variant for the Gnome top bar and when the high contrast theme is in use ([#414](transmission/transmission#414), [#449](transmission/transmission#449))
- Update file icon when its name changes ([#37](transmission/transmission#37))
- Switch from intltool to gettext for translations ([#584](transmission/transmission#584), [#647](transmission/transmission#647))
- Update translations, add new translations for Portuguese (Portugal)

### Qt Client
- Bump minimum Qt version to 5.2
- Fix dropping .torrent files into main window on Windows ([#269](transmission/transmission#269))
- Fix prepending of drive letter to various user-selected paths on Windows ([#236](transmission/transmission#236), [#307](transmission/transmission#307), [#404](transmission/transmission#404), [#437](transmission/transmission#437), [#699](transmission/transmission#699), [#723](transmission/transmission#723), [#877](transmission/transmission#877))
- Fix sorting by progress in presence of magnet transfers ([#234](transmission/transmission#234))
- Fix .torrent file trashing upon addition ([#262](transmission/transmission#262))
- Add queue up/down hotkeys ([#158](transmission/transmission#158))
- Reduce torrent properties (file tree) memory usage
- Display tooltips in torrent properties (file tree) in case the names don't fit ([#411](transmission/transmission#411))
- Improve UI look on hi-dpi displays (YMMV)
- Use session ID (if available) to check if session is local or not ([#861](transmission/transmission#861))
- Use default (instead of system) locale to be more flexible ([#130](transmission/transmission#130))
- Modernize the .desktop file ([#162](transmission/transmission#162))
- Update translations, add new translations for Afrikaans, Catalan, Danish, Greek, Norwegian Bokmål, Slovenian

### Daemon
- Use libsystemd instead of libsystemd-daemon (TRAC-5921)
- Harden transmission-daemon.service by disallowing privileges elevation ([#795](transmission/transmission#795))
- Fix exit code to be zero when dumping settings ([#487](transmission/transmission#487))

### Web Client
- Fix tracker error XSS in inspector (CVE-?)
- Fix performance issues due to improper use of `setInterval()` for UI refresh (TRAC-6031)
- Fix recognition of `https://` links in comments field ([#41](transmission/transmission#41), [#180](transmission/transmission#180))
- Fix torrent list style in Google Chrome 59+ ([#384](transmission/transmission#384))
- Show ETA in compact view on non-mobile devices ([#146](transmission/transmission#146))
- Show upload file button on mobile devices ([#320](transmission/transmission#320), [#431](transmission/transmission#431), [#956](transmission/transmission#956))
- Add keyboard hotkeys for web interface ([#351](transmission/transmission#351))
- Disable autocompletion in torrent URL field ([#367](transmission/transmission#367))

### Utils
- Prevent crash in transmission-show displaying torrents with invalid creation date ([#609](transmission/transmission#609))
- Handle IPv6 RPC addresses in transmission-remote ([#247](transmission/transmission#247))
- Add `--unsorted` option to transmission-show ([#767](transmission/transmission#767))
- Widen the torrent-id column in transmission-remote for cleaner formatting ([#840](transmission/transmission#840))
netbsd-srcmastr pushed a commit to NetBSD/pkgsrc that referenced this issue Aug 3, 2020
net/transmission-gtk: security update
net/transmission-qt: security update
net/transmission: security update

Revisions pulled up:
- net/transmission-gtk/Makefile                                 1.46
- net/transmission-gtk/PLIST                                    1.2
- net/transmission-qt/Makefile                                  1.54
- net/transmission/Makefile                                     1.27
- net/transmission/Makefile.common                              1.10
- net/transmission/PLIST                                        1.4
- net/transmission/distinfo                                     1.16
- net/transmission/patches/patch-qt_qtr.pro                     1.7

-------------------------------------------------------------------
   Module Name:	pkgsrc
   Committed By:	wiz
   Date:		Mon Jul 13 13:01:02 UTC 2020

   Modified Files:
   	pkgsrc/net/transmission: Makefile Makefile.common PLIST distinfo
   	pkgsrc/net/transmission-gtk: Makefile PLIST
   	pkgsrc/net/transmission-qt: Makefile
   	pkgsrc/net/transmission/patches: patch-qt_qtr.pro

   Log Message:
   transmission*: update to 3.00

   ### All Platforms
   - Allow the RPC server to listen on an IPv6 address ([#161](transmission/transmission#161))
   - Change `TR_CURL_SSL_VERIFY` to `TR_CURL_SSL_NO_VERIFY` and enable verification by default ([#334](transmission/transmission#334))
   - Go back to using hash as base name for resume and torrent files (those stored in configuration directory) ([#122](transmission/transmission#122))
   - Handle "fields" argument in "session-get" RPC request; if "fields" array is present in arguments, only return session fields specified; otherwise return all the fields as before
   - Limit the number of incorrect authentication attempts in embedded web server to 100 to prevent brute-force attacks ([#371](transmission/transmission#371))
   - Set idle seed limit range to 1..40320 (4 weeks tops) in all clients ([#212](transmission/transmission#212))
   - Add Peer ID for Xfplay, PicoTorrent, Free Download Manager, Folx, Baidu Netdisk torrent clients ([#256](transmission/transmission#256), [#285](transmission/transmission#285), [#355](transmission/transmission#355), [#363](transmission/transmission#363), [#386](transmission/transmission#386))
   - Announce `INT64_MAX` as size left if the value is unknown (helps with e.g. Amazon S3 trackers) ([#250](transmission/transmission#250))
   - Add `TCP_FASTOPEN` support (should result in slight speedup) ([#184](transmission/transmission#184))
   - Improve ToS handling on IPv6 connections ([#128](transmission/transmission#128), [#341](transmission/transmission#341), [#360](transmission/transmission#360), [#692](transmission/transmission#692), [#737](transmission/transmission#737))
   - Abort handshake if establishing DH shared secret fails (leads to crash) ([#27](transmission/transmission#27))
   - Don't switch trackers while announcing (leads to crash) ([#297](transmission/transmission#297))
   - Improve completion scripts execution and error handling; add support for .cmd and .bat files on Windows ([#405](transmission/transmission#405))
   - Maintain a "session ID" file (in temporary directory) to better detect whether session is local or remote; return the ID as part of "session-get" response (TRAC-5348, [#861](transmission/transmission#861))
   - Change torrent location even if no data move is needed ([#35](transmission/transmission#35))
   - Support CIDR-notated blocklists ([#230](transmission/transmission#230), [#741](transmission/transmission#741))
   - Update the resume file before running scripts ([#825](transmission/transmission#825))
   - Make multiscrape limits adaptive ([#837](transmission/transmission#837))
   - Add labels support to libtransmission and transmission-remote ([#822](transmission/transmission#822))
   - Parse `session-id` header case-insensitively ([#765](transmission/transmission#765))
   - Sanitize suspicious path components instead of rejecting them ([#62](transmission/transmission#62), [#294](transmission/transmission#294))
   - Load CA certs from system store on Windows / OpenSSL ([#446](transmission/transmission#446))
   - Add support for mbedtls (formely polarssl) and wolfssl (formely cyassl), LibreSSL ([#115](transmission/transmission#115), [#116](transmission/transmission#116), [#284](transmission/transmission#284), [#486](transmission/transmission#486), [#524](transmission/transmission#524), [#570](transmission/transmission#570))
   - Fix building against OpenSSL 1.1.0+ ([#24](transmission/transmission#24))
   - Fix quota support for uClibc-ng 1.0.18+ and DragonFly BSD ([#42](transmission/transmission#42), [#58](transmission/transmission#58), [#312](transmission/transmission#312))
   - Fix a number of memory leaks (magnet loading, session shutdown, bencoded data parsing) ([#56](transmission/transmission#56))
   - Bump miniupnpc version to 2.0.20170509 ([#347](transmission/transmission#347))
   - CMake-related improvements (Ninja generator, libappindicator, systemd, Solaris and macOS) ([#72](transmission/transmission#72), [#96](transmission/transmission#96), [#117](transmission/transmission#117), [#118](transmission/transmission#118), [#133](transmission/transmission#133), [#191](transmission/transmission#191))
   - Switch to submodules to manage (most of) third-party dependencies
   - Fail installation on Windows if UCRT is not installed

   ### Mac Client
   - Bump minimum macOS version to 10.10
   - Dark Mode support ([#644](transmission/transmission#644), [#722](transmission/transmission#722), [#757](transmission/transmission#757), [#779](transmission/transmission#779), [#788](transmission/transmission#788))
   - Remove Growl support, notification center is always used ([#387](transmission/transmission#387))
   - Fix autoupdate on High Sierra and up by bumping the Sparkle version ([#121](transmission/transmission#121), [#600](transmission/transmission#600))
   - Transition to ARC ([#336](transmission/transmission#336))
   - Use proper UTF-8 encoding (with macOS-specific normalization) when setting download/incomplete directory and completion script paths ([#11](transmission/transmission#11))
   - Fix uncaught exception when dragging multiple items between groups ([#51](transmission/transmission#51))
   - Add flat variants of status icons for message log ([#134](transmission/transmission#134))
   - Optimize image resources size ([#304](transmission/transmission#304), [#429](transmission/transmission#429))
   - Update file icon when file name changes ([#37](transmission/transmission#37))
   - Update translations

   ### GTK+ Client
   - Add queue up/down hotkeys ([#158](transmission/transmission#158))
   - Modernize the .desktop file ([#162](transmission/transmission#162))
   - Add AppData file ([#224](transmission/transmission#224))
   - Add symbolic icon variant for the Gnome top bar and when the high contrast theme is in use ([#414](transmission/transmission#414), [#449](transmission/transmission#449))
   - Update file icon when its name changes ([#37](transmission/transmission#37))
   - Switch from intltool to gettext for translations ([#584](transmission/transmission#584), [#647](transmission/transmission#647))
   - Update translations, add new translations for Portuguese (Portugal)

   ### Qt Client
   - Bump minimum Qt version to 5.2
   - Fix dropping .torrent files into main window on Windows ([#269](transmission/transmission#269))
   - Fix prepending of drive letter to various user-selected paths on Windows ([#236](transmission/transmission#236), [#307](transmission/transmission#307), [#404](transmission/transmission#404), [#437](transmission/transmission#437), [#699](transmission/transmission#699), [#723](transmission/transmission#723), [#877](transmission/transmission#877))
   - Fix sorting by progress in presence of magnet transfers ([#234](transmission/transmission#234))
   - Fix .torrent file trashing upon addition ([#262](transmission/transmission#262))
   - Add queue up/down hotkeys ([#158](transmission/transmission#158))
   - Reduce torrent properties (file tree) memory usage
   - Display tooltips in torrent properties (file tree) in case the names don't fit ([#411](transmission/transmission#411))
   - Improve UI look on hi-dpi displays (YMMV)
   - Use session ID (if available) to check if session is local or not ([#861](transmission/transmission#861))
   - Use default (instead of system) locale to be more flexible ([#130](transmission/transmission#130))
   - Modernize the .desktop file ([#162](transmission/transmission#162))
   - Update translations, add new translations for Afrikaans, Catalan, Danish, Greek, Norwegian Bokmål, Slovenian

   ### Daemon
   - Use libsystemd instead of libsystemd-daemon (TRAC-5921)
   - Harden transmission-daemon.service by disallowing privileges elevation ([#795](transmission/transmission#795))
   - Fix exit code to be zero when dumping settings ([#487](transmission/transmission#487))

   ### Web Client
   - Fix tracker error XSS in inspector (CVE-?)
   - Fix performance issues due to improper use of `setInterval()` for UI refresh (TRAC-6031)
   - Fix recognition of `https://` links in comments field ([#41](transmission/transmission#41), [#180](transmission/transmission#180))
   - Fix torrent list style in Google Chrome 59+ ([#384](transmission/transmission#384))
   - Show ETA in compact view on non-mobile devices ([#146](transmission/transmission#146))
   - Show upload file button on mobile devices ([#320](transmission/transmission#320), [#431](transmission/transmission#431), [#956](transmission/transmission#956))
   - Add keyboard hotkeys for web interface ([#351](transmission/transmission#351))
   - Disable autocompletion in torrent URL field ([#367](transmission/transmission#367))

   ### Utils
   - Prevent crash in transmission-show displaying torrents with invalid creation date ([#609](transmission/transmission#609))
   - Handle IPv6 RPC addresses in transmission-remote ([#247](transmission/transmission#247))
   - Add `--unsorted` option to transmission-show ([#767](transmission/transmission#767))
   - Widen the torrent-id column in transmission-remote for cleaner formatting ([#840](transmission/transmission#840))


   To generate a diff of this commit:
   cvs rdiff -u -r1.26 -r1.27 pkgsrc/net/transmission/Makefile
   cvs rdiff -u -r1.9 -r1.10 pkgsrc/net/transmission/Makefile.common
   cvs rdiff -u -r1.3 -r1.4 pkgsrc/net/transmission/PLIST
   cvs rdiff -u -r1.15 -r1.16 pkgsrc/net/transmission/distinfo
   cvs rdiff -u -r1.45 -r1.46 pkgsrc/net/transmission-gtk/Makefile
   cvs rdiff -u -r1.1 -r1.2 pkgsrc/net/transmission-gtk/PLIST
   cvs rdiff -u -r1.52 -r1.53 pkgsrc/net/transmission-qt/Makefile
   cvs rdiff -u -r1.6 -r1.7 pkgsrc/net/transmission/patches/patch-qt_qtr.pro
-------------------------------------------------------------------
   Module Name:    pkgsrc
   Committed By:   wiz
   Date:           Sat Jul 25 20:20:05 UTC 2020

   Modified Files:
           pkgsrc/net/transmission-qt: Makefile

   Log Message:
   transmission-qt: needs gcc 7.x (for <optional>)

   Reported and tested by spz.


   To generate a diff of this commit:
   cvs rdiff -u -r1.53 -r1.54 pkgsrc/net/transmission-qt/Makefile
netbsd-srcmastr pushed a commit to NetBSD/pkgsrc that referenced this issue Oct 14, 2021
net/transmission-gtk: security update
net/transmission-qt: security update
net/transmission: security update

Revisions pulled up:
- net/transmission-gtk/Makefile                                 1.46
- net/transmission-gtk/PLIST                                    1.2
- net/transmission-qt/Makefile                                  1.54
- net/transmission/Makefile                                     1.27
- net/transmission/Makefile.common                              1.10
- net/transmission/PLIST                                        1.4
- net/transmission/distinfo                                     1.16
- net/transmission/patches/patch-qt_qtr.pro                     1.7

-------------------------------------------------------------------
   Module Name:	pkgsrc
   Committed By:	wiz
   Date:		Mon Jul 13 13:01:02 UTC 2020

   Modified Files:
   	pkgsrc/net/transmission: Makefile Makefile.common PLIST distinfo
   	pkgsrc/net/transmission-gtk: Makefile PLIST
   	pkgsrc/net/transmission-qt: Makefile
   	pkgsrc/net/transmission/patches: patch-qt_qtr.pro

   Log Message:
   transmission*: update to 3.00

   ### All Platforms
   - Allow the RPC server to listen on an IPv6 address ([#161](transmission/transmission#161))
   - Change `TR_CURL_SSL_VERIFY` to `TR_CURL_SSL_NO_VERIFY` and enable verification by default ([#334](transmission/transmission#334))
   - Go back to using hash as base name for resume and torrent files (those stored in configuration directory) ([#122](transmission/transmission#122))
   - Handle "fields" argument in "session-get" RPC request; if "fields" array is present in arguments, only return session fields specified; otherwise return all the fields as before
   - Limit the number of incorrect authentication attempts in embedded web server to 100 to prevent brute-force attacks ([#371](transmission/transmission#371))
   - Set idle seed limit range to 1..40320 (4 weeks tops) in all clients ([#212](transmission/transmission#212))
   - Add Peer ID for Xfplay, PicoTorrent, Free Download Manager, Folx, Baidu Netdisk torrent clients ([#256](transmission/transmission#256), [#285](transmission/transmission#285), [#355](transmission/transmission#355), [#363](transmission/transmission#363), [#386](transmission/transmission#386))
   - Announce `INT64_MAX` as size left if the value is unknown (helps with e.g. Amazon S3 trackers) ([#250](transmission/transmission#250))
   - Add `TCP_FASTOPEN` support (should result in slight speedup) ([#184](transmission/transmission#184))
   - Improve ToS handling on IPv6 connections ([#128](transmission/transmission#128), [#341](transmission/transmission#341), [#360](transmission/transmission#360), [#692](transmission/transmission#692), [#737](transmission/transmission#737))
   - Abort handshake if establishing DH shared secret fails (leads to crash) ([#27](transmission/transmission#27))
   - Don't switch trackers while announcing (leads to crash) ([#297](transmission/transmission#297))
   - Improve completion scripts execution and error handling; add support for .cmd and .bat files on Windows ([#405](transmission/transmission#405))
   - Maintain a "session ID" file (in temporary directory) to better detect whether session is local or remote; return the ID as part of "session-get" response (TRAC-5348, [#861](transmission/transmission#861))
   - Change torrent location even if no data move is needed ([#35](transmission/transmission#35))
   - Support CIDR-notated blocklists ([#230](transmission/transmission#230), [#741](transmission/transmission#741))
   - Update the resume file before running scripts ([#825](transmission/transmission#825))
   - Make multiscrape limits adaptive ([#837](transmission/transmission#837))
   - Add labels support to libtransmission and transmission-remote ([#822](transmission/transmission#822))
   - Parse `session-id` header case-insensitively ([#765](transmission/transmission#765))
   - Sanitize suspicious path components instead of rejecting them ([#62](transmission/transmission#62), [#294](transmission/transmission#294))
   - Load CA certs from system store on Windows / OpenSSL ([#446](transmission/transmission#446))
   - Add support for mbedtls (formely polarssl) and wolfssl (formely cyassl), LibreSSL ([#115](transmission/transmission#115), [#116](transmission/transmission#116), [#284](transmission/transmission#284), [#486](transmission/transmission#486), [#524](transmission/transmission#524), [#570](transmission/transmission#570))
   - Fix building against OpenSSL 1.1.0+ ([#24](transmission/transmission#24))
   - Fix quota support for uClibc-ng 1.0.18+ and DragonFly BSD ([#42](transmission/transmission#42), [#58](transmission/transmission#58), [#312](transmission/transmission#312))
   - Fix a number of memory leaks (magnet loading, session shutdown, bencoded data parsing) ([#56](transmission/transmission#56))
   - Bump miniupnpc version to 2.0.20170509 ([#347](transmission/transmission#347))
   - CMake-related improvements (Ninja generator, libappindicator, systemd, Solaris and macOS) ([#72](transmission/transmission#72), [#96](transmission/transmission#96), [#117](transmission/transmission#117), [#118](transmission/transmission#118), [#133](transmission/transmission#133), [#191](transmission/transmission#191))
   - Switch to submodules to manage (most of) third-party dependencies
   - Fail installation on Windows if UCRT is not installed

   ### Mac Client
   - Bump minimum macOS version to 10.10
   - Dark Mode support ([#644](transmission/transmission#644), [#722](transmission/transmission#722), [#757](transmission/transmission#757), [#779](transmission/transmission#779), [#788](transmission/transmission#788))
   - Remove Growl support, notification center is always used ([#387](transmission/transmission#387))
   - Fix autoupdate on High Sierra and up by bumping the Sparkle version ([#121](transmission/transmission#121), [#600](transmission/transmission#600))
   - Transition to ARC ([#336](transmission/transmission#336))
   - Use proper UTF-8 encoding (with macOS-specific normalization) when setting download/incomplete directory and completion script paths ([#11](transmission/transmission#11))
   - Fix uncaught exception when dragging multiple items between groups ([#51](transmission/transmission#51))
   - Add flat variants of status icons for message log ([#134](transmission/transmission#134))
   - Optimize image resources size ([#304](transmission/transmission#304), [#429](transmission/transmission#429))
   - Update file icon when file name changes ([#37](transmission/transmission#37))
   - Update translations

   ### GTK+ Client
   - Add queue up/down hotkeys ([#158](transmission/transmission#158))
   - Modernize the .desktop file ([#162](transmission/transmission#162))
   - Add AppData file ([#224](transmission/transmission#224))
   - Add symbolic icon variant for the Gnome top bar and when the high contrast theme is in use ([#414](transmission/transmission#414), [#449](transmission/transmission#449))
   - Update file icon when its name changes ([#37](transmission/transmission#37))
   - Switch from intltool to gettext for translations ([#584](transmission/transmission#584), [#647](transmission/transmission#647))
   - Update translations, add new translations for Portuguese (Portugal)

   ### Qt Client
   - Bump minimum Qt version to 5.2
   - Fix dropping .torrent files into main window on Windows ([#269](transmission/transmission#269))
   - Fix prepending of drive letter to various user-selected paths on Windows ([#236](transmission/transmission#236), [#307](transmission/transmission#307), [#404](transmission/transmission#404), [#437](transmission/transmission#437), [#699](transmission/transmission#699), [#723](transmission/transmission#723), [#877](transmission/transmission#877))
   - Fix sorting by progress in presence of magnet transfers ([#234](transmission/transmission#234))
   - Fix .torrent file trashing upon addition ([#262](transmission/transmission#262))
   - Add queue up/down hotkeys ([#158](transmission/transmission#158))
   - Reduce torrent properties (file tree) memory usage
   - Display tooltips in torrent properties (file tree) in case the names don't fit ([#411](transmission/transmission#411))
   - Improve UI look on hi-dpi displays (YMMV)
   - Use session ID (if available) to check if session is local or not ([#861](transmission/transmission#861))
   - Use default (instead of system) locale to be more flexible ([#130](transmission/transmission#130))
   - Modernize the .desktop file ([#162](transmission/transmission#162))
   - Update translations, add new translations for Afrikaans, Catalan, Danish, Greek, Norwegian Bokmål, Slovenian

   ### Daemon
   - Use libsystemd instead of libsystemd-daemon (TRAC-5921)
   - Harden transmission-daemon.service by disallowing privileges elevation ([#795](transmission/transmission#795))
   - Fix exit code to be zero when dumping settings ([#487](transmission/transmission#487))

   ### Web Client
   - Fix tracker error XSS in inspector (CVE-?)
   - Fix performance issues due to improper use of `setInterval()` for UI refresh (TRAC-6031)
   - Fix recognition of `https://` links in comments field ([#41](transmission/transmission#41), [#180](transmission/transmission#180))
   - Fix torrent list style in Google Chrome 59+ ([#384](transmission/transmission#384))
   - Show ETA in compact view on non-mobile devices ([#146](transmission/transmission#146))
   - Show upload file button on mobile devices ([#320](transmission/transmission#320), [#431](transmission/transmission#431), [#956](transmission/transmission#956))
   - Add keyboard hotkeys for web interface ([#351](transmission/transmission#351))
   - Disable autocompletion in torrent URL field ([#367](transmission/transmission#367))

   ### Utils
   - Prevent crash in transmission-show displaying torrents with invalid creation date ([#609](transmission/transmission#609))
   - Handle IPv6 RPC addresses in transmission-remote ([#247](transmission/transmission#247))
   - Add `--unsorted` option to transmission-show ([#767](transmission/transmission#767))
   - Widen the torrent-id column in transmission-remote for cleaner formatting ([#840](transmission/transmission#840))


   To generate a diff of this commit:
   cvs rdiff -u -r1.26 -r1.27 pkgsrc/net/transmission/Makefile
   cvs rdiff -u -r1.9 -r1.10 pkgsrc/net/transmission/Makefile.common
   cvs rdiff -u -r1.3 -r1.4 pkgsrc/net/transmission/PLIST
   cvs rdiff -u -r1.15 -r1.16 pkgsrc/net/transmission/distinfo
   cvs rdiff -u -r1.45 -r1.46 pkgsrc/net/transmission-gtk/Makefile
   cvs rdiff -u -r1.1 -r1.2 pkgsrc/net/transmission-gtk/PLIST
   cvs rdiff -u -r1.52 -r1.53 pkgsrc/net/transmission-qt/Makefile
   cvs rdiff -u -r1.6 -r1.7 pkgsrc/net/transmission/patches/patch-qt_qtr.pro
-------------------------------------------------------------------
   Module Name:    pkgsrc
   Committed By:   wiz
   Date:           Sat Jul 25 20:20:05 UTC 2020

   Modified Files:
           pkgsrc/net/transmission-qt: Makefile

   Log Message:
   transmission-qt: needs gcc 7.x (for <optional>)

   Reported and tested by spz.


   To generate a diff of this commit:
   cvs rdiff -u -r1.53 -r1.54 pkgsrc/net/transmission-qt/Makefile
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

No branches or pull requests

9 participants