added a convenience method
Using the latest and greatest
Ensure that resolveDependencyJar works for NetBeans compile-on-save (and possibly other IDE’s similar features) even when plugin dependencies are snapshots (possibly in the reactor).
Merge branch 'master' of git://github.com/jenkinsci/jenkins
Revert "Using the latest and greatest"

This reverts commit 816f9d02e6058d807f04a2b560f95ee5b17deefc.
Revert "Using the latest and greatest"

This reverts commit 816f9d02e6058d807f04a2b560f95ee5b17deefc.
[JENKINS-11643]

An unexpected failure in processing remember me cookie should be handled
gracefully. In particular, possibly problematic cookie should be
removed, or else the browser will keep bombarding the server with the
same cookie, and will never be able to get through.

It's much better to just drop the cookie.
Merge REMERGE_HEAD into HEAD
Merge pull request #1154 from christ66/exposeRun

Expose the computer runs and timestamp to api.
added a convenience method
added a convenience method.
[JENKINS-20064]

Jenkins now remembers the authorities (read group memberships) that the user had carried when he/she last time interactively logged in.
This information is exposed via User.impersonate(), which is used when using Jenkins SSH, Jenkins CLI, or access via API tokens.

Previously this was impossible for a subset of SecurityRealms that does not allow us to read group membership information without
successful login (such as Active Directory, OpenID, etc.)

For security reasons, if the backend determines that the user does not exist (as opposed to the backend who cannot tell if the user
exists or not), then the impersonation will fail.

I need to check AD plugin is reporting a failure correctly in this case, before marking as JENKINS-20064 fixed.
Using latest and greatest (take 2
User.impersonate() now does the loadUserDetailsByName call.

So ApiTokenFilter no longer needs to do that.
Moving impersonation logic once again.

I think the cleanest place to do this is as a filter of UserDetailsService.

The problem is that SecurityRealm defines loadUserByName method, which AbstractPasswordBasedSecurityRealm overrides
Doing impersonation here as well.

See javadoc for discussion why this possibly redundant use is desirable
NPE fix
added another test for the basic remember-me flow
Merge branch 'master' of github.com:jenkinsci/jenkins
a convenience method