Commit Graph
17976 Commits
Author SHA1 Message Date
Kohsuke Kawaguchi 0db32ecaa1 Clarifying assertions that they are trying to test. 2014-03-14 14:42:51 -07:00
Kohsuke Kawaguchi bd8234cceb Fixing a test failure.
The intent of this test is to make sure that a floating User object without any storage returns false from canDelete() method.
The earlier change made User.impersonate() to actually check if the user is a valid, so to make this test case work where it does
"user.impersonate" and "user2.impersonate2", I'm creating valid accounts for these two users.

Now what that means is that user2 is no longer a floating flyweight storage-less User, so it breaks the assumption of the
"User should not be able to delete because he is not saved." assertion.

To make this test case work, I'm introducing the 3rd user that is storage-less, and using it for the test.
2014-03-14 14:39:27 -07:00
Jesse Glick 17c4c1f507 [FIXED JENKINS-22131] Merged deconstructing-AbstractProject branch from #1146. 2014-03-14 13:33:44 -04:00
Jesse Glick 2b6726290d Merge branch 'deconstructing-AbstractProject' 2014-03-14 13:29:11 -04:00
Kohsuke Kawaguchi f04b0e011a User.impersonate now requires that the user be a valid user.
These tests weren't using a SecurityRealm that recognizes these user names
2014-03-14 10:17:36 -07:00
Kohsuke Kawaguchi 2a78c10b94 Updating tests to fix more regressions 2014-03-14 10:17:36 -07:00
Jesse Glick 28710f7874 Reverting #1154 (superseding #1159).
There seems to be no way to export this over the REST API without incurring serious performance penalties.
2014-03-14 09:57:05 -04:00
Jesse Glick 8da19c833c Merge pull request #1152 from daniel-beck/BuildTrigger_terminology
Fix terminology used in BuildTrigger conditions
2014-03-14 09:36:45 -04:00
Harald Albers a77b96a113 Merge pull request #1158 from phoenix384/patch-1
Added some missing German translations
2014-03-14 09:22:49 +01:00
Kohsuke Kawaguchi 38ae112093 LastGrantedAuthoritiesProperty was missing a descriptor 2014-03-13 15:42:25 -07:00
Kohsuke Kawaguchi 16d0bc3fa9 More test fixes 2014-03-13 15:19:44 -07:00
phoenix384 5827f6069d Added some missing German translations 2014-03-13 22:32:41 +01:00
phoenix384 c25c223ace Added some missing German translations 2014-03-13 22:25:53 +01:00
Kohsuke Kawaguchi 664f7e3400 More test fixes 2014-03-13 13:31:04 -07:00
Kohsuke Kawaguchi e400bc7d94 Working toward fixing regressions.
So far none of them are real regressions but just that I needed to update tets
2014-03-13 12:48:27 -07:00
Kohsuke Kawaguchi ddf391cfec Updating test to fix failures.
Now that User.impersonate() actually checks if the user is valid, User.get("user").impersonate() is expected to fail.
Use a DummySecurityRealm to make this user a valid user.
2014-03-13 12:48:27 -07:00
Jesse Glick 5a01c0b7c5 Merge branch 'master' into deconstructing-AbstractProject 2014-03-13 10:37:21 -04:00
Kohsuke Kawaguchi 80b1cf9f8b Remember Me option doesn't always show. 2014-03-12 20:56:27 -07:00
Kohsuke Kawaguchi ce7e6390ee Adding the reload job functionality 2014-03-12 18:18:17 -07:00
Kohsuke Kawaguchi c0ed4b82fd doc improvement 2014-03-12 18:01:55 -07:00
Kohsuke Kawaguchi 5a28378cd9 a convenience method 2014-03-12 18:01:55 -07:00
Kohsuke Kawaguchi b478ca8904 Merge branch 'master' of github.com:jenkinsci/jenkins 2014-03-11 16:32:16 -07:00
Kohsuke Kawaguchi b078ac62f5 added another test for the basic remember-me flow 2014-03-11 16:22:40 -07:00
Kohsuke Kawaguchi accc0e59d3 NPE fix 2014-03-11 16:15:18 -07:00
Kohsuke Kawaguchi a4e29ae0df Doing impersonation here as well.
See javadoc for discussion why this possibly redundant use is desirable
2014-03-11 16:11:14 -07:00
Kohsuke Kawaguchi 27d208b0a9 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
2014-03-11 15:55:17 -07:00
Kohsuke Kawaguchi bded790f46 User.impersonate() now does the loadUserDetailsByName call.
So ApiTokenFilter no longer needs to do that.
2014-03-11 15:36:46 -07:00
Kohsuke Kawaguchi b173e8d403 Using latest and greatest (take 2 2014-03-11 15:01:06 -07:00
Kohsuke Kawaguchi 0e339d7a45 [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.
2014-03-11 14:55:25 -07:00
Kohsuke Kawaguchi 86fcc4733d added a convenience method. 2014-03-11 14:21:46 -07:00
Kohsuke Kawaguchi 983ee33df1 added a convenience method 2014-03-11 14:12:27 -07:00
Steven Christou e1272b5859 Merge pull request #1154 from christ66/exposeRun
Expose the computer runs and timestamp to api.
2014-03-11 13:52:50 -07:00
CloudBees DEV@Cloud f488ba8cbb Merge REMERGE_HEAD into HEAD 2014-03-11 19:39:52 +00:00
Kohsuke Kawaguchi 2dbd6eca7f [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.
2014-03-11 12:17:11 -07:00
Kohsuke Kawaguchi 3b477a62ed Revert "Using the latest and greatest"
This reverts commit 816f9d02e6.
2014-03-11 11:42:31 -07:00
Jesse Glick 967a9aae5c Revert "Using the latest and greatest"
This reverts commit 816f9d02e6.
builds/62 changes/62
2014-03-11 14:21:10 -04:00
Jesse Glick fb19139082 Merge branch 'master' of git://github.com/jenkinsci/jenkins 2014-03-11 14:20:38 -04:00
Jesse Glick fb0ad71b71 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). changes/61 2014-03-11 14:15:26 -04:00
Kohsuke Kawaguchi 816f9d02e6 Using the latest and greatest 2014-03-11 10:08:06 -07:00
Kohsuke Kawaguchi 5b81675c6d added a convenience method 2014-03-11 09:22:27 -07:00
Jesse Glick b39a779444 Introduced RunMixIn so that Run itself does not have to deal with the details. 2014-03-11 11:11:21 -04:00
Jesse Glick 8f23ee87a3 Renamed type variables for consistency with the names used in Job/Run. 2014-03-11 10:14:46 -04:00
Jesse Glick c3df857cf0 Replaced job field with asJob(). 2014-03-11 10:10:18 -04:00
Jesse Glick 71a29a7bac Merge branch 'master' into deconstructing-AbstractProject 2014-03-11 09:36:42 -04:00
Oliver Gondža 000b93fe70 Merge pull request #1147 from olivergondza/expose-key-reading
Expose PrivateKeyProvider
2014-03-11 12:17:02 +01:00
Olivier Lamy 0d3819bb91 Merge pull request #1155 from msrb/logging
Switch to java.util.logging on few places
2014-03-11 21:20:38 +11:00
Michal Srb 86ad82227c Switch to java.util.logging on few places 2014-03-11 07:57:52 +01:00
christ66 dd27df6805 Add project name and result for run api 2014-03-10 17:54:47 -07:00
Steven Christou a4c4ed5fda Merge pull request #1143 from christ66/JENKINS-21969
[FIXED JENKINS-21969] Performance issue with search box
2014-03-10 17:47:54 -07:00
Oliver Gondža 63ceab84a5 Test PrivateKeyProvider 2014-03-10 22:21:50 +01:00