[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: Offer re-prompt to change user authn after failed commit?

From: Stefan Küng <tortoisesvn_at_gmail.com>
Date: Fri, 3 Feb 2017 21:52:23 +0100

On 03.02.2017 19:53, Karl Fogel wrote:
> In TortoiseSVN 1.9.5, on a Windows 10 box [1], I needed to do a commit from an existing working copy, but on that machine, Tortoise only had cached authentication credentials for a read-only user for the repository in question.
>
> "No problem," I thought, "It'll just fail the first commit attempt, because it will default first to the cached user creds, but then it will prompt me for a new username / password pair, the way the command-line client would, and let me commit with those."
>
> That's not what happened. I right-clicked on the file and chose "TortoiseSVN Commit", and as expected the initial commit attempt failed... but that was it. There was no re-prompt interface at which I could enter a different username and password. The only client-side solution would have been to wipe out all the cached authentication credentials, which of course I didn't want to do (I didn't want to lose the creds for the read-only user, I just wanted to do this commit as another user.) The solution I actually used was to temporarily enable read-write for the original user on the repository side, commit, and then use propset to change the "svn:author" revprop. But that's obviously not ideal, and would have been impossible if I didn't have admin access to the repository.
>
> Is there a re-prompt feature in TortoiseSVN and I just didn't manage to find it? Or if not, would this be a desirable feature to have? (I looked in the ChangeLog, the users@ archive, and in the bug tracker, and did not see any discussion of this enhancement.)

Sorry, there's not re-prompt feature implemented.
Subversion only asks for authentication (username/password) if
necessary. Since auth data is already stored locally, it uses that data
to authenticate. But the authentication succeeds! So it doesn't ask the
user for authentication anymore.
The problem is that the authorization later fails, which comes much
later than the authentication.

There's a workaround though:
in the settings dialog, Sync page you can export all settings to a file.
If you check the box "sync stored auth data", then that export file will
contain also all the stored auth data. You can then delete the stored
auth data, do your commit and then import the exported file again.

Also: settings dialog->saved data
There's not just a "Clear" button next to "Authentication data" but also
a "Clear..." button. If you click the "Clear..." button you'll get a
dialog showing you all the stored auth data, and there you can select
just the one stored data to delete.
Maybe that's the easiest way.
(note: just in case you forgot your password(s): on that dialog you can
Ctrl+Shift+DoubleClick to have it show you the passwords in clear).

Hope that helps a little bit.

Stefan

-- 
        ___
   oo  // \\      "De Chelonian Mobile"
  (_,\/ \_/ \     TortoiseSVN
    \ \_/_\_/>    The coolest interface to (Sub)version control
    /_/   \_\     http://tortoisesvn.net
------------------------------------------------------
http://tortoisesvn.tigris.org/ds/viewMessage.do?dsForumId=4061&dsMessageId=3206584
To unsubscribe from this discussion, e-mail: [users-unsubscribe_at_tortoisesvn.tigris.org].
Received on 2017-02-03 21:52:54 CET

This is an archived mail posted to the TortoiseSVN Users mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.