Hi,
In a previous thread (http://www.ghisler.ch/board/viewtopic.php?t=36923&highlight=webdav&sid=73d6b873728a46cb72ab4b0e94842af2), it was mentioned that the WebDav plugin should prompt for UserName/PW if none is provided in the configuration.
Is this something that is still on the roadmap?
WebDav authentication prompt
Moderators: Hacker, petermad, Stefan2, white
- ghisler(Author)
- Site Admin
- Posts: 50475
- Joined: 2003-02-04, 09:46 UTC
- Location: Switzerland
- Contact:
The problem is that WebDAV uses HTTP or HTTPS, and there is no indication whether user name or password is wrong, or both.
Author of Total Commander
https://www.ghisler.com
https://www.ghisler.com
For those interested in the workaround:
My goal is to have WebDav behave like TC FTP without a configured UN/PW and thus have it prompt me for both.
To do this, I have TC call a script from a button-bar button. The first argument is "?" and the second argument is "user name". As a result, TC prompts for input for what seems like the user name.
The result of the input is the argument to my script. In the script, I write tcwebdav.ini config. The config is allways the same, with the exception of the username. The PW remains empty.
The script then calls TC.exe again (same instance) with the desired WebDav URL "\\\\WebDAV\<ConnectionName>" as the target for the right panel.
TC WebDav opens the URL and prompts for the PW.
This is virtually identical to opening an FTP connection that has no UN/PW configured and for which TC prompts for the UN/PW.
The difference is that the user name remains in the webdav config, but I'll wipe that via some other way.
My goal is to have WebDav behave like TC FTP without a configured UN/PW and thus have it prompt me for both.
To do this, I have TC call a script from a button-bar button. The first argument is "?" and the second argument is "user name". As a result, TC prompts for input for what seems like the user name.
The result of the input is the argument to my script. In the script, I write tcwebdav.ini config. The config is allways the same, with the exception of the username. The PW remains empty.
The script then calls TC.exe again (same instance) with the desired WebDav URL "\\\\WebDAV\<ConnectionName>" as the target for the right panel.
TC WebDav opens the URL and prompts for the PW.
This is virtually identical to opening an FTP connection that has no UN/PW configured and for which TC prompts for the UN/PW.
The difference is that the user name remains in the webdav config, but I'll wipe that via some other way.
Does WebDav reread username from INI every time it opens a connection? It may simply read it once and then keep in memory.
BTW you can use tools for changing INI parameter instead of rewriting it, also there are tiny tools that ask TC to change path (I believe such tools work faster because there is no need to load large executable into memory). For example, you can use TCFS2 in order to write INI parameter and then change TC path, also you can use AskParam to prompt for username and then pass it to TCFS2 so it may work w/o scripts, just from buttonbar button.
BTW you can use tools for changing INI parameter instead of rewriting it, also there are tiny tools that ask TC to change path (I believe such tools work faster because there is no need to load large executable into memory). For example, you can use TCFS2 in order to write INI parameter and then change TC path, also you can use AskParam to prompt for username and then pass it to TCFS2 so it may work w/o scripts, just from buttonbar button.