On Tuesday, March 18, 2014 12:44:45 PM UTC-7, RjOllos wrote: > > On Friday, February 14, 2014 9:29:26 PM UTC-8, ilewismsl wrote: >> >> On our system we have >> >> ignore_auth_case = true >> >> In general, this works without issue, but recently many users have seen >> the ticket.commit_updater fail, while it used to work for them. But, for me >> it has been working and I have been unable to see the problem under my user >> until today. >> >> I have just isolated the difference between the times that worked for me >> and the failures I had today. My user on the system is ian. And, in the >> test commit messages that worked that is how the change set sees my users >> name. On the other hand, change sets by the users who have seen the >> commit_updater fail, show their user names in all upper case. >> >> Today, for reasons I do not yet understand, and probably having something >> to do with Subversion, the changesets see me as IAN. And, for those change >> sets, and only those change sets, the commit_updater fails, just as it does >> for the other users who reported the failure to me. >> >> Extract of relevant lines from the log where my commits failed to update >> a ticket (I do not have logs for other failures, but I would bet they would >> look the same): >> 2014-02-14 20:47:22,622 Trac[commit_updater] DEBUG: Updating ticket >> #1113 >> 2014-02-14 20:47:22,622 Trac[perm] DEBUG: No policy allowed IAN >> performing TICKET_APPEND on <Resource u'ticket:1113'> >> 2014-02-14 20:47:22,622 Trac[commit_updater] INFO: IAN doesn't have >> TICKET_APPEND permission for #1113 >> >> To me, this sounds like a defect in the authorization on change sets from >> the repository when ignore_auth_case = true. The system should be >> authorizing ignoring case, but it clearly is not doing that. Should I log a >> defect ticket on Trac? >> > > Which protocol do you use to interact with Subversion?: HTTP/S, SVN over > SSH, ... > > How is the username displayed for the rev associated with the log message > you show, when inspected through the SVN command line client? Is the > username in uppercase or lowercase? >
My previous comment was based on my understanding that you don't know why the Subversion username is appearing in all uppercase characters since you have authenticated using a username with lowercase characters. Presumably that is a Subversion issue, as you've suggested. It would be nice to know what the command line client displays for the changeset metadata though. You are also wondering why the [trac] ignore_auth_case parameter is not being respected in CommitTicketUpdater. The effect of the ignore_auth_case parameter is to convert a username to lowercase when a Request object is constructed. Usually `PermissionCache` is constructed using `req.authname` for the `username` parameter: `PermissionCache(self.env, req.authname)`, and that PermissionCache is used to grant/deny authorization. In `CommitTicketUpdater` we aren't working with a `Request` object, but to get the same effect we can convert the author parameter to lowercase here: http://trac.edgewall.org/browser/tags/trac-1.0.1/tracopt/ticket/commit_updater.py?marks=211#L209 However, that would leave the author of the ticket comment in its case-sensitive form. <https://lh5.googleusercontent.com/-NMpt-nWcKq4/UyjaVujO40I/AAAAAAAABMc/498Bc7i_c90/s1600/Screenshot+from+2014-03-18+16%3A42%3A19.png> To work around that, we could replace the author of the Changeset object with its lower case form, but it should also be realized that the case-sensitivity of the username will be reflected anywhere the Subversion changeset username is displayed, for example on the Repository Browser page: <https://lh5.googleusercontent.com/-zqHgAgEL98A/UyjaeaffHZI/AAAAAAAABMk/4zUXYxJ85wY/s1600/Screenshot+from+2014-03-18+16%3A32%3A48.png> Side note: This relates back to my question about what you see in the SVN changeset messages. Do you see the username in uppercase characters when viewing the changeset messages through your SVN client, and when viewing those revisions in the repository browser? If we wish to optionally treat all usernames from the SVN repository as lowercase, that issue would need to be dealt with in the Subversion FS wrapper: http://trac.edgewall.org/browser/tags/trac-1.0.1/tracopt/versioncontrol/svn/svn_fs.py?marks=929#L918 We could have an option to coerce all author names coming from Subversion changesets to lower case (effectively treating those usernames the same as ignore_auth_case). I think that would probably give us consistent behavior throughout Trac, but I'd like to get some more feedback from the Trac devs on that proposed change. An alternative is that you could just make your Subversion authorization mechanism to be case-sensitive, but I guess we need to get to the bottom of why that username is unexpectedly appearing in all uppercase. -- You received this message because you are subscribed to the Google Groups "Trac Development" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/trac-dev. For more options, visit https://groups.google.com/d/optout.
