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

JavaHL: support for authenticating with different credentials for the same realm

From: Marc Strapetz <marc.strapetz_at_syntevo.com>
Date: Thu, 06 Feb 2014 15:27:14 +0100

For SmartSVN, we are looking for a way to support multiple credentials
(username and password) for the same realm. When using the command line
client, --username will do the job, however this option is not well
suited for a GUI client. Here, a quite flexible as well as intuitive
approach would be to support the user_at_-specification as part of the URL.
To be able to implement that, I'd suggest to extend JavaHL in either of
the following ways:

(A) UserPasswordCallback.prompt(String realm, String username) should
give the user_at_-user from the requested URL as the default "username", if
present. Hence, precedence for this default would be:

  (a) ISVNClient.username() (--username-option)
  (2) "user@" from URL
  (3) system user (as currently)

(B) rework UserPasswordCallback to include the accessed URL, like:

  UserPasswordCallback.prompt(String realm, String username, String url)

(B) will allow to parse the user@ from the specified URL and has the
additional advantage that the credentials prompt will also be able to
display for which URL credentials are required. This can be helpful to
design a clearer "Login" dialog.

Taken as a whole, I'd appreciate a more general review of
UserPasswordCallback which is currently hard to implement for a GUI
client: e.g. to provide better support for SSL, more specific methods
than askQuestion with a single String-parameter would be needed. I can
post a proposal, if this will be helpful.

Thanks for your consideration.

-Marc
Received on 2014-02-06 15:28:00 CET

This is an archived mail posted to the Subversion Dev mailing list.

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