Compare commits

..
2342 Commits
Author SHA1 Message Date
keycloak-bot 46a6c0e002 Set version to 1.9.5.Final 2016-05-26 17:12:20 +00:00
Stian Thorgersen 6bec306173 Merge pull request #2893 from stianst/1.9.x
Ignore temperamental test
2016-05-26 19:11:22 +02:00
Stian Thorgersen 21e0f600c0 Ignore temperamental test 2016-05-26 19:10:23 +02:00
Stian Thorgersen 3ab8917e01 Merge pull request #2892 from stianst/1.9.x
[KEYCLOAK-2894] - Fixing saml signature validation
2016-05-26 17:01:04 +02:00
Pedro Igor 11cc678296 [KEYCLOAK-2894] - Fixing saml signature validation 2016-05-26 15:58:01 +02:00
Stian Thorgersen 7428d969f0 Merge pull request #2887 from ssilvert/1.9.x-migrate-events
KEYCLOAK-2912 Migrate events package to new testsuite
2016-05-26 15:01:52 +02:00
Stian Thorgersen 179dde5f55 Merge pull request #2890 from stianst/1.9.x
Fixes displaying message on login using base theme
2016-05-26 09:50:43 +02:00
Fernando Mora 07369b7e1a Fixes displaying message on login using base theme
Using base theme produces an error when login page tries to display a message.
The following properties that are not defined in base theme (only in keycloak theme) are being called without default_value operator "!"

* Steps to Reproduce:
1. Set `base` theme as `Login Theme`
2. Sign out
3. Try to sign in using and invalid username/password

* Expected behaviour:
  * Message `Invalid username or password.`is shown
* Actual behavior:
  * Bank page is shown and following stackatrace in logs:
```
15:58:19,575 ERROR [freemarker.runtime] (default task-9) Error executing FreeMarker template: freemarker.core.InvalidReferenceException: The following has evaluated to null or missing:
==> properties.kcFeedbackErrorIcon  [in template "template.ftl" at line 67, column 76]

----
Tip: It's the step after the last dot that caused this error, not those before it.
----
Tip: If the failing expression is known to be legally refer to something that's sometimes null or missing, either specify a default value like myOptionalVar!myDefault, or use <#if myOptionalVar??>when-present<#else>when-missing</#if>. (These only cover the last step of the expression; to cover the whole expression, use parenthesis: (myOptionalVar.foo)!myDefault, (myOptionalVar.foo)??
----

----
FTL stack trace ("~" means nesting-related):
	- Failed at: ${properties.kcFeedbackErrorIcon}  [in template "template.ftl" in macro "registrationLayout" at line 67, column 74]
	- Reached through: @layout.registrationLayout displayInf...  [in template "login.ftl" at line 2, column 1]
----
	at freemarker.core.InvalidReferenceException.getInstance(InvalidReferenceException.java:131)
	at freemarker.core.EvalUtil.coerceModelToString(EvalUtil.java:355)
	at freemarker.core.Expression.evalAndCoerceToString(Expression.java:82)
	at freemarker.core.DollarVariable.accept(DollarVariable.java:41)
	at freemarker.core.Environment.visit(Environment.java:324)
	at freemarker.core.MixedContent.accept(MixedContent.java:54)
	at freemarker.core.Environment.visitByHiddingParent(Environment.java:345)
	at freemarker.core.ConditionalBlock.accept(ConditionalBlock.java:48)
	at freemarker.core.Environment.visit(Environment.java:324)
	at freemarker.core.MixedContent.accept(MixedContent.java:54)
	at freemarker.core.Environment.visitByHiddingParent(Environment.java:345)
	at freemarker.core.ConditionalBlock.accept(ConditionalBlock.java:48)
	at freemarker.core.Environment.visit(Environment.java:324)
	at freemarker.core.MixedContent.accept(MixedContent.java:54)
	at freemarker.core.Environment.visit(Environment.java:324)
	at freemarker.core.Macro$Context.runMacro(Macro.java:184)
	at freemarker.core.Environment.invoke(Environment.java:701)
	at freemarker.core.UnifiedCall.accept(UnifiedCall.java:84)
	at freemarker.core.Environment.visit(Environment.java:324)
	at freemarker.core.MixedContent.accept(MixedContent.java:54)
	at freemarker.core.Environment.visit(Environment.java:324)
	at freemarker.core.Environment.process(Environment.java:302)
	at freemarker.template.Template.process(Template.java:325)
	at org.keycloak.theme.FreeMarkerUtil.processTemplate(FreeMarkerUtil.java:61)
	at org.keycloak.forms.login.freemarker.FreeMarkerLoginFormsProvider.createResponse(FreeMarkerLoginFormsProvider.java:314)
	at org.keycloak.forms.login.freemarker.FreeMarkerLoginFormsProvider.createLogin(FreeMarkerLoginFormsProvider.java:431)
	at org.keycloak.authentication.authenticators.browser.AbstractUsernameFormAuthenticator.invalidUser(AbstractUsernameFormAuthenticator.java:58)
	at org.keycloak.authentication.authenticators.browser.AbstractUsernameFormAuthenticator.invalidUser(AbstractUsernameFormAuthenticator.java:87)
	at org.keycloak.authentication.authenticators.browser.AbstractUsernameFormAuthenticator.validateUserAndPassword(AbstractUsernameFormAuthenticator.java:141)
	at org.keycloak.authentication.authenticators.browser.UsernamePasswordForm.validateForm(UsernamePasswordForm.java:56)
	at org.keycloak.authentication.authenticators.browser.UsernamePasswordForm.action(UsernamePasswordForm.java:49)
	at org.keycloak.authentication.DefaultAuthenticationFlow.processAction(DefaultAuthenticationFlow.java:84)
	at org.keycloak.authentication.DefaultAuthenticationFlow.processAction(DefaultAuthenticationFlow.java:75)
	at org.keycloak.authentication.AuthenticationProcessor.authenticationAction(AuthenticationProcessor.java:756)
	at org.keycloak.services.resources.LoginActionsService.processFlow(LoginActionsService.java:359)
	at org.keycloak.services.resources.LoginActionsService.processAuthentication(LoginActionsService.java:341)
	at org.keycloak.services.resources.LoginActionsService.authenticateForm(LoginActionsService.java:386)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:498)
	at org.jboss.resteasy.core.MethodInjectorImpl.invoke(MethodInjectorImpl.java:139)
	at org.jboss.resteasy.core.ResourceMethodInvoker.invokeOnTarget(ResourceMethodInvoker.java:295)
	at org.jboss.resteasy.core.ResourceMethodInvoker.invoke(ResourceMethodInvoker.java:249)
	at org.jboss.resteasy.core.ResourceLocatorInvoker.invokeOnTargetObject(ResourceLocatorInvoker.java:138)
	at org.jboss.resteasy.core.ResourceLocatorInvoker.invoke(ResourceLocatorInvoker.java:101)
	at org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:395)
	at org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:202)
	at org.jboss.resteasy.plugins.server.servlet.ServletContainerDispatcher.service(ServletContainerDispatcher.java:221)
	at org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.service(HttpServletDispatcher.java:56)
	at org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.service(HttpServletDispatcher.java:51)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:790)
	at io.undertow.servlet.handlers.ServletHandler.handleRequest(ServletHandler.java:85)
	at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:129)
	at org.keycloak.services.filters.KeycloakSessionServletFilter.doFilter(KeycloakSessionServletFilter.java:88)
	at io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:60)
	at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:131)
	at io.undertow.servlet.handlers.FilterHandler.handleRequest(FilterHandler.java:84)
	at io.undertow.servlet.handlers.security.ServletSecurityRoleHandler.handleRequest(ServletSecurityRoleHandler.java:62)
	at io.undertow.servlet.handlers.ServletDispatchingHandler.handleRequest(ServletDispatchingHandler.java:36)
	at org.wildfly.extension.undertow.security.SecurityContextAssociationHandler.handleRequest(SecurityContextAssociationHandler.java:78)
	at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43)
	at io.undertow.servlet.handlers.security.SSLInformationAssociationHandler.handleRequest(SSLInformationAssociationHandler.java:131)
	at io.undertow.servlet.handlers.security.ServletAuthenticationCallHandler.handleRequest(ServletAuthenticationCallHandler.java:57)
	at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43)
	at io.undertow.security.handlers.AbstractConfidentialityHandler.handleRequest(AbstractConfidentialityHandler.java:46)
	at io.undertow.servlet.handlers.security.ServletConfidentialityConstraintHandler.handleRequest(ServletConfidentialityConstraintHandler.java:64)
	at io.undertow.security.handlers.AuthenticationMechanismsHandler.handleRequest(AuthenticationMechanismsHandler.java:60)
	at io.undertow.servlet.handlers.security.CachedAuthenticatedSessionHandler.handleRequest(CachedAuthenticatedSessionHandler.java:77)
	at io.undertow.security.handlers.NotificationReceiverHandler.handleRequest(NotificationReceiverHandler.java:50)
	at io.undertow.security.handlers.AbstractSecurityContextAssociationHandler.handleRequest(AbstractSecurityContextAssociationHandler.java:43)
	at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43)
	at org.wildfly.extension.undertow.security.jacc.JACCContextIdHandler.handleRequest(JACCContextIdHandler.java:61)
	at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43)
	at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43)
	at io.undertow.servlet.handlers.ServletInitialHandler.handleFirstRequest(ServletInitialHandler.java:284)
	at io.undertow.servlet.handlers.ServletInitialHandler.dispatchRequest(ServletInitialHandler.java:263)
	at io.undertow.servlet.handlers.ServletInitialHandler.access$000(ServletInitialHandler.java:81)
	at io.undertow.servlet.handlers.ServletInitialHandler$1.handleRequest(ServletInitialHandler.java:174)
	at io.undertow.server.Connectors.executeRootHandler(Connectors.java:202)
	at io.undertow.server.HttpServerExchange$1.run(HttpServerExchange.java:793)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
	at java.lang.Thread.run(Thread.java:745)
```
2016-05-26 08:40:35 +02:00
Marek Posolda 3db1d28a5a Merge pull request #2888 from mposolda/1.9.x
Admin events fixes and more tests
2016-05-25 23:50:47 +02:00
mposolda 8b771e5ce6 KEYCLOAK-3006 Fix admin event inconsistencies related to roles (points 1,3,4,15,16 from JIRA) 2016-05-25 22:44:32 +02:00
mposolda cdbe4e2423 KEYCLOAK-3006 Fix admin event inconsistencies (points 2,5-14 from JIRA) 2016-05-25 22:44:32 +02:00
Thomas Darimont a58595e210 KEYCLOAK-2947: Include group representation for GroupMembership changes in AdminEvents
We now include the full group representation in AdminEvents
for Group Membership changes.
This enables EventListener to propagate potential role / attribute
chnages based on the removal / addition of the group.
2016-05-25 22:44:32 +02:00
mposolda 84d543b232 KEYCLOAK-3003 Support for admin events in AuthenticationManagementResource 2016-05-25 22:44:32 +02:00
Stan Silvert 8fba58c7a7 KEYCLOAK-2912 Migrate events package to new testsuite 2016-05-25 15:52:49 -04:00
Stian Thorgersen 4f3764371a Merge pull request #2880 from stianst/KEYCLOAK-3034-1.9
KEYCLOAK-3034 NullPointerException when log in via Twitter
2016-05-25 13:44:03 +02:00
Stian Thorgersen 964fabb5f1 Merge pull request #2879 from stianst/KEYCLOAK-3021-1.9
KEYCLOAK-3021
2016-05-25 10:05:44 +02:00
Stian Thorgersen 5679946ff3 Merge pull request #2883 from stianst/1.9.x
KEYCLOAK-3029
2016-05-25 09:17:10 +02:00
Stian Thorgersen 13f1d742da KEYCLOAK-3029 2016-05-25 08:56:42 +02:00
Stian Thorgersen a9691844bc KEYCLOAK-3034 NullPointerException when log in via Twitter 2016-05-25 08:11:21 +02:00
Thomas Darimont 34f1e8b74b KEYCLOAK-3021: Add Realm Display Name to the label part of the otpauth URI.
Due to the  removal of the realm-displayname as a result of changes made for KEYCLOAK-2410
 the otpauth URI no longer included the realm display name as a hint for the user to which system an
 authenticator belongs to.

We now ensure that the realm display name is again part of the label component of the otpauth URI.
This enables a user to better distinguish between user accounts for different systems.
2016-05-25 07:29:55 +02:00
Stian Thorgersen 5da837abf7 Merge pull request #2876 from abstractj/KEYCLOAK-3023-1.9.x
OAuthRedirectUriTest.testLocalhost fails on wildfly
2016-05-25 07:25:27 +02:00
Stian Thorgersen acd9dc4b82 Merge pull request #2874 from vramik/KEYCLOAK-3024-1.9.x
KEYCLOAK-3024 support for smoke test - clean start domain mode
2016-05-25 07:24:16 +02:00
Stian Thorgersen e349f4734b Merge pull request #2860 from ssilvert/1.9.x-migrate-i18n
KEYCLOAK-2913 Migrate i18n package to new testsuite
2016-05-25 07:23:08 +02:00
Stian Thorgersen eb324d3516 Merge pull request #2877 from stianst/1.9.x
KEYCLOAK-3020 Fix migration docs
2016-05-25 06:51:23 +02:00
Stian Thorgersen 7a3a0469b4 KEYCLOAK-3020 Fix migration docs 2016-05-25 06:50:12 +02:00
Bruno Oliveira f3f2fb1ae1 OAuthRedirectUriTest.testLocalhost fails on wildfly 2016-05-24 07:28:08 -03:00
Stan Silvert d27beb5688 KEYCLOAK-2913 Switch to use xpath for finding links instead of adding an
id.
2016-05-23 09:19:18 -04:00
Stian Thorgersen 4db7e8b964 Merge pull request #2872 from stianst/KEYCLOAK-3008-1.9
KEYCLOAK-3008 Upload Realm Keys doesn't work
2016-05-23 14:01:24 +02:00
Stian Thorgersen 7a365329c9 Merge pull request #2868 from stianst/KEYCLOAK-3020-1.9
KEYCLOAK-3020
2016-05-23 13:59:15 +02:00
Vlasta Ramik 6f9c46488b support for smoke test - clean start domain mode 2016-05-23 13:17:20 +02:00
Stian Thorgersen 06ab9c9dcf Merge pull request #2870 from stianst/KEYCLOAK-2851-1.9
KEYCLOAK-2851 InitialAccessTokenTest#createExpired fails occasionally
2016-05-23 12:04:26 +02:00
Stian Thorgersen 429bae62ec Merge pull request #2849 from wyvie/1.9.x
KEYCLOAK-3000: fixed the saml brokering tests - 1.9.x
2016-05-23 11:23:13 +02:00
Stian Thorgersen 8024f71799 KEYCLOAK-3020
Increase default password hashing intervals to 20K
2016-05-23 11:21:01 +02:00
Stian Thorgersen 2a9548d27b KEYCLOAK-3008 Upload Realm Keys doesn't work 2016-05-23 10:34:54 +02:00
Stian Thorgersen 8f11d08aa2 KEYCLOAK-2851 InitialAccessTokenTest#createExpired fails occasionally 2016-05-23 09:33:58 +02:00
Stian Thorgersen 1085a4c9f6 Merge pull request #2863 from mhajas/fixOfflineServlets-1.9.x
KEYCLOAK-3025 Fix offline servlet adapter tests and refactoring
2016-05-23 08:41:40 +02:00
Stian Thorgersen 05b2fbb6da Merge pull request #2861 from mhajas/fixSSLOnWildfly
KEYCLOAK-3022 Fix ssl adapter tests on wildfly
2016-05-23 08:40:10 +02:00
Stian Thorgersen d263f0af51 Merge pull request #2857 from vmuzikar/KEYCLOAK-3013-1.9.x
KEYCLOAK-3013 Fix Upload Keystore tests in ClientAuthSignedJWTTest
2016-05-23 08:37:17 +02:00
mhajas bf18c88655 Fix offline servlets and refactoring 2016-05-20 15:00:34 +02:00
mhajas 1747368f2f Fix ssl adapter tests on wildfly 2016-05-20 14:40:03 +02:00
Stan Silvert 04860906e7 KEYCLOAK-2913 Migrate i18n package to new testsuite 2016-05-20 08:25:47 -04:00
Vaclav Muzikar 27b9a880b0 KEYCLOAK-3013 Fix Upload Keystore tests in ClientAuthSignedJWTTest 2016-05-20 10:25:52 +02:00
Stian Thorgersen 9b47a4d1c5 Merge pull request #2848 from raehalme/KEYCLOAK-3016
KEYCLOAK-3016: BasicAuthRequestAuthenticator consumes HttpEntity on errors
2016-05-20 09:14:30 +02:00
Stian Thorgersen 0cac57c64e Merge pull request #2854 from abstractj/OAuthRedirectUriTest-1.9.x
OAuthRedirectUriTest migration
2016-05-20 09:13:03 +02:00
Stian Thorgersen 574e306271 Merge pull request #2847 from ssilvert/1.9.x-migrate-composites
KEYCLOAK-2911 Migrate composites package to new testsuite.
2016-05-20 09:12:32 +02:00
Stian Thorgersen 88d65409aa Merge pull request #2845 from vmuzikar/KEYCLOAK-3011-1.9.x
KEYCLOAK-3011 Fix WelcomePageTest
2016-05-20 09:10:48 +02:00
Stian Thorgersen cc29c9c6ad Merge pull request #2842 from vramik/KEYCLOAK-3010-1.9.x
KEYCLOAK-3010 Add support for smoke test - clean start - standalone mode
2016-05-20 09:07:11 +02:00
Stian Thorgersen 51d3dd2ee0 Merge pull request #2839 from abstractj/KEYCLOAK-2908-1.9.x
KEYCLOAK-2908 - Migration of oidc package
2016-05-20 08:56:39 +02:00
Stian Thorgersen 78188c9865 Merge pull request #2834 from vmuzikar/1.9.x
KEYCLOAK-3004 Fix PKCS12 tests in ClientAuthSignedJWTTest
2016-05-20 08:55:12 +02:00
Stian Thorgersen d04eda276e Merge pull request #2835 from ssilvert/1.9.x-migrate-account
KEYCLOAK-2909 Migrate account package to new testsuite
2016-05-20 08:40:18 +02:00
wyvie 45fcf76db1 KEYCLOAK-3000: fixed the saml brokering tests 2016-05-19 14:31:55 +02:00
Bruno Oliveira e526a22ecb OAuthRedirectUriTest migration 2016-05-18 18:30:04 -03:00
Thomas Raehalme 52c3066fdc KEYCLOAK-3016: BasicAuthRequestAuthenticator now consumes HttpEntity also on errors. 2016-05-18 10:22:56 +03:00
Stan Silvert aab94084d4 KEYCLOAK-2911 Migrate composites package to new testsuite. 2016-05-17 10:29:45 -04:00
Vaclav Muzikar 5e7bdb1742 KEYCLOAK-3011 Fix WelcomePageTest 2016-05-17 14:34:19 +02:00
Vlasta Ramik 0e50bd24df Add support for smoke test - clean start - standalone mode 2016-05-17 13:46:48 +02:00
Bruno Oliveira 1d06fe5253 KEYCLOAK-2908 - Migration of oidc package 2016-05-14 00:51:21 -03:00
Marek Posolda 10e9cc43e3 Merge pull request #2830 from mposolda/1.9.x
KEYCLOAK-2881 Admin events testing
2016-05-13 13:43:44 +02:00
Stan Silvert 58a3d9efc9 KEYCLOAK-2909 Migrate account package to new testsuite 2016-05-13 07:38:12 -04:00
Vaclav Muzikar e152711aec KEYCLOAK-3004 Fix PKCS12 tests in ClientAuthSignedJWTTest
Use smaller keys to avoid illegal key size exception
2016-05-13 13:35:12 +02:00
mposolda 0533bd7e67 KEYCLOAK-2881 Admin events testing 2016-05-13 11:24:09 +02:00
Stian Thorgersen e72e20b6dd Merge pull request #2828 from stianst/1.9.x
Ignore KcSamlBrokerTest
2016-05-13 08:21:40 +02:00
Stian Thorgersen 3aa0a59609 Ignore KcSamlBrokerTest 2016-05-13 08:21:10 +02:00
Stian Thorgersen 5d6ae2583c Merge pull request #2827 from vmuzikar/1.9.x
KEYCLOAK-2995 Revert changes from KEYCLOAK-2989 in JWTClientCredentialsProvider
2016-05-13 07:50:21 +02:00
Stian Thorgersen 4de70b9110 Merge pull request #2824 from mstruk/KEYCLOAK-2993-b
KEYCLOAK-2993 Fix integration-arquillian tests failing with -Pauth-server-wildfly
2016-05-13 07:32:25 +02:00
Stian Thorgersen c0e2f01c45 Merge pull request #2822 from mstruk/KEYCLOAK-2863-b
KEYCLOAK-2863 ClientAttributeCertificateResource
2016-05-12 16:50:42 +02:00
Stian Thorgersen 9047314a1f Merge pull request #2817 from pdrozd/1.9.x
KEYCLOAK-2988 - Fix kerberos tests - able to run with Windows and RHIDM.
2016-05-12 16:43:40 +02:00
Vaclav Muzikar 11351692ac KEYCLOAK-2995 Revert changes from KEYCLOAK-2989 in JWTClientCredentialsProvider 2016-05-12 10:46:43 +02:00
Marko Strukelj a583c7d399 KEYCLOAK-2993 Fix integration-arquillian tests failing with -Pauth-server-wildfly 2016-05-12 09:43:44 +02:00
Stian Thorgersen 3aaecbf0de Merge pull request #2820 from vmuzikar/1.9.x
KEYCLOAK-2989 Extend ClientAuthSignedJWTTest
2016-05-12 06:42:18 +02:00
Marko Strukelj d921c133a7 KEYCLOAK-2863 ClientAttributeCertificateResource 2016-05-11 15:22:04 +02:00
Stian Thorgersen 5dc8e6b8b5 Merge pull request #2816 from abstractj/AuthorizationCodeTest-1.9.x
Migration of AuthorizationCodeTest
2016-05-11 14:09:31 +02:00
Bruno Oliveira 4f993eb1cc Migration of AuthorizationCodeTest 2016-05-11 06:22:44 -03:00
Stian Thorgersen cdea5829e3 Merge pull request #2814 from abstractj/OAuthGrantTest-1.9.x
OAuthGrantTest migration
2016-05-11 06:58:00 +02:00
Stian Thorgersen 4045c4c683 Merge pull request #2780 from wyvie/1.9.x
KEYCLOAK-2971: Added basic oidc broker testing to the new testsuite - 1.9.x
2016-05-11 06:57:32 +02:00
wyvie e85f065b6a KEYCLOAK-2990: added test for single logout to broker testing (new testsuite) 2016-05-10 15:20:38 +02:00
Vaclav Muzikar ce3319d9fa KEYCLOAK-2989 Extend ClientAuthSignedJWTTest 2016-05-10 13:33:25 +02:00
Pavel Drozd 6362aa8773 KEYCLOAK-2988 - Fix kerberos tests - able to run with Windows and RHIDM. 2016-05-10 11:26:26 +02:00
wyvie 8ef52b35c9 KEYCLOAK-2971: saml provider with signature in broker test 2016-05-10 11:07:58 +02:00
Bruno Oliveira fe8fd76d7c OAuthGrantTest migration 2016-05-09 11:04:52 -03:00
keycloak-bot 2f47d99c98 Set version to 1.9.5.Final-SNAPSHOT 2016-05-09 07:40:39 +00:00
keycloak-bot 5d80e21062 Set version to 1.9.4.Final 2016-05-09 06:29:52 +00:00
Stian Thorgersen 4494cd9ea9 Merge pull request #2811 from stianst/1.9.x
KEYCLOAK-2880 Refactor PermissionTest to not require Java8
2016-05-09 08:28:09 +02:00
Stian Thorgersen 4d3fbbaa32 KEYCLOAK-2880 Refactor PermissionTest to not require Java8 2016-05-09 07:25:39 +02:00
Marek Posolda bad3debfc3 Merge pull request #2808 from mposolda/1.9.x
KEYCLOAK-2862 AuthenticationManagementResource tests
2016-05-06 21:29:26 +02:00
mposolda b8d7c20cd6 KEYCLOAK-2862 AuthenticationManagementResource tests 2016-05-06 20:17:04 +02:00
Marek Posolda 8f28504a50 Merge pull request #2806 from vramik/KEYCLOAK-2936-1.9.x
KEYCLOAK-2936 add app.server.java.home to karaf arquillian.xsl to be able to run fu…
2016-05-06 20:06:27 +02:00
Stian Thorgersen 803ae2cdcd Merge pull request #2805 from stianst/1.9.x
Close admin client after test
2016-05-06 16:27:32 +02:00
wyvie 40d437af57 KEYCLOAK-2971: saml provider without signature in broker test 2016-05-06 16:05:38 +02:00
Vlasta Ramik cc4c2622a2 add app.server.java.home to karaf arquillian.xsl to be able to run fuse tests on jdk7, minor test fix 2016-05-06 15:09:25 +02:00
Stian Thorgersen 26c6b4b624 Close admin client after test 2016-05-06 15:01:15 +02:00
Stian Thorgersen d9fe19c438 Merge pull request #2787 from stianst/1.9.x
KEYCLOAK-2865 Extend coverage of client admin endpoints
2016-05-06 11:13:29 +02:00
Marek Posolda 4c612fbde3 Merge pull request #2769 from vramik/KEYCLOAK-2936-1.9.x
KEYCLOAK-2936 Add app server module and test module for testing fuse6.3, ...
2016-05-06 08:37:28 +02:00
Stian Thorgersen 5531fab517 KEYCLOAK-2865 Extend coverage of client admin endpoints 2016-05-06 08:09:10 +02:00
Marek Posolda c50564388a Merge pull request #2800 from mposolda/1.9.x
KEYCLOAK-2805 KEYCLOAK-2777 Fuse 6.3 support
2016-05-06 08:00:20 +02:00
Stian Thorgersen 16bb58e2c6 Merge pull request #2803 from dbarentine/1.9.x
KEYCLOAK-2973 Persist federated identity on token update
2016-05-06 07:07:44 +02:00
Stian Thorgersen 631ac7bcc9 Merge pull request #2799 from abstractj/OAuthDance-1.9.x
Migration of OAuthDanceClientSessionExtensionTest
2016-05-06 07:06:25 +02:00
Stian Thorgersen e0a0d58853 Merge pull request #2797 from abstractj/RefreshTokenTest-1.9.x
Refresh token test 1.9.x
2016-05-06 07:05:38 +02:00
Stian Thorgersen 73a060adbb Merge pull request #2795 from mstruk/KEYCLOAK-2869-b
KEYCLOAK-2869 IdentityProvidersResource/IdentityProviderResource
2016-05-06 07:04:02 +02:00
Stian Thorgersen 5e699682ae Merge pull request #2793 from ssilvert/1.9.x-migrate-forms
KEYCLOAK-2906 Migrate forms package to new testsuite
2016-05-06 07:00:13 +02:00
Stian Thorgersen 6474db1e3d Merge pull request #2790 from mhajas/SAML-stability-1.9.x
KEYCLOAK-2959 KEYCLOAK-2459 Refactor and improve stability of SAML adapter tests
2016-05-06 06:58:54 +02:00
Stian Thorgersen c7787136c8 Merge pull request #2788 from stianst/KEYCLOAK-2549-1.9
KEYCLOAK-2549 Re-create master admin client if master realm is overwr…
2016-05-06 06:58:16 +02:00
Dane Barentine c02b43685f KEYCLOAK-2973 Persist federated identity on token update 2016-05-05 14:53:12 -07:00
mposolda 47def9efb3 KEYCLOAK-2805 Minor changes - cleanup and docs 2016-05-05 23:16:16 +02:00
Paolo Antinori c789510534 KEYCLOAK-2777 - Examples Fuse. Correct Parent pom reference 2016-05-05 22:10:31 +02:00
Paolo Antinori 26fee3b1c0 KEYCLOAK-2777 - Added PathBasedKeycloakConfigResolver for OSGi + examples 2016-05-05 22:10:22 +02:00
Paolo Antinori bd14f818ab KEYCLOAK-2805 - Update docs for JBoss Fuse 6.3 2016-05-05 22:10:13 +02:00
Paolo Antinori 11d91f1305 KEYCLOAK-2805 - Moved cxf.version up to the main pom 2016-05-05 22:10:03 +02:00
Paolo Antinori 473f4a0a97 KEYCLOAK-2805 - Support for JBoss Fuse 6.3
Upgrade of CXF, Jetty and Pax-Web required to rewrite part of the integration.
2016-05-05 22:09:54 +02:00
Bruno Oliveira e448b92074 Migration of OAuthDanceClientSessionExtensionTest 2016-05-05 15:30:39 -03:00
Bruno Oliveira 00456139c4 Migration of RefreshTokenTest 2016-05-05 15:21:52 -03:00
Bruno Oliveira 3746407657 Replace by ClientManager and make the code less verbose 2016-05-05 15:21:38 -03:00
Marko Strukelj 31683ce776 KEYCLOAK-2869 IdentityProvidersResource/IdentityProviderResource 2016-05-05 17:30:20 +02:00
mhajas ea238834b6 Refactor and improve stability of SAML tests 2016-05-05 12:29:02 +02:00
Marek Posolda 8b9abf551d Merge pull request #2782 from mposolda/1.9.x
Easier MariaDB support in tests
2016-05-05 10:04:41 +02:00
Stian Thorgersen 972145a0dc KEYCLOAK-2549 Re-create master admin client if master realm is overwritten on import 2016-05-05 07:20:23 +02:00
Stian Thorgersen 070d6149d1 Merge pull request #2785 from abstractj/RHSSO-121_1.9.x
RHSSO-121: Offline Tokens
2016-05-05 06:36:03 +02:00
Bruno Oliveira b021a86330 RHSSO-121: Offline Tokens 2016-05-04 22:51:59 -03:00
Stan Silvert a729aaa3bc KEYCLOAK-2906 Migrate forms package to new testsuite 2016-05-04 19:20:03 -04:00
mposolda 820c615769 Easier MariaDB support in tests 2016-05-04 22:08:58 +02:00
wyvie b9142ac6ce KEYCLOAK-2971: Added basic oidc broker testing to the new testsuite 2016-05-04 17:53:37 +02:00
Stian Thorgersen 7dd1406f1b Merge pull request #2777 from stianst/1.9.x
KEYCLOAK-2880 Permissions tests for admin endpoints
2016-05-04 16:54:12 +02:00
Stian Thorgersen 095a08e208 Suppress log output from resteasy during tests 2016-05-04 13:57:40 +02:00
Stian Thorgersen d39669c00b KEYCLOAK-2880 Permissions tests for admin endpoints 2016-05-04 07:32:17 +02:00
Stian Thorgersen 31f0cc2e4b Merge pull request #2775 from mhajas/jsconsole-stability-1.9.x
KEYCLOAK-2916 Improve stability of JS-console
2016-05-04 06:35:06 +02:00
mhajas c8e0529d81 Improve stability of JS-console tests 2016-05-03 15:04:55 +02:00
keycloak-bot 6132f50d34 Set version to 1.9.4.Final-SNAPSHOT 2016-04-28 16:21:32 +00:00
keycloak-bot ea46bb0be3 Set version to 1.9.3.Final 2016-04-28 15:14:56 +00:00
Vlasta Ramik 5ba8191ff2 Add app server module and test module for testing fuse6.3, rename feature in fuse6.2 tests 2016-04-28 14:48:57 +02:00
Stian Thorgersen 7b988d267b Merge pull request #2764 from stianst/1.9.x
KEYCLOAK-2932 KEYCLOAK-2934
2016-04-28 13:50:40 +02:00
Stian Thorgersen 99372d2534 Merge pull request #2762 from mposolda/1.9.x
KEYCLOAK-2903 Document proxy-address-forwarding with reverse proxy/lo…
2016-04-28 13:11:10 +02:00
Stian Thorgersen 508bddc70a KEYCLOAK-2932 KEYCLOAK-2934 2016-04-28 13:06:41 +02:00
Stian Thorgersen 56d95b5414 Merge pull request #2760 from stianst/1.9.x
KEYCLOAK-2933
2016-04-28 13:01:57 +02:00
mposolda 71b9420286 KEYCLOAK-2903 Document proxy-address-forwarding with reverse proxy/loadbalancer setup 2016-04-28 13:01:45 +02:00
Stian Thorgersen 024d64e0e0 KEYCLOAK-2933
RealmTest is failing on WildFly
2016-04-28 12:22:10 +02:00
Stian Thorgersen e719f1af96 Merge pull request #2758 from vramik/KEYCLOAK-2928-1.9.x
KEYCLOAK-2928 Enabled/edited CustomAuthFlowCookieTest
2016-04-28 11:17:56 +02:00
Vlasta Ramik 225aab1fed Enabled/edited CustomAuthFlowCookieTest 2016-04-28 10:22:02 +02:00
Stian Thorgersen fde9e6870f Merge pull request #2757 from stianst/KEYCLOAK-2924-1.9
KEYCLOAK-2924: Fire AdminEvents on user group membership changes.
2016-04-28 10:18:09 +02:00
Thomas Darimont 90a9465caf KEYCLOAK-2924: Fire AdminEvents on user group membership changes.
We now fire AdminEvents if a user joins or leaves a group.
This information can be used to deduce potential role changes
in custom event listeners.
2016-04-28 08:38:17 +02:00
Stian Thorgersen 37a61d79a6 Merge pull request #2754 from ssilvert/1.9.x-migrate-actions
KEYCLOAK-2905 Migrate actions package from old testsuite
2016-04-28 06:44:23 +02:00
Bill Burke cb2fce74a6 Merge pull request #2756 from patriot1burke/1.9.x
add bind addresses to domain template
2016-04-27 22:09:32 -04:00
Bill Burke aaad122cff add bind addresses to domain template 2016-04-27 22:03:13 -04:00
Stan Silvert 269a2e9ba9 KEYCLOAK-2905 Migrate actions package from old testsuite 2016-04-27 14:14:16 -04:00
Bill Burke d5b86bedd6 Merge pull request #2751 from patriot1burke/1.9.x
KEYCLOAK-2922 KEYCLOAK-2920
2016-04-27 11:37:15 -04:00
Bill Burke 790f0fe7f9 Merge pull request #2749 from stianst/1.9.x
KEYCLOAK-2927 Rename add-user script to add-user-keycloak
2016-04-27 11:05:20 -04:00
Bill Burke 8417144677 Merge remote-tracking branch 'remote19/1.9.x' into b_1_9 2016-04-27 10:25:04 -04:00
Bill Burke 277f90e8b0 KEYCLOAK-2922 KEYCLOAK-2920 2016-04-27 10:23:23 -04:00
Stian Thorgersen 9306dc2015 KEYCLOAK-2927 Rename add-user script to add-user-keycloak 2016-04-27 16:17:41 +02:00
Stian Thorgersen e979b96923 Merge pull request #2736 from mhajas/adapter-ssl-1.9.x
KEYCLOAK-2915 Fix adapter ssl tests on EAP/EAP6
2016-04-27 13:50:01 +02:00
Stian Thorgersen 5a362df491 Merge pull request #2735 from vramik/KEYCLOAK-2889-1.9.x
KEYCLOAK-2889 Fix adapter tests for Karaf/Fuse
2016-04-27 13:49:30 +02:00
Stian Thorgersen 1b611fef01 Merge pull request #2746 from stianst/KEYCLOAK-2871
KEYCLOAK-2871 Extend coverage on RealmAdminResource
2016-04-27 13:38:22 +02:00
Marek Posolda 2f7d415cba Merge pull request #2742 from mposolda/1.9.x-loadbalancer
KEYCLOAK-2903 Fix WelcomeResource to not allow requests forwarded fro…
2016-04-27 11:10:48 +02:00
Stian Thorgersen 5e992f6db9 KEYCLOAK-2871 Extend coverage on RealmAdminResource 2016-04-27 10:28:02 +02:00
Marek Posolda 844da0193a Merge pull request #2744 from mposolda/1.9.x
KEYCLOAK-2898 Fix GroupMappersTest on wildfly. Clearing AssertEvents …
2016-04-26 18:01:28 +02:00
mposolda d42b44ee13 KEYCLOAK-2898 Fix GroupMappersTest on wildfly. Clearing AssertEvents events queue before test instead of after 2016-04-26 16:08:10 +02:00
mposolda c3616ecb4d KEYCLOAK-2903 Fix WelcomeResource to not allow requests forwarded from proxy/loadbalancer 2016-04-26 12:01:42 +02:00
mhajas 3a7787b1d7 Fix adapter ssl tests on EAP/EAP6 2016-04-26 09:08:35 +02:00
Stian Thorgersen 47103a040f Merge pull request #2727 from abstractj/RHSSO-106-1.9.x
RHSSO-106: Migration of ResourceOwnerPasswordCredentialsGrantTest
2016-04-25 19:46:15 +02:00
Bruno Oliveira 568140de4a RHSSO-106: Migration of ResourceOwnerPasswordCredentialsGrantTest 2016-04-25 10:15:50 -03:00
Vlasta Ramik 6d2ade5f77 Fix adapter tests for Karaf/Fuse 2016-04-25 15:10:08 +02:00
Marek Posolda 40427a2200 Merge pull request #2733 from mposolda/1.9.x
KEYCLOAK-2900
2016-04-25 15:00:12 +02:00
Stian Thorgersen bb34cfb7d6 Merge pull request #2731 from abstractj/RHSSO-130-1.9.x
RHSSO-130: AccessTokenTest migration
2016-04-25 13:43:05 +02:00
Stian Thorgersen 3fd840515b Merge pull request #2712 from ssilvert/1.9.x-migrate-LoginTest
Migrate LoginTest
2016-04-25 13:40:56 +02:00
mposolda 604a757665 KEYCLOAK-2900 2016-04-25 11:18:56 +02:00
Marek Posolda 107a3f4f11 Merge pull request #2729 from mstruk/KEYCLOAK-2899-b
KEYCLOAK-2899 Tests fail with -Pauth-server-wildfly due to missing logging dependecy
2016-04-22 21:37:54 +02:00
Bruno Oliveira f6fe53a44c RHSSO-130: AccessTokenTest migration 2016-04-22 16:32:50 -03:00
Marko Strukelj 7281c2d8ae KEYCLOAK-2899 Tests fail with -Pauth-server-wildfly due to missing logging dependecy 2016-04-22 19:50:40 +02:00
Marek Posolda bb8bc7f976 Merge pull request #2723 from mstruk/KEYCLOAK-2893-b
KEYCLOAK-2893 Fix TokenIntrospectionTest
2016-04-22 15:16:13 +02:00
Marek Posolda b4ae814567 Merge pull request #2719 from abstractj/RHSSO-108-client-auth-signed-1.9.x
Rhsso 108 client auth signed 1.9.x
2016-04-22 15:07:07 +02:00
Marek Posolda b482396af9 Merge pull request #2720 from mposolda/1.9.x
EYCLOAK
2016-04-22 15:00:49 +02:00
Marko Strukelj 9d9bf3c39b KEYCLOAK-2893 Fix TokenIntrospectionTest 2016-04-22 14:20:53 +02:00
mposolda 01fece902c KEYCLOAK-2878 Added UserFederationLdapConnectionTest 2016-04-22 13:46:58 +02:00
mposolda 663a145bd7 KEYCLOAK-2878 UserFederation mapper testing 2016-04-22 13:46:58 +02:00
Marek Posolda 2417e49f9c Merge pull request #2717 from mstruk/KEYCLOAK-2893-b
KEYCLOAK-2893 Fix TokenIntrospectionTest
2016-04-22 13:42:51 +02:00
Bruno Oliveira b053ce70f9 Inclusion of try/finally suggested by Stian 2016-04-22 08:30:15 -03:00
Bruno Oliveira a6f4588ef2 RHSSO-108: Migration of ClientAuthSignedJWTTest 2016-04-22 08:30:12 -03:00
Marko Strukelj 025df56796 KEYCLOAK-2893 Fix TokenIntrospectionTest 2016-04-22 11:19:54 +02:00
Marek Posolda f75f14141c Merge pull request #2714 from mposolda/1.9.x
UserFederation admin testing
2016-04-22 00:43:32 +02:00
mposolda f966d53f9e Simplified calling of AuthenticationManagementResource.getExecutions() 2016-04-21 22:54:27 +02:00
mposolda 2c25fd3c08 KEYCLOAK-2878 Testing of UserFederation admin REST endpoints 2016-04-21 22:54:17 +02:00
Stan Silvert e671d4429b Migrate LoginTest 2016-04-21 09:43:19 -04:00
Stian Thorgersen 95cf7bdeea Merge pull request #2708 from stianst/KEYCLOAK-2866-1.9
KEYCLOAK-2866 KEYCLOAK-2874 Test role mapping resource
2016-04-21 14:58:13 +02:00
Stian Thorgersen 7f96e0438e KEYCLOAK-2866 KEYCLOAK-2874 Test role mapping resource 2016-04-21 14:22:25 +02:00
Stian Thorgersen 82006f812a Merge pull request #2706 from stianst/KEYCLOAK-2868-1.9
KEYCLOAK-2868 Extend coverage of GroupResource tests
2016-04-21 13:38:16 +02:00
Stian Thorgersen 951fb095fc Merge pull request #2703 from stianst/KEYCLOAK-2838-1.9
KEYCLOAK-2838: Add cookie storage fallback to keycloak.js
2016-04-21 13:37:48 +02:00
Stian Thorgersen 06c1f0a7e9 KEYCLOAK-2868 Extend coverage of GroupResource tests 2016-04-21 11:52:04 +02:00
Stian Thorgersen 4445989f85 Merge pull request #2702 from stianst/KEYCLOAK-2873-1.9
KEYCLOAK-2873 / KEYCLOAK-2875 Test RoleContainerResource
2016-04-21 11:47:46 +02:00
Maximilian Szengel c1156bb053 KEYCLOAK-2838: Add cookie storage fallback to keycloak.js 2016-04-21 11:10:18 +02:00
Stian Thorgersen fc1a7908d6 KEYCLOAK-2873 / KEYCLOAK-2875 Test RoleContainerResource 2016-04-21 10:59:45 +02:00
Stian Thorgersen 70d427acea Merge pull request #2699 from stianst/KEYCLOAK-2864-1.9
KEYCLOAK-2864 Test InitialAccessTokenResource
2016-04-21 10:27:13 +02:00
Stian Thorgersen d299ae9af5 KEYCLOAK-2864 Test InitialAccessTokenResource 2016-04-21 09:44:59 +02:00
Stian Thorgersen f79d7a65fd Merge pull request #2698 from stianst/KEYCLOAK-2872-1.9
KEYCLOAK-2872 Test RoleByIdResource
2016-04-21 09:31:45 +02:00
Stian Thorgersen cff654b784 KEYCLOAK-2872 Test RoleByIdResource 2016-04-21 07:10:25 +02:00
Stian Thorgersen bdbd765e7e Merge pull request #2693 from abstractj/RHSSO-108-1.9.x
RHSSO-108: Client signed token authentication
2016-04-21 06:19:20 +02:00
Stian Thorgersen 61bb2ee660 Merge pull request #2695 from stianst/1.9.x
Ignore failing CustomAuthFlowCookieTest
2016-04-21 06:07:20 +02:00
Stian Thorgersen 2472eef714 Ignore failing CustomAuthFlowCookieTest 2016-04-21 06:06:14 +02:00
Bruno Oliveira 51c87609ae RHSSO-108: Client signed token authentication 2016-04-20 20:47:09 -03:00
Stian Thorgersen 33c8ced3e9 Merge pull request #2691 from stianst/role-assertevents-1.9
Made AssertEvents work with @Rule
2016-04-20 21:44:42 +02:00
Stian Thorgersen 94f1e43be7 Merge pull request #2692 from stianst/KEYCLOAK-2835-1.9
[KEYCLOAK-2835] - Adding SOAP binding to the list of supported Single…
2016-04-20 20:16:26 +02:00
Pedro Igor 13e09d2341 [KEYCLOAK-2835] - Adding SOAP binding to the list of supported SingleSignOnService. 2016-04-20 20:15:30 +02:00
Stian Thorgersen d3fc34752e Made AssertEvents work with @Rule 2016-04-20 20:11:02 +02:00
Stian Thorgersen f8ddecdf2f Merge pull request #2689 from ssilvert/1.9.x
Rename oauthClient to oauth in AbstractKeycloakTst
2016-04-20 19:41:00 +02:00
Stian Thorgersen 53a7025784 Merge pull request #2686 from mposolda/1.9.x
KEYCLOAK-2842 Not possible to add new execution under registration flow
2016-04-20 19:40:41 +02:00
Stian Thorgersen 4f07522953 Merge pull request #2685 from mstruk/assert-events-refactor-b
KEYCLOAK-2755 Refactor testsuite events provider
2016-04-20 19:37:01 +02:00
Stian Thorgersen ad0c9adc03 Merge pull request #2682 from stianst/KEYCLOAK-2861
KEYCLOAK-2861 Test AttackDetectionResource
2016-04-20 19:36:08 +02:00
Stan Silvert 16390ee4b6 Rename oauthClient to oauth in AbstractKeycloakTst 2016-04-20 12:40:10 -04:00
mposolda ec8eee02fe KEYCLOAK-2842 Not possible to add new execution under registration flow 2016-04-20 18:36:35 +02:00
Marko Strukelj db85f77b00 KEYCLOAK-2755 Refactor testsuite events provider 2016-04-20 16:46:42 +02:00
Stian Thorgersen 433fe5944c KEYCLOAK-2861 Test AttackDetectionResource 2016-04-20 16:20:38 +02:00
Stian Thorgersen fb476e5022 Merge pull request #2681 from stianst/KEYCLOAK-2850-1.9
Moved admin tests from endpoint package back to admin package
2016-04-20 15:35:52 +02:00
Stian Thorgersen 29113b9398 Moved admin tests from endpoint package back to admin package 2016-04-20 14:57:15 +02:00
Stian Thorgersen fc0c8e898d Merge pull request #2678 from stianst/KEYCLOAK-2850-1.9
KEYCLOAK-2850 Migrated ImpersonationTest and added builders
2016-04-20 14:48:07 +02:00
Marek Posolda fca9122052 Merge pull request #2676 from mposolda/1.9.x
Client template fixes
2016-04-20 14:13:51 +02:00
Stian Thorgersen f1e5cbf8fc KEYCLOAK-2850 Migrated ImpersonationTest and added builders 2016-04-20 13:52:32 +02:00
mposolda 2a6b25b840 KEYCLOAK-2846 export/import of clientTemplate scopes 2016-04-20 13:22:40 +02:00
mposolda 1c9f4cfb5c KEYCLOAK-2844 Unexpected error when trying to remove clientTemplate in use 2016-04-20 13:20:48 +02:00
Stian Thorgersen 4c7c2a4cd3 Merge pull request #2674 from stianst/1.9.x
KEYCLOAK-2850 Migrated ConcurrencyTest
2016-04-20 12:50:06 +02:00
Stian Thorgersen 110c142a53 Merge pull request #2672 from stianst/KEYCLOAK-2491-1.9
KEYCLOAK-2491 Fix permissions in admin console to match permissions i…
2016-04-20 12:49:31 +02:00
Stian Thorgersen 8c8f2019e9 KEYCLOAK-2850 Migrated ConcurrencyTest 2016-04-20 10:07:49 +02:00
Stian Thorgersen e5557e0cde KEYCLOAK-2491 Fix permissions in admin console to match permissions in admin endpoints 2016-04-20 09:57:31 +02:00
Marek Posolda f4f7488d8a Merge pull request #2669 from mposolda/1.9.x
KEYCLOAK-2850 Migrate RealmTest from old testsuite to new
2016-04-20 09:33:50 +02:00
Stian Thorgersen 7ea27e7c28 Merge pull request #2668 from stianst/KEYCLOAK-2832-1.9
KEYCLOAK-2832
2016-04-20 09:10:51 +02:00
mposolda b14b384777 Remove AbstractAdminTest.assertNames and related methods (as they are available in Assert class) 2016-04-20 08:04:40 +02:00
mposolda 7c284dc843 KEYCLOAK-2850 migrate RealmTest from old testsuite to new 2016-04-20 08:04:40 +02:00
Stian Thorgersen 320e81f11b KEYCLOAK-2832
Authentication failure logs at ERROR level
2016-04-20 07:32:33 +02:00
Stian Thorgersen 350f45ef76 Merge pull request #2650 from mhajas/truststore.1.9.x
KEYCLOAK-2841 Trustore support in adapter tests
2016-04-20 06:56:58 +02:00
Stian Thorgersen 20f7b444bb Merge pull request #2665 from stianst/1.9.x
Migrate pages from old testsuite, make OAuthClient injectable
2016-04-19 22:08:50 +02:00
Stian Thorgersen 3da4b3a6d3 Removed duplicated ClientInitialAccessTest 2016-04-19 20:34:47 +02:00
Stian Thorgersen 37a9f88983 Merge pull request #2663 from vmuzikar/1.9.x
KEYCLOAK-2854 Fix Client Settings Console UI test
2016-04-19 20:32:06 +02:00
Stian Thorgersen d4c82dbd72 Merge pull request #2660 from abstractj/apiutil-removal-1.9.x
Removal of duplicated API Util
2016-04-19 20:31:10 +02:00
Stian Thorgersen 85e2b5eea0 Merge pull request #2647 from tkyjovsk/performance-tests-1.9.x
Added module 'adapters/jboss/remote' with performance tests. 1.9.x
2016-04-19 20:30:23 +02:00
Stian Thorgersen e6cf4afc29 Migrate pages from old testsuite, make OAuthClient injectable 2016-04-19 20:18:09 +02:00
Vaclav Muzikar 26ba12962c KEYCLOAK-2854 Fix Client Settings Console UI test 2016-04-19 18:04:57 +02:00
Marek Posolda e963344f87 Merge pull request #2657 from stianst/KEYCLOAK-2850-1.9
KEYCLOAK-2850 Migrate admin endpoint identity provider test
2016-04-19 16:24:49 +02:00
Bruno Oliveira daf8658568 Removal of duplicated API Util 2016-04-19 10:22:26 -03:00
Marek Posolda 38394a6949 Merge pull request #2655 from mposolda/1.9.x
KEYCLOAK-2849 Admin endpoint tests for client templates
2016-04-19 15:22:14 +02:00
mposolda af34927930 KEYCLOAK-2849 Admin endpoint tests for client templates 2016-04-19 14:36:30 +02:00
Stian Thorgersen fe4fbfca30 KEYCLOAK-2850 Migrate admin endpoint identity provider test 2016-04-19 14:27:53 +02:00
Stian Thorgersen 28de85f8f9 Merge pull request #2653 from stianst/KEYCLOAK-2828-1.9.x
KEYCLOAK-2828
2016-04-19 13:44:12 +02:00
Stian Thorgersen 91817ea333 KEYCLOAK-2828 Refactor contribution and add tests 2016-04-19 13:09:35 +02:00
Thomas Raehalme c285fc1cf7 KEYCLOAK-2828: LoginStatusIframeEndpoint now sets the P3P header.
IE requires a P3P header to be present in <iframe /> response. Otherwise
cookies are forbidden. The value of the header does not seem to matter.
2016-04-19 10:27:17 +02:00
Marek Posolda 45173f4063 Merge pull request #2648 from pdrozd/1.9.x
KEYCLOAK-2839 - kerberos tests migration.
2016-04-18 20:05:33 +02:00
mhajas c4271b30e9 Trustore support in adapter tests + fix tests 2016-04-18 16:12:58 +02:00
Tomas Kyjovsky c7205fa43d Updated version fo adapters/jboss/remote/pom.xml to 1.9.3-Final-SNAPSHOT. 2016-04-18 14:27:14 +02:00
Pavel Drozd 5ac65413f2 KEYCLOAK-2839 - kerberos tests migration. 2016-04-18 14:27:12 +02:00
Tomas Kyjovsky 848c234e06 Added module 'adapters/jboss/remote' with performance tests. 2016-04-18 14:25:13 +02:00
Stian Thorgersen 1b987ff2a5 Merge pull request #2636 from ssilvert/1.9.x-migrate-oauth-client-2
KEYCLOAK-2743: Port OAuthClient to new testsuite
2016-04-18 07:35:09 +02:00
Bill Burke 8c0c80f6af Merge pull request #2645 from patriot1burke/1.9.x
KEYCLOAK-2740
2016-04-15 17:29:46 -04:00
Bill Burke 8d3d80e603 KEYCLOAK-2740 2016-04-15 16:48:38 -04:00
Bill Burke 3df22af3f0 Merge pull request #2606 from vramik/KEYCLOAK-2757-1.9.x
KEYCLOAK-2757 Add tests to cover custom auth flows
2016-04-15 16:27:56 -04:00
Bill Burke 199198ecb5 Merge pull request #2642 from patriot1burke/1.9.x
KEYCLOAK-2584
2016-04-15 16:27:34 -04:00
Bill Burke 6180132486 KEYCLOAK-2584 2016-04-15 15:14:43 -04:00
Bill Burke 7731e74c38 KEYCLOAK-2584 2016-04-15 15:09:42 -04:00
Stan Silvert 15f75a36b5 Move test under 'endpoint' package. 2016-04-15 08:12:58 -04:00
Stan Silvert 37eddc23fd Create TestRealmKeycloakTest as common base class for tests that need
testrealm.json.  Rename admin packaget to endpoint.  Rename legacy package
to match old testsuite.
test suite.
2016-04-15 08:12:22 -04:00
Stan Silvert 7099dc3e51 KEYCLOAK-2743: Port OAuthClient to new testsuite 2016-04-15 08:11:54 -04:00
keycloak-bot cf1c7a319a Set version to 1.9.3.Final-SNAPSHOT 2016-04-14 14:07:48 +00:00
keycloak-bot eb68ef47b1 Set version to 1.9.2.Final 2016-04-14 13:33:01 +00:00
Stian Thorgersen 7f7fb23f32 Merge pull request #2633 from stianst/1.9.x
KEYCLOAK-2825 KEYCLOAK-2826 Remove private for org.keycloak.keycloak-…
2016-04-14 15:30:10 +02:00
Stian Thorgersen 846bc2ca35 KEYCLOAK-2827 ModuleLoadError: org.keycloak.keycloak-core-public:main 2016-04-14 15:21:58 +02:00
Stian Thorgersen ed77589a43 KEYCLOAK-2825 KEYCLOAK-2826 Remove private for org.keycloak.keycloak-adapter-core and org.keycloak.keycloak-adapter-spi modules 2016-04-14 14:40:05 +02:00
Marek Posolda 6ab94ce4e8 Merge pull request #2629 from mposolda/1.9.x
KEYCLOAK-2823 Password policy 'hashAlgorithm' value not correctly sho…
2016-04-14 13:56:06 +02:00
mposolda a5179907ad KEYCLOAK-2823 Password policy 'hashAlgorithm' value not correctly shown in admin console 2016-04-14 13:15:23 +02:00
Marek Posolda 77bbf2afb5 Merge pull request #2626 from mposolda/1.9.x
Migration and mongo fix
2016-04-14 11:48:13 +02:00
mposolda 85b95c5432 KEYCLOAK-2820 Mongo doesn't start on wildfly 2016-04-14 10:41:31 +02:00
mposolda 613a26cd1c KEYCLOAK-2819 Fix realm security header setup after migration 2016-04-14 10:22:14 +02:00
Stian Thorgersen 18cc0fdaf3 Merge pull request #2625 from stianst/1.9.x
KEYCLOAK-2818
2016-04-14 09:14:33 +02:00
Stian Thorgersen 39c0dfeb8f KEYCLOAK-2818
Fix poms not updated by versions plugin
2016-04-14 08:17:05 +02:00
Stian Thorgersen 524ae68224 Fix to cors-example-fix 2016-04-14 07:10:50 +02:00
Bruno Oliveira e63726d51c Fix the broken logout URL 2016-04-14 07:10:33 +02:00
Bruno Oliveira 29c839602f Make the client URL match exactly the same configured at the realm 2016-04-14 07:10:33 +02:00
Stian Thorgersen 1e20cad2ae Merge pull request #2616 from abstractj/minor-fix
There's no such profile for this example
2016-04-14 07:02:47 +02:00
Stian Thorgersen 7feeca8273 Merge pull request #2615 from abstractj/cordova
inappbrowser plugin returns 404 with the current namespace
2016-04-14 06:59:54 +02:00
Bill Burke 9c8d9ceb28 Merge pull request #2622 from patriot1burke/1.9.x
merge adapter-spi and adapter-spi-public
2016-04-13 22:52:22 -04:00
Bill Burke 07a7035398 merge adapter-spi and adapter-spi-public 2016-04-13 22:18:26 -04:00
Stian Thorgersen 6c2f8a8f65 Merge pull request #2612 from abstractj/angular2-example
Example points to wrong KC version
2016-04-13 19:35:06 +02:00
Bruno Oliveira d1bf3c3be6 There's no such profile for this example 2016-04-13 14:10:22 -03:00
Bruno Oliveira edef864ffc inappbrowser plugin returns 404 with the current namespace 2016-04-13 14:05:45 -03:00
Marek Posolda 3effc265c4 Merge pull request #2610 from mposolda/1.9.x
KEYCLOAK-2812 Make testsuite-arquillian working with -Pauth-server-wi…
2016-04-13 16:41:22 +02:00
Bruno Oliveira 41775bf8ef Example points to wrong KC version 2016-04-13 11:07:48 -03:00
mposolda 6c2464e399 KEYCLOAK-2812 Make testsuite-arquillian working with -Pauth-server-wildfly 2016-04-13 16:04:20 +02:00
Marek Posolda 17a7d04de9 Merge pull request #2609 from mposolda/1.9.x
KEYCLOAK-2811 FederationProvidersIntegrationTest.testReadOnly failing…
2016-04-13 13:50:07 +02:00
mposolda b630c5b447 KEYCLOAK-2811 FederationProvidersIntegrationTest.testReadOnly failing on MSAD 2016-04-13 12:40:10 +02:00
Marek Posolda ab69b98766 Merge pull request #2605 from mposolda/1.9.x
KEYCLOAK-2809 NPE when removing role, which is in scope of some Clien…
2016-04-13 12:39:07 +02:00
Vlasta Ramik 41ac0f3b04 Add tests to cover custom auth flows 2016-04-13 12:08:03 +02:00
Stian Thorgersen d78450137e Merge pull request #2603 from stianst/KEYCLOAK-2810-1.9
KEYCLOAK-2810 Added robots.txt and robots meta header
2016-04-13 11:58:23 +02:00
mposolda 1e47e28f20 KEYCLOAK-2809 NPE when removing role, which is in scope of some ClientTemplate 2016-04-13 11:48:04 +02:00
Stian Thorgersen 80a8961878 KEYCLOAK-2810 Added robots.txt and robots meta header 2016-04-13 11:24:19 +02:00
Marek Posolda 95d555ef39 Merge pull request #2598 from mposolda/1.9.x
Fix testsuite with Mongo
2016-04-13 11:06:49 +02:00
Stian Thorgersen 1a8f56f3d1 Merge pull request #2601 from stianst/KEYCLOAK-2804-1.9
KEYCLOAK-2804 Prevent browser from prefilling username/password into …
2016-04-13 10:39:48 +02:00
Stian Thorgersen 4e1059740a KEYCLOAK-2804 Prevent browser from prefilling username/password into non-login form 2016-04-13 10:01:44 +02:00
mposolda 7e225d60fd Fix testsuite with Mongo 2016-04-13 09:54:36 +02:00
Bill Burke b55449b739 Merge pull request #2597 from patriot1burke/1.9.x
KEYCLOAK-2790
2016-04-12 19:45:22 -04:00
Bill Burke 5b298cf43c KEYCLOAK-2790 2016-04-12 18:25:01 -04:00
Bill Burke b56fe48277 Merge pull request #2586 from mhajas/secureDeployment-1.9.x-PR
KEYCLOAK-2199 Add tests for secure deployment
2016-04-12 17:53:34 -04:00
Bill Burke 4c438de595 Merge pull request #2568 from cpitman/proxy-headers-1.9
KEYCLOAK-2791 - Proxy handling for X-Forwarded headers
2016-04-12 17:53:07 -04:00
Bill Burke ea006f1d77 Merge pull request #2588 from vramik/KEYCLOAK-2794-1.9.x
KEYCLOAK-2794 Change undertow-embedded version
2016-04-12 17:52:39 -04:00
Bill Burke cb4e0a9e75 Merge pull request #2595 from patriot1burke/1.9.x
public private api
2016-04-12 17:51:49 -04:00
Bill Burke 7df32ba4cd public/private fixes 2016-04-12 15:19:31 -04:00
Bill Burke 89098b3726 Merge remote-tracking branch 'remote19/1.9.x' into b_1_9 2016-04-12 12:10:04 -04:00
Bill Burke 9e45c2ac4d public/private modules 2016-04-12 12:09:46 -04:00
Stian Thorgersen d4f8f833a2 Merge pull request #2592 from stianst/KEYCLOAK-2807-1.9
KEYCLOAK-2807 Fix server info providers page
2016-04-12 16:18:20 +02:00
Stian Thorgersen e159254cd2 KEYCLOAK-2807 Fix server info providers page 2016-04-12 15:40:22 +02:00
Stian Thorgersen ee090149b9 Merge pull request #2590 from stianst/KEYCLOAK-2799-1.9
KEYCLOAK-2799 Show error for identity brokering login if user is disa…
2016-04-12 14:11:21 +02:00
Stian Thorgersen a22c8c1d8e KEYCLOAK-2799 Show error for identity brokering login if user is disabled 2016-04-12 13:15:21 +02:00
Stian Thorgersen 83ff45ce04 Merge pull request #2584 from stianst/KEYCLOAK-2803-1.9
KEYCLOAK-2803 Fix failure to add execution to client flow
2016-04-12 13:05:07 +02:00
Vlasta Ramik 815e650448 Change undertow-embedded version from snapshot to released version 1.0.0.Alpha2 2016-04-12 09:48:20 +02:00
mhajas 777bdc908f Add tests for secure deployment 2016-04-12 09:16:28 +02:00
Stian Thorgersen 45231b69a7 KEYCLOAK-2803 Fix failure to add execution to client flow 2016-04-12 08:04:54 +02:00
Stian Thorgersen b01f522ace Merge pull request #2582 from stianst/KEYCLOAK-2770-1.9
KEYCLOAK-2770 Close mail transport after sending message
2016-04-12 07:43:58 +02:00
Stian Thorgersen e840766b1f Merge pull request #2571 from pdrozd/1.9.x
KEYCLOAK-2794 - changed version of undertow-embedded.
2016-04-12 07:42:10 +02:00
Stian Thorgersen 4298916013 Merge pull request #2574 from stianst/KEYCLOAK-2700-1.9
KEYCLOAK-2700 Import existing realm fails due to can't delete group
2016-04-12 07:20:03 +02:00
Stian Thorgersen 788bdfb29b KEYCLOAK-2770 Close mail transport after sending message 2016-04-12 07:07:53 +02:00
Marek Posolda 3ec8672a75 Merge pull request #2580 from mposolda/1.9.x
Identity brokering error handling fixes
2016-04-12 00:08:55 +02:00
mposolda fc95067193 KEYCLOAK-2802 NPE during identity broker cancelled from account mgmt 2016-04-11 23:28:59 +02:00
mposolda d14867f785 KEYCLOAK-2801 Redirected to login theme error page after failed social linking from account management 2016-04-11 22:51:05 +02:00
Marek Posolda ffe483ae2d Merge pull request #2578 from mposolda/1.9.x
KEYCLOAK-2769 Better error handling of expired code in IdentityBroker…
2016-04-11 18:56:32 +02:00
mposolda dc2d71489d KEYCLOAK-2769 Better error handling of expired code in IdentityBrokerService 2016-04-11 18:08:10 +02:00
Marek Posolda 42402ee6f4 Merge pull request #2576 from mposolda/1.9.x
KEYCLOAK-2795 Testsuite fails sometimes with NPE in LockServiceFactor…
2016-04-11 10:50:59 +02:00
mposolda f4f95cd096 KEYCLOAK-2795 Testsuite fails sometimes with NPE in LockServiceFactory.getLockService 2016-04-11 10:08:26 +02:00
Stian Thorgersen dafea0cad6 KEYCLOAK-2700 Import existing realm fails due to can't delete group 2016-04-11 09:19:20 +02:00
Stian Thorgersen b5fe63af22 Merge pull request #2570 from stianst/KEYCLOAK-2766-1.9
KEYCLOAK-2766 Add missing id to AuthenticatorConfigRepresentation
2016-04-11 08:35:34 +02:00
Pavel Drozd a48ace4d70 KEYCLOAK-2794 - changed version of undertow-embedded. 2016-04-11 08:34:54 +02:00
Stian Thorgersen 5440688dd9 KEYCLOAK-2766 Add missing id to AuthenticatorConfigRepresentation 2016-04-11 07:43:45 +02:00
Stian Thorgersen b21b548b9c Merge pull request #2560 from vramik/KEYCLOAK-2783
KEYCLOAK-2783 added nexus-staging-maven-plugin
2016-04-11 07:14:50 +02:00
Stian Thorgersen fe44483e60 Merge pull request #2563 from guusdk/1.9.x
KEYCLOAK-2785: Admin client should be able to delete a user.
2016-04-11 07:14:13 +02:00
Stian Thorgersen 12be32f6dc Merge pull request #2559 from mhajas/js-console-stability-1.9.x-PR
KEYCLOAK-2780 Better stability in JSConsole test
2016-04-11 07:12:27 +02:00
Stian Thorgersen 524080b0ae Merge pull request #2557 from mhajas/secure-portal-1.9.x-PR
KEYCLOAK-2779 Fix DemoServletAdpater tests
2016-04-11 07:10:57 +02:00
Stian Thorgersen d8dfc1ca0b Merge pull request #2555 from mhajas/eap6URLs-1.9.x-PR
KEYCLOAK-2778 Fix urls on eap6
2016-04-11 07:09:57 +02:00
Chris Pitman bee7c077b7 KEYCLOAK-2791 - Proxy handling for X-Forwarded headers 2016-04-09 02:22:15 -04:00
Marek Posolda a3abc0296d Merge pull request #2566 from mposolda/1.9.x
KEYCLOAK-2769 Fix NPE during 'Identity Broker cancelled' and instead …
2016-04-08 22:14:22 +02:00
mposolda 2d3580e2d4 KEYCLOAK-2769 Fix NPE during 'Identity Broker cancelled' and instead show keycloak 'we are sorry' page 2016-04-08 19:19:52 +02:00
Guus der Kinderen 3c5fcebce9 KEYCLOAK-2785: Admin client should be able to delete a user.
The delete user service should be exposed in the admin client.
2016-04-08 16:36:54 +02:00
Vlasta Ramik 00bb2de032 added nexus-staging-maven-plugin 2016-04-08 15:37:21 +02:00
mhajas 013af68d74 Better stability in JSConsole test 2016-04-08 13:57:57 +02:00
mhajas 8209c74918 Fix DemoServlet test 2016-04-08 13:50:16 +02:00
mhajas 4ed2c4e5a8 Fix timeouts in DemoServlets tests 2016-04-08 13:50:03 +02:00
mhajas 34e125ea80 Fix urls on eap6 2016-04-08 13:31:08 +02:00
Marek Posolda 135071b3aa Merge pull request #2552 from mposolda/1.9.x
KEYCLOAK-2614 Refactor database lock to use 'SELECT FOR UPDATE' pessi…
2016-04-08 13:18:43 +02:00
mposolda 38952e5b3d KEYCLOAK-2614 Refactor database lock to use 'SELECT FOR UPDATE' pessimistic locking 2016-04-08 11:48:43 +02:00
Stian Thorgersen 3eefe2438b Merge pull request #2550 from stianst/KEYCLOAK-2683-1.9
KEYCLOAK-2683 Remove QRCodeResource and embed QR code in image
2016-04-08 09:53:24 +02:00
Stian Thorgersen faaf20de95 KEYCLOAK-2683 Remove QRCodeResource and embed QR code in image 2016-04-08 09:01:28 +02:00
Stian Thorgersen 7d5cedc6eb Merge pull request #2549 from stianst/1.9.x
KEYCLOAK-2774
2016-04-08 07:00:45 +02:00
Stian Thorgersen 51efc3c184 KEYCLOAK-2774
Adapters logout section points to removed tokens endpoint
2016-04-08 07:00:32 +02:00
Stian Thorgersen cddba23dcf Merge pull request #2545 from vmuzikar/1.9.x
KEYCLOAK-2772 Add deletion test to GroupTest
2016-04-08 06:51:36 +02:00
Stian Thorgersen 5c693246ba Merge pull request #2542 from stianst/KEYCLOAK-2646-1.9
KEYCLOAK-2646 Admin console shows 'Page not found' after password reset
2016-04-07 19:36:58 +02:00
Stian Thorgersen ae0aa61b3c Merge pull request #2547 from stianst/1.9.x
Revert accidentally removed ResteasyClient configuration in admin
2016-04-07 19:36:49 +02:00
Konstantin Gribov 1cf10f1f11 Revert accidentally removed ResteasyClient configuration in admin
Fixes accidentally removed in PR #2449 ResteasyClient pool size parameter in
`org.keycloak.admin.client.Keycloak`.
2016-04-07 19:36:25 +02:00
Vaclav Muzikar b576703533 KEYCLOAK-2772 Add deletion test to GroupTest 2016-04-07 18:05:12 +02:00
Stian Thorgersen 850de683db Merge pull request #2541 from stianst/admin-client-prs-1.9
Add service account support to Keycloak admin client
2016-04-07 16:53:01 +02:00
Stian Thorgersen 59fd461563 Merge pull request #2537 from stianst/KEYCLOAK-2751-1.9
KEYCLOAK-2751
2016-04-07 16:27:09 +02:00
Stian Thorgersen ddd93df503 KEYCLOAK-2646 Admin console shows 'Page not found' after password reset 2016-04-07 16:23:34 +02:00
Konstantin Gribov 74f98f9eb2 Add service account support to Keycloak admin client
Added grant_type=client_credentials support to keycloak-admin-client
so `keycloak-admin-client` can be used with service client account.

Fixes #KEYCLOAK-2236
2016-04-07 15:45:48 +02:00
Stian Thorgersen b32d50df2d Merge pull request #2540 from guusdk/1.9.x
KEYCLOAK-2767: Should return a primitive if possible.
2016-04-07 15:41:36 +02:00
Stian Thorgersen 61d1c498ef KEYCLOAK-2751
Separate HTTP status codes for REST API errors
2016-04-07 15:39:55 +02:00
Guus der Kinderen 7bbc618e1b KEYCLOAK-2767: Should return a primitive if possible.
A JSON primitive is valid JSON. There is no need to construct a JSON object
just for the sake of being JSON complient. This keeps things nice and simple.
2016-04-07 13:59:17 +02:00
Stian Thorgersen 865371b58f Merge pull request #2536 from stianst/1.9.x
KEYCLOAK-2763
2016-04-07 09:37:36 +02:00
Stian Thorgersen 16b1f88546 KEYCLOAK-2763
Document requirement to use a secure private network for clustering
2016-04-07 09:37:17 +02:00
Stian Thorgersen 0f43e2b6f2 Merge pull request #2533 from stianst/KEYCLOAK-2762-1.9
KEYCLOAK-2762 Renaming a realm without saving the form affects all li…
2016-04-07 09:34:38 +02:00
Stian Thorgersen 949ecf60d9 Merge pull request #2534 from stianst/admin-client-prs-1.9
Add admin client PRs from master
2016-04-07 09:06:59 +02:00
Guus der Kinderen 0024162121 KEYCLOAK-2731: Improve thread safety of TokenManager
This commit guards access to the non-final fields of TokenManager by its intrinsic lock.
2016-04-07 07:36:36 +02:00
Guus der Kinderen 958471b081 KEYCLOAK-2746: By default, allow for concurrent usage
The nature of Keycloak makes it very plausible that it is used in
a concurrent setting. With that in mind, it would make sense to,
by default, allow for more than one concurrent Resteasy connection
in the admin client code.
2016-04-07 07:35:53 +02:00
Guus der Kinderen de80133ea2 KEYCLOAK-2726: Invalidate token upon failure
When a token managed by TokenManager is known to be invalid, it should no
longer be used. This commit adds a response listener to the only filter
using TokenManager, which causes, upon authentication failure, to
invalidate the token that was used.
2016-04-07 07:24:21 +02:00
Guus der Kinderen 13104750f6 KEYCLOAK-2721: Do not recreate TokenService proxy
By re-using the service proxy, classloading issues can be prevented.
2016-04-07 07:20:58 +02:00
Stian Thorgersen 2f575af3d2 Merge pull request #2531 from stianst/KEYCLOAK-2761-1.9
KEYCLOAK-2761 Broken on/off switch at Client Mappers with specific wi…
2016-04-07 07:13:37 +02:00
Stian Thorgersen 56f99ed640 KEYCLOAK-2762 Renaming a realm without saving the form affects all links in Console 2016-04-07 06:59:48 +02:00
Stian Thorgersen a42e7f226f Merge pull request #2529 from stianst/KEYCLOAK-2760-1.9
KEYCLOAK-2760
2016-04-07 06:51:26 +02:00
Stian Thorgersen d6e513f6c3 Merge pull request #2526 from stianst/KEYCLOAK-2759-1.9
KEYCLOAK-2759 Fix error message when renaming realm to name that exists
2016-04-07 06:50:52 +02:00
Stian Thorgersen 1500fff93e Merge pull request #2525 from stianst/KEYCLOAK-2758-1.9
KEYCLOAK-2758
2016-04-07 06:50:07 +02:00
Stian Thorgersen c37437e82b KEYCLOAK-2761 Broken on/off switch at Client Mappers with specific window width 2016-04-07 06:19:48 +02:00
Stian Thorgersen 7d0bb05aaa KEYCLOAK-2760
Cannot delete a client template mapper with a little trash icon in heading
2016-04-07 06:07:32 +02:00
Stian Thorgersen 35297a149d KEYCLOAK-2759 Fix error message when renaming realm to name that exists 2016-04-07 06:00:57 +02:00
Stian Thorgersen e68b71ba01 KEYCLOAK-2758
Weird behavior of add/remove button for 'Valid Redirect URIs' in a client settings form
2016-04-07 05:43:36 +02:00
Stian Thorgersen 900be13423 Merge pull request #2521 from stianst/KEYCLOAK-2756-1.9
KEYCLOAK-2756
2016-04-06 19:25:56 +02:00
Stian Thorgersen 02b8cc7ad3 KEYCLOAK-2756
Renaming a realm breaks down the Clients
2016-04-06 15:19:36 +02:00
Marek Posolda 0371c53d07 Merge pull request #2516 from mposolda/1.9.x
KEYCLOAK-1982 Some builtin objects might be missing when import JSON exported from previous versions
2016-04-06 13:24:29 +02:00
Stian Thorgersen 364a54f792 Merge pull request #2518 from stianst/1.9.x
KEYCLOAK-2752
2016-04-06 13:19:30 +02:00
Stian Thorgersen 0016bd8744 KEYCLOAK-2752
Update documentation re directory for providers
2016-04-06 13:18:56 +02:00
Stian Thorgersen 36baf38d09 Merge pull request #2515 from stianst/KEYCLOAK-2590-1.9
KEYCLOAK-2590 Add custom rest endpoint to set time offset
2016-04-06 12:58:18 +02:00
mposolda 437244f61e KEYCLOAK-1982 Some builtin objects might be missing when import JSON exported from old versions 2016-04-06 11:36:42 +02:00
mposolda 70c85af7e2 Ensure KeycloakSessionFactory.close is called before shutdown of auth-server-undertow 2016-04-06 11:36:42 +02:00
mposolda d97dbdac36 KEYCLOAK-2737 Handle the databaseSchema: 'validate' against empty database 2016-04-06 11:36:41 +02:00
Stian Thorgersen 89013c8f6e KEYCLOAK-2590 Add custom rest endpoint to set time offset 2016-04-06 11:16:28 +02:00
Stian Thorgersen ff80f613d3 Merge pull request #2513 from stianst/KEYCLOAK-2262-1.9
KEYCLOAK-2262
2016-04-06 11:12:04 +02:00
Stian Thorgersen 15cbddba13 KEYCLOAK-2262 Refactor realm resource provider, remove admin resource provider and added example 2016-04-06 10:29:40 +02:00
Pedro Igor 7c11bd2214 [KEYCLOAK-2262] - New SPIs to extend both Realm and Admin RESTful APIs 2016-04-06 10:26:59 +02:00
Stian Thorgersen 7280eb3cd9 Merge pull request #2510 from stianst/KEYCLOAK-2748-1.9
KEYCLOAK-2748
2016-04-06 09:10:21 +02:00
Stian Thorgersen 4d38c1f95d KEYCLOAK-2748
Mark modules as private
2016-04-06 08:07:52 +02:00
Stian Thorgersen 8d196500d8 Merge pull request #2504 from stianst/KEYCLOAK-2707-1.9
KEYCLOAK-2707 Fix account management layout for medium size screens
2016-04-05 13:26:05 +02:00
Marek Posolda a0e21c8bf6 Merge pull request #2506 from mposolda/1.9.x
KEYCLOAK-2623 Remove auth-server-url-for-backend-requests from adapters
2016-04-05 13:09:57 +02:00
mposolda 6b85ff0d77 Removed docker-cluster as integration-arquillian has support for clustering tests now 2016-04-05 11:41:53 +02:00
mposolda 89b622e6a0 KEYCLOAK-2623 Remove auth-server-url-for-backend-requests from adapters 2016-04-05 11:41:53 +02:00
Stian Thorgersen 53e2e352fd Merge pull request #2414 from velias/KEYCLOAK-2670
KEYCLOAK-2670 - client app is able to push additional HTTP GET
2016-04-05 11:20:04 +02:00
Stian Thorgersen fda48fc537 Merge pull request #2501 from vmuzikar/1.9.x
KEYCLOAK-2745 More UI tests stabilization
2016-04-05 11:19:07 +02:00
Stian Thorgersen 3d8721246a Merge pull request #2499 from stianst/KEYCLOAK-2722-1.9
KEYCLOAK-2722 Check user session in token introspection endpoint
2016-04-05 11:18:34 +02:00
Stian Thorgersen 0b3847eb5d KEYCLOAK-2707 Fix account management layout for medium size screens 2016-04-05 10:31:16 +02:00
Vaclav Muzikar 96606fe3da KEYCLOAK-2745 More UI tests stabilization
(cherry picked from commit 3dbf5ee)
2016-04-05 10:14:41 +02:00
Stian Thorgersen b061288d1c KEYCLOAK-2722 Check user session in token introspection endpoint 2016-04-05 09:32:14 +02:00
Stian Thorgersen 89080af339 Merge pull request #2497 from stianst/KEYCLOAK-2652-1.9
KEYCLOAK-2652 Added fasterxml modules to as7 adapter dist
2016-04-05 08:57:56 +02:00
Stian Thorgersen 7bfe51c925 Merge pull request #2495 from stianst/KEYCLOAK-2711-1.9
KEYCLOAK-2711
2016-04-05 08:54:36 +02:00
Stian Thorgersen 07b43f11e2 Merge pull request #2493 from stianst/KEYCLOAK-2704-1.9
KEYCLOAK-2704
2016-04-05 08:54:20 +02:00
Marek Posolda 8b4fe15aeb Merge pull request #2486 from mposolda/1.9.x
databaseSchema option - proper support for "validate" for both JPA and Mongo
2016-04-05 08:48:37 +02:00
Stian Thorgersen 95486ef962 KEYCLOAK-2652 Added fasterxml modules to as7 adapter dist 2016-04-05 08:02:59 +02:00
Stian Thorgersen 5a799d4c33 KEYCLOAK-2711
Button for 'impersonate user' is visible when I am creating new user
2016-04-05 07:54:31 +02:00
Stian Thorgersen 5da2fad0a2 KEYCLOAK-2704
User count missing in REST admin endpoint
2016-04-05 07:48:51 +02:00
Bill Burke 6c84520021 Merge pull request #2491 from patriot1burke/1.9.x
KEYCLOAK-2669
2016-04-04 21:14:21 -04:00
Bill Burke 2955c814b3 KEYCLOAK-2669 2016-04-04 21:13:14 -04:00
Bill Burke aad3b77996 Merge pull request #2489 from patriot1burke/1.9.x
KEYCLOAK-2738
2016-04-04 18:54:51 -04:00
Bill Burke 109191f248 KEYCLOAK-2738 2016-04-04 18:48:22 -04:00
mposolda 749130b689 KEYCLOAK-2737 connectionsMongo: Support for 'databaseSchema: validate' 2016-04-04 22:23:24 +02:00
mposolda a8732aa83c KEYCLOAK-2744 connectionsJpa: the databaseSchema 'validate' should check if database schema is updated to latest version 2016-04-04 22:23:24 +02:00
Bill Burke 6b9aa49f79 Merge pull request #2482 from stianst/KEYCLOAK-2742-1.9.x
KEYCLOAK-2742
2016-04-04 12:54:27 -04:00
Stian Thorgersen 50b701ccf0 Merge pull request #2483 from stianst/1.9.x
Minor update to themes README.txt
2016-04-04 15:26:25 +02:00
Stian Thorgersen 7a67217c87 Minor update to themes README.txt 2016-04-04 15:24:40 +02:00
Stian Thorgersen 4f861dcbec KEYCLOAK-2742
Broken navigation links while creating/editing a Client Mapper
2016-04-04 15:18:32 +02:00
Stian Thorgersen 4be5d27ada Merge pull request #2480 from stianst/KEYCLOAK-2651-1.9.x
KEYCLOAK-2651
2016-04-04 10:05:04 +02:00
Stian Thorgersen 71b0ffa3ca Merge pull request #2478 from stianst/1.9.x
KEYCLOAK-2608
2016-04-04 10:04:47 +02:00
Stian Thorgersen 7ff35067aa KEYCLOAK-2651
No CSRF protection or general security headers on welcome page
2016-04-04 09:12:01 +02:00
Stian Thorgersen 05ee844bf6 KEYCLOAK-2608
Timestamp resolution of 1s for Event.time is inappropriate for use with tests
2016-04-04 08:31:04 +02:00
Stian Thorgersen d05a139a5f Merge pull request #2472 from winfinit/1.9.x
fixed typo in javascript example
2016-04-04 08:16:12 +02:00
Bill Burke b8da04814b Merge pull request #2476 from patriot1burke/1.9.x
KEYCLOAK-2662
2016-04-01 17:55:46 -04:00
Bill Burke 5482a80fe3 KEYCLOAK-2662 2016-04-01 16:43:16 -04:00
Bill Burke 2fd2812c94 Merge pull request #2459 from vmuzikar/1.9.x
KEYCLOAK-2732
2016-04-01 16:03:08 -04:00
Bill Burke bd0cd93c90 Merge pull request #2474 from patriot1burke/1.9.x
KEYCLOAK-2512
2016-04-01 16:01:58 -04:00
Bill Burke 90efb232a4 KEYCLOAK-2512 2016-04-01 14:50:55 -04:00
Roman Jurkov 431bf08c83 fixed typo in javascript example 2016-04-01 14:28:06 -04:00
Marek Posolda d6a70fb31e Merge pull request #2471 from mposolda/1.9.x
KEYCLOAK-2737 Remove 'databaseSchema' property from connectionsMongo
2016-04-01 18:48:40 +02:00
mposolda a049cfefe8 KEYCLOAK-2737 Remove 'databaseSchema' property from connectionsMongo 2016-04-01 16:55:46 +02:00
Marek Posolda 88725f68dd Merge pull request #2469 from mposolda/1.9.x
KEYCLOAK-2613 KEYCLOAK-2413 Export/import fixes and improvements
2016-04-01 16:46:13 +02:00
mposolda e07aefdcfd KEYCLOAK-2613 Add version to RealmRepresentation in JSON exports 2016-04-01 15:49:35 +02:00
mposolda 878b724ce1 KEYCLOAK-2413 Very slow export/import of realms with large users count 2016-04-01 15:33:39 +02:00
Marek Posolda d0bcb6b6aa Merge pull request #2467 from mposolda/1.9.x
Fix LDAPGroupMapperTest with MSAD and Mongo
2016-04-01 11:22:58 +02:00
mposolda e6489b3bc1 Fix LDAPGroupMapperTest with MSAD and Mongo 2016-04-01 10:43:36 +02:00
Marek Posolda aebc473071 Merge pull request #2465 from mposolda/1.9.x
KEYCLOAK-2661 Broken migration from Keycloak 1.5 with Mongo 3
2016-04-01 09:28:32 +02:00
mposolda fdf43f058a KEYCLOAK-2661 Broken migration from Keycloak 1.5 with Mongo 3 2016-03-31 22:29:46 +02:00
Bill Burke 6886510e32 Merge pull request #2463 from patriot1burke/1.9.x
KEYCLOAK-2621
2016-03-31 14:34:47 -04:00
Bill Burke dafa2e3401 KEYCLOAK-2621 2016-03-31 14:33:58 -04:00
Bill Burke e67d37e9d8 Merge pull request #2461 from patriot1burke/1.9.x
KEYCLOAK-2516
2016-03-31 13:58:01 -04:00
Bill Burke 9422542635 KEYCLOAK-2516 2016-03-31 13:57:13 -04:00
Vaclav Muzikar f5bed87eec KEYCLOAK-2732 2016-03-31 18:31:06 +02:00
Marek Posolda 7d2f0fd5cf Merge pull request #2456 from mposolda/1.9.x
KEYCLOAK-2610 Performance improve - add more indexes to database
2016-03-31 13:36:02 +02:00
mposolda cfd8770499 KEYCLOAK-2610 Add more indexes to database 2016-03-31 11:48:41 +02:00
mposolda a540e9a0da KEYCLOAK-2610 More operations added to ManyUsersTest 2016-03-31 11:48:41 +02:00
Bill Burke 028059a668 Merge pull request #2455 from patriot1burke/1.9.x
KEYCLOAK-2716
2016-03-30 20:26:48 -04:00
Bill Burke 1031d6b6f5 resolve conflict 2016-03-30 18:23:18 -04:00
Bill Burke c6a0243c92 KEYCLOAK-2716 2016-03-30 18:14:47 -04:00
Bill Burke 9736f56d3b Merge pull request #2453 from patriot1burke/1.9.x
KEYCLOAK-2490
2016-03-30 15:49:40 -04:00
Bill Burke 662d50eeea Merge pull request #2451 from patriot1burke/1.9.x
KEYCLOAK-2691
2016-03-30 15:47:57 -04:00
Bill Burke bfbbd5375f KEYCLOAK-2490 2016-03-30 15:42:05 -04:00
Bill Burke b735106750 Merge pull request #2445 from mhajas/js-console-1.9.x-PR
KEYCLOAK-2725 Run js-console example on non-relative scanario + tests of implicit flow
2016-03-30 15:16:55 -04:00
Bill Burke 1857c0c0b4 Merge pull request #2431 from mstruk/assert-events-b
KEYCLOAK-2589 KEYCLOAK-2607 KEYCLOAK-2597 Port AssertEvents to integration-arquillian
2016-03-30 15:16:34 -04:00
Bill Burke 157bb84bce Merge pull request #2448 from tkyjovsk/KEYCLOAK-2641-fix_1.9.x
KEYCLOAK-2641 fix 1.9.x
2016-03-30 15:15:36 -04:00
Bill Burke 52617e6ef1 Merge remote-tracking branch 'remote19/1.9.x' into b_1_9 2016-03-30 15:13:51 -04:00
Bill Burke 239816f4f5 KEYCLOAK-2691 2016-03-30 15:13:39 -04:00
Tomas Kyjovsky e4ee88a492 KEYCLOAK-2641 updated READMEs 2016-03-30 18:15:56 +02:00
Tomas Kyjovsky 353958538c KEYCLOAK-2641 Fixed location of module.xsl 2016-03-30 18:15:36 +02:00
mhajas 47a91ccf33 Run js-console example on non-relative scanario + tests of implicit flow 2016-03-30 12:20:40 +02:00
Bill Burke 85baeeb34e Merge pull request #2442 from ssilvert/1.9.x
KEYCLOAK-2619: Partial Import doesn't support groups
2016-03-28 22:58:33 -04:00
Stan Silvert ef1c8199a5 KEYCLOAK-2619: Partial Import doesn't support groups 2016-03-28 15:56:06 -04:00
Bill Burke 89da594735 Merge pull request #2440 from patriot1burke/1.9.x
KEYCLOAK-2718
2016-03-28 12:01:28 -04:00
Bill Burke 811085f9bd KEYCLOAK-2718 2016-03-28 11:13:50 -04:00
Bill Burke b8904bc018 Merge pull request #2438 from patriot1burke/1.9.x
KEYCLOAK-2698
2016-03-28 10:22:13 -04:00
Bill Burke 937d234964 KEYCLOAK-2698 2016-03-28 10:20:50 -04:00
Bill Burke b5bc4f15f8 Merge pull request #2427 from tkyjovsk/fail-if-no-tests-false-1.9.x
Arq. TestSuite Surefire config: failIfNoTests=false
2016-03-28 08:48:09 -04:00
Bill Burke 16863f2ed1 Merge pull request #2434 from patriot1burke/1.9.x
KEYCLOAK-2584
2016-03-25 00:08:47 -04:00
Bill Burke 805afbb592 KEYCLOAK-2584 2016-03-24 18:56:24 -04:00
Bill Burke 977b61f91c Merge pull request #2432 from patriot1burke/1.9.x
KEYCLOAK-2624
2016-03-24 16:24:57 -04:00
Bill Burke 91815c65a3 KEYCLOAK-2624 2016-03-24 15:43:08 -04:00
Marko Strukelj 13cb6f481f KEYCLOAK-2597 Invalid children group location header response 2016-03-24 17:57:09 +01:00
Marko Strukelj dc254ff0f7 KEYCLOAK-2607 Migrate Group tests to ARQ testsuite 2016-03-24 17:57:08 +01:00
Marko Strukelj a633241d2f KEYCLOAK-2589 Copy AssertEvents to Arquillian testsuite and modify to pull events from admin endpoints 2016-03-24 17:57:00 +01:00
Vlastimil Elias 97b38f4ccd KEYCLOAK-2670 - client app is able to push additional HTTP GET
parameters in initial OpenID auth request for use in Auth flows
2016-03-24 16:19:13 +01:00
Marek Posolda 416e4948d7 Merge pull request #2428 from mposolda/1.9.x
KEYCLOAK-2713 Fix error at startup
2016-03-24 16:12:04 +01:00
mposolda 60dff589d4 KEYCLOAK-2713 Fix error at startup 2016-03-24 15:30:11 +01:00
Tomas Kyjovsky 61656c6eba Arq. TestSuite Surefire config: failIfNoTests=false 2016-03-24 15:26:20 +01:00
Bill Burke 2affc4d847 Merge pull request #2422 from tkyjovsk/KEYCLOAK-2641-1.9.x
KEYCLOAK-2641 moved app-server configurations from adapter tests
2016-03-24 09:31:36 -04:00
Bill Burke 09179159e7 Merge pull request #2423 from patriot1burke/1.9.x
KEYCLOAK-2543
2016-03-24 09:30:51 -04:00
Bill Burke b43dc8348d KEYCLOAK-2543 2016-03-24 08:44:31 -04:00
Tomas Kyjovsky f3357c2b5b KEYCLOAK-2641 moved app-server configurations from adapter tests to servers/app-server module 2016-03-24 12:10:37 +01:00
Marek Posolda 79c308166a Merge pull request #2419 from mposolda/1.9.x
Fixes and performance improvements for "create user"
2016-03-24 11:58:41 +01:00
mposolda 2ea985fd30 KEYCLOAK-2610 Ommit checks for default roles and groups during creation of user 2016-03-24 10:47:18 +01:00
mposolda 385cfd5161 KEYCLOAK-2712 Default required actions not added when user created through admin console 2016-03-24 10:47:18 +01:00
mposolda db3cd543df KEYCLOAK-2710 Improve hibernate statistics report 2016-03-24 10:47:17 +01:00
Stian Thorgersen e139fadb02 Merge pull request #2412 from vmuzikar/1.9.x
[KEYCLOAK-2697] Fix some UI tests stability
2016-03-24 08:19:40 +00:00
Stian Thorgersen 10809b47ad Merge pull request #2408 from vmuzikar/1.9.x-KEYCLOAK-2694
[KEYCLOAK-2694] Add system property for test constants location
2016-03-24 08:18:35 +00:00
Stian Thorgersen dd449ffed0 Merge pull request #2406 from vramik/1.9.x-KEYCLOAK-2676
KEYCLOAK-2676 - Review clients tests
2016-03-24 08:17:36 +00:00
Marek Posolda 1f5124fc8a Merge pull request #2416 from mposolda/1.9.x
DB tuning - step 1
2016-03-23 23:29:23 +01:00
mposolda 741a251d89 KEYCLOAK-2610 Improve performance of creating users with MySQL 2016-03-23 22:34:00 +01:00
mposolda 1012611785 KEYCLOAK-2710 Possibility to log some hibernate statistics 2016-03-23 22:33:50 +01:00
Marek Posolda 465f828d73 Merge pull request #2404 from mposolda/1.9.x-idpcache
KEYCLOAK-2632 Caching of identity provider links
2016-03-22 21:35:26 +01:00
mposolda 038294d5c1 KEYCLOAK-2632 Remove flag from UserCacheSession.invalidateUsers 2016-03-22 18:04:59 +01:00
Vaclav Muzikar d1b33e1638 [KEYCLOAK-2697] Fix some UI tests stability 2016-03-22 14:29:35 +01:00
Marek Posolda d863a4b143 Merge pull request #2409 from mposolda/1.9.x
LDAP fixes
2016-03-22 13:43:18 +01:00
mposolda 4a073b6e46 KEYCLOAK-2696 Unexpected error when trying to delete role mappings from read-only LDAP role mapper 2016-03-22 13:01:40 +01:00
mposolda 30b0c35442 KEYCLOAK-2682 NPE when LDAP groups points to non-existent user 2016-03-22 12:26:29 +01:00
Vaclav Muzikar ef5bb6d447 Add system property for test constants location
(cherry picked from commit f9afa13)
2016-03-22 12:21:29 +01:00
Vlasta Ramik 6aa0c7ca39 KEYCLOAK-2676 - Review clients tests 2016-03-22 11:52:20 +01:00
mposolda 70b3091097 KEYCLOAK-2632 Caching of identity provider links 2016-03-22 10:20:22 +01:00
Stian Thorgersen 210a79a575 Merge pull request #2403 from stianst/1.9.x
KEYCLOAK-2657 Remove copyright.txt and README.txt from server dist
2016-03-22 08:34:41 +00:00
Stian Thorgersen a4fb4fd530 KEYCLOAK-2657 Remove copyright.txt and README.txt from server dist 2016-03-22 07:28:32 +00:00
Marek Posolda 6f56320177 Merge pull request #2400 from mposolda/1.9.x
Caching of user consents and serviceAccount links
2016-03-22 08:03:36 +01:00
mposolda 4d13b5105e KEYCLOAK-2631 Caching of service account links 2016-03-22 07:02:18 +01:00
mposolda 97a398790f KEYCLOAK-2630 Add caching for user consents 2016-03-22 07:01:59 +01:00
mposolda c09da5cac8 KEYCLOAK-2687 ZIPException during import big number of users 2016-03-22 07:01:46 +01:00
Stian Thorgersen 9521e71840 Merge pull request #2397 from vramik/KEYCLOAK-2690
KEYCLOAK-2690 - create page source file when test fails
2016-03-21 15:26:26 +01:00
Stian Thorgersen e5d09e1b04 Merge pull request #2396 from mhajas/mellon-realm-1.9.x-PR
KEYCLOAK-2689 Modify mod_auth_mellon realm for rhel7
2016-03-21 15:21:30 +01:00
Stian Thorgersen ebe6d5c5c1 Merge pull request #2394 from mhajas/mellon-timeout-1.9.x-PR
KEYCLOAK-2688 Modified session length in mod_auth_mellon test
2016-03-21 15:21:03 +01:00
Stian Thorgersen 0320884c72 Merge pull request #2387 from pdrozd/1.9.x
KEYCLOAK-2685 - Updated EAP7 namespaces
2016-03-21 15:20:20 +01:00
Stian Thorgersen a254d2120d Merge pull request #2390 from stianst/1.9.x
KEYCLOAK-2686 - Fix failing migration from 1.9.1 to 1.9.2.
2016-03-21 15:12:21 +01:00
Vlasta Ramik 4157907358 create page source file when test fails 2016-03-21 14:16:55 +01:00
mhajas dfc8708808 Modify realm for rhel7 2016-03-21 12:44:43 +01:00
mhajas 67c40eb212 Modified session length 2016-03-21 12:38:00 +01:00
Thomas Darimont bafaef7060 KEYCLOAK-2664 - QRCodeResource should prohibit caching of the generated image
Added cache-control headers to avoid caching for generated
QRCode images.

Adjusted CacheControlUtil#noCache() to avoid caching more aggressively.
2016-03-21 10:39:53 +01:00
Stian Thorgersen ee06eda05c Merge pull request #2379 from vmuzikar/1.9.x
Add properties file for some "constants" used in integration tests
2016-03-21 10:37:31 +01:00
Thomas Darimont a3525dd073 KEYCLOAK-2686 - Fix failing migration from 1.9.1 to 1.9.2.
Since the `Map` returned by `realm.getBrowserSecurityHeaders()` is unmodifiable
we need to add the new header setting to a copy of the map which we then set
on the realm.
2016-03-21 10:31:43 +01:00
Pavel Drozd f97f0e4e1b KEYCLOAK-2685 - Updated EAP7 namespaces 2016-03-21 08:59:05 +01:00
Marek Posolda c62e93577b Merge pull request #2385 from mposolda/1.9.x
KEYCLOAK-2681 JS adapter init function with initOptions argument does…
2016-03-18 14:16:47 +01:00
ratcashdev bcebd3fb83 KEYCLOAK-2679: Fix when importing empty uniqueMember attributes 2016-03-18 12:20:37 +01:00
mposolda 0589c82242 KEYCLOAK-2681 JS adapter init function with initOptions argument doesn't call success callback 2016-03-18 12:08:33 +01:00
Vaclav Muzikar 4ddf4d1c99 Add support for testing default theme name in prop file
(cherry picked from commit 2d7424c)
2016-03-14 16:44:00 +01:00
Vaclav Muzikar a98148f19b Add LDAP vendors test
(cherry picked from commit cd063c6)
2016-03-14 16:43:39 +01:00
Vaclav Muzikar d1072e8942 Add support for some test constants in props file
(cherry picked from commit a35aa47)
2016-03-14 16:43:24 +01:00
Marek Posolda 5b0254f0c7 Merge pull request #2376 from mposolda/1.9.x
KEYCLOAK-2634 Better error reporting if password update failed due to…
2016-03-14 14:32:24 +01:00
mposolda c2b406e7d6 KEYCLOAK-2634 Better error reporting if password update failed due to MSAD password policy 2016-03-14 13:35:30 +01:00
Marek Posolda 4821290c32 Merge pull request #2375 from mposolda/1.9.x
A bit more details about Kerberos and LDAP mappers in docs
2016-03-14 11:52:59 +01:00
mposolda d3bb68c2b0 A bit more details about Kerberos and LDAP mappers in docs 2016-03-14 11:51:13 +01:00
Marek Posolda 9560364a1c Merge pull request #2372 from mposolda/1.9.x
1.9.x
2016-03-14 10:32:32 +01:00
mposolda 4b49bc7140 KEYCLOAK-2659 Allow sync all roles even if there are more than 1000 2016-03-14 09:37:31 +01:00
mposolda 88bac57cad KEYCLOAK-2644 Delete user with a READ_ONLY LDAP federation provider just from Keycloak DB 2016-03-14 09:27:21 +01:00
Marek Posolda 9630921d91 Merge pull request #2371 from mposolda/1.9.x
LDAP fixes
2016-03-11 23:12:10 +01:00
Bill Burke 84e216c2ac Merge pull request #2369 from patriot1burke/1.9.x
refactor user cache
2016-03-11 16:57:15 -05:00
mposolda 0bc72e908f KEYCLOAK-2655 Support of lazy sync LDAP groups, which user is member of 2016-03-11 22:29:43 +01:00
mposolda 6910572bd2 KEYCLOAK-2643 Added write-only property to LDAP full-name attribute mapper 2016-03-11 22:29:43 +01:00
mposolda a4dd8a38b3 KEYCLOAK-2629 LDAP Federation provider - input fields validation 2016-03-11 22:29:42 +01:00
mposolda f0b4127567 KEYCLOAK-2640 LDAP group sync does not sync more than 1000 groups 2016-03-11 22:29:42 +01:00
Bill Burke c4f3a4e68e refactor user cache
KEYCLOAK-2612 Set default eviction strategy for users cache
2016-03-11 11:43:06 -05:00
Stian Thorgersen c0aa4289e2 Merge pull request #2367 from stianst/KEYCLOAK-2612
KEYCLOAK-2612 Set default eviction strategy for users cache
2016-03-11 16:22:51 +01:00
Stian Thorgersen 9be600cffe KEYCLOAK-2593 Character set missing from responses and no content sniffing defense in place 2016-03-11 15:33:09 +01:00
Stian Thorgersen c998f6eb53 KEYCLOAK-2612 Set default eviction strategy for users cache 2016-03-11 15:29:30 +01:00
Stian Thorgersen c901b38858 Merge pull request #2366 from stianst/KEYCLOAK-2637
KEYCLOAK-2637
2016-03-11 15:23:08 +01:00
Stian Thorgersen 4bd09cf14b KEYCLOAK-2637
ModelExceptionMapper uses AdminMessagesProvider which loads messages outside of themes
2016-03-11 13:01:18 +01:00
Stian Thorgersen 3edadb01c5 Merge pull request #2363 from stianst/1.9.x
KEYCLOAK-2636
2016-03-11 12:33:17 +01:00
Stian Thorgersen b738764442 KEYCLOAK-2636
Tooltip for redirect uri is wrong
2016-03-11 11:12:53 +01:00
Marek Posolda 660fd94e7f Merge pull request #2362 from mposolda/1.9.x
KEYCLOAK-2628 protected method to IdpCreateUserIfUniqueAuthenticator …
2016-03-11 11:08:23 +01:00
mposolda a3138b8514 KEYCLOAK-2628 protected method to IdpCreateUserIfUniqueAuthenticator after user is registered 2016-03-11 10:05:07 +01:00
helio-frota 627e434b73 minor update javascript adapter docs 2016-03-11 06:03:40 +01:00
Stian Thorgersen 406754f31b Merge branch 'master' of https://github.com/keycloak/keycloak into 1.9.x 2016-03-10 08:09:40 +01:00
Stian Thorgersen b9fea7b143 Merge pull request #2357 from stianst/master
Fixes
2016-03-10 08:08:09 +01:00
Stian Thorgersen ae63830c22 Merge pull request #2355 from abstractj/KEYCLOAK-2633
Let the admin manage her own account
2016-03-10 07:30:49 +01:00
Stian Thorgersen 96967c0373 Merge pull request #2354 from vramik/KEYCLOAK-2586
KEYCLOAK-2586 - fix URL providers on classpath for graphene 2.1.0.Aplha3
2016-03-10 07:30:26 +01:00
Stian Thorgersen 6e0eb21428 Merge pull request #2352 from mposolda/master
KEYCLOAK-2601 Fix incorrectly autodetected dialect with MSSQL2014
2016-03-10 07:29:28 +01:00
Stian Thorgersen e295efed07 Revert "Updated docs for KEYCLOAK-1020"
This reverts commit 6fe3a3da71.
2016-03-10 07:28:45 +01:00
Stian Thorgersen cd2f6e83b3 Allow ignoring patterns in LogChecker 2016-03-10 07:28:45 +01:00
Stian Thorgersen d722e53108 Next is 1.9.2.Final 2016-03-10 07:28:27 +01:00
mposolda 28252e2409 Fix failing test 2016-03-09 16:49:01 +01:00
Bruno Oliveira 746d285c7b Let the admin manage her own account 2016-03-09 12:16:21 -03:00
Vlasta Ramik 32b29bb130 KEYCLOAK-2586 - fix URL providers on classpath for graphene 2.1.0.Aplha3 2016-03-09 13:58:07 +01:00
mposolda 583f8ad739 KEYCLOAK-2601 Fix incorrectly autodetected dialect with MSSQL2014 2016-03-09 11:56:31 +01:00
Stian Thorgersen b371521b33 Merge pull request #2350 from mposolda/1.9.x
1.9.x
2016-03-09 06:13:52 +01:00
Stian Thorgersen 321b23a78d Merge pull request #2349 from mposolda/master
Log DB info in arquillian testsuite
2016-03-09 06:13:40 +01:00
mposolda f151933d91 Log DB info in arquillian testsuite 2016-03-08 22:08:45 +01:00
mposolda 5ea93822e7 Disable DBLockTest for now 2016-03-08 22:08:33 +01:00
mposolda cafd2d80d2 Added exclusion of old commons-io dependency as it's causing issues in some environments 2016-03-08 22:08:22 +01:00
mposolda c9dcd7973a Fix DB2 2016-03-08 22:08:08 +01:00
mposolda bcace1eacf Log DB info in arquillian testsuite 2016-03-08 22:04:25 +01:00
Marek Posolda dad4945358 Merge pull request #2347 from mposolda/master
Disable DBLockTest for now
2016-03-08 17:57:13 +01:00
mposolda f914a30b6e Disable DBLockTest for now 2016-03-08 17:44:03 +01:00
Marek Posolda d65fb963e6 Merge pull request #2346 from mposolda/master
Added exclusion of old commons-io dependency as it's causing issues i…
2016-03-08 17:42:51 +01:00
mposolda 5772ea2b09 Added exclusion of old commons-io dependency as it's causing issues in some environments 2016-03-08 17:01:48 +01:00
Marek Posolda 620f22249a Merge pull request #2345 from mposolda/master
Fix DB2
2016-03-08 16:06:57 +01:00
mposolda 29052019c5 Fix DB2 2016-03-08 16:05:45 +01:00
Marek Posolda c17b70e454 Merge pull request #2344 from mposolda/master
KEYCLOAK-2611 Keycloak fails to start with Oracle DB
2016-03-08 14:35:43 +01:00
Stian Thorgersen 1199fa7f6d Merge pull request #2343 from stianst/KEYCLOAK-2596
KEYCLOAK-2596 Fix import with dir and ignore existing
2016-03-08 13:50:57 +01:00
Stian Thorgersen 4928f779f7 Merge pull request #2329 from mbaluch/master
KPR-87 - Agreement on terms and conditions as part of authentication …
2016-03-08 13:50:49 +01:00
mposolda 8371c256b2 KEYCLOAK-2611 Keycloak fails to start with Oracle DB 2016-03-08 13:49:19 +01:00
Marek Baluch fa0335613f KPR-87 - Agreement on terms and conditions as part of authentication - Tests 2016-03-08 10:32:25 +01:00
Stian Thorgersen dc1d0e7f44 KEYCLOAK-2596 Fix import with dir and ignore existing 2016-03-08 08:55:10 +01:00
Marek Posolda 229eca302f Merge pull request #2342 from mposolda/master
LDAP fixes
2016-03-08 08:46:28 +01:00
Stian Thorgersen 446c9fea4b Merge pull request #2340 from dbarentine/master
KEYCLOAK-2609 Use createCredential so that authentication will work with both 2.x a…
2016-03-08 07:54:46 +01:00
Stian Thorgersen 1d882cdb87 Merge pull request #2339 from tkyjovsk/jpa-performance
Added workaround for KEYCLOAK-2560 to jpa-performance tests.
2016-03-08 07:53:41 +01:00
Stian Thorgersen bdc5f1c185 Merge pull request #2335 from mhajas/master
Run adapter tests on EAP6/7 + test fixes
2016-03-08 07:53:11 +01:00
Stian Thorgersen 7b578b8c87 Merge pull request #2336 from byF/master
Updated docs for KEYCLOAK-1020
2016-03-08 07:52:40 +01:00
Stian Thorgersen 37f605de5b Merge pull request #2333 from mhajas/newSAMLTest
IdpInitiated login unauthorized test
2016-03-08 07:51:49 +01:00
mposolda 8d21cfc234 KEYCLOAK-2583 Synchronize users after creating ldap federation provider 2016-03-07 23:19:43 +01:00
mposolda df56265976 KEYCLOAK-2582 Wrong message after synchronization (removing user from ldap) 2016-03-07 23:19:43 +01:00
Dane Barentine 7be0b1c9f5 Use createCredential so that authentication will work with both 2.x and 3.x MongoDB servers 2016-03-07 10:14:00 -08:00
Tomas Kyjovsky 52f3693747 Added workaround for KEYCLOAK-2560 to jpa-performance tests.
Optional delete/reimport realm phases.
2016-03-07 18:10:12 +01:00
Marek Posolda 392b1f1e17 Merge pull request #2337 from mposolda/dblock2
KEYCLOAK-2529 More proper handling of DB errors during migration
2016-03-07 16:06:49 +01:00
mposolda ebb61c104b KEYCLOAK-2529 More proper handling of DB errors during migration 2016-03-07 15:19:12 +01:00
Farana, Zdenek 6fe3a3da71 Updated docs for KEYCLOAK-1020 2016-03-07 14:48:32 +01:00
Marek Posolda f597f163f7 Merge pull request #2334 from mposolda/dblock2
Fix testsuite with Mongo
2016-03-07 13:15:31 +01:00
mposolda 1ac0529d04 Fix testsuite with mongo 2016-03-07 12:21:43 +01:00
mposolda 3c60881d8c Check performance of multiple get calls over cluster 2016-03-07 12:21:43 +01:00
Marek Posolda 74ac00349e Merge pull request #2332 from mposolda/dblock2
KEYCLOAK-2529 Concurrent startup by more cluster nodes at the same ti…
2016-03-07 11:47:53 +01:00
mhajas 048c64b6bd IdpInitiated login unauthorized test 2016-03-07 11:23:36 +01:00
mhajas 5917d5885b Merge remote-tracking branch 'upstream/master' 2016-03-07 11:21:24 +01:00
mposolda 8da768a514 KEYCLOAK-2529 Concurrent startup by more cluster nodes at the same time. Added DBLockProvider 2016-03-07 10:34:30 +01:00
Stian Thorgersen ad63b18781 Merge pull request #2330 from stianst/KEYCLOAK-2605
KEYCLOAK-2605 Revert upgrade of Arquillian Graphene
2016-03-07 09:19:53 +01:00
Stian Thorgersen 95d5ce9dd4 KEYCLOAK-2605 Revert upgrade of Arquillian Graphene 2016-03-07 08:38:39 +01:00
Stian Thorgersen 56c3d53a24 Merge pull request #2324 from ssilvert/client-tests
KEYCLOAK-2535: ClientResource endpoint tests
2016-03-07 06:13:55 +01:00
Stian Thorgersen c91255f620 Merge pull request #2328 from abstractj/reg-cli-minor-fix
Client registration won't compile without these changes
2016-03-07 06:12:43 +01:00
Stian Thorgersen 4f047565fb Merge pull request #2326 from stianst/KEYCLOAK-2592
Keycloak 2592
2016-03-07 06:12:17 +01:00
Stan Silvert f65a053182 Make imports in ServerInfoAdminResource explicitly point to the new
packages.
2016-03-04 11:17:12 -05:00
Bill Burke b709ca96b1 Merge pull request #2327 from patriot1burke/master
cleanup cache
2016-03-04 11:08:50 -05:00
Bruno Oliveira 4a027d97b0 Client registration won't compile without these changes 2016-03-04 12:46:57 -03:00
Bill Burke 4be6dc2f0c cleanup cache 2016-03-04 10:30:48 -05:00
Stian Thorgersen 57b6ddbace KEYCLOAK-2592 Set secure on OAuth_Token_Request_State cookie 2016-03-04 14:22:48 +01:00
Stian Thorgersen bf38ec040f KEYCLOAK-2592 Set http-only on OAuth_Token_Request_State cookie 2016-03-04 13:43:00 +01:00
Stan Silvert 2c79456e72 KEYCLOAK-2535: ClientResource endpoint tests 2016-03-04 07:41:24 -05:00
Stian Thorgersen 8caad0118c Merge pull request #2322 from vramik/KEYCLOAK-2586
KEYCLOAK-2586 - Update arquillian component versions to make screensh…
2016-03-04 08:22:47 +01:00
Stian Thorgersen afdbdb285d Merge pull request #2323 from abstractj/KEYCLOAK-2585
KEYCLOAK-2585: Changes on Brute force messages
2016-03-04 08:18:16 +01:00
Bill Burke ad2638cc20 Merge pull request #2325 from jblashka/master
Increase CERTIFICATE column size
2016-03-03 20:26:43 -05:00
Jared Blashka 05c590ac88 Increase CERTIFICATE column size 2016-03-03 17:35:40 -05:00
Bruno Oliveira 8d6f71e7d1 KEYCLOAK-2585: Changes on Brute force messages 2016-03-03 10:11:03 -03:00
Vlasta Ramik 10e1b6206f KEYCLOAK-2586 - Update arquillian component versions to make screenshooter working 2016-03-03 13:39:10 +01:00
Marek Posolda 002074bb30 Merge pull request #2320 from mposolda/master
KEYCLOAK-2523 Fix concurrency tests with all databases by track trans…
2016-03-03 12:34:29 +01:00
Stian Thorgersen 375d4e9e83 Merge pull request #2321 from stianst/KEYCLOAK-2547
KEYCLOAK-2547 NPE in TokenEndpoint and InfinispanUserSessionProvider
2016-03-03 12:06:40 +01:00
mposolda 286de3e905 Fix failing test 2016-03-03 11:46:27 +01:00
mposolda a258dd51ee KEYCLOAK-2523 Fix concurrency tests with all databases by track transaction startup revision 2016-03-03 11:21:26 +01:00
Stian Thorgersen b4239c40c1 KEYCLOAK-2547 NPE in TokenEndpoint and InfinispanUserSessionProvider 2016-03-03 10:45:05 +01:00
Stian Thorgersen b6118a6705 Merge pull request #2319 from stianst/KEYCLOAK-2580
KEYCLOAK-2580 Failed to create execution flow
2016-03-03 10:33:42 +01:00
Stian Thorgersen 2bf3531c43 Merge pull request #2318 from stianst/KEYCLOAK-2577
KEYCLOAK-2577 Rollback session in KeycloakSessionServletFilter if not…
2016-03-03 10:33:29 +01:00
Stian Thorgersen 2d42ad9993 KEYCLOAK-2580 Failed to create execution flow 2016-03-03 09:18:48 +01:00
Stian Thorgersen 2edb7f6831 KEYCLOAK-2577 Rollback session in KeycloakSessionServletFilter if not committed by KeycloakTransactionCommitter 2016-03-03 08:59:19 +01:00
Stian Thorgersen 402feb9710 Merge pull request #2317 from stianst/KEYCLOAK-2576
KEYCLOAK-2576
2016-03-03 07:48:43 +01:00
Stian Thorgersen 13506bec82 Merge pull request #2316 from stianst/KEYCLOAK-2568
KEYCLOAK-2568 Add autocomplete=off to password and otp input fields
2016-03-03 07:28:25 +01:00
Stian Thorgersen 13b6c6f507 KEYCLOAK-2576 KEYCLOAK-2576
Changing locale on login screen doesn't affect current user
2016-03-03 07:06:10 +01:00
Stian Thorgersen 7b8869bde6 Removed english values from non-english messages bundles£ 2016-03-03 06:53:00 +01:00
Stian Thorgersen e4815cd103 Merge pull request #2314 from mstruk/admin-client
KEYCLOAK-2574 Add more admin-client authentication tests
2016-03-03 06:30:48 +01:00
Stian Thorgersen 4214793a2d KEYCLOAK-2568 Add autocomplete=off to password and otp input fields 2016-03-03 06:29:56 +01:00
Bill Burke 860b58552e Merge pull request #2315 from patriot1burke/master
concurrent transaction fix
2016-03-02 17:43:33 -05:00
Bill Burke a13bac4c9d concurrent transaction fix 2016-03-02 16:55:55 -05:00
Marko Strukelj c6fc7622d2 KEYCLOAK-2574 Add more admin-client authentication tests 2016-03-02 15:12:32 +01:00
Stian Thorgersen c584a1a161 Merge pull request #2313 from abstractj/documentation_updates
Inclusion of add user instructions for overlay
2016-03-02 14:52:54 +01:00
Bruno Oliveira b8c50c431c Inclusion of add user instructions for overlay 2016-03-02 10:14:41 -03:00
Stian Thorgersen cc776abacb Merge pull request #2311 from stianst/KEYCLOAK-2557
KEYCLOAK-2557
2016-03-02 08:50:55 +01:00
Stian Thorgersen fea5d5099d Merge pull request #2310 from stianst/KEYCLOAK-2570
KEYCLOAK-2570
2016-03-02 08:50:23 +01:00
Marek Posolda 95e1dedb32 Merge pull request #2306 from mposolda/mysql-concurrency
Added ConcurrentTransactionsTest
2016-03-02 08:14:40 +01:00
Stian Thorgersen 370b86141c KEYCLOAK-2557
Cannot login with email if another user is using this email as username
2016-03-02 08:08:48 +01:00
Stian Thorgersen 45b940ad2d Merge pull request #2308 from tkyjovsk/auth-server-eap7-cluster
KEYCLOAK-1679 Auth server eap7 cluster
2016-03-02 07:54:24 +01:00
Stian Thorgersen 8c3545d219 KEYCLOAK-2570
Login event error field typo (lower case)
2016-03-02 07:52:04 +01:00
Stian Thorgersen 2f3a1626d7 Merge pull request #2309 from tkyjovsk/console-ui-tests
KEYCLOAK-2570 disabled failing test
2016-03-02 07:26:45 +01:00
Stian Thorgersen 5d93f4a298 Merge pull request #2307 from stianst/KEYCLOAK-2566
KEYCLOAK-2566 kc-action-cell action buttons don't appear on IE
2016-03-02 07:04:42 +01:00
Tomas Kyjovsky 66a75d93ee KEYCLOAK-2570 disabled failing test 2016-03-01 23:08:19 +01:00
Tomas Kyjovsky e107a403cf Fixed & enabled SessionFailoverClusterTest by default 2016-03-01 21:44:46 +01:00
Stian Thorgersen 8270c0a19a KEYCLOAK-2566 kc-action-cell action buttons don't appear on IE 2016-03-01 19:58:11 +01:00
Stian Thorgersen db5efdca64 Merge pull request #2304 from stianst/KEYCLOAK-2513
KEYCLOAK-2513 Add test for direct grant with OTP
2016-03-01 19:33:45 +01:00
Stian Thorgersen 5eb319f3c5 Merge pull request #2303 from tkyjovsk/auth-server-jdk
Added property "auth.server.java.home" to the Arquillian testsuite.
2016-03-01 19:33:35 +01:00
Stian Thorgersen 6baa4a7950 Merge pull request #2302 from stianst/KEYCLOAK-2567
KEYCLOAK-2567 Order required actions alphabetically
2016-03-01 19:32:35 +01:00
Tomas Kyjovsky 73b6751219 KEYCLOAK-1679 added cluster profile for eap7 2016-03-01 16:13:12 +01:00
Tomas Kyjovsky c0de43d51f KEYCLOAK-1678 added cluster config to the EAP7 test server module 2016-03-01 16:12:59 +01:00
mposolda 5d9966f6df Ignore ConcurrentTransactionsTest as it's currently failing 2016-03-01 13:52:59 +01:00
mposolda 893fb2a55b Added ConcurrentTransactionsTest 2016-03-01 13:39:03 +01:00
Marek Posolda 4add134dff Merge pull request #2305 from mposolda/master
KEYCLOAK-2542 User can't set password for account created over social…
2016-03-01 11:54:52 +01:00
mhajas 7dc228beca IPv6 in login events 2016-03-01 11:42:16 +01:00
mposolda e6e367392a KEYCLOAK-2542 Fix tests 2016-03-01 10:52:35 +01:00
mposolda 0768bcc452 KEYCLOAK-2542 User can't set password for account created over social login if UserFedarationProvider used 2016-03-01 10:13:21 +01:00
Stian Thorgersen 4f8669d668 KEYCLOAK-2513 Add test for direct grant with OTP 2016-03-01 09:05:02 +01:00
Tomas Kyjovsky c65ed96bd7 Added property "auth.server.java.home" to the Arquillian testsuite. 2016-03-01 08:46:17 +01:00
Stian Thorgersen 7ad8a6e074 KEYCLOAK-2567 Order required actions alphabetically 2016-03-01 08:41:35 +01:00
Stian Thorgersen 2bddd9ad34 Merge pull request #2297 from tkyjovsk/console-ui-tests
Fixed admin console tests' compilation errors.
2016-03-01 08:00:46 +01:00
Stian Thorgersen ff9ebb0f79 Merge pull request #2294 from vramik/KEYCLOAK-2565
KEYCLOAK-2565 - Add assert check to testsuite for KEYCLOAK-2554 and ...
2016-03-01 08:00:23 +01:00
Bill Burke 09133a9e2a Merge pull request #2301 from patriot1burke/master
KEYCLOAK-2510
2016-02-29 20:51:34 -05:00
Bill Burke 32d15e2027 KEYCLOAK-2510 2016-02-29 20:39:44 -05:00
Bill Burke 8aa0727d88 Merge pull request #2300 from patriot1burke/master
KEYCLOAK-2536
2016-02-29 20:08:19 -05:00
Bill Burke c0d0c1f39a fix 2016-02-29 16:48:28 -05:00
Bill Burke 64daa568b9 KEYCLOAK-2536 2016-02-29 16:05:43 -05:00
Marek Posolda 47652ae179 Merge pull request #2298 from mposolda/master
KEYCLOAK-1928 Fix Saml with IBM JDK
2016-02-29 20:57:55 +01:00
mposolda e2558ca827 KEYCLOAK-1928 Fix Saml with IBM JDK 2016-02-29 17:32:33 +01:00
mhajas 5fb7e8186f Make adapter tests run also on EAP6 and EAP7 2016-02-29 17:23:27 +01:00
Tomas Kyjovsky e66060b00b Fixed admin console tests' compilation errors. 2016-02-29 17:13:08 +01:00
Bill Burke 84de9cca8e Merge pull request #2295 from patriot1burke/master
unsecure url has principal
2016-02-29 10:54:19 -05:00
Bill Burke 37584a24e0 unsecure url has principal
KEYCLOAK-2550
Typo in userguide

KEYCLOAK-1928 Kerberos working with IBM JDK

KEYCLOAK-1928 Remove sun.jdk.jgss module

KEYCLOAK-1928 Fix kerberos with adapter on JDK7

KPR-147 - Initial login scenarios around admin password - test

KEYCLOAK-2561 Fix issues with blank password

KEYCLOAK-2559 Missing add/remove button for 'Valid Redirect URIs' in a client settings form

Added simple test for JPA performance (with many users).

Fixed "re-import" operation logging.

Fixed for Timer.saveData()

Fixed for Timer.saveData()

ManyUsersTest: ArrayList --> LinkedList

Fix AbstractUserTest

Fix parentheses in login page object

Add tests for IDP initiated login

KEYCLOAK-1040
Allow import of realm keys (like we do for SAML)

KEYCLOAK-2556 Remove required for client create root url and saml endpoint

KEYCLOAK-2555 ForbiddenException when importing test realm or creating test user

KEYCLOAK-2553
Unexpected form behavior while creating a client

KEYCLOAK-2551
Broken navigation links while creating/editing a Client Mapper
2016-02-29 09:30:28 -05:00
Vlasta Ramik cfc61fa262 KEYCLOAK-2565 - Add assert check to testsuite for KEYCLOAK-2554 and KEYCLOAK-2555 2016-02-29 15:08:19 +01:00
Stian Thorgersen 4286f0560f Merge pull request #2293 from stianst/KEYCLOAK-2551
KEYCLOAK-2551
2016-02-29 14:06:46 +01:00
Stian Thorgersen 116d147bf7 Merge pull request #2292 from stianst/KEYCLOAK-2553
KEYCLOAK-2553
2016-02-29 14:06:13 +01:00
Stian Thorgersen a71adde8fa KEYCLOAK-2551
Broken navigation links while creating/editing a Client Mapper
2016-02-29 12:25:36 +01:00
Stian Thorgersen 45a03a654f KEYCLOAK-2553
Unexpected form behavior while creating a client
2016-02-29 12:05:20 +01:00
Stian Thorgersen 2154dd120b Merge pull request #2291 from stianst/KEYCLOAK-2555
KEYCLOAK-2555 ForbiddenException when importing test realm or creatin…
2016-02-29 12:00:44 +01:00
Stian Thorgersen 2a4dfe7920 Merge pull request #2290 from stianst/KEYCLOAK-2556
KEYCLOAK-2556 Remove required for client create root url and saml end…
2016-02-29 12:00:00 +01:00
Stian Thorgersen 5556736968 Merge pull request #2289 from stianst/KEYCLOAK-1040
KEYCLOAK-1040
2016-02-29 11:59:42 +01:00
Stian Thorgersen 24336bcd4d Merge pull request #2286 from mhajas/newSAMLTest
KEYCLOAK-2563 Add test for IDP initiated login
2016-02-29 11:59:35 +01:00
Stian Thorgersen 6fae1c6411 Merge pull request #2285 from mhajas/fixSAMLTest
Fix parentheses in login page object
2016-02-29 11:59:20 +01:00
Stian Thorgersen d7641f8830 Merge pull request #2282 from tkyjovsk/jpa-performance
Added some jpa perf tests (adding/removing many users)
2016-02-29 11:58:09 +01:00
Stian Thorgersen 24328fdc47 KEYCLOAK-2555 ForbiddenException when importing test realm or creating test user 2016-02-29 10:09:06 +01:00
Stian Thorgersen 4f46ab45cc KEYCLOAK-2556 Remove required for client create root url and saml endpoint 2016-02-29 09:48:15 +01:00
Stian Thorgersen ccfae82b77 KEYCLOAK-1040
Allow import of realm keys (like we do for SAML)
2016-02-29 09:35:08 +01:00
Stian Thorgersen 711e6a54ca Merge pull request #2283 from stianst/KEYCLOAK-2559
KEYCLOAK-2559 Missing add/remove button for 'Valid Redirect URIs' in …
2016-02-29 09:34:59 +01:00
Bill Burke 1d8f3d8702 Merge pull request #2288 from patriot1burke/master
clustered cache fixes
2016-02-26 18:22:38 -05:00
Bill Burke a0696fcb97 clustered testing 2016-02-26 16:45:58 -05:00
Bill Burke abddbfb3a4 clustered testing 2016-02-26 15:39:22 -05:00
Marek Posolda a97c4bdff9 Merge pull request #2287 from mposolda/master
KEYCLOAK-2561 Fix issues with blank password
2016-02-26 21:25:41 +01:00
mposolda e7a5b88b2d KEYCLOAK-2561 Fix issues with blank password 2016-02-26 18:14:37 +01:00
mhajas 4f0609f8b2 Add tests for IDP initiated login 2016-02-26 16:55:12 +01:00
mhajas e4d056f54b Fix parentheses in login page object 2016-02-26 16:50:00 +01:00
Tomas Kyjovsky a3f7339fca Fix AbstractUserTest 2016-02-26 14:57:28 +01:00
Stian Thorgersen 57cd7e132c KEYCLOAK-2559 Missing add/remove button for 'Valid Redirect URIs' in a client settings form 2016-02-26 13:53:27 +01:00
Stian Thorgersen d766c56eba Merge pull request #2278 from mbaluch/master
KPR-147 - Initial login scenarios around admin password - test
2016-02-26 13:46:52 +01:00
Tomas Kyjovsky 0fa2b5c25d ManyUsersTest: ArrayList --> LinkedList 2016-02-26 12:34:39 +01:00
Marek Baluch 072fe0d8a0 KPR-147 - Initial login scenarios around admin password - test 2016-02-26 12:21:51 +01:00
Marek Posolda 2ec355e2d2 Merge pull request #2281 from mposolda/master
KEYCLOAK-1928 Fix kerberos with adapter on JDK7
2016-02-26 11:36:04 +01:00
mposolda 94b3e85513 KEYCLOAK-1928 Fix kerberos with adapter on JDK7 2016-02-26 10:49:10 +01:00
Marek Posolda 4abcb2761f Merge pull request #2280 from mposolda/master
KEYCLOAK-1928 Kerberos working with IBM JDK
2016-02-26 10:13:14 +01:00
mposolda aae550a7c7 KEYCLOAK-1928 Remove sun.jdk.jgss module 2016-02-26 09:16:39 +01:00
mposolda 7f32ce810a KEYCLOAK-1928 Kerberos working with IBM JDK 2016-02-26 09:16:39 +01:00
Stian Thorgersen 13acd512b6 Merge pull request #2279 from stianst/master
KEYCLOAK-2550
2016-02-26 07:54:18 +01:00
Stian Thorgersen b94ced2204 KEYCLOAK-2550
Typo in userguide
2016-02-26 07:53:38 +01:00
Tomas Kyjovsky c59123e974 Fixed for Timer.saveData() 2016-02-26 03:21:15 +01:00
Tomas Kyjovsky ff2c100664 Fixed for Timer.saveData() 2016-02-26 03:20:57 +01:00
Tomas Kyjovsky 41949b63f6 Fixed "re-import" operation logging. 2016-02-26 02:31:51 +01:00
Tomas Kyjovsky aea35454bf Added simple test for JPA performance (with many users). 2016-02-26 02:24:20 +01:00
Stian Thorgersen 25d183c1d9 Merge pull request #2277 from pedroigor/KEYCLOAK-2471
Updating xmlsec to 2.0.5
2016-02-25 16:28:56 +01:00
Pedro Igor 3b8364f1e6 Updating xmlsec to 2.0.5 2016-02-25 11:43:00 -03:00
Stian Thorgersen ca81f3f18d Merge pull request #2275 from stianst/KEYCLOAK-2511
KEYCLOAK-2511 Rename session-state in access token response to sessio…
2016-02-25 12:03:37 +01:00
Stian Thorgersen 6df72d67c5 Merge pull request #2274 from stianst/KEYCLOAK-2500
KEYCLOAK-2500 Add cors headers to .well-known endpoints
2016-02-25 12:03:25 +01:00
Stian Thorgersen f6c7ecf8e3 Merge pull request #2273 from stianst/KEYCLOAK-2522
KEYCLOAK-2522 master realm admin can't use client registration api
2016-02-25 12:03:07 +01:00
Stian Thorgersen d723efae77 Merge pull request #2276 from msavy/keycloak-update-docs
Update docs for move of themes and providers directories
2016-02-25 10:56:26 +01:00
Marc Savy b7f4d52de1 Update docs for change of themes and providers directories to reflect 1.9.x refactoring. 2016-02-25 09:50:11 +00:00
Stian Thorgersen 3ca39801dc KEYCLOAK-2511 Rename session-state in access token response to session_state 2016-02-25 10:14:12 +01:00
Stian Thorgersen da8f2dc2ce KEYCLOAK-2500 Add cors headers to .well-known endpoints 2016-02-25 10:05:46 +01:00
Stian Thorgersen 2fce06ffca KEYCLOAK-2522 master realm admin can't use client registration api 2016-02-25 09:54:34 +01:00
Stian Thorgersen 14ea988b24 Merge pull request #2267 from ssilvert/client-tests
KEYCLOAK-2533: Test values of events in LoginEventsTest
2016-02-25 08:50:09 +01:00
Bill Burke 5723baa367 Merge pull request #2272 from patriot1burke/master
group list caching
2016-02-24 18:31:25 -05:00
Bill Burke 450ce0e0e0 oops, showSql=false 2016-02-24 17:46:30 -05:00
Bill Burke 17ea3fca0b Merge remote-tracking branch 'upstream/master' 2016-02-24 17:21:25 -05:00
Bill Burke f10f00ba71 group list caching 2016-02-24 17:21:11 -05:00
Stian Thorgersen 8c73f8743d Merge pull request #2269 from stianst/KEYCLOAK-2539
KEYCLOAK-2539
2016-02-24 16:15:50 +01:00
Stian Thorgersen ab96114ef8 KEYCLOAK-2539
Migration fails if DisplayNameHtml is null for master realm
2016-02-24 06:59:32 +01:00
Bill Burke c45e40db99 Merge pull request #2268 from patriot1burke/master
query caches
2016-02-23 15:10:58 -05:00
Bill Burke 9488787986 Merge remote-tracking branch 'upstream/master' 2016-02-23 14:36:30 -05:00
Stan Silvert 64b2aed370 KEYCLOAK-2533: Test values of events in LoginEventsTest. Also do the same
for AdminEventTest.
2016-02-23 14:20:35 -05:00
Stian Thorgersen f63bb66170 Merge pull request #2266 from stianst/master
Added wallpaper svg
2016-02-23 20:09:04 +01:00
Stian Thorgersen 1957103270 Added wallpaper svg 2016-02-23 20:08:43 +01:00
Stan Silvert 3383b044b2 KEYCLOAK-2316: Sync admin client with endpoints for Client. First commit. 2016-02-23 13:29:12 -05:00
Stian Thorgersen f34260478e Merge pull request #2263 from vmuzikar/master
[KEYCLOAK-2532] Fix Console UI tests
2016-02-23 19:25:05 +01:00
Stian Thorgersen 4cf26a68fc Merge pull request #2264 from stianst/master
KEYCLOAK-2530
2016-02-23 19:24:30 +01:00
Stian Thorgersen 2c16335a03 Updated examples with moved themes directory 2016-02-23 15:30:50 +01:00
Stian Thorgersen af26b5b610 KEYCLOAK-2530
Missing IP address in Login Events
2016-02-23 14:33:30 +01:00
Stian Thorgersen eacd689f91 Merge pull request #2262 from stianst/master
KEYCLOAK-2527
2016-02-23 14:15:25 +01:00
Stian Thorgersen 023b558f43 KEYCLOAK-2527
Cordova not working
2016-02-23 13:32:00 +01:00
Vaclav Muzikar 8601b321d5 Fix InternationalizationTest 2016-02-23 13:22:56 +01:00
Vaclav Muzikar 83181f28b2 Swap 'expected' and 'actual' in URLAssert 2016-02-23 13:13:22 +01:00
Vaclav Muzikar 77c16c320e Fix LdapUserFederationTest 2016-02-23 12:58:39 +01:00
Vaclav Muzikar a6458250bc Merge branch 'master' of https://github.com/keycloak/keycloak 2016-02-23 12:11:17 +01:00
Marek Posolda 6654a154b9 Merge pull request #2259 from mposolda/master
Fix fuse adapter
2016-02-23 11:57:21 +01:00
mposolda 4d82cc92fe Fix fuse adapter 2016-02-23 11:19:34 +01:00
Stian Thorgersen 3e1976b3e5 Merge pull request #2255 from stianst/master
Next is 1.9.1.Final-SNAPSHOT
2016-02-23 10:59:53 +01:00
Marek Posolda 695f8d34ab Merge pull request #2257 from mposolda/master
KEYCLOAK-2526 JPA migration from 1.8.1 doesn't work
2016-02-23 10:37:53 +01:00
mposolda ad753a50a3 KEYCLOAK-2526 JPA migration from 1.8.1 doesn't work 2016-02-23 10:01:40 +01:00
Stian Thorgersen 0fc9cb78d5 KEYCLOAK-2525
Built-in themes not loaded from modules
2016-02-23 09:51:22 +01:00
Stian Thorgersen ec9c9b8ee1 Remove old logo from sunrise theme example 2016-02-23 09:06:51 +01:00
Bruno Oliveira 5ac3443729 Admin client example fails after login 2016-02-23 08:51:17 +01:00
Bruno Oliveira fac8c4a6d0 Angular Product raises an exception on logout 2016-02-23 08:49:58 +01:00
Bruno Oliveira d7f4277ba8 Admin cannot manage her own profile at Customer Portal app 2016-02-23 08:49:13 +01:00
Stian Thorgersen a1d9753ec2 Next is 1.9.1.Final-SNAPSHOT 2016-02-23 08:48:26 +01:00
Bill Burke 599faa454b Merge remote-tracking branch 'upstream/master' 2016-02-22 17:17:01 -05:00
Bill Burke 4dcdaf4985 role cached queries 2016-02-22 17:16:35 -05:00
Marek Posolda 03215787e0 Merge pull request #2250 from mposolda/master
Fix SyncFederationTest to work with MSSQL and envs with slower databases
2016-02-22 12:05:19 +01:00
mposolda 838764ba5a Fix SyncFederationTest to work with MSSQL and envs with slower databases 2016-02-22 12:04:27 +01:00
Stian Thorgersen 4fd97091ff Version bump to 2.0.0.CR1-SNAPSHOT 2016-02-22 11:36:56 +01:00
Stian Thorgersen a444899176 Merge pull request #2249 from stianst/master
KEYCLOAK-2482
2016-02-22 09:40:24 +00:00
Stian Thorgersen d21a01280b KEYCLOAK-2482
Themes doesn't support patching
2016-02-22 10:01:42 +01:00
Stian Thorgersen 0840f39495 Merge pull request #2247 from vramik/KEYCLOAK-2502
Update test jvm memory settings
2016-02-22 08:03:32 +00:00
Stian Thorgersen 367f3256ea Merge pull request #2246 from mhajas/fixDemoExample
Fix DemoExampleAdapterTest
2016-02-22 08:03:27 +00:00
Stian Thorgersen 0e8c87e649 Merge pull request #2245 from mhajas/master
KEYCLOAK-2405 Add tests for mod_auth_mellon
2016-02-22 08:03:21 +00:00
Stian Thorgersen 10024f9526 Merge pull request #2243 from abstractj/KEYCLOAK-2501
KEYCLOAK-2501: Add-user should prompt user for password if not set
2016-02-22 08:02:33 +00:00
Stian Thorgersen 38ce5e069c Merge pull request #2237 from lkubik/restructurizeParents
Update parent poms structure
2016-02-22 08:01:58 +00:00
Bill Burke daa09f9a41 more fine tuning 2016-02-20 09:40:04 -05:00
Bill Burke 1511f7088f javadoc 2016-02-19 17:08:45 -05:00
Bill Burke 2e64d01251 reorg caching 2016-02-19 16:38:31 -05:00
Marek Posolda b991ba44d3 Merge pull request #2248 from mposolda/master
LDAP fixes
2016-02-19 22:05:56 +01:00
mposolda b8cf8fabe2 KEYCLOAK-2505 docs 2016-02-19 22:05:35 +01:00
Bill Burke c45524d8d4 caching 2016-02-19 15:44:19 -05:00
mposolda daca6d7062 KEYCLOAK-2505 Keystore configuration is not honored for LDAP over SSL connections 2016-02-19 18:02:39 +01:00
Vlasta Ramik 10e5205a57 Update test jvm memory settings 2016-02-19 15:29:27 +01:00
mposolda 706d4fc01c KEYCLOAK-2507 All LDAP special DN characters should be escaped in LDAPDn 2016-02-19 14:54:33 +01:00
Vaclav Muzikar d3769caaac Add wait for body to AbstractPage.navigateTo
(cherry picked from commit aba731b)
2016-02-19 13:35:31 +01:00
mhajas 0aa1b37e30 Fix DemoExampleAdapterTest 2016-02-19 13:24:28 +01:00
Vaclav Muzikar 3a138db842 Fix UserAttributesTest
(cherry picked from commit 7ac10b3)
2016-02-19 12:51:11 +01:00
Vaclav Muzikar b41dd22ed3 Fix DefaultRolesTest
(cherry picked from commit 6e7470d)
2016-02-19 12:50:52 +01:00
Vaclav Muzikar c34aa5763d Fix TokensTest
(cherry picked from commit 32e6bb0)
2016-02-19 12:50:34 +01:00
Vaclav Muzikar 02851989b3 Fix SecurityDefensesTest
(cherry picked from commit 1973f02)
2016-02-19 12:50:11 +01:00
Vaclav Muzikar 9bde0af0f1 Fix InternationalizationTest
(cherry picked from commit d58a575)
2016-02-19 12:49:47 +01:00
Vaclav Muzikar 8006c64dba Add Alert assert messages
(cherry picked from commit 9f847fa)
2016-02-19 12:48:10 +01:00
Vaclav Muzikar 4b5fee02cc Fix AbstractClientTest.createClient
(cherry picked from commit 5ab40b0)
2016-02-19 12:47:59 +01:00
Vaclav Muzikar 1569cf7fb5 Fix ClientScopeForm
(cherry picked from commit 7edd674)
2016-02-19 12:47:29 +01:00
Vaclav Muzikar 5a0711655a Fix ClientCredentialsForm
(cherry picked from commit 3e825bf)
2016-02-19 12:47:08 +01:00
Vaclav Muzikar b5660cbbab Fix LoginActions.feedbackText selector
(cherry picked from commit d05f809)
2016-02-19 12:45:52 +01:00
Vaclav Muzikar ec2cfba670 Fix LoginForm.registerLink
(cherry picked from commit 6414232)
2016-02-19 12:45:01 +01:00
Vaclav Muzikar 97d0f39346 Fix getFeedbackText()
(cherry picked from commit 131b99b)
2016-02-19 12:42:31 +01:00
Marek Posolda 7fc5afcc2f Merge pull request #2244 from mposolda/master
KEYCLOAK-2508 Possible NullPointerException during bigger load when r…
2016-02-19 12:29:17 +01:00
mhajas 2c1b13d6c2 Add tests for mod_auth_mellon 2016-02-19 11:53:19 +01:00
mposolda a441be57ed KEYCLOAK-2508 Possible NullPointerException during bigger load when removing UserSession 2016-02-19 11:49:30 +01:00
Bruno Oliveira 34a16f035a KEYCLOAK-2501: Add-user should prompt user for password if not set 2016-02-19 08:42:43 -02:00
Marek Posolda d5a57a2bbd Merge pull request #2242 from mposolda/master
KEYCLOAK-2479 Avoid ZIPException during bigger load
2016-02-18 21:49:51 +01:00
Bill Burke ed161d2426 Merge pull request #2238 from patriot1burke/master
KEYCLOAK-2477
2016-02-18 15:48:08 -05:00
mposolda 0f21b6f6d9 KEYCLOAK-2479 Avoid ZIPException during bigger load 2016-02-18 19:28:20 +01:00
Stian Thorgersen caec65c576 Merge pull request #2241 from mstruk/KEYCLOAK-2485
KEYCLOAK-2485 local description is missing in jboss as7/eap adapter
2016-02-18 16:58:11 +00:00
Stian Thorgersen ebb030c3bd Merge pull request #2240 from stianst/KEYCLOAK-2484
KEYCLOAK-2484
2016-02-18 16:57:22 +00:00
Stian Thorgersen f88908fa18 Merge pull request #2239 from mstruk/KEYCLOAK-2483
KEYCLOAK-2483 Modules are in wrong location
2016-02-18 15:55:58 +00:00
Marko Strukelj cb2aa547f9 KEYCLOAK-2485 local description is missing in jboss as7/eap adapter 2016-02-18 16:51:40 +01:00
Stian Thorgersen d386920b58 KEYCLOAK-2484
Update to new logo
2016-02-18 16:47:26 +01:00
Marko Strukelj 75d74890ca KEYCLOAK-2483 Modules are in wrong location 2016-02-18 15:41:57 +01:00
Bill Burke fd49213cb9 KEYCLOAK-2477 2016-02-17 17:02:14 -05:00
Bill Burke b20031faed Merge pull request #2228 from patriot1burke/master
make RealmModel unmodifiable collections
2016-02-17 16:58:49 -05:00
Bill Burke acf2d662c2 remove RealmModel.getClientNameMap() 2016-02-17 16:09:25 -05:00
Bill Burke 20348e5d0b remove RealmModel.getClientNameMap() 2016-02-17 16:05:25 -05:00
Bill Burke 3143a2e500 unmodifiable complete 2016-02-17 15:43:03 -05:00
Bill Burke d731189236 Merge remote-tracking branch 'upstream/master' 2016-02-17 14:57:38 -05:00
Lukas Kubik d22f4cb08c Update parent poms 2016-02-17 16:35:29 +00:00
Stian Thorgersen 98fe7c04a9 Merge pull request #2235 from pdrozd/KEYCLOAK-2498
KEYCLOAK-2498 - Fix assertion on page content.
2016-02-17 16:00:09 +00:00
Bill Burke 69c3d38164 Merge pull request #2236 from pedroigor/KEYCLOAK-2497
[KEYCLOAK-2497] - Prevent inserting malicious SAML assertion
2016-02-17 09:38:39 -05:00
Pedro Igor f7ba306016 [KEYCLOAK-2497] - Prevent inserting malicious SAML assertion 2016-02-17 11:51:58 -02:00
Pavel Drozd 38e4ad15d5 KEYCLOAK-2498 - Fix assertion on page content. 2016-02-17 14:35:41 +01:00
Marek Posolda c4144dd884 Merge pull request #2234 from mposolda/master
KEYCLOAK-2412 KEYCLOAK-2495 cluster fixes and improvements
2016-02-17 13:57:13 +01:00
mposolda e237bcd383 KEYCLOAK-2412 wildfly configs and polishing 2016-02-17 13:10:51 +01:00
mposolda f52f998bcd KEYCLOAK-2495 Improve startup time with many offlineSessions in UserSessionPersister 2016-02-17 11:02:42 +01:00
mposolda 1328531f31 KEYCLOAK-2412 Added ClusterProvider. Avoid concurrent federation sync execution by more cluster nodes at the same time.
Clustering - more progress
2016-02-17 11:02:42 +01:00
mposolda 61f2baf65e KEYCLOAK-2412 Test for concurrent federation sync in cluster 2016-02-17 11:02:42 +01:00
Stian Thorgersen 7841c5f07b Merge pull request #2232 from abstractj/cli-registration-parent
Fixes the parent for Keycloak client registration cli module
2016-02-17 07:45:15 +00:00
Stian Thorgersen 7f60e4f986 Merge pull request #2231 from stianst/master
KEYCLOAK-2493
2016-02-17 07:41:44 +00:00
Stian Thorgersen 181b329faf Merge pull request #2230 from tkyjovsk/cluster-testing
Cluster testing - updates
2016-02-17 07:41:35 +00:00
Stian Thorgersen 6d2eeb7cd6 Merge pull request #2227 from mhajas/master
Fix SAML adapter tests
2016-02-17 07:39:28 +00:00
Stian Thorgersen 5df540df8c Merge pull request #2223 from ssilvert/partial-import-tests
KEYCLOAK-2481: Create admin client endpoint for partial import + tests
2016-02-17 07:39:03 +00:00
Stian Thorgersen a8ea2ef5d5 Merge pull request #2221 from mstruk/admin-client
Move event and authentication tests under org/keycloak/teststuite/admin
2016-02-17 07:38:26 +00:00
Tomas Kyjovsky 65a840be3d KEYCLOAK-1678 added invalidation tests for groups and roles, added mroe update tests for realm 2016-02-16 18:57:12 +01:00
Bruno Oliveira f3752f804f Fixes the parent for Keycloak client registration cli module 2016-02-16 15:33:49 -02:00
Stian Thorgersen 5bc3ee0e8c KEYCLOAK-2493
Set default theme based on product name
2016-02-16 18:05:06 +01:00
Tomas Kyjovsky acf8549d51 KEYCLOAK-1678 generalized invalidation tests, added test for users and clients 2016-02-16 05:49:43 +01:00
Tomas Kyjovsky fa3c0bb0aa KEYCLOAK-1678 generalized cluster tests for any number of backend nodes 2016-02-15 23:58:50 +01:00
Tomas Kyjovsky 9fd9a1a5ad KEYCLOAK-1678 customizable server outputs to console 2016-02-15 23:56:44 +01:00
Tomas Kyjovsky cbdf30b549 KEYCLOAK-1678 parametrized ispn cache owners 2016-02-15 23:46:49 +01:00
Bill Burke c9cc189602 make RealmModel unmodifiable collections 2016-02-12 16:28:07 -05:00
Bill Burke 328e1a0cd8 Merge pull request #2224 from patriot1burke/master
cache fixes, optimzations, stress test framework
2016-02-12 12:33:55 -05:00
Bill Burke 24da8288eb Merge remote-tracking branch 'upstream/master' 2016-02-12 11:38:36 -05:00
Bill Burke 4ff1848681 javadoc 2016-02-12 11:38:12 -05:00
mhajas 474043b688 Merge remote-tracking branch 'upstream/master' 2016-02-12 16:10:03 +01:00
mhajas 7c64ab228b Fix SAML adapter tests 2016-02-12 16:05:23 +01:00
Marek Posolda a25658fb31 Merge pull request #2226 from mposolda/master
KEYCLOAK-1989 Refreshing offline tokens didn't work correctly in clus…
2016-02-12 13:32:21 +01:00
mposolda 969b8c153f KEYCLOAK-1989 Refreshing offline tokens didn't work correctly in cluster with revokeRefreshToken enabled 2016-02-12 12:54:47 +01:00
Stian Thorgersen b0dd65c706 Merge pull request #2216 from jean-merelis/master
Angular2 example
2016-02-12 11:06:00 +01:00
Marek Posolda 57eefca4a0 Merge pull request #2225 from mposolda/master
Fix MySQL
2016-02-12 09:47:37 +01:00
mposolda 132044bcb1 Support for add big number of users in batches 2016-02-12 09:06:35 +01:00
mposolda e880a768c5 Fix MySQL 2016-02-12 09:06:12 +01:00
Bill Burke 860a104828 stress testing 2016-02-12 00:30:36 -05:00
Bill Burke bddf214bc0 test 2016-02-11 22:09:58 -05:00
Bill Burke d79a7146ba fix cache 2016-02-11 22:01:54 -05:00
Stan Silvert 17e09a557b Fix conflict. 2016-02-11 15:38:58 -05:00
Stan Silvert dd9cf3be39 KEYCLOAK-2481: Create admin client endpoint for partial endpoint + tests 2016-02-11 15:26:52 -05:00
Marek Posolda 3bd6974ccb Merge pull request #2222 from mposolda/master
Fix Kerberos test broken in some environments
2016-02-11 17:26:23 +01:00
mposolda fee1f6f61a Fix Kerberos test broken in some environments 2016-02-11 16:49:21 +01:00
Marko Strukelj 92f5f8f5cd Move event and authentication tests under org/keycloak/teststuite/admin 2016-02-11 16:48:35 +01:00
Marek Posolda b234db4b34 Merge pull request #2220 from mposolda/master
KEYCLOAK-2436 Better defaults
2016-02-11 16:21:42 +01:00
mposolda 6c39810ba7 KEYCLOAK-2436 Better defaults 2016-02-11 15:50:11 +01:00
Bill Burke c2fa0e5c6d Merge pull request #2214 from mposolda/master
KEYCLOAK-2463 Fix performance issue with just 2 default connections p…
2016-02-11 09:41:48 -05:00
Bill Burke 67ce3fdbd2 Merge pull request #2215 from patriot1burke/master
concurrency, some JPA cleanup too
2016-02-11 09:41:37 -05:00
Stian Thorgersen 49d0b72c74 Merge pull request #2218 from mstruk/admin-client
KEYCLOAK-1967 Add support for authentication flows into admin-rest-client
2016-02-11 15:34:24 +01:00
Bill Burke 018c44ef2c conflicts 2016-02-11 08:43:29 -05:00
Marko Strukelj dadb470609 KEYCLOAK-1967 Add support for authentication flows into admin-rest-client 2016-02-11 12:18:01 +01:00
Stian Thorgersen a4ce389bf5 Merge pull request #2217 from stianst/master
Revert back to servlet 3.0
2016-02-11 10:02:54 +01:00
Stian Thorgersen c2a601dc04 Merge pull request #2213 from mstruk/npe
KEYCLOAK-2461 NPE when deploying an .ear
2016-02-11 09:25:25 +01:00
Stian Thorgersen 4ea586ebe6 Revert back to servlet 3.0 2016-02-11 09:09:39 +01:00
Jean Merelis 94c71aa59c fix link to angular2-product 2016-02-11 02:03:29 -02:00
Jean Merelis bc514fd308 added instructions for install and transpile angular2 2016-02-11 01:59:45 -02:00
Jean Merelis 71cfa11d2f cleanup angular2-product example 2016-02-11 01:46:31 -02:00
Jean Merelis 5e9f3b32fc add angular2-product example 2016-02-11 00:53:03 -02:00
Jean Merelis fd48d4335a add client in testream for angular2-product example 2016-02-11 00:48:05 -02:00
Bill Burke 8bf9ea838a remove some @JoinTables 2016-02-10 21:32:44 -05:00
Bill Burke f2bd50335a errors 2016-02-10 20:47:27 -05:00
Bill Burke e714d4f724 filter needs to be backward compatible 2016-02-10 14:55:18 -05:00
Bill Burke fd212a2a2a Merge remote-tracking branch 'upstream/master' 2016-02-10 14:09:43 -05:00
Bill Burke 84949bb51f concurrency 2016-02-10 14:09:29 -05:00
mposolda aac274bbb3 KEYCLOAK-2463 Fix performance issue with just 2 default connections per route in Apache HTTP client 2016-02-10 18:07:11 +01:00
Marko Strukelj 94da1dfc13 KEYCLOAK-2461 NPE when deploying an .ear 2016-02-10 16:13:46 +01:00
Stian Thorgersen 066d6bb230 Merge pull request #2211 from stianst/KEYCLOAK-2475
KEYCLOAK-2475
2016-02-10 14:52:22 +01:00
Stian Thorgersen 72ded04517 Merge pull request #2210 from stianst/KEYCLOAK-2466
KEYCLOAK-2466 Redirection back to account/password is broken
2016-02-10 14:44:54 +01:00
Stian Thorgersen 77912b2117 KEYCLOAK-2475
Move client registration endpoints
2016-02-10 14:23:04 +01:00
Stian Thorgersen dcb5ef4fd8 Merge pull request #2201 from tkyjovsk/cluster-testing
KEYCLOAK-1678 fixed containers setup & TwoNodeClusterTest
2016-02-10 14:07:51 +01:00
Stian Thorgersen d6acf2496a Merge pull request #2209 from stianst/KEYCLOAK-2472
KEYCLOAK-2472
2016-02-10 14:04:19 +01:00
Stian Thorgersen 555236c3f0 KEYCLOAK-2466 Redirection back to account/password is broken 2016-02-10 14:02:33 +01:00
Stian Thorgersen 4670d93f76 KEYCLOAK-2472
Remove deprecated endpoints
2016-02-10 13:32:53 +01:00
Stian Thorgersen 8ed1677249 Merge pull request #2188 from ahus1/logout_should_keep_fragement_KEYCLOAK-2323
Don't encode URL fragment for logout URL / KEYCLOAK-2323
2016-02-10 13:16:51 +01:00
Marek Posolda cf7a194ea3 Merge pull request #2208 from mposolda/master
KEYCLOAK-2470 Upgrade Apache HTTP Client to wildfly 10.0.0.Final alig…
2016-02-10 11:24:53 +01:00
mposolda eae36ac2c0 KEYCLOAK-2470 Upgrade Apache HTTP Client to wildfly 10.0.0.Final aligned version 2016-02-10 11:00:40 +01:00
Stian Thorgersen 6f56d006fc Merge pull request #2207 from stianst/KEYCLOAK-2303
KEYCLOAK-2303 Update Hibernate
2016-02-10 10:58:08 +01:00
Stian Thorgersen 633eb842a3 KEYCLOAK-2303 Update Hibernate 2016-02-10 10:07:56 +01:00
Stian Thorgersen 11b7e62e58 Merge pull request #2205 from stianst/KEYCLOAK-2303
KEYCLOAK-2303
2016-02-10 10:07:22 +01:00
Stian Thorgersen bb77c717c9 KEYCLOAK-2303
Update dependency versions to align with WildFly 10
2016-02-10 09:07:06 +01:00
Bill Burke 0b54838f31 concurrency 2016-02-09 22:13:55 -05:00
Bill Burke 45e5cfac99 concurrency 2 2016-02-09 21:10:30 -05:00
Marek Posolda 03b8839abe Merge pull request #2203 from mposolda/master
Support for bulk adding of users in testsuite CLI
2016-02-09 21:22:36 +01:00
mposolda 4dffc3cf7e Support for bulk adding of users in testsuite CLI 2016-02-09 21:20:05 +01:00
Tomas Kyjovsky ef77e2a246 KEYCLOAK-1678 added SessionFailoverClusterTest 2016-02-09 19:30:02 +01:00
Tomas Kyjovsky 620ca86d45 KEYCLOAK-1678 updated README with some info about cluster tests 2016-02-09 19:29:03 +01:00
Bill Burke 1c97b9c41d Merge remote-tracking branch 'upstream/master' 2016-02-09 12:26:11 -05:00
Bill Burke 347cdcbb28 concurrency 2016-02-09 12:25:48 -05:00
Tomas Kyjovsky 590ad1a7ca KEYCLOAK-1678 fixed TwoNodeClusterTest 2016-02-09 16:36:00 +01:00
Tomas Kyjovsky fd327bb225 KEYCLOAK-1678 fixed cluster containers setup (-Djava.net.preferIPv4Stack=true is needed for cluster to form) 2016-02-09 16:35:40 +01:00
Bill Burke 00236c13ff Merge pull request #2180 from cainj13/persistentWildcard
add support for wildcard persistent nameId attribute to SAML protocol
2016-02-09 09:43:30 -05:00
Stian Thorgersen cd9d67037c Merge pull request #2200 from gtudan/KEYCLOAK-2468
KEYCLOAK-2468: Update bcprov to 1.52
2016-02-09 13:31:50 +01:00
Gregor Tudan 50a2c1d0ed Use bouncy-castle version 1.52 (as provided by wildfly) 2016-02-09 10:34:35 +01:00
Stian Thorgersen 3ecdc9506e Merge pull request #2199 from stianst/KEYCLOAK-2425
KEYCLOAK-2425
2016-02-09 09:57:53 +01:00
Stian Thorgersen c4df7f7674 Merge pull request #2196 from stianst/KEYCLOAK-2434
KEYCLOAK-2434
2016-02-09 09:57:38 +01:00
Stian Thorgersen 98f9f94cab Merge pull request #2198 from tkyjovsk/cluster-testing
KEYCLOAK-1678 Initial 2-node cluster test
2016-02-09 09:05:39 +01:00
Stian Thorgersen cc7f755fe9 KEYCLOAK-2425
Replacing SNAPSHOT with timestamp in /auth/resources/<VERSION> path doesn't work well with load balancing
2016-02-09 09:03:25 +01:00
Stian Thorgersen 528e3127e6 KEYCLOAK-2434
BasicAuthRequestAuthenticator ignores HttpClientBuilder configuration
2016-02-09 08:41:35 +01:00
Stian Thorgersen 5ff266b148 Merge pull request #2197 from abstractj/KEYCLOAK-2452
Server Cache documentation is out of date
2016-02-09 08:30:36 +01:00
Tomas Kyjovsky 655a5a1401 KEYCLOAK-1678 Enabled exclusion pattern for cluster test by default. 2016-02-09 05:29:20 +01:00
Tomas Kyjovsky 4a8b19cfce KEYCLOAK-1678 Added initial cluster test for 2-node cluster. 2016-02-09 05:21:11 +01:00
Tomas Kyjovsky db25a81d23 KEYCLOAK-1678 Added module for building wildfly mod_cluster load balancer. 2016-02-09 05:20:19 +01:00
Tomas Kyjovsky 28fa2b92d9 Merge upstream-master into cluster-testing 2016-02-08 23:53:30 +01:00
Bruno Oliveira 3b6f26b2ec Server Cache documentation is out of date 2016-02-08 22:23:31 +01:00
Stian Thorgersen 155a2d687b Merge pull request #2195 from stianst/KEYCLOAK-2429
KEYCLOAK-2429
2016-02-08 20:33:25 +01:00
Stian Thorgersen cf94411aaa Merge pull request #2194 from stianst/KEYCLOAK-2426
KEYCLOAK-2426
2016-02-08 20:32:57 +01:00
Stian Thorgersen e5447f7f1e Merge pull request #2193 from stianst/KEYCLOAK-2455
KEYCLOAK-2455
2016-02-08 20:32:41 +01:00
Bill Burke 02b9d5ee13 Merge pull request #2191 from patriot1burke/master
hashcode/equals on all entities/adapters
2016-02-08 14:32:37 -05:00
Stian Thorgersen 635ccae144 KEYCLOAK-2429
Disabled Google Identity Provider still kicks in when 'Authenticate by default' is enabled
2016-02-08 19:51:21 +01:00
Stian Thorgersen d8779a3d01 KEYCLOAK-2426
No visible link for users with 'manage-users' role
2016-02-08 19:47:02 +01:00
Stian Thorgersen ec20c004ba KEYCLOAK-2455
Typo in cached ClientTemplateAdapter
2016-02-08 19:40:42 +01:00
Stian Thorgersen 5f41215e27 Merge pull request #2192 from stianst/master
KEYCLOAK-2450
2016-02-08 19:39:38 +01:00
Stian Thorgersen 98bd0b003e KEYCLOAK-2450
WildFly adapter script should support offline installation of adapter
2016-02-08 19:39:15 +01:00
Stian Thorgersen f28f87b050 Merge pull request #2189 from stianst/master
KEYCLOAK-2430 Load resource bundle before bootstrapping Angular
2016-02-08 19:20:16 +01:00
Bill Burke ffc0e4f005 hashcode/equals on all entities/adapters 2016-02-08 12:20:14 -05:00
Tomas Kyjovsky a275a24797 Added auth-server-wildfly-cluster profile. 2016-02-08 16:12:47 +01:00
Stian Thorgersen fd0d30fd1a KEYCLOAK-2430 Load resource bundle before bootstrapping Angular 2016-02-08 11:49:41 +01:00
Stian Thorgersen fb07559980 Merge pull request #2186 from vmuzikar/master
Fix Adapter Tests dependencies
2016-02-08 10:13:46 +01:00
Stian Thorgersen 8128d23059 Merge pull request #2184 from mhajas/KEYCLOAK-2391
KEYCLOAK-2391 history of resource access test
2016-02-08 10:13:35 +01:00
Stian Thorgersen 4c7f686505 Merge pull request #2182 from tkyjovsk/container-handling
Changes to container handling in arquillian testsuite, updated README
2016-02-08 10:12:45 +01:00
Stian Thorgersen 8ebf6a650f Merge pull request #2187 from ssilvert/admin-endpoint-tests
KEYCLOAK-1976: Add support for events into admin-rest-client + tests
2016-02-08 08:51:55 +01:00
Tomas Kyjovsky 1c792ad769 Merge container-handling into cluster-testing 2016-02-07 21:37:13 +01:00
Tomas Kyjovsky 1752ac8e63 Refactoring of auth-server-* and auth server migration Maven profiles 2016-02-07 21:30:54 +01:00
Tomas Kyjovsky 8f32e1b554 Adapter tests: updated artifactId of saml-post-signatures example to sales-post-sig 2016-02-07 21:28:25 +01:00
Tomas Kyjovsky 89250a69fb KEYCLOAK-1678: H2TestEnricher for running H2 server instance during integration tests. 2016-02-07 19:39:30 +01:00
Tomas Kyjovsky a264c15886 KEYCLOAK-1678: Configuration of remote (tcp) H2 datasource for wildfly. 2016-02-07 19:38:40 +01:00
Tomas Kyjovsky 96a00317b8 Merge container-handling into cluster-testing 2016-02-07 19:19:39 +01:00
Stan Silvert 228b24a1c5 Fix it right this time. (Hard to tell for sure since I can't reproduce
locally)
2016-02-06 14:43:18 -05:00
Stan Silvert d7295473c3 Fix failure when tests are run in a different order. 2016-02-06 14:34:03 -05:00
Alexander Schwartz 01083d21d0 Don't encode URL fragment for logout URL / KEYCLOAK-2323 2016-02-06 17:43:38 +01:00
mhajas be59e2419c KEYCLOAK-2391 history of resource access tests 2016-02-06 09:17:55 +01:00
Stan Silvert e89f511465 KEYCLOAK-1976: Add support for events into admin-rest-client. Also,
arquillian tests for events.
2016-02-05 18:45:25 -05:00
Josh Cain 66cec589f7 add docbook info on how NameID is calculated 2016-02-05 11:22:10 -06:00
mhajas e3d64f301d KEYCLOAK-2428 Log also other accesses 2016-02-05 11:22:10 -06:00
Stian Thorgersen ca841abe9b KEYCLOAK-2458 Added initial concurrency test for admin endpoints 2016-02-05 11:22:09 -06:00
Bill Burke 726f746b85 KEYCLOAK-2367 2016-02-05 11:22:09 -06:00
Stian Thorgersen 192987bad5 Bump version to 1.9.0.Final-SNAPSHOT 2016-02-05 11:22:09 -06:00
Vaclav Muzikar b4a2559ac5 KEYCLOAK-2451 Add Internationalization test 2016-02-05 11:22:09 -06:00
Bill Burke 23e5357870 Merge pull request #2185 from mhajas/KEYCLOAK-2428
KEYCLOAK-2428 Log also other accesses on adapter
2016-02-05 10:37:37 -05:00
Stian Thorgersen 9c1f084dbc Merge pull request #2183 from stianst/master
KEYCLOAK-2458 Added initial concurrency test for admin endpoints
2016-02-05 12:17:20 +01:00
Vaclav Muzikar 94dbeb9c8d Fix Adapter Tests dependencies 2016-02-05 12:10:19 +01:00
mhajas 8a8552822a KEYCLOAK-2428 Log also other accesses 2016-02-05 11:56:05 +01:00
Stian Thorgersen 1c0f1b4e60 Merge pull request #2181 from patriot1burke/master
KEYCLOAK-2367
2016-02-05 10:50:27 +01:00
Stian Thorgersen d12119a089 KEYCLOAK-2458 Added initial concurrency test for admin endpoints 2016-02-05 10:35:56 +01:00
Tomas Kyjovsky dfeb35b5e6 Updated Arquillian testsuite README / UI Testing. 2016-02-05 04:16:01 +01:00
Tomas Kyjovsky 585f1035f9 Updated Arquillian testsuite README. 2016-02-05 03:54:22 +01:00
Tomas Kyjovsky 64212fc9a2 Merge upstream-master into container-handling 2016-02-05 01:31:02 +01:00
Tomas Kyjovsky 191d03f5f3 minor edits 2016-02-05 01:29:53 +01:00
Tomas Kyjovsky 58084d5ee5 KEYCLOAK-1678 Fixed app-server containers' handling. 2016-02-05 01:07:40 +01:00
Bill Burke c63ef3c825 Merge remote-tracking branch 'upstream/master' 2016-02-04 16:50:16 -05:00
Bill Burke e26ac0983a KEYCLOAK-2367 2016-02-04 16:50:02 -05:00
Tomas Kyjovsky 3a51b3530d KEYCLOAK-1678 Reorganized containers handling. (WIP: adapter-libs installation via CLI doesn't work) 2016-02-04 20:24:58 +01:00
Josh Cain d5d954e80a add support for wildcard persistent nameId attribute to SAML protocol 2016-02-04 11:06:14 -06:00
Stian Thorgersen d8d96e5ec1 Merge pull request #2177 from vmuzikar/master
KEYCLOAK-2451 Add Internationalization test
2016-02-04 16:35:24 +01:00
Stian Thorgersen b32365aa12 Merge pull request #2179 from stianst/master
Bump version to 1.9.0.Final-SNAPSHOT
2016-02-04 16:35:04 +01:00
Stian Thorgersen 579ab56a5a Bump version to 1.9.0.Final-SNAPSHOT 2016-02-04 15:55:11 +01:00
Vaclav Muzikar 9e8a33710f KEYCLOAK-2451 Add Internationalization test 2016-02-04 12:48:06 +01:00
Stian Thorgersen affe6ef229 Merge pull request #2176 from stianst/master
KEYCLOAK-2446
2016-02-04 10:12:55 +01:00
Stian Thorgersen 19b1190185 Merge pull request #2175 from pdrozd/KEYCLOAK-2445
KEYCLOAK-2445 - Added ssl profile to eap7 server and adapter.
2016-02-04 09:55:22 +01:00
Stian Thorgersen 040b32ead7 KEYCLOAK-2446
Cordova not working
2016-02-04 09:47:25 +01:00
Stian Thorgersen 989e2dcc11 Merge pull request #2174 from stianst/master
Fix provider examples
2016-02-04 09:18:09 +01:00
Stian Thorgersen ca38602cfe Fix provider examples 2016-02-04 09:17:44 +01:00
Marek Posolda 39379a8129 Merge pull request #2173 from mposolda/master
Docs update: Fix typo and update list of supported databases
2016-02-04 09:15:31 +01:00
mposolda 9fee1275e3 Docs update: Fix typo and update list of supported databases 2016-02-04 09:14:37 +01:00
Pavel Drozd 9adbd370c2 KEYCLOAK-2445 - Added ssl profile to eap7 server and adapter. 2016-02-04 09:10:41 +01:00
Stian Thorgersen 8931be5e61 Merge pull request #2171 from abstractj/basic-example-documentation
Fix the documentation mismatch at basic auth
2016-02-04 07:56:01 +01:00
Bill Burke 461d766f7d Merge pull request #2172 from patriot1burke/master
KEYCLOAK-2444  	KEYCLOAK-2443
2016-02-03 18:21:31 -05:00
Bill Burke 75c88999d8 Merge remote-tracking branch 'upstream/master' 2016-02-03 17:32:00 -05:00
Bill Burke c4c99d5f81 KEYCLOAK-2443 2016-02-03 17:31:50 -05:00
Bill Burke a899d86ac0 KEYCLOAK-2444 2016-02-03 16:43:29 -05:00
Bruno Oliveira 524c809c82 Fix the documentation mismatch at basic auth 2016-02-03 15:13:50 -02:00
Stian Thorgersen eae52a563c Merge pull request #2169 from stianst/master
KEYCLOAK-2441
2016-02-03 16:53:14 +01:00
Marek Posolda a25e8c337e Merge pull request #2170 from mposolda/master
Fix fuse packaging and example
2016-02-03 16:42:24 +01:00
mposolda a707aa945f Fix fuse packaging and example 2016-02-03 16:09:06 +01:00
Stian Thorgersen 1bcc305392 Remove eap6 overlay from downloads bundle 2016-02-03 15:40:38 +01:00
Stian Thorgersen fc1914e53d Merge pull request #2168 from stianst/master
KEYCLOAK-2440 Disable migration tests as they are causing problems bu…
2016-02-03 15:40:23 +01:00
Stian Thorgersen 76ca4e6475 KEYCLOAK-2441
Authenticator example doesn't work
2016-02-03 15:40:09 +01:00
Stian Thorgersen 7277df2bb5 Merge pull request #2167 from mstruk/ose-sni-master
KEYCLOAK-2439 Client adapter fails to set SNI field during TLS handshake
2016-02-03 15:17:54 +01:00
Stian Thorgersen 1d98d5db6d KEYCLOAK-2440 Disable migration tests as they are causing problems building release 2016-02-03 15:04:25 +01:00
Stian Thorgersen 337f390090 Merge pull request #2165 from stianst/master
KEYCLOAK-2435
2016-02-03 14:54:42 +01:00
Marko Strukelj 683487aafe KEYCLOAK-2439 Client adapter fails to set SNI field during TLS handshake 2016-02-03 14:47:19 +01:00
Stian Thorgersen 136c797813 KEYCLOAK-2436
Account exists page shows to primary buttons
2016-02-03 14:20:40 +01:00
Stian Thorgersen 2974034974 KEYCLOAK-2435
Feedback on login screen not showing correctly
2016-02-03 13:41:31 +01:00
Stian Thorgersen adfc93cfc9 Merge pull request #2164 from mposolda/master
Fix failing test with DB2
2016-02-03 13:04:57 +01:00
Stian Thorgersen b52ac0fbfb Merge pull request #2163 from stianst/master
KEYCLOAK-2433
2016-02-03 13:04:24 +01:00
mposolda bae3ce4aab Fix failing test with DB2 2016-02-03 12:29:37 +01:00
Stian Thorgersen 60872dd8dd KEYCLOAK-2433
ClassNotFoundException: javax.ws.rs.core.Response from Module 'org.keycloak.keycloak-server-spi:main'
2016-02-03 12:25:31 +01:00
Stian Thorgersen 60f9f73c4c Merge pull request #2162 from stianst/master
KEYCLOAK-1524
2016-02-03 11:49:43 +01:00
Stian Thorgersen c7a8742a36 KEYCLOAK-1524
Source code headers
2016-02-03 11:20:22 +01:00
Stian Thorgersen c9c590d1cf Merge pull request #2161 from mposolda/master
KEYCLOAK-2431 Ensure users removed through UserManager to properly in…
2016-02-03 10:53:51 +01:00
Stian Thorgersen bdc0977a0e Merge pull request #2152 from vramik/KEYCLOAK-2423
KEYCLOAK-2423: Update arquillian testsuite for eap7
2016-02-03 10:53:25 +01:00
Stian Thorgersen 1a31c3af15 Merge pull request #2125 from mhajas/mellon
KEYCLOAK-2405 mod_auth_mellon test + docker image
2016-02-03 10:21:27 +01:00
mposolda db76655717 KEYCLOAK-2431 Ensure users removed through UserManager to properly invoke callbacks. Make UserSessionPersister implementations more resistent when user was not properly removed 2016-02-03 10:16:39 +01:00
Stian Thorgersen 1edbf96cae Merge pull request #2160 from stianst/master
KEYCLOAK-2299
2016-02-03 10:13:24 +01:00
Stian Thorgersen 26897ea46d KEYCLOAK-2299
createdDate of credential is not exported
2016-02-03 09:49:10 +01:00
Bill Burke c68a78bd31 Merge pull request #2159 from patriot1burke/master
filter examples, subsystem dependencies
2016-02-02 19:51:00 -05:00
Bill Burke ec9b9879e8 filter examples, subsystem dependencies 2016-02-02 19:15:05 -05:00
Bill Burke 11eaf0d731 Merge pull request #2157 from mposolda/master
KEYCLOAK-2404 Fix migration issue on postgres from 1.6.0
2016-02-02 14:06:56 -05:00
Bill Burke 2934cb108f Merge pull request #2158 from patriot1burke/master
KEYCLOAK-2297
2016-02-02 14:06:17 -05:00
Bill Burke 84bc19ff87 Merge remote-tracking branch 'upstream/master' 2016-02-02 12:28:59 -05:00
Bill Burke d0b17a0aea KEYCLOAK-2297 2016-02-02 12:28:50 -05:00
Bill Burke 057e049bde Merge pull request #2156 from patriot1burke/master
KEYCLOAK-2220
2016-02-02 11:29:21 -05:00
mposolda 8838486df6 KEYCLOAK-2404 Fix migration issue on postgres from 1.6.0 2016-02-02 17:05:54 +01:00
Bill Burke e2287188a8 Merge remote-tracking branch 'upstream/master' 2016-02-02 09:50:21 -05:00
Bill Burke 0f63a5063b KEYCLOAK-2220 2016-02-02 09:46:28 -05:00
Bill Burke 0d842f47a7 Merge pull request #2155 from stianst/KEYCLOAK-2424
KEYCLOAK-2424 Add delete role button to client role list
2016-02-02 09:34:40 -05:00
Bill Burke 40fee55474 Merge pull request #2154 from mposolda/master
KEYCLOAK-1506 Mysql warning at startup
2016-02-02 09:34:33 -05:00
Bill Burke d1a4221ce6 Merge pull request #2153 from stianst/master
KEYCLOAK-2420
2016-02-02 09:34:24 -05:00
Stian Thorgersen 6c106dc681 KEYCLOAK-2424 Add delete role button to client role list 2016-02-02 14:32:58 +01:00
mposolda 958c379688 KEYCLOAK-1506 Mysql warning at startup 2016-02-02 14:28:34 +01:00
Stian Thorgersen 26264ec042 KEYCLOAK-2420
Export client
2016-02-02 14:24:52 +01:00
Stian Thorgersen 00e50111b1 Merge pull request #2151 from stianst/master
KEYCLOAK-1774
2016-02-02 11:37:43 +01:00
Vlasta Ramik 8e49d4ff90 Update arquillian testsuite for eap7 2016-02-02 11:05:35 +01:00
Stian Thorgersen 747d110da0 KEYCLOAK-2421
Remove aesh module from server feature pack
2016-02-02 10:54:54 +01:00
Stian Thorgersen af9e995412 KEYCLOAK-1774
Upgrade to WildFly 10.0.0.Final
2016-02-02 10:36:11 +01:00
Bill Burke b0f548f3cb Merge pull request #2149 from patriot1burke/master
KEYCLOAK-2408 KEYCLOAK-2330
2016-02-01 17:14:15 -05:00
Bill Burke c65160db1f Merge remote-tracking branch 'upstream/master' 2016-02-01 16:35:12 -05:00
Bill Burke 37cf335247 KEYCLOAK-2408 KEYCLOAK-2330 2016-02-01 16:35:00 -05:00
Marek Posolda 8ad8a3fbac Merge pull request #2148 from mposolda/master
KEYCLOAK-2235 Fix possible transaction leak at startup with add-user
2016-02-01 22:23:43 +01:00
Bill Burke bd104e2138 Merge pull request #2137 from abstractj/KEYCLOAK-2411
Realm import will raise NPE when clientID is missing
2016-02-01 16:03:17 -05:00
mposolda 6b2fb9a2bb KEYCLOAK-2235 Fix possible transaction leak at startup with add-user 2016-02-01 21:47:46 +01:00
Bill Burke c5b0bb64f7 Merge pull request #2146 from patriot1burke/master
saml subsystem as7 backport
2016-02-01 14:58:19 -05:00
Bill Burke f660e4e757 Merge pull request #2147 from mposolda/master
KEYCLOAK-2235 Fix transaction leaks
2016-02-01 14:58:10 -05:00
mposolda 732256eceb KEYCLOAK-2235 Fix transaction leaks 2016-02-01 18:21:27 +01:00
Bill Burke 9bc5a4592c fix 2016-02-01 10:39:00 -05:00
Bill Burke 4ba77a15a0 Merge remote-tracking branch 'upstream/master' 2016-02-01 10:36:45 -05:00
Bill Burke 66f4921227 saml subsystem as7 backport 2016-02-01 10:36:25 -05:00
Stian Thorgersen 77a7b5a130 Merge pull request #2116 from mstruk/KEYCLOAK-2315
KEYCLOAK-2315 Remove jboss-earlyaccess-repository repository
2016-02-01 15:26:26 +01:00
Marek Posolda dab7f617d4 Merge pull request #2144 from mposolda/master
KEYCLOAK-330 Fix failing test with DB2
2016-02-01 10:57:44 +01:00
mposolda f268170aa9 KEYCLOAK-330 Fix failing test with DB2 2016-02-01 10:57:04 +01:00
Bill Burke db78ea76b8 Merge pull request #2142 from patriot1burke/master
saml subsystem model changes
2016-01-30 08:40:10 -05:00
Bill Burke dede702b65 Merge pull request #2140 from vmuzikar/master
KEYCLOAK-2415 Add disabledClient test
2016-01-30 07:20:26 -05:00
Bill Burke 6c020661e8 saml subsystem model changes 2016-01-30 07:13:13 -05:00
Marek Posolda 1d023056e9 Merge pull request #2141 from mposolda/master
KEYCLOAK-2292 Broker login: remove identity provider prefix from auto…
2016-01-29 21:15:54 +01:00
mposolda 9332655110 KEYCLOAK-2292 Broker login: remove identity provider prefix from autogenerated username 2016-01-29 18:43:12 +01:00
Marek Posolda 61c838955e Merge pull request #2139 from mposolda/master
KEYCLOAK-330 IBM DB2 support
2016-01-29 18:43:01 +01:00
Vaclav Muzikar bd6f2a3e2d KEYCLOAK-2415 Add disabledClient test 2016-01-29 18:19:30 +01:00
Vaclav Muzikar b930ef4b1b KEYCLOAK-2414 Fix ClientSettingsTest 2016-01-29 18:18:51 +01:00
mposolda dcebc453df KEYCLOAK-330 IBM DB2 support 2016-01-29 17:43:11 +01:00
Bill Burke 5959d5cbf3 Merge pull request #2130 from ssilvert/partial-import-description
KEYCLOAK-2335: Document Partial Import in Admin Console
2016-01-29 09:34:39 -05:00
Bill Burke 39f12549a3 Merge pull request #2122 from abstractj/KEYCLOAK-2151
Brute force detector active for non-existing accounts
2016-01-29 09:32:28 -05:00
Bill Burke 16cb4eca0c Merge pull request #2136 from mhajas/my-prod-branch
Fix adapter tests
2016-01-29 09:30:34 -05:00
Bill Burke 8cffbdd581 Merge pull request #2131 from patriot1burke/master
saml adapter needs endpoint
2016-01-29 09:30:04 -05:00
Marek Posolda 366606e6a0 Merge pull request #2138 from mposolda/master
Fix testsuite with Sybase
2016-01-29 15:04:21 +01:00
mposolda f2082d5e24 Fix testsuite with Sybase 2016-01-29 13:30:44 +01:00
Marek Posolda 41551e08b0 Merge pull request #2129 from georgekankava/staging/literal-boolean-values-should-not-be-used-in-condition-expressions-fix-1
squid:S1125 - Literal boolean values should not be used in condition expressions
2016-01-29 13:23:20 +01:00
Marek Posolda a7619f90e2 Merge pull request #2128 from georgekankava/staging/long-suffix-L-should-be-upper-case-fix-1
squid:LowerCaseLongSuffixCheck - Long suffix "L" should be upper case
2016-01-29 13:20:42 +01:00
Bruno Oliveira 5eb8d3be5a Realm import will raise NPE when clientID is missing 2016-01-29 10:05:42 -02:00
mhajas 3e1aef1678 Merge remote-tracking branch 'upstream/master' into my-prod-branch 2016-01-29 12:11:58 +01:00
mhajas ce907bbd15 Fix adapter tests demorealm 2016-01-29 11:48:10 +01:00
Stian Thorgersen c1cdcb424f Merge pull request #2135 from stianst/master
KEYCLOAK-2410
2016-01-29 11:36:05 +01:00
mhajas c5719b4604 Fix SAML tests 2016-01-29 11:23:22 +01:00
Stian Thorgersen 9bd04b18a8 KEYCLOAK-2410
TOTP shows both realm name and display name
2016-01-29 11:01:49 +01:00
Marek Posolda 9f2bd0f55e Merge pull request #2132 from mposolda/master
Fix sybase
2016-01-29 08:38:06 +01:00
mposolda 8ed76c6921 Fix sybase 2016-01-29 08:36:05 +01:00
Bill Burke 34095ef522 docs 2016-01-28 23:28:11 -05:00
Bill Burke a068d83dd8 saml adapter endpoint changes 2016-01-28 22:56:14 -05:00
Stan Silvert 3a2ec809e9 KEYCLOAK-2335: Document Partial Import in Admin Console 2016-01-28 16:56:28 -05:00
George Kankava 92a494359d squid:S1125 - Literal boolean values should not be used in condition expressions 2016-01-29 00:22:47 +04:00
Marek Posolda 02d3993c7f Merge pull request #2127 from mposolda/master
KEYCLOAK-2364 Fix migration with MSSQL
2016-01-28 17:54:48 +01:00
mposolda 6046d15279 KEYCLOAK-2364 Fix migration with MSSQL 2016-01-28 16:39:01 +01:00
Bill Burke fae05c1cc5 Merge pull request #2126 from patriot1burke/master
browser back button
2016-01-28 10:31:14 -05:00
George Kankava e937dda556 squid:LowerCaseLongSuffixCheck - Long suffix "L" should be upper case 2016-01-28 19:06:41 +04:00
Bill Burke 93f85d34a7 Merge remote-tracking branch 'upstream/master' 2016-01-28 09:23:34 -05:00
Bill Burke 6f036ac434 fix tests 2016-01-28 09:23:23 -05:00
mhajas 6b6fb9975f Merge remote-tracking branch 'upstream/master' into mellon 2016-01-28 10:47:34 +01:00
Marek Posolda 1618d9250a Merge pull request #2124 from mposolda/master
KEYCLOAK-1402 Postgresplus 9.4 support
2016-01-28 10:18:14 +01:00
mposolda e1416b658f KEYCLOAK-1402 Postgresplus 9.4 support 2016-01-28 10:12:23 +01:00
mhajas 50f4986dd7 Docker image apache + mod_auth_mellon 2016-01-28 09:54:39 +01:00
mhajas 6c5fb2a4aa Tests for mod_auth_mellon 2016-01-28 09:54:28 +01:00
Bill Burke 9027f9b4d3 fix2 2016-01-27 23:06:20 -05:00
Bill Burke 8a3148017d fix 2016-01-27 23:04:12 -05:00
Bill Burke 5853ae4eff whoops 2016-01-27 22:59:41 -05:00
Bill Burke b37fbd6a2f browser back button 2016-01-27 22:59:08 -05:00
Bill Burke 25347cd45e browser back button 2016-01-27 22:14:28 -05:00
Bruno Oliveira 385717c0fb Brute force detector active for non-existing accounts 2016-01-27 19:09:44 -02:00
Marko Strukelj 5826c034eb KEYCLOAK-2315 Remove jboss-earlyaccess-repository repository 2016-01-27 14:17:25 +01:00
Stian Thorgersen 1b0ccae4ac Merge pull request #2121 from pdrozd/KEYCLOAK-2401-ssl
KEYCLOAK-2401 - add ssl profile and fix urls when ssl profile enabled.
2016-01-27 11:39:06 +01:00
Stian Thorgersen 003ed1e302 Merge pull request #2120 from pdrozd/KEYCLOAK-2400
KEYCLOAK-2400 - adapter installation on windows
2016-01-27 11:38:52 +01:00
Pavel Drozd 09f8d14572 KEYCLOAK-2401 - add ssl profile and fix urls when ssl profile enabled. 2016-01-27 10:06:11 +01:00
Pavel Drozd bf276a833e KEYCLOAK-2400 - changed adapter installation to be able to install it on windows. 2016-01-27 08:34:04 +01:00
Bill Burke 81569ce5d2 Merge pull request #2119 from patriot1burke/master
KEYCLOAK-2349
2016-01-26 16:22:02 -05:00
Bill Burke 527edf8a3b Merge pull request #2115 from mstruk/typo
Fix typo bug introduced during modules refactoring
2016-01-26 16:06:21 -05:00
Bill Burke 66e1ee79d0 KEYCLOAK-2349 2016-01-26 15:45:40 -05:00
Marek Posolda b36a4bee5d Merge pull request #2117 from mposolda/master
KEYCLOAK-2080 Downgrade H2 to 1.3.173, which is version in Wildfly  1…
2016-01-26 21:24:20 +01:00
Bill Burke 9fa35eda69 Merge pull request #2118 from patriot1burke/master
KEYCLOAK-2387
2016-01-26 14:20:27 -05:00
Bill Burke 449bc5c4dc KEYCLOAK-2387 2016-01-26 14:19:53 -05:00
mposolda 526fdd021d KEYCLOAK-2080 Downgrade H2 to 1.3.173, which is version in Wildfly 10.0.0.CR5 2016-01-26 17:59:30 +01:00
Marek Posolda 4baeaded23 Merge pull request #2110 from mposolda/master
KEYCLOAK-2351 Support for response_type=token to be OAuth2 compliant
2016-01-26 17:54:08 +01:00
mposolda 3bc4355bb1 Small note about distributable HttpSessions in clustering docs 2016-01-26 17:12:26 +01:00
mposolda 3731964a2a KEYCLOAK-2351 Support for response_type=token to be OAuth2 compliant 2016-01-26 17:09:42 +01:00
Marko Strukelj 5c46f0603d Fix typo bug introduced during modules refactoring 2016-01-26 16:45:22 +01:00
mposolda 90842cf7ef Minor change in message 2016-01-26 16:24:08 +01:00
Stian Thorgersen 9143d4b5cb Merge pull request #2111 from mstruk/KEYCLOAK-2362
KEYCLOAK-2362 NPE if SSL certificate is not trusted by Java's default keystore
2016-01-26 16:17:29 +01:00
Stian Thorgersen 301b61c4f9 Merge pull request #2113 from stianst/KEYCLOAK-2327
KEYCLOAK-2327 Make sure transaction is only committed or rolledback before response is returned
2016-01-26 16:06:15 +01:00
Stian Thorgersen e3daf6fcf8 KEYCLOAK-2327 Make sure transaction is only committed for success 2016-01-26 14:47:59 +01:00
Stian Thorgersen 39b3c648a2 Merge pull request #2109 from stianst/KEYCLOAK-2218
KEYCLOAK-2218 Allow updating user without including username
2016-01-26 13:56:01 +01:00
Marko Strukelj 4f890e8f2e KEYCLOAK-2362 NPE if SSL certificate is not trusted by Java's default keystore 2016-01-26 13:53:16 +01:00
Stian Thorgersen f9fd398f5b KEYCLOAK-2218 Allow updating user without including username 2016-01-26 13:01:49 +01:00
Stian Thorgersen b93deddda3 Merge pull request #2107 from mstruk/i18n
KEYCLOAK-2305 Complete internationalization of admin console
2016-01-26 12:50:03 +01:00
Stian Thorgersen 561fa06140 Merge pull request #2106 from stianst/KEYCLOAK-1341
KEYCLOAK-1341
2016-01-26 12:48:14 +01:00
Stian Thorgersen 646c75c6ff Merge pull request #2103 from stianst/KEYCLOAK-2388
KEYCLOAK-2388
2016-01-26 12:47:51 +01:00
Marek Posolda 3a67fd7685 Merge pull request #2105 from mposolda/master
KEYCLOAK-2379 Fix possible error during sycnchronization changed user…
2016-01-26 11:48:15 +01:00
Stian Thorgersen 4a698bc22a KEYCLOAK-2388
Localisation should fallback to english rather than display raw keys
2016-01-26 11:47:30 +01:00
Stian Thorgersen 26ec117b5e KEYCLOAK-1341
Admins can change sso timeout to 1 second and then not able to login
2016-01-26 11:24:00 +01:00
Marko Strukelj ea33af2c59 KEYCLOAK-2305 Complete internationalization of admin console 2016-01-26 11:22:45 +01:00
Stian Thorgersen c55b91ed32 Merge pull request #2102 from stianst/KEYCLOAK-2237
KEYCLOAK-2237
2016-01-26 11:08:14 +01:00
mposolda 506194fb7f KEYCLOAK-2379 Fix possible error during sycnchronization changed users with Active Directory 2016-01-26 10:43:17 +01:00
Stian Thorgersen 54abfa4859 KEYCLOAK-2237
Offer the possibility to add own locale to login/registration dialogs
2016-01-26 10:16:05 +01:00
Stian Thorgersen a21f70fcd2 Merge pull request #2104 from stianst/KEYCLOAK-2390
KEYCLOAK-2390
2016-01-26 09:51:54 +01:00
Stian Thorgersen 256819ea3a Merge pull request #2101 from stianst/KEYCLOAK-2391
KEYCLOAK-2391
2016-01-26 09:31:23 +01:00
Stian Thorgersen ee847c1f20 KEYCLOAK-2390
Relative redirect uri is broken
2016-01-26 09:01:14 +01:00
Stian Thorgersen 06caa8e67e KEYCLOAK-2391
View history of access to Resource Server
2016-01-26 08:50:28 +01:00
Bill Burke bdc439b4a4 Merge pull request #2100 from patriot1burke/master
KEYCLOAK-2389
2016-01-26 00:42:29 -05:00
Bill Burke daec8977e4 KEYCLOAK-2389 2016-01-25 19:34:57 -05:00
Bill Burke 1b0aa8e55b saml logging 2016-01-25 17:38:29 -05:00
Bill Burke 85c4279f0b Merge pull request #2098 from patriot1burke/master
fix doco errors
2016-01-25 10:16:35 -05:00
Bill Burke ca2c573f50 fix doco errors 2016-01-25 10:16:08 -05:00
Bill Burke 1cc359d1d8 Merge pull request #2096 from patriot1burke/master
redirect after post in flow
2016-01-22 18:40:45 -05:00
Bill Burke c28e1c76e0 Merge remote-tracking branch 'upstream/master' 2016-01-22 18:40:14 -05:00
Bill Burke 8b7bc5b153 redirect after post in flow 2016-01-22 18:39:55 -05:00
Bill Burke d3cab2be93 Merge pull request #2094 from bdecoste/master
KeyStore element in subsystem not required
2016-01-22 18:34:55 -05:00
Bill Burke 4d18812768 Merge pull request #2093 from patriot1burke/master
KEYCLOAK-2377
2016-01-22 18:20:07 -05:00
root ae6dde9cda KeyStore element in sunsystem not required 2016-01-22 15:05:24 -08:00
Bill Burke f3ea2ab8d0 fix errant pom 2016-01-22 17:03:31 -05:00
Bill Burke 742f162cfc Merge remote-tracking branch 'upstream/master' 2016-01-22 17:01:14 -05:00
Bill Burke fedf3d0e52 KEYCLOAK-2377 2016-01-22 17:00:51 -05:00
Stian Thorgersen e71ac6f1b3 Merge pull request #2090 from velias/KEYCLOAK-2348
KEYCLOAK-2348 - Social login provider for Microsoft account - KC master branch
2016-01-22 13:26:45 +01:00
Vlastimil Elias 4e23311318 KEYCLOAK-2348 - Social login provider for Microsoft account - KC master
branch
2016-01-22 11:03:08 +01:00
Stian Thorgersen 4492af2bda Merge pull request #2089 from mikesir87/patch-1
Update javascript-adapter.xml
2016-01-22 09:10:23 +01:00
Michael Irwin cd3a6007d7 Update javascript-adapter.xml
Several spelling fixes, grammar adjustments, and other alterations.

Some parts are still a little hard to read/follow, but this is at least a little bit of an improvement.
2016-01-22 00:33:46 -05:00
Bill Burke e0af79e66b Merge pull request #2087 from patriot1burke/master
KEYCLOAK-2373 KEYCLOAK-2376
2016-01-21 21:30:01 -05:00
Bill Burke 1ee76a126f KEYCLOAK-2373 KEYCLOAK-2376 2016-01-21 20:18:07 -05:00
Stian Thorgersen de472dbd43 Merge pull request #2085 from ssilvert/logging-i18n-services2
KEYCLOAK-1280: i18n for logging in services module
2016-01-21 19:49:43 +01:00
Stian Thorgersen 72ebaca233 Merge pull request #2084 from Sweazer/credential-migration-fix
Fixed sql syntax error in credential migration script
2016-01-21 19:47:44 +01:00
Stan Silvert fa2055c896 KEYCLOAK-1280: pom should not override version from dependency management 2016-01-21 11:55:38 -05:00
Stan Silvert c6dd0d52b9 KEYCLOAK-1280: i18n logging for org.keycloak.services.scheduled 2016-01-21 11:55:36 -05:00
Stan Silvert 446cd3701f KEYCLOAK-1280: i18n logging for org.keycloak.services.resources 2016-01-21 11:55:35 -05:00
Stan Silvert e73a88443c KEYCLOAK-1280: i18n logging for org.keycloak.services.resources 2016-01-21 11:55:33 -05:00
Stan Silvert 857201ab55 KEYCLOAK-1280: i18n logging for org.keycloak.services.messages 2016-01-21 11:55:31 -05:00
Stan Silvert 779a5c2f3c KEYCLOAK-1280: i18n logging for org.keycloak.services.managers 2016-01-21 11:55:30 -05:00
Stan Silvert c81b37cc4d KEYCLOAK-1280: i18n logging for
org.keycloak.services.clientregistration.oidc
2016-01-21 11:55:28 -05:00
Stan Silvert 27ad9dcdd1 KEYCLOAK-1280: i18n logging for org.keycloak.services 2016-01-21 11:55:26 -05:00
Stan Silvert 1f04676f08 KEYCLOAK-1280: i18n logging for org.keycloak.provider 2016-01-21 11:55:25 -05:00
Stan Silvert 0de4170865 KEYCLOAK-1280: i18n logging for org.keycloak.protocol.oidc.utils 2016-01-21 11:55:23 -05:00
Stan Silvert 9c33738941 KEYCLOAK-1280: i18n logging for org.keycloak.protocol.oidc.mappers 2016-01-21 11:55:21 -05:00
Stan Silvert adfc192877 KEYCLOAK-1280: i18n logging for org.keycloak.protocol.oidc.endpoints 2016-01-21 11:55:20 -05:00
Stan Silvert 550e23c8f6 KEYCLOAK-1280: i18n logging for org.keycloak.protocol.oidc 2016-01-21 11:55:18 -05:00
Stan Silvert 9dccd45543 KEYCLOAK-1280: i18n logging for org.keycloak.protocol 2016-01-21 11:55:17 -05:00
Stan Silvert d2ad1808a5 KEYCLOAK-1280: i18n logging for org.keycloak.partialimport 2016-01-21 11:55:15 -05:00
Stan Silvert 273c662b29 KEYCLOAK-1280: i18n logging for org.keycloak.exportimport 2016-01-21 11:55:14 -05:00
Stan Silvert 24602257e1 KEYCLOAK-1280: i18n logging for org.keycloak.email 2016-01-21 11:55:12 -05:00
Stan Silvert b544adf170 KEYCLOAK-1280: i18n logging for
org.keycloak.authentication.requiredactions
2016-01-21 11:55:10 -05:00
Stan Silvert 2cecce37a7 KEYCLOAK-1280: i18n logging for org.keycloak.authentication.forms 2016-01-21 11:55:09 -05:00
Stan Silvert 7bc74aac73 KEYCLOAK-1280: i18n logging for
org.keycloak.authentication.authenticators.resetcred
2016-01-21 11:55:07 -05:00
Stan Silvert dfb92db2b7 KEYCLOAK-1280: i18n logging for
org.keycloak.authentication.authenticators.directgrant
2016-01-21 11:55:05 -05:00
Stan Silvert 36e711fb88 KEYCLOAK-1280: i18n logging for
org.keycloak.authentication.authenticators.client
2016-01-21 11:55:04 -05:00
Stan Silvert 0ef8c18b93 KEYCLOAK-1280: i18n logging for
org.keycloak.services.authentication.authenticators.browser
2016-01-21 11:55:02 -05:00
Stan Silvert b1baea7023 KEYCLOAK-1280: i18n logging for
org.keycloak.authentication.authenticators.broker
2016-01-21 11:55:00 -05:00
Stan Silvert 3b4cb94ff1 KEYCLOAK-1280: i18n logging for org.keycloak.authentication 2016-01-21 11:54:59 -05:00
Stan Silvert 7514104974 KEYCLOAK-1280: I18N for logging 2016-01-21 11:54:57 -05:00
Moritz Becker 35a2d176fa Fixed sql syntax error in credential migration script 2016-01-21 17:09:42 +01:00
Bill Burke 0df651cc0c Merge pull request #2082 from Sweazer/client-ui-fix
Client UI fix
2016-01-21 10:18:56 -05:00
Moritz Becker b23ea18c89 client UI fix 2016-01-21 16:09:13 +01:00
Bill Burke ac513eac70 Merge pull request #2081 from patriot1burke/master
fix embedded keycloak, re-org saml-core
2016-01-21 09:57:14 -05:00
Bill Burke b625ed13a8 fix embedded keycloak, re-org saml-core 2016-01-21 09:56:28 -05:00
Stian Thorgersen f5db03d6e9 Merge pull request #2079 from stianst/master
Add test with different case in scheme part of redirect uri
2016-01-21 15:30:54 +01:00
Stian Thorgersen 45f8f5c926 Merge pull request #2078 from stianst/KEYCLOAK-2370
KEYCLOAK-2370
2016-01-21 14:22:13 +01:00
Stian Thorgersen e4898ae983 Add test with different case in scheme part of redirect uri 2016-01-21 14:12:40 +01:00
Stian Thorgersen 52048a6060 KEYCLOAK-2312 Move forms/common-themes to themes 2016-01-21 13:51:01 +01:00
Stian Thorgersen 53626fca5b Merge pull request #2077 from stianst/master
KEYCLOAK-2369
2016-01-21 13:16:22 +01:00
Stian Thorgersen a43be534c2 KEYCLOAK-2370
Remove syslog event listener
2016-01-21 13:15:30 +01:00
Stian Thorgersen bfdc18f482 KEYCLOAK-2369
Account page doesn't load
2016-01-21 12:34:41 +01:00
Stian Thorgersen 5008799895 Merge pull request #2064 from tkyjovsk/KEYCLOAK-1420
Keycloak 1420 enabled arqullian testsuite in default build
2016-01-21 09:58:53 +01:00
Stian Thorgersen 86fa63fbca Merge pull request #2075 from stianst/master
Updated readme
2016-01-21 09:51:12 +01:00
Stian Thorgersen 64b75f6833 Updated readme 2016-01-21 09:50:33 +01:00
Stian Thorgersen dd4981b3fd Merge pull request #2074 from stianst/master
Updated readme
2016-01-21 09:49:05 +01:00
Stian Thorgersen a7d4d4373a Updated readme 2016-01-21 09:48:45 +01:00
Stian Thorgersen 82a260b18a Merge pull request #2073 from stianst/master
KEYCLOAK-2312 Move client-registration libs into integration
2016-01-21 09:48:06 +01:00
Stian Thorgersen 59c7cfcc97 KEYCLOAK-2312 Move client-registration libs into integration 2016-01-21 09:06:23 +01:00
Stian Thorgersen 6677995ba3 Merge pull request #2046 from tkyjovsk/KEYCLOAK-1642
KEYCLOAK-1642 Moved Admin Console UI tests to a separate module.
2016-01-21 08:25:50 +01:00
Bill Burke fcde4c3302 Merge pull request #2072 from patriot1burke/master
final re-org work
2016-01-20 17:27:03 -05:00
Bill Burke efd8317259 final re-org work 2016-01-20 17:26:26 -05:00
Bill Burke d9487a8745 social broker reorg 2016-01-20 16:46:38 -05:00
Bill Burke fd83f0acef Merge pull request #2070 from patriot1burke/master
infinispan reorg
2016-01-20 16:15:16 -05:00
Bill Burke 01f3c6ceb7 reorg event log/email 2016-01-20 15:38:09 -05:00
Bill Burke 83ecef2f29 force rebuild 2016-01-20 15:28:06 -05:00
Bill Burke ad33d3c0d8 infinispan reorg 2016-01-20 14:52:04 -05:00
Bill Burke 94fa1b2c89 Merge pull request #2068 from stianst/KEYCLOAK-2185
KEYCLOAK-2185 Add support to disable realm and user cache, and added …
2016-01-20 10:54:00 -05:00
Tomas Kyjovsky 91195102f3 Moved EAP7 adapter test module to proper location. 2016-01-20 16:15:33 +01:00
Tomas Kyjovsky 6d7092ef4c Merge upstream-master into KEYCLOAK-1642
Conflicts:
	testsuite/integration-arquillian/tests/adapters/eap6/pom.xml
	testsuite/integration-arquillian/tests/adapters/pom.xml
2016-01-20 16:12:20 +01:00
Stian Thorgersen 7ab851728e Merge pull request #2069 from stianst/KEYCLOAK-2323
KEYCLOAK-2323 Revert changes
2016-01-20 14:36:08 +01:00
Stian Thorgersen 73db7a0ea9 KEYCLOAK-2323 Revert changes 2016-01-20 14:34:59 +01:00
Stian Thorgersen d7ee63f3c1 Merge pull request #2065 from vramik/KEYCLOAK-2347
KEYCLOAK-2347: Test - Adapter - EAP 7.0
2016-01-20 14:18:58 +01:00
Stian Thorgersen 3dc090b893 KEYCLOAK-2185 Add support to disable realm and user cache, and added support to clear caches from admin console 2016-01-20 14:09:03 +01:00
Stian Thorgersen c4b1acb8eb Merge pull request #2067 from stianst/KEYCLOAK-2346
KEYCLOAK-2346 Add identity provider and external username to event wh…
2016-01-20 13:00:22 +01:00
Stian Thorgersen 733ca53983 KEYCLOAK-2346 Add identity provider and external username to event when login via broker 2016-01-20 10:23:46 +01:00
Stian Thorgersen 5b3fcab4c9 Merge pull request #2063 from tkyjovsk/KEYCLOAK-2238
Keycloak 2238 fixes for some servlet-based adapter tests
2016-01-20 09:11:44 +01:00
Stian Thorgersen 4318ed26b2 Merge pull request #2059 from fmaturel/master
Correcting French translation
2016-01-20 09:10:27 +01:00
Stian Thorgersen ddfeae39d0 Merge pull request #2055 from vramik/prod
KEYCLOAK-2340: Update arquillian testsuite for dr3 build
2016-01-20 09:09:35 +01:00
Tomas Kyjovsky eb14bdff01 KEYCLOAK-1642 Added profile for enabling console UI tests. Disabled by default. 2016-01-20 09:07:07 +01:00
Tomas Kyjovsky 424678c131 KEYCLOAK-1420 Removed redundant travis build step. 2016-01-20 07:28:27 +01:00
Tomas Kyjovsky a69a89cbde KEYCLOAK-1420 Removed redundant profile "arquillian-integration-tests" from the root POM. 2016-01-20 07:27:43 +01:00
Tomas Kyjovsky 9d68d46a1b KEYCLOAK-1420 Added arquillian testsuite to the default build. 2016-01-20 07:26:46 +01:00
Tomas Kyjovsky c8d8423852 KEYCLOAK-2238 Fixed client URLs in demorealm.json used in servlet adapter tests. 2016-01-20 07:22:19 +01:00
Tomas Kyjovsky efb82cbafb KEYCLOAK-2238 Added null check into AbstractAdapterTest 2016-01-20 07:21:31 +01:00
Tomas Kyjovsky cc82c509c5 Reorganized arquillian testsuite modules. 2016-01-20 07:16:53 +01:00
Bill Burke 9a63039d1a Merge pull request #2062 from patriot1burke/master
re-org, jpa, mongo, truststore, httpclient
2016-01-19 19:25:22 -05:00
Bill Burke 35caa10ce8 Merge remote-tracking branch 'upstream/master' 2016-01-19 18:11:56 -05:00
Bill Burke 7d08d4c036 fixes 2016-01-19 18:11:45 -05:00
Bill Burke 4ed1eb66ee truststore httpclient 2016-01-19 17:29:16 -05:00
Bill Burke 17d856a5d8 mongo 2016-01-19 17:12:54 -05:00
Bill Burke 9b09a91481 consolidate JPA 2016-01-19 17:00:58 -05:00
Bill Burke d52e186c4e Merge pull request #2060 from patriot1burke/master
reorg freemarker
2016-01-19 14:06:23 -05:00
fmaturel 17268a0bd5 Correcting French translation 2016-01-19 17:37:14 +01:00
Bill Burke 46634b386e reorg freemarker 2016-01-19 11:33:59 -05:00
Tomas Kyjovsky 1dd8a04703 Merge upstream-master into KEYCLOAK-1642 2016-01-19 17:33:20 +01:00
Vlasta Ramik 9385c8a4b3 KEYCLOAK-2340: removed reference to RH-SSO 2016-01-19 14:18:39 +01:00
Vlasta Ramik 6d872f0c03 KEYCLOAK-2347: Test - Adapter - EAP 7.0 2016-01-19 13:59:07 +01:00
Stian Thorgersen 65521864d4 Merge pull request #2056 from stianst/KEYCLOAK-2344
KEYCLOAK-2344
2016-01-19 13:35:42 +01:00
Stian Thorgersen e50709fc2d KEYCLOAK-2344
Realm Display Name is not used in verification e-mail
2016-01-19 13:01:30 +01:00
Stian Thorgersen e4e532ca39 Merge pull request #2054 from stianst/KEYCLOAK-2157
KEYCLOAK-2157
2016-01-19 11:44:22 +01:00
Vlasta Ramik 0211798161 KEYCLOAK-2340: Update arquillian testsuite for dr3 build 2016-01-19 11:09:08 +01:00
Stian Thorgersen fdd7001bee KEYCLOAK-2157
Language drop-down is not obvious
2016-01-19 10:44:31 +01:00
Stian Thorgersen 56b9009225 Merge pull request #2052 from stianst/KEYCLOAK-1572
Keycloak 1572
2016-01-19 10:44:16 +01:00
Stian Thorgersen 5f8c26de63 Merge pull request #2053 from stianst/KEYCLOAK-813
KEYCLOAK-813
2016-01-19 10:08:04 +01:00
Stian Thorgersen 3452078177 Update migration guide 2016-01-19 09:59:49 +01:00
Stian Thorgersen 8b91d46ea2 KEYCLOAK-813
Long user attributes render off the screen
2016-01-19 09:26:10 +01:00
Stian Thorgersen 32978d022d KEYCLOAK-1572
Messages on login page are not in line with PatternFly
2016-01-19 08:52:44 +01:00
Stian Thorgersen 9d9ce6c04e Merge pull request #2048 from stianst/KEYCLOAK-2286
KEYCLOAK-2286 Remove deprecated OpenID Connect endpoints
2016-01-18 21:55:22 +01:00
Stian Thorgersen e8336f3dd4 Merge pull request #2051 from stianst/KEYCLOAK-2308
KEYCLOAK-2308
2016-01-18 20:43:31 +01:00
Stian Thorgersen 1a344fe8a0 Merge pull request #2047 from tkyjovsk/KEYCLOAK-2127_property-fix
KEYCLOAK-2127 Added missing definition of "jboss.server.config.dir" p…
2016-01-18 20:43:08 +01:00
Stian Thorgersen ebd732eaff Merge pull request #2050 from stianst/KEYCLOAK-2328
KEYCLOAK-2328
2016-01-18 20:42:41 +01:00
Stian Thorgersen 594c1451c0 Merge pull request #2049 from stianst/KEYCLOAK-2160
KEYCLOAK-2160 Add id to user table
2016-01-18 20:42:21 +01:00
Stian Thorgersen bc845bed0e KEYCLOAK-2286 Remove deprecated OpenID Connect endpoints 2016-01-18 20:31:23 +01:00
Stian Thorgersen 55ab973cad KEYCLOAK-2308
Save button is enabled on Theme page
2016-01-18 20:28:34 +01:00
Stian Thorgersen 60a372a35e KEYCLOAK-2328
Client registration service documentation has <provider> in example links
2016-01-18 20:11:15 +01:00
Stian Thorgersen 75ad0c8ac6 KEYCLOAK-2160 Add id to user table 2016-01-18 20:07:57 +01:00
Tomas Kyjovsky 52af74f051 KEYCLOAK-2127 Added missing definition of "jboss.server.config.dir" property. 2016-01-18 19:33:32 +01:00
Stian Thorgersen 81fc03b3fe Merge pull request #2044 from stianst/master
KEYCLOAK-2313 Add getName, getDisplayName, getDisplayNameHtml to acco…
2016-01-18 19:17:02 +01:00
Tomas Kyjovsky 3e35f83eb3 Merge upstream-master into refactoring 2016-01-18 18:13:19 +01:00
Tomas Kyjovsky 2650cc152d Moved admin UI tests to separate module. 2016-01-18 16:02:24 +01:00
Stian Thorgersen 3f6b848849 KEYCLOAK-2313 Add getName, getDisplayName, getDisplayNameHtml to account RealmBean 2016-01-18 14:42:08 +01:00
Stian Thorgersen 79eb42522a Merge pull request #2042 from pedroigor/KEYCLOAK-2336
[KEYCLOAK-2336] - Support ECP clients using SOAP 1.1
2016-01-18 14:37:56 +01:00
Stian Thorgersen bb3f036267 Merge pull request #2041 from stianst/master
KEYCLOAK-2319
2016-01-18 14:37:34 +01:00
Pedro Igor 7ec52ebc2b [KEYCLOAK-2336] - Support ECP clients using SOAP 1.1 2016-01-18 11:01:59 -02:00
Stian Thorgersen 904ed65a5c KEYCLOAK-2319
Cannot login to admin console after upgrade 1.6 -> 1.8.CR1
2016-01-18 12:34:18 +01:00
Stian Thorgersen ded919c0a6 Merge pull request #2033 from ahus1/ahus1_location_fragment_lost_on_logout
Handle URL fragments when redirect from logout / KEYCLOAK-2323
2016-01-18 09:52:37 +01:00
Stian Thorgersen 5462075d17 Merge pull request #2039 from patriot1burke/master
broker and social re-org
2016-01-18 09:27:43 +01:00
Bill Burke b0054b7682 email, login, account 2016-01-16 09:38:24 -05:00
Bill Burke ec05103ca0 Merge remote-tracking branch 'upstream/master' 2016-01-16 09:16:17 -05:00
Bill Burke b403c9b934 broker and social 2016-01-16 09:15:17 -05:00
Bill Burke 7895eb6a3d Merge pull request #2038 from patriot1burke/master
1st phase module re-org
2016-01-15 21:22:50 -05:00
Bill Burke 76e3a72f4c fixes 2016-01-15 20:18:36 -05:00
Bill Burke d1a43d6318 fixes 2016-01-15 20:08:17 -05:00
Bill Burke 007e9530ec brute force refactr, mv protocol 2016-01-15 19:25:28 -05:00
Bill Burke 5017d71383 exportimport and timer and events 2016-01-15 19:07:17 -05:00
Bill Burke b93d55cb63 remove model-api, add server-spi 2016-01-15 18:44:17 -05:00
Bill Burke de84756515 Merge pull request #2036 from thomasdarimont/issue/KEYCLOAK-2329-propagate-generated-id-to-new-identity-provider
KEYCLOAK-2329 - fix wrong resourcePath in AdminEvent after creating new IdentityProvider stored via JPA.
2016-01-15 17:31:40 -05:00
Thomas Darimont 39cb362d63 KEYCLOAK-2329 - fix wrong resourcePath in AdminEvent after creating new IdentityProvider stored via JPA.
We now propagate the generated internal id to the given IdentityProvider instance.
Previously if one creates a new IdentityProvider in a Realm with activated admin event listeners,
then a admin event is created that contains a resourcePath that ends with /null instead of /some-uuid.
2016-01-15 20:29:38 +01:00
Stian Thorgersen 504218470b Merge pull request #2032 from ahus1/ahus1_timeskew_for_init
set timeSkew when passing tokens to init()
2016-01-15 16:38:38 +01:00
Stian Thorgersen b21bf21043 Merge pull request #2028 from stianst/JACKSON2
KEYCLOAK-1809
2016-01-15 16:29:01 +01:00
Stian Thorgersen 33565ff8d9 Added jax-rs response filter to commit transaction 2016-01-15 15:50:38 +01:00
Bill Burke e77f940c9f Merge pull request #2031 from helder-jaspion/master
Fix typos
2016-01-14 19:27:06 -05:00
Bill Burke af554a95eb Merge pull request #2034 from patriot1burke/master
saml client installation formats
2016-01-14 19:26:07 -05:00
Bill Burke 5a74c72452 Merge remote-tracking branch 'upstream/master' 2016-01-14 18:33:22 -05:00
Bill Burke 96193c0b8e formatting 2016-01-14 18:11:58 -05:00
Alexander Schwartz b7ac2548f1 Handle URL fragments when redirect from logout / KEYCLOAK-2323 2016-01-14 23:06:16 +01:00
Bill Burke 67ef3e7a45 client installation formats 2016-01-14 16:50:17 -05:00
Alexander Schwartz 9b8c80e83f set timeSkew when passing tokens to init(), also allow timeSkew to be passed as a parameter / KEYCLOAK-2322 2016-01-14 22:37:29 +01:00
Helder Alves 7283d4a0c6 Update admin-messages_en.properties
typo fix
2016-01-14 14:47:42 -02:00
Helder Alves a20aec89ba Update messages_pt_BR.properties
changed from "email" to "e-mail"
2016-01-14 14:42:42 -02:00
Helder Alves 09a4a864de Update messages_pt_BR.properties
Changed word "email" to "e-mail"
2016-01-14 14:41:24 -02:00
Stian Thorgersen 435980d776 KEYCLOAK-1809
Upgrade jackson to version 2.x
2016-01-14 16:34:30 +01:00
Stian Thorgersen e913c8da16 Merge pull request #2029 from stianst/KEYCLOAK-2307
KEYCLOAK-2307
2016-01-14 16:33:45 +01:00
Stian Thorgersen e27d0752c4 KEYCLOAK-2307
OTP field is remember in browser
2016-01-14 15:56:08 +01:00
Bill Burke 0bad78c53b Merge pull request #2025 from thomasdarimont/issue/KEYCLOAK-2311-white-list-role-for-conditional-otp
KEYCLOAK-2311 - Allow to specify role to skip conditional OTP authentication.
2016-01-14 09:05:58 -05:00
Bill Burke 1e16803d7b Merge pull request #2021 from cainj13/providerConfigPassword
Add 'password' configuration field type for federation providers
2016-01-14 09:05:17 -05:00
Stian Thorgersen 04d3f1a632 Merge pull request #2027 from stianst/master
Reintrodce creating admin from welcome page as removing it breaks tests
2016-01-14 15:02:49 +01:00
Stian Thorgersen 15103aad81 Reintrodce creating admin from welcome page as removing it breaks tests 2016-01-14 13:46:13 +01:00
Stian Thorgersen 73e23cf235 Merge pull request #2026 from raehalme/events-typo
Fixed typo in 22.2. Event Listener
2016-01-14 13:16:50 +01:00
Thomas Raehalme 8c249c331c Fixed typo in 22.2. Event Listener 2016-01-14 13:52:05 +02:00
Stian Thorgersen eb10d6bfd6 Merge pull request #2024 from stianst/FIX-CLIENT-INSTALLATION-TEST
Fix client installation test
2016-01-14 12:33:26 +01:00
Stian Thorgersen 0db0dad4e6 Merge pull request #2019 from vramik/prod
arquillian-testsuite: add support for testing prod binaries
2016-01-14 12:29:06 +01:00
Thomas Darimont d6b10aa911 KEYCLOAK-2311 - Polishing.
Aligned constant names, but keep constant values to stay compatible with previous version.
2016-01-14 12:05:19 +01:00
Stian Thorgersen a6da6e48f9 Fix client installation test 2016-01-14 11:54:39 +01:00
Thomas Darimont 92c2ec366d KEYCLOAK-2311 - Allow to specify role to skip conditional OTP authentication.
We now allow specify a role to skip OTP.
Previously it was  not possible to specify that OTP authentication should be skipped via a role but the
ConditionalOtpAuthenticator allowed to specify to show/skip OTP via a user attribute or HTTP request header pattern.
Having the "skip role" aligns the role based configuration options with the user attribute and HTTP request header configuration.
2016-01-14 11:47:30 +01:00
Bill Burke 714e2fa7a5 Merge pull request #2022 from patriot1burke/master
KEYCLOAK-2098
2016-01-13 19:44:29 -05:00
Bill Burke f9c458aa0e Merge remote-tracking branch 'upstream/master' 2016-01-13 16:18:42 -05:00
Bill Burke 9dc21224bd clean up most redirects 2016-01-13 16:18:24 -05:00
Josh Cain 202d562022 Add 'password' configuration field type for federation providers 2016-01-13 13:05:38 -06:00
Stian Thorgersen 30c3a5ed70 Merge pull request #2020 from stianst/master
Mark all SPIs as internal
2016-01-13 19:24:43 +01:00
Bill Burke b3967263d1 Merge remote-tracking branch 'upstream/master' 2016-01-13 10:16:06 -05:00
Bill Burke b9c9b58727 refactor 2016-01-13 10:15:54 -05:00
Stian Thorgersen f8841d2365 Mark all SPIs as internal 2016-01-13 15:49:53 +01:00
Vlasta Ramik 36461aabc1 renamed version.eap6.server.dist proprty to version.server.dist, removed auth-server-eap6 profile 2016-01-13 15:37:30 +01:00
Stian Thorgersen 1619624691 Merge pull request #2018 from stianst/master
KEYCLOAK-2142
2016-01-13 15:06:48 +01:00
Stian Thorgersen e572d45bea KEYCLOAK-2142
Drop support to deploy server to EAP 6.4
2016-01-13 14:32:04 +01:00
Vlasta Ramik 1bbd670091 removed redundant profile 2016-01-13 13:49:15 +01:00
Vlasta Ramik 2edc68fff6 removed redundant dependency declaration 2016-01-13 12:20:49 +01:00
Vlasta Ramik 06a3c3b995 update datasource.xsl in wildfly server module 2016-01-13 12:15:09 +01:00
Vlasta Ramik ef1aa2127d eap7 server version bump 2016-01-13 12:10:02 +01:00
Vlasta Ramik 6dd7634a77 Merge remote-tracking branch 'upstream/master' into prod
Conflicts:
	testsuite/integration-arquillian/tests/adapters/eap6/pom.xml
	testsuite/integration-arquillian/tests/adapters/eap6/src/main/xslt/standalone.xsl
2016-01-13 12:09:34 +01:00
Stian Thorgersen ddb41e2c58 Merge pull request #2017 from mposolda/master
KEYCLOAK-2270 Use sub instead of iss for clientId in JWTClientAuthent…
2016-01-13 11:10:09 +01:00
Stian Thorgersen 50fdf33040 Merge pull request #2011 from mhajas/eap64
KEYCLOAK-1646 Run adapter tests on EAP 6.4
2016-01-13 11:09:49 +01:00
Stian Thorgersen 3a83adae77 Merge pull request #2016 from stianst/master
Version bump
2016-01-13 11:09:26 +01:00
mposolda 4642876323 KEYCLOAK-2270 Use sub instead of iss for clientId in JWTClientAuthenticator 2016-01-13 10:12:20 +01:00
Stian Thorgersen 0193c696ab Version bump 2016-01-13 09:20:38 +01:00
Stian Thorgersen 75d715d8a7 Merge pull request #2015 from stianst/master
Remove reference to built-in admin account from docs
2016-01-13 09:03:15 +01:00
Stian Thorgersen 62b90ee4e3 Remove reference to built-in admin account from docs 2016-01-13 09:02:52 +01:00
Stian Thorgersen 2f88868e20 Merge pull request #2014 from ssilvert/KEYCLOAK-2294-pi-testrealm
KEYCLOAK-2294 Partial import can fail with 'Removing a detached insta…
2016-01-13 08:37:49 +01:00
Stan Silvert b0de77013c KEYCLOAK-2294 Partial import can fail with 'Removing a detached instance' 2016-01-12 15:46:48 -05:00
Stian Thorgersen 25cd3e3ba8 Merge pull request #2013 from stianst/master
KEYCLOAK-2298
2016-01-12 20:31:37 +01:00
Stian Thorgersen 1b0bf966b6 KEYCLOAK-2298
Demo doesn't have add-user-keycloak.bat
2016-01-12 19:46:34 +01:00
Marek Posolda d8e28ad96b Merge pull request #2012 from mposolda/master
KEYCLOAK-2290 Migration fixes. Bulk update of algorithm field during migration
2016-01-12 18:49:34 +01:00
mposolda 3336d4d7ac KEYCLOAK-2290 bulk update of algorithm field during migration from 1.7 2016-01-12 18:04:50 +01:00
Stian Thorgersen ee3a880a55 Merge pull request #1999 from pedroigor/KEYCLOAK-2266
[KEYCLOAK-2266] - OAuth2 Token Introspection.
2016-01-12 15:37:41 +01:00
Vlasta Ramik 52588bb25f fixed adapter dependencies for eap6 and as7 2016-01-12 15:13:59 +01:00
Vlasta Ramik a2f5d46764 add support for firefox_binary for second browser 2016-01-12 14:59:21 +01:00
Vlasta Ramik 6c3c08e711 add installing adapter tests via cli scripts, checking server log 2016-01-12 14:31:28 +01:00
Pedro Igor c9f9ee9799 [KEYCLOAK-2266] - OAuth2 Token Introspection. 2016-01-12 11:16:42 -02:00
mhajas c0d3d9cf6b Remove unnecessary lines 2016-01-12 12:52:26 +01:00
mhajas c93db980a6 Merge remote-tracking branch 'upstream/master' into eap64 2016-01-12 12:02:56 +01:00
mhajas acf0100411 Ignore DemoServletsAdapterTest on EAP6 2016-01-12 11:56:10 +01:00
Marek Posolda 0536f2c247 Merge pull request #2010 from mposolda/master
KEYCLOAK-2229 Fix NoClassDefFoundError when IdpEmailVerificationAuthe…
2016-01-12 11:31:16 +01:00
mposolda 6f262423f1 KEYCLOAK-2229 Fix NoClassDefFoundError when IdpEmailVerificationAuthenticator is used for link accounts during first broker login 2016-01-12 10:37:44 +01:00
Stian Thorgersen 3c5e7872a7 Merge pull request #2009 from stianst/master
KEYCLOAK-2290
2016-01-12 10:32:22 +01:00
Stian Thorgersen 421dc6043d KEYCLOAK-2290
Migration: empty algorithm field on user credentials of type 'password'
2016-01-12 09:46:35 +01:00
Stian Thorgersen 9402f89d8e Merge pull request #2008 from stianst/master
KEYCLOAK-2229
2016-01-12 09:18:57 +01:00
Stian Thorgersen 81a0135fa6 KEYCLOAK-2229
First broker login throws NoClassDefFoundError: org/keycloak/broker/provider/BrokeredIdentityContext
2016-01-12 09:18:03 +01:00
Bill Burke 43dc250bf2 Merge pull request #2006 from thomasdarimont/issue/KEYCLOAK-2040-Conditional-OTP-Authentication
KEYCLOAK-2040 - Add support for Conditional OTP auth.
2016-01-11 14:56:48 -05:00
Marek Posolda bc3222ab67 Merge pull request #2007 from mposolda/master
Fix DB tests. Cleanup after AddUserTest
2016-01-11 18:56:56 +01:00
mposolda e761d6ce10 Fix DB tests. Cleanup after AddUserTest 2016-01-11 18:00:56 +01:00
Thomas Darimont 46991764d4 KEYCLOAK-2040 - Add support for Conditional OTP auth.
Previously it was not possible to conditionally show a OTP authentication
form. This PR adds support to conditionally require OTP authentication
based on a custom user attribute, a role, a request header pattern
(with black- and whitelisting) as well as a configurable default in
case no condition matches.
2016-01-11 17:39:42 +01:00
Stian Thorgersen 747c0f9869 Merge pull request #2004 from stianst/master
KEYCLOAK-2288
2016-01-11 17:32:38 +01:00
Marek Posolda 5424cd80a8 Merge pull request #2005 from mposolda/master
Fix MySQL - fixing transactions during bootstrap
2016-01-11 17:02:08 +01:00
Stian Thorgersen 8d2becf681 Fix import of com.mongodb.util.MyAsserts.assertFalse 2016-01-11 15:47:09 +01:00
mposolda c3f69fdc54 Fix MySQL - fixing transactions during bootstrap 2016-01-11 15:31:45 +01:00
Stian Thorgersen 45215f361f KEYCLOAK-2288
Upgrade Mongo driver version to 3.2.0
2016-01-11 15:10:00 +01:00
Stian Thorgersen 802488cea0 Merge pull request #2003 from mposolda/master
Fix mongo model
2016-01-11 13:58:06 +01:00
Stian Thorgersen 3ac3d79e30 Merge pull request #2002 from stianst/master
KEYCLOAK-2284
2016-01-11 13:22:44 +01:00
mposolda fe8755d4a4 Fix mongo model 2016-01-11 13:00:56 +01:00
Stian Thorgersen e2b889d727 KEYCLOAK-2284
Setup of background tasks doesn't close KeycloakSession
2016-01-11 11:41:36 +01:00
Stian Thorgersen 2ec4cb82cc Merge pull request #2001 from stianst/master
KEYCLOAK-2278
2016-01-11 11:41:15 +01:00
Stian Thorgersen bc14cade62 KEYCLOAK-2278
NoSuchMethodError org.infinispan.Cache.entrySet() in EAP6 server overlay
2016-01-11 10:07:04 +01:00
Vlasta Ramik 554da73398 Merge remote-tracking branch 'upstream/master' into prod 2016-01-11 09:43:52 +01:00
Stian Thorgersen a6c852603e Merge pull request #2000 from mstruk/truststore
KEYCLOAK-1717 Truststore SPI and file provider
2016-01-11 09:24:53 +01:00
Stian Thorgersen f1602b3b8d Merge pull request #1998 from ssilvert/partial-import
KEYCLOAK-1979: Partial import
2016-01-11 09:22:09 +01:00
Stian Thorgersen 7c8bc5814e Merge pull request #1990 from raehalme/KEYCLOAK-2257
KEYCLOAK-2257: Store user attribute when accepting terms and conditions
2016-01-11 09:03:58 +01:00
Stian Thorgersen 33f83689d5 Merge pull request #1995 from stianst/master
Add test to create user, set password and login using admin endpoints
2016-01-11 09:01:44 +01:00
Marko Strukelj 80e2b8eb39 KEYCLOAK-1717 Truststore SPI and file provider 2016-01-10 12:39:30 +01:00
Stan Silvert fbff61bfba For overwrite, do all deletes, then all adds.
Minor UI enhancements.
Fix 2 JPA bugs.
General cleanup.
Documentation.
2016-01-08 13:45:22 -05:00
Bill Burke ba1a17e668 Merge pull request #1997 from patriot1burke/master
KEYCLOAK-2189
2016-01-08 12:05:50 -05:00
Bill Burke 7bc7510d1b KEYCLOAK-2189 2016-01-08 12:05:43 -05:00
Bill Burke dc337d684a improve client creation when template 2016-01-08 11:40:46 -05:00
Bill Burke 0f9d50924c Merge pull request #1996 from patriot1burke/master
improve client creation when template
2016-01-08 11:40:45 -05:00
Stian Thorgersen cf0eb1184a Add test to create user, set password and login using admin endpoints 2016-01-08 16:37:01 +01:00
Stian Thorgersen ecd31010fe Merge pull request #1994 from stianst/KEYCLOAK-2259
KEYCLOAK-2259
2016-01-08 16:36:12 +01:00
Stian Thorgersen 0985d3c88a Merge pull request #1993 from stianst/master
KEYCLOAK-2276
2016-01-08 16:35:56 +01:00
Vlasta Ramik 1cde40f556 fixed some compile warnings 2016-01-08 16:28:36 +01:00
Vlasta Ramik df590bfc3f fixed some compile warnings 2016-01-08 16:27:25 +01:00
Vlasta Ramik bce5c49cbc fixed some compile warnings 2016-01-08 16:27:06 +01:00
Vlasta Ramik bd8e662f88 fixed copy-admin-user-json-file 2016-01-08 16:13:15 +01:00
Stian Thorgersen ddd99c2411 KEYCLOAK-2259
Redirect URIs and token domains are matched case-sensitively
2016-01-08 15:38:00 +01:00
Stian Thorgersen 7834637749 KEYCLOAK-2276
Login page doesn't render properly when window height is less than 550px
2016-01-08 15:19:59 +01:00
Stian Thorgersen a90d7e54d4 Merge pull request #1992 from stianst/master
KEYCLOAK-2275
2016-01-08 15:19:38 +01:00
mhajas f9f1e36df6 Ignore DemoServletAdapterTest on EAP6 2016-01-08 14:49:48 +01:00
Stian Thorgersen bae2b62200 KEYCLOAK-2275
No Content-Security-Policy meta tag found on Cordova 5.x
2016-01-08 14:34:52 +01:00
Stian Thorgersen 71bcf697cc Merge pull request #1991 from stianst/master
KEYCLOAK-2272
2016-01-08 14:34:31 +01:00
mhajas 27f6390d00 Fix grantServerBasedApp test 2016-01-08 14:09:06 +01:00
Stian Thorgersen 9acb4b86aa Add note that JDK8 is required to build and to run the server 2016-01-08 13:56:07 +01:00
Stian Thorgersen dee0be4237 KEYCLOAK-2272
Update keycloak-datasources.xml and keycloak-infinispan.xml
2016-01-08 13:39:49 +01:00
mhajas 8c4f071003 Merge remote-tracking branch 'upstream/master' into eap64 2016-01-08 13:28:35 +01:00
Thomas Raehalme c4544e8caf Like other timestamps attribute value is now seconds since 1970. 2016-01-08 14:21:43 +02:00
Thomas Raehalme bca3893070 Required action TermsAndConditions now stores user attribute indicating acceptance of terms and conditions. 2016-01-08 13:14:04 +02:00
Vlasta Ramik c5fc4c0805 Merge remote-tracking branch 'upstream/master' into prod 2016-01-08 11:36:46 +01:00
vramik 48be6070d0 add support for prod bits 2016-01-08 11:13:59 +01:00
Bill Burke 280725a2ae Merge pull request #1985 from patriot1burke/master
KEYCLOAK-1990 KEYCLOAK-1991
2016-01-07 18:24:31 -05:00
Bill Burke 2892b093ab Merge remote-tracking branch 'upstream/master' 2016-01-07 17:25:58 -05:00
Bill Burke 78fe064cf0 2213 2016-01-07 17:25:47 -05:00
vramik 448a15b2ca install adapter via cli script from java code after start 2016-01-07 18:58:32 +01:00
Stian Thorgersen 30aaea73e4 Merge pull request #1989 from stianst/master
KEYCLOAK-2127 Re-enable set admin user with welcome page
2016-01-07 16:20:28 +01:00
Stian Thorgersen 4b1b697aa3 KEYCLOAK-2127 Re-enable set admin user with welcome page 2016-01-07 16:19:59 +01:00
Stian Thorgersen 112a44676d Merge pull request #1988 from stianst/KEYCLOAK-2269
KEYCLOAK-2269
2016-01-07 14:08:01 +01:00
Stian Thorgersen f7282d71e5 Merge pull request #1987 from stianst/master
KEYCLOAK-2252
2016-01-07 14:07:49 +01:00
Stian Thorgersen 9840c47970 Merge pull request #1986 from mhajas/master
KEYCLOAK-2127 Use add-user script for admin user creating
2016-01-07 13:17:47 +01:00
Stian Thorgersen 8695e16971 KEYCLOAK-2269
add-user script adds identityFederationEnabled field to keycloak-add-user.json
2016-01-07 13:17:10 +01:00
Stian Thorgersen 65f5ce9f13 KEYCLOAK-2252
Cannot delete client mapper with delete icon
2016-01-07 13:10:01 +01:00
Stian Thorgersen 77962ec896 Merge pull request #1984 from mstruk/providers-init
Prevent ProviderFactories being loaded twice
2016-01-07 11:57:12 +01:00
mhajas 54712e29aa Use user script for admin user creating 2016-01-07 11:24:51 +01:00
Bill Burke 71b6ed80ae Merge remote-tracking branch 'upstream/master' 2016-01-06 16:51:24 -05:00
Bill Burke 4a4bbf26f4 installation provider 2016-01-06 16:51:02 -05:00
Bill Burke 64de96d34b installation provider 2016-01-06 16:49:58 -05:00
Stian Thorgersen 084873f7fb Merge pull request #1981 from stianst/master
KEYCLOAK-2247 Upgrade to WildFly 10.0.0.CR5
2016-01-06 19:19:35 +01:00
Stian Thorgersen c684dac625 Tweak mem for Travis 2016-01-06 16:15:00 +01:00
Stian Thorgersen a5c159eeff KEYCLOAK-2247
Upgrade to WildFly 10.0.0.CR5
2016-01-06 16:15:00 +01:00
Bill Burke 1cbe5c4c80 Merge remote-tracking branch 'upstream/master' 2016-01-06 10:03:27 -05:00
Bill Burke 4a472b8272 KEYCLOAK-1990 KEYCLOAK-1991 2016-01-06 10:02:56 -05:00
Stian Thorgersen ddf74c0d9c Merge pull request #1983 from mstruk/ispn-conf
Fix missing offlineSessions local-cache config for demo-dist
2016-01-06 14:49:04 +01:00
Stian Thorgersen b2a3918fc3 Merge pull request #1982 from abstractj/KEYCLOAK-1919
Make use of display name by default for TOTP
2016-01-06 14:26:05 +01:00
Marko Strukelj aca00dd42c Prevent ProviderFactories being loaded twice 2016-01-05 23:07:13 +01:00
Marko Strukelj 2a8e868bc1 Fix missing offlineSession local-cache config for demo-dist 2016-01-05 22:56:44 +01:00
Stan Silvert 979205c827 Cleanup 2016-01-05 15:33:45 -05:00
Stan Silvert 55e36acfc0 For overwrite, delete then create.
Do all prepares to check for errors, then call doImport on each type.
Combine Realm Role and Client Role processing (RolesPartialImport).
2016-01-05 15:33:45 -05:00
Stan Silvert 4b6825806a Bare bones pagination for partial import results. 2016-01-05 15:33:44 -05:00
Stan Silvert 2d878805c1 Fix resource path for partial import events. 2016-01-05 15:33:43 -05:00
Stan Silvert dd038ddbd5 Add id to partial import results. 2016-01-05 15:33:43 -05:00
Stan Silvert f6a02bd408 Clean commit for partial import with single page for all imports. 2016-01-05 15:33:42 -05:00
Bruno Oliveira 7ec0dad88f Make use of display name by default for TOTP
- use realm name just in case of display name is not available
2016-01-05 18:31:13 -02:00
Marek Posolda 1e3ec1983d Merge pull request #1980 from mposolda/master
LDAP testing: added activation
2016-01-05 20:54:56 +01:00
mposolda 7ec02761ef LDAP testing: added activation 2016-01-05 20:53:25 +01:00
Bill Burke 7b30a6c9c4 Merge pull request #1979 from mposolda/master
Docs for LDAP mappers. Fix testsuite to pass with MSAD
2016-01-05 14:19:50 -05:00
Bill Burke 0d56713871 Merge pull request #1978 from patriot1burke/master
KEYCLOAK-2221
2016-01-05 14:19:33 -05:00
mposolda 658f204d92 Documentation for new LDAP mappers 2016-01-05 18:50:54 +01:00
mposolda 04401af470 Fix testsuite to pass with MSAD 2016-01-05 17:25:42 +01:00
Bill Burke 39d5a07218 KEYCLOAK-2221 2016-01-05 10:59:13 -05:00
Bill Burke a65f619c9a Merge pull request #1977 from mposolda/master
KEYCLOAK-2258 Removing leftovers of file model from docs and testsuite
2016-01-05 10:06:07 -05:00
Bill Burke 01c408ba68 Merge pull request #1975 from thomasdarimont/issue/KEYCLOAK-2256
KEYCLOAK-2256 - Guarantee deterministic ordering for custom user attributes in admin console.
2016-01-05 10:05:36 -05:00
Bill Burke 63975886cb Merge pull request #1974 from patriot1burke/master
set frameork for template config
2016-01-05 10:03:48 -05:00
Bill Burke c3f2ae1cd1 Merge pull request #1973 from thomasdarimont/issue/KEYCLOAK-2253
KEYCLOAK-2253 - Add support for ConfiguredProvider based UserFederationProviderFactory.
2016-01-05 10:03:40 -05:00
mposolda 133e4c59e5 KEYCLOAK-2258 Removing leftovers of file model from docs and testsuite 2016-01-05 15:25:22 +01:00
Marek Posolda d3247bc66a Merge pull request #1976 from mposolda/master
KEYCLOAK-2178 KEYCLOAK-1744 Added MSADUserAccountControlMapper. Remov…
2016-01-05 13:16:32 +01:00
mposolda b6718b44a1 KEYCLOAK-2178 KEYCLOAK-1744 Added MSADUserAccountControlMapper. Removing enableUserAccountControlAfterPasswordUpdate option 2016-01-05 12:11:48 +01:00
Thomas Darimont 15506e3db3 KEYCLOAK-2256 - Guarantee deterministic ordering for custom user attributes in admin console.
We now iterate over custom-user attributes in a deterministic way such that new attributes don't lead
to a complete reordering of the properties in the custom user attributes listings.
Previously the order of custom attributes in the user attributes listings was not deterministic which lead
to cases where keys that shared a common prefix where not placed at arbitrary positions.
Introduced a custom angularjs flter "toOrderedMapSortedByKey" that helps to deterministically iterate
over object properites.
2016-01-05 00:04:40 +01:00
Bill Burke 977f4051b3 Merge remote-tracking branch 'upstream/master' 2016-01-04 17:23:15 -05:00
Bill Burke 49c15f200e Merge pull request #1972 from dbarentine/master
KEYCLOAK-2255 Location header should return IdP alias instead of prov…
2016-01-04 17:18:42 -05:00
Bill Burke 3e5874b2a1 Merge pull request #1971 from abstractj/tooltip-initial-access-token
Tooltips for initial access token fields
2016-01-04 17:15:45 -05:00
Bill Burke f7ac5fae2a Merge pull request #1945 from raehalme/KEYCLOAK-1579
KEYCLOAK-1579: Replaced AdapterDeploymentContextBean with AdapterDeploymentContextFactoryBean
2016-01-04 17:15:25 -05:00
Bill Burke 22ba4847f4 Merge pull request #1965 from jean-merelis/translate
translation of messages to pt_BR
2016-01-04 17:14:55 -05:00
Bill Burke 90822e5b34 Merge pull request #1970 from abstractj/minor-update
Minor change for client registration documentation
2016-01-04 17:14:43 -05:00
Bill Burke 3f62cee836 Merge remote-tracking branch 'upstream/master' 2016-01-04 17:14:19 -05:00
Bill Burke 3bacbdf6ff set framework for template config 2016-01-04 17:13:15 -05:00
Thomas Darimont edcc39d906 KEYCLOAK-2253 - Use string representation for boolean properties in GenericUserFederationCtrl.
Adapted due to code review.
2016-01-04 23:07:08 +01:00
Thomas Darimont 3ec516d14c KEYCLOAK-2253 - Add support for ConfiguredProvider based UserFederationProviderFactory.
UserFederationProvidersResource is now aware of ConfiguredProvider and allows sophisticated
configuration of configuration properties via ProviderConfigProperty definitions.
See DummyUserFederationProviderFactory. getConfigProperties() for example.

Previously  UserFederationProvidersResource did only support simple key-value pairs for expressing
configurable options.

Tested this by launching a standalone KeycloakServer and creating a new Dummy UserFederationProvider.
The default values, labels and help messages are correctly displayed and the values are stored correctly.
2016-01-04 22:23:14 +01:00
Dane Barentine d8d0298498 KEYCLOAK-2255 Location header should return IdP alias instead of provider ID. 2016-01-04 11:30:57 -08:00
Thomas Raehalme 8356409b44 Fixed some typos in the docs and added paragraph regarding GrantedAuthoritiesMapper. 2016-01-04 21:16:37 +02:00
Thomas Raehalme 57971ce0b2 Changed docs to match the new code. 2016-01-04 21:09:36 +02:00
Stian Thorgersen b708cd671e Merge pull request #1969 from vmuzikar/ui-stability
[KEYCLOAK-1865] Enable LdapUserFederationTest#invalidSettingsTest - already fixed
2016-01-04 20:07:52 +01:00
Bruno Oliveira 1b857387f2 Minor change for client registration documentation 2016-01-04 16:31:39 -02:00
Bruno Oliveira cea70337ef Tooltips for initial access token fields 2016-01-04 15:49:57 -02:00
Bill Burke 6d5de7b44e Merge remote-tracking branch 'upstream/master' 2016-01-04 11:26:15 -05:00
Bill Burke 10eba78036 Merge remote-tracking branch 'upstream/master'
Conflicts:
	saml/saml-protocol/src/main/java/org/keycloak/protocol/saml/profile/ecp/SamlEcpProfileProtocolFactory.java
2016-01-04 11:25:14 -05:00
vramik efa112f820 updated version of xml plugin, fix adapter-libs-provided profile in eap6 adapter 2016-01-04 16:46:47 +01:00
Stian Thorgersen dd6b05224d Merge pull request #1968 from stianst/master
KEYCLOAK-2250
2016-01-04 14:33:39 +01:00
Stian Thorgersen e7009cac47 KEYCLOAK-2204 Add test to make sure disabled client can't refresh token 2016-01-04 13:15:58 +01:00
Stian Thorgersen eece3689f2 KEYCLOAK-2228
Deleting of realm when using JPA requires server restart
2016-01-04 13:04:33 +01:00
Vaclav Muzikar f48753f6e1 Enable LdapUserFederationTest#invalidSettingsTest - already fixed 2016-01-04 12:36:38 +01:00
Stian Thorgersen 392ce0b323 KEYCLOAK-2250
Infinispan offline sessions cache is missing from configuration files
2016-01-04 11:53:25 +01:00
Jean Merelis 2fce7f8498 fix doLogIn key (pt_BR) 2016-01-03 21:02:32 -02:00
Jean Merelis c5f19ff2b3 fix some missing translation (pt_BR) 2016-01-02 23:23:04 -02:00
Jean Merelis b24dfa0009 translation of messages to pt_BR 2016-01-02 00:37:47 -02:00
Stian Thorgersen a9b5d07263 Merge pull request #1964 from stianst/master
KEYCLOAK-2242
2015-12-23 14:39:41 +01:00
Stian Thorgersen eddf3eef17 KEYCLOAK-2242
Remove built-in admin account
2015-12-23 13:46:11 +01:00
Bill Burke dbac147419 client config refactor 2015-12-22 17:50:03 -05:00
Marek Posolda 6752a4f9b0 Merge pull request #1963 from mposolda/master
KEYCLOAK-1899 Added HardcodedLDAPRoleMapper
2015-12-22 20:43:09 +01:00
Pedro Igor 35804aa0df Merge pull request #1961 from pedroigor/KEYCLOAK-2202
[KEYCLOAK-2202] - Removing LoginProtocol in order to reuse SAML settings.
2015-12-22 13:48:54 -02:00
mposolda 41d22986d5 KEYCLOAK-1899 Added HardcodedLDAPRoleMapper 2015-12-22 16:22:02 +01:00
Pedro Igor 9172b5472e [KEYCLOAK-2202] - Removing LoginProtocol in order to reuse SAML settings. 2015-12-22 12:53:39 -02:00
Marek Posolda b27b0411a6 Merge pull request #1960 from mposolda/master
KEYCLOAK-2154 Group mapper fixes
2015-12-22 13:19:40 +01:00
mposolda 0c293089c3 KEYCLOAK-2154 Group mapper fixes 2015-12-22 12:32:37 +01:00
Marek Posolda 5403296ac6 Merge pull request #1959 from mposolda/master
KEYCLOAK-2154 Added Group mapper for LDAP. LDAP mappers improvements and fixes
2015-12-22 10:15:26 +01:00
mposolda 20548b402d Separate package for LDAP tests 2015-12-22 09:35:53 +01:00
mposolda 1747e0981f KEYCLOAK-2154 Added Group mapper for LDAP. LDAP mappers improvements and fixes 2015-12-22 08:54:09 +01:00
Bill Burke ea6374163d Merge pull request #1957 from stianst/master
KEYCLOAK-2043
2015-12-21 16:56:01 -05:00
Bill Burke 4782780857 Merge pull request #1958 from patriot1burke/master
refactor client create
2015-12-21 16:55:52 -05:00
Bill Burke b90409c5e4 refactor client create 2015-12-21 16:36:13 -05:00
Stian Thorgersen 9a921f66ff KEYCLOAK-2043
.well-known/openid-configuration doesn't set cache-control header
2015-12-21 15:35:23 +01:00
Stian Thorgersen 4a492ce13c Merge pull request #1956 from stianst/master
KEYCLOAK-2240
2015-12-21 14:29:17 +00:00
Stian Thorgersen 39904548eb KEYCLOAK-2240
Internationalize admin console title
2015-12-21 13:16:54 +01:00
Stian Thorgersen 18268f686c Merge pull request #1955 from stianst/master
Support for branding
2015-12-21 12:00:56 +00:00
mhajas 4463f6e1e1 Run adapter tests on EAP 6.4 + test fixes + hot fix of bad arquillian URL provider 2015-12-21 12:36:34 +01:00
Stian Thorgersen 1594e07628 KEYCLOAK-2239
Add link to keycloak.org to Keycloak logo
2015-12-21 12:15:36 +01:00
Stian Thorgersen 606e6fa479 KEYCLOAK-1934
Add display-name and display-name-html to realm
2015-12-21 12:15:13 +01:00
Stian Thorgersen 1afd3d422c Merge pull request #1952 from vmuzikar/ui-stability
KEYCLOAK-1865 Fix stability of some UI arquillian tests
2015-12-21 07:50:11 +00:00
Bill Burke 80fae7116b Merge pull request #1953 from patriot1burke/master
client template scope
2015-12-18 18:32:00 -05:00
Bill Burke 86a0995f29 fix test 2015-12-18 17:31:53 -05:00
Bill Burke a7c684b909 oops 2015-12-18 17:19:31 -05:00
Bill Burke 5caf3e0a2d Merge remote-tracking branch 'upstream/master' 2015-12-18 17:15:40 -05:00
Bill Burke d939b6a431 template scope 2015-12-18 17:15:27 -05:00
Vaclav Muzikar 42d17577d0 Upstream sync 2015-12-18 17:28:57 +01:00
Vaclav Muzikar eaf326dd37 Fix Client Mappers tests
(cherry picked from commit b9f9db0)
2015-12-18 17:18:59 +01:00
Vaclav Muzikar 53a542d1e2 Enable TokensTest (already fixed by previous commit bf70927)
(cherry picked from commit 6783bcb)
2015-12-18 17:15:20 +01:00
Vaclav Muzikar c51d5e9820 Fix PasswordPolicyTest
(cherry picked from commit 87b125e)
2015-12-18 17:15:18 +01:00
Vaclav Muzikar 817127a751 Fix + refactor SecurityDefensesTest
(cherry picked from commit a652173)
2015-12-18 17:15:16 +01:00
Vaclav Muzikar 0e6e3d10d8 Fix LoginSettingsTest
(cherry picked from commit bf70927)
2015-12-18 17:15:09 +01:00
vramik c759719e95 added support for set jdk for adapter container 2015-12-18 14:56:49 +01:00
vramik 19471d07b8 added support for set jdk for adapter container 2015-12-18 13:40:00 +01:00
vramik 57ea0a3b42 set default build to community eap6 2015-12-18 10:49:57 +01:00
Bill Burke 0197c69ac3 Merge pull request #1951 from pedroigor/KEYCLOAK-2202
[KEYCLOAK-2202] - Initial support for SAML ECP Profile.
2015-12-17 19:04:17 -05:00
vramik 6bb05bf339 fix 2015-12-18 00:23:19 +01:00
vramik d5950a615a exclude client tests from adapters 2015-12-18 00:15:03 +01:00
vramik 6af2e1054c eap6-adapter 2015-12-17 23:20:37 +01:00
vramik 53ca4b9294 integration-arquillian prod: add support for non default firefox 2015-12-17 10:27:42 +01:00
Stian Thorgersen 83eea5036f Merge pull request #1948 from pdrozd/wf10
Arquillian xsl templates - changed namespaces to WF10.
2015-12-17 09:01:14 +00:00
Pedro Igor 1b614a379b [KEYCLOAK-2202] - Initial support for SAML ECP Profile. 2015-12-16 18:46:52 -02:00
Bill Burke 0527d441e3 better logging 2015-12-16 12:23:41 -05:00
Marek Posolda 6569b22c79 Merge pull request #1950 from mposolda/master
Mongo fix
2015-12-16 14:36:27 +01:00
mposolda d0ec1c3b02 Mongo fix 2015-12-16 14:35:59 +01:00
Marek Posolda 2fe7e2a952 Merge pull request #1949 from mposolda/master
LDAP mappers enhancements
2015-12-16 14:33:54 +01:00
mposolda 0d52e4e6c5 Added sync support to UserFederationMapper 2015-12-16 13:52:11 +01:00
mposolda 358c273d39 KEYCLOAK-2227 Added UserRolesRetrieveStrategy. Possibility to read user role mappings through 'memberOf' attribute 2015-12-16 13:52:11 +01:00
mposolda 215d59b1e5 KEYCLOAK-2053 Memberships based on memberUid like attribute 2015-12-16 13:52:11 +01:00
mposolda 2b409b3462 Minor test fix 2015-12-16 13:52:11 +01:00
vramik aa0d463487 integration-arquillian prod: add jpa profile 2015-12-16 12:22:44 +01:00
Vlasta Ramik a418e71dc6 Merge branch 'master' of https://github.com/keycloak/keycloak into prod 2015-12-16 10:36:07 +01:00
Pavel Drozd b4e53b1677 Arquillian xsl templates - changed namespaces to WF10. 2015-12-16 10:26:10 +01:00
Marek Posolda 051f175f68 Merge pull request #1946 from dbarentine/master
KEYCLOAK-2229 Added depending on keycloak-broker-core module to resol…
2015-12-16 07:58:05 +01:00
Bill Burke fd447702e7 Merge pull request #1947 from patriot1burke/master
remove default client mappers when templated
2015-12-15 19:36:37 -05:00
Bill Burke ee79f5e69d remove default client mappers when templated 2015-12-15 17:37:53 -05:00
Dane Barentine de5baa9df7 KEYCLOAK-2229 Added depending on keycloak-broker-core module to resolve NoClassDefFoundError for BrokeredIdentityContext class 2015-12-15 11:15:55 -08:00
vramik e1de2c0661 integration-arquillian: add support for prod testing 2015-12-15 13:14:30 +01:00
Thomas Raehalme 566a58b5d8 Replaced AdapterDeploymentContextBean with AdapterDeploymentContextFactoryBean and added support for KeycloakConfigResolver. 2015-12-15 11:53:10 +02:00
Marek Posolda f837cbfaa9 Merge pull request #1944 from mposolda/master
KEYCLOAK-1906 Customized LDAP filter. LDAP conditions improvements
2015-12-14 14:50:38 +01:00
mposolda 06a55419f1 KEYCLOAK-1906 Customized LDAP filter. LDAP conditions improvements 2015-12-14 13:55:11 +01:00
Marek Posolda 82a573a536 Merge pull request #1939 from mhajas/master
KEYCLOAK-1667 Added adapter tests of SAML to integration arquillian
2015-12-14 09:26:32 +01:00
Stian Thorgersen d46bad56ae Merge pull request #1942 from keycloak/wildfly-10
KEYCLOAK-2223 Upgrade to WildFly 10.0.0.CR4
2015-12-13 21:04:38 +00:00
Marko Strukelj 32af1bd3a5 KEYCLOAK-2223 Upgrade to WildFly 10.0.0.CR4 2015-12-13 21:26:07 +01:00
Bill Burke 38b9d05cd7 Merge pull request #1941 from patriot1burke/master
client templates
2015-12-11 21:02:40 -05:00
Bill Burke e26e31d8b4 client template ui 2015-12-11 17:56:45 -05:00
Bill Burke 2328e0a6f9 Merge remote-tracking branch 'upstream/master' 2015-12-11 10:31:55 -05:00
Bill Burke 96e1813b34 client templates backend 2015-12-11 10:31:42 -05:00
mhajas 97357d020b Merge remote-tracking branch 'upstream/master' 2015-12-11 15:43:03 +01:00
Pavel Drozd b466cec4e5 Merge pull request #1940 from vramik/master
arquillian-testsuite: updated screenshooter version
2015-12-11 15:32:51 +01:00
Pavel Drozd 9228c6a16b Merge pull request #1938 from mhajas/fixDataTable
Fix adapter tests errors caused by changed DataTable fragment
2015-12-11 15:29:28 +01:00
Pavel Drozd 35f8e3c19f Merge pull request #1937 from pdrozd/ssl-required
Support for testing ssl-required.
2015-12-11 15:28:38 +01:00
vramik 9956f425eb arquillian-testsuite: updated screenshooter version 2015-12-11 12:15:27 +01:00
mhajas 5464e600ea Set SAMLServlet test abstract 2015-12-10 17:23:33 +01:00
mhajas cbdba622a5 Merge remote-tracking branch 'upstream/master' 2015-12-10 15:27:55 +01:00
mhajas 49e9965125 Fix timeouts after logout from servlet 2015-12-10 15:26:33 +01:00
mhajas dcaf7ea9d5 Fix test errors caused by changed DataTable fragment 2015-12-10 11:46:40 +01:00
Pavel Drozd 3f51f620b7 Support for testing ssl-required. 2015-12-10 07:21:23 +01:00
Marek Posolda 06e44b185e Merge pull request #1936 from mposolda/master
KEYCLOAK-2124 Post-Broker login flow support
2015-12-09 17:35:00 +01:00
mposolda 17a2bd266b KEYCLOAK-2124 post-broker login flow docs 2015-12-09 17:34:44 +01:00
mposolda 081db0d353 KEYCLOAK-2124 Post-Broker login flow support 2015-12-09 16:36:26 +01:00
mhajas b82346761c Merge remote-tracking branch 'upstream/master' 2015-12-09 10:53:50 +01:00
mhajas 595e7a92e2 Added SAML servlets adapter tests to integration-arquillian 2015-12-09 10:50:25 +01:00
mhajas fee1dea3e6 Added SAML example adapter tests to integration-arqullian 2015-12-09 10:48:53 +01:00
mhajas 9a58e1276a Added integration-arqullian servlet used in SAML tests 2015-12-09 10:45:56 +01:00
mhajas 1d401767d6 Added integration-arqullian SAML example page objects 2015-12-09 10:42:02 +01:00
mhajas 68e3b6c504 Added integration-arqullian SAML servlets page objects 2015-12-09 10:41:17 +01:00
mhajas 813ddf365e Added integration-arqullian keycloak-saml resources 2015-12-09 10:39:34 +01:00
mhajas edf3499662 Added integration-arqullian configuration for SAML adapter tests 2015-12-09 10:36:42 +01:00
Marek Posolda df26caed07 Merge pull request #1933 from vramik/clients
KEYCLOAK-2203, KEYCLOAK-2205
2015-12-09 10:28:56 +01:00
Marek Posolda 9f9067663f Merge pull request #1932 from mhajas/fixDataTable
Fix xpath for rows in DataTable fragment
2015-12-09 10:28:48 +01:00
Marek Posolda 0f3d8b8513 Merge pull request #1935 from thomasdarimont/patch-1
Fixed missing ':' in the JSON example.
2015-12-09 08:52:32 +01:00
mhajas 4ca3bf530f Merge remote-tracking branch 'upstream/master' into fixDataTable 2015-12-09 07:41:45 +01:00
Thomas Darimont c8c0a45ce4 Fixed missing ':' in the JSON example. 2015-12-08 18:45:25 +01:00
Stian Thorgersen 7313b843b9 Merge pull request #1934 from stianst/KEYCLOAK-1900-PASS-HASH
KEYCLOAK-1900 Password Hash SPI
2015-12-08 16:17:32 +01:00
Stian Thorgersen 321cac2ab8 KEYCLOAK-1900 Refactoring 2015-12-08 14:06:40 +01:00
tsudot 162dd4051d KEYCLOAK-1900 Add password hash SPI and provider
- Default encoder set to Pbkdf2PasswordEncoder
2015-12-08 13:25:59 +01:00
vramik cd19c1acdf fix tests witch fails with phantomjs 2015-12-08 08:40:40 +01:00
vramik 44ed912154 Merge branch 'master' of https://github.com/keycloak/keycloak into clients
Conflicts:
	testsuite/integration-arquillian/tests/base/src/main/java/org/keycloak/testsuite/console/page/clients/CreateClientForm.java
	testsuite/integration-arquillian/tests/base/src/main/java/org/keycloak/testsuite/console/page/fragment/FlashMessage.java
	testsuite/integration-arquillian/tests/base/src/main/java/org/keycloak/testsuite/console/page/fragment/OnOffSwitch.java
	testsuite/integration-arquillian/tests/base/src/main/java/org/keycloak/testsuite/util/WaitUtils.java
	testsuite/integration-arquillian/tests/base/src/test/java/org/keycloak/testsuite/AbstractAuthTest.java
	testsuite/integration-arquillian/tests/base/src/test/java/org/keycloak/testsuite/console/clients/ClientRolesTest.java
2015-12-07 15:45:02 +01:00
vramik 39856c32d1 Merge branch 'master' of https://github.com/keycloak/keycloak into clients
Conflicts:
	testsuite/integration-arquillian/tests/base/src/main/java/org/keycloak/testsuite/console/page/clients/CreateClientForm.java
	testsuite/integration-arquillian/tests/base/src/main/java/org/keycloak/testsuite/console/page/fragment/FlashMessage.java
	testsuite/integration-arquillian/tests/base/src/main/java/org/keycloak/testsuite/console/page/fragment/OnOffSwitch.java
	testsuite/integration-arquillian/tests/base/src/main/java/org/keycloak/testsuite/util/WaitUtils.java
	testsuite/integration-arquillian/tests/base/src/test/java/org/keycloak/testsuite/AbstractAuthTest.java
	testsuite/integration-arquillian/tests/base/src/test/java/org/keycloak/testsuite/console/clients/ClientRolesTest.java
2015-12-07 15:44:34 +01:00
vramik d3a893b171 KEYCLOAK-2203 - Add new cluster node form doesn't validate host input 2015-12-07 15:28:39 +01:00
vramik ba861f227e added UI tests for client's tabs: clustering, installation 2015-12-07 15:09:24 +01:00
Tomas Kyjovsky 4a57bcc0b4 Merge pull request #1903 from tkyjovsk/master
Increased pageload timeout. Increased other timeouts for travis. Better handling of closeable alert messages.
2015-12-07 11:09:37 +01:00
Tomas Kyjovsky 87a8e017fa Disabled crudRole test, unstable. Role tests need rewrite. 2015-12-07 09:10:32 +01:00
Tomas Kyjovsky b8fe608aaf Merge upstream-master 2015-12-07 05:59:51 +01:00
mhajas d3e6b38a8e Fix xpath for DataTable row and tests 2015-12-04 14:26:24 +01:00
Marek Posolda 8589327cdd Merge pull request #1931 from mposolda/master
KEYCLOAK-2197 Fix broker tests to work with sybase. Added LoggingRule
2015-12-04 12:24:33 +01:00
vramik 1b936a1230 added UI tests for client scope 2015-12-04 12:04:39 +01:00
mposolda 45c490b640 KEYCLOAK-2197 Fix broker tests to work with sybase. Added LoggingRule 2015-12-04 11:44:30 +01:00
vramik 1dd3fc537b added UI tests for client mappers saml 2015-12-03 14:47:13 +01:00
Stian Thorgersen 73cf2404ff Merge pull request #1928 from stianst/master
KEYCLOAK-2176 Add default roles and actions to users created with add…
2015-12-03 13:30:29 +01:00
vramik c16b6e6a43 update ClientSettingsTest due to KEYCLOAK-1129 2015-12-03 12:49:29 +01:00
Stian Thorgersen 8d23422605 KEYCLOAK-2176 Add default roles and actions to users created with add-user script 2015-12-03 11:45:56 +01:00
Stian Thorgersen 9cd8d1612e Merge pull request #1926 from ssilvert/mappers-tooltip
Fix typo for mappers.tooltip
2015-12-03 11:44:39 +01:00
Stian Thorgersen 277faea1d0 Merge pull request #1924 from ppalaga/151202-rename-w9-subsystem-dir
Rename keycloak-wf9-subsystem directory to keycloak-wildfly-subsystem to match t
2015-12-03 10:53:36 +01:00
Stian Thorgersen 58c7b6090b Merge pull request #1919 from stianst/master
Cache fixes
2015-12-03 10:53:18 +01:00
Stian Thorgersen f45bb62fcc KEYCLOAK-2192
Class serialization issues when Realm and User caches are in ASYNC mode
2015-12-03 08:24:30 +01:00
Stian Thorgersen 34c3ffaae1 Ported AdminApiTest to use admin client 2015-12-03 08:24:23 +01:00
Stian Thorgersen a218cc3034 KEYCLOAK-2179 Cache fixes 2015-12-03 08:24:16 +01:00
Stan Silvert c62b3822f4 Fix typo for mappers.tooltip 2015-12-02 11:54:02 -05:00
Tomas Kyjovsky b0e9720f88 Increased arquillian timeouts. 2015-12-02 16:46:15 +01:00
Tomas Kyjovsky 6507f58b49 Merge upstream-master 2015-12-02 16:11:45 +01:00
Tomas Kyjovsky 46e2440d30 Refactoring of arquillian waiting methods. 2015-12-02 15:58:23 +01:00
vramik 9b51b6e43b Merge upstream/master into clients 2015-12-02 15:18:15 +01:00
Peter Palaga 4772b8401a KEYCLOAK-2099 fixup: Rename keycloak-wf9-subsystem directory to
keycloak-wildfly-subsystem to match the WF module it contains
2015-12-02 14:51:48 +01:00
vramik 2b25c120d4 added UI tests for client mappers oidc 2015-12-02 13:12:05 +01:00
Marek Posolda c19e65f93c Merge pull request #1922 from mposolda/master
Minor fixes in kerberos example
2015-12-02 12:15:18 +01:00
mposolda 87994e032d Minor fixes in kerberos example 2015-12-02 11:31:12 +01:00
Stian Thorgersen ee6753d31b KEYCLOAK-1813 KEYCLOAK-2182 Fixes enable/disable cache 2015-12-02 11:24:04 +01:00
Stian Thorgersen 09c18306c2 KEYCLOAK-2179
Realm and user cache is invalidated when added to other nodes
2015-12-02 11:23:54 +01:00
Marek Posolda 6124fd64f3 Merge pull request #1918 from mposolda/master
Fix typos
2015-12-02 10:25:15 +01:00
mposolda 2a03d23098 Fix typos 2015-12-02 08:51:20 +01:00
Stian Thorgersen ff806eae08 Version bump 2015-12-01 19:54:28 +01:00
Tomas Kyjovsky e44d6f9888 Merge upstream-master 2015-12-01 17:30:02 +01:00
Tomas Kyjovsky 4e79dde17f Removed travis profile from arq. testsuite. 2015-12-01 17:29:28 +01:00
Tomas Kyjovsky 29e05ecf0d Fixed arquillian wait intervals config. 2015-12-01 17:28:28 +01:00
Marek Posolda a388782f9b Merge pull request #1916 from mposolda/master
KEYCLOAK-2172 Added migration docs
2015-12-01 17:03:15 +01:00
mposolda 352ea30d20 KEYCLOAK-2172 Added migration docs 2015-12-01 17:02:31 +01:00
Marek Posolda 6e0444e17b Merge pull request #1915 from mposolda/master
KEYCLOAK-2172 Make Identity broker User Attribute mappers compatible …
2015-12-01 16:45:47 +01:00
Stian Thorgersen b3f0dc7399 Merge pull request #1914 from stianst/KEYCLOAK-2176
KEYCLOAK-2176
2015-12-01 16:37:56 +01:00
mposolda ad34d63cb3 KEYCLOAK-2172 Make Identity broker User Attribute mappers compatible with First Broker Login flow 2015-12-01 15:48:25 +01:00
Stian Thorgersen 703720fa43 Merge pull request #1912 from stianst/KEYCLOAK-2173
KEYCLOAK-2173 No such method on Infinispan on EAP6
2015-12-01 15:19:16 +01:00
Stian Thorgersen e01c789a93 KEYCLOAK-2176
User added by add-user script doesn't have access to account management
2015-12-01 15:14:40 +01:00
Stian Thorgersen 8064c88e3c Merge pull request #1913 from stianst/KEYCLOAK-2175
KEYCLOAK-2175
2015-12-01 14:41:55 +01:00
Stian Thorgersen b06e747d28 Merge pull request #1911 from stianst/KEYCLOAK-2174
KEYCLOAK-2174 javax/mail not found for DefaultEmailSenderProviderFactory
2015-12-01 14:33:28 +01:00
Stian Thorgersen f9b89df326 KEYCLOAK-2175
WildFly server overlay includes aesh/main as well as aesh/0.65
2015-12-01 14:32:05 +01:00
Stian Thorgersen 778a96c9e4 KEYCLOAK-2173 No such method on Infinispan on EAP6 2015-12-01 13:54:17 +01:00
Stian Thorgersen f6f6b6a258 KEYCLOAK-2174 javax/mail not found for DefaultEmailSenderProviderFactory 2015-12-01 13:49:22 +01:00
vramik c4f3bd3dda Merge upstream/master 2015-12-01 12:51:57 +01:00
Marek Posolda 9d5356a001 Merge pull request #1910 from mposolda/master
KEYCLOAK-2149 Fix possible NPE during migration
2015-12-01 12:35:27 +01:00
mposolda 32fb604c88 KEYCLOAK-2149 Fix possible NPE during migration 2015-12-01 11:41:32 +01:00
Marek Posolda b3ea8f3add Merge pull request #1909 from mposolda/master
KEYCLOAK-2171 Fix broker test with MySQL and Sybase
2015-12-01 10:04:57 +01:00
mposolda 382161c425 KEYCLOAK-2171 Fix broker test with MySQL and Sybase 2015-12-01 09:20:18 +01:00
Marek Posolda ec527da868 Merge pull request #1908 from mposolda/master
KEYCLOAK-1129 Implicit flow docs
2015-12-01 00:00:40 +01:00
mposolda 0038c1ce9a KEYCLOAK-1129 Implicit flow docs 2015-11-30 23:59:09 +01:00
Marek Posolda d8fb0f1540 Merge pull request #1906 from mposolda/master
KEYCLOAK-2167 EmailAsUsername not reflected during registration throu…
2015-11-30 23:45:41 +01:00
Bill Burke 866c11b25b Merge pull request #1907 from patriot1burke/master
KEYCLOAK-2059
2015-11-30 17:42:35 -05:00
Bill Burke 64f5d032ed KEYCLOAK-2059 2015-11-30 17:40:35 -05:00
mposolda 635310123e KEYCLOAK-2167 EmailAsUsername not reflected during registration through broker 2015-11-30 22:46:34 +01:00
Marek Posolda 0bf53ad0ab Merge pull request #1905 from mposolda/master
Minor fixes
2015-11-30 20:58:26 +01:00
mposolda bf7863b300 Minor fixes 2015-11-30 20:18:36 +01:00
Marek Posolda 07e12f3b5f Merge pull request #1904 from mposolda/master
Fixes
2015-11-30 20:05:46 +01:00
mposolda 0f3d2bbfb4 KEYCLOAK-2149 DB fixes. firstBrokerLogin migration 2015-11-30 18:57:31 +01:00
Tomas Kyjovsky ed30c4454a Increased arquillian timeouts for travis. 2015-11-30 17:09:57 +01:00
Tomas Kyjovsky 0d4771a763 Merge upstream-master 2015-11-30 16:48:25 +01:00
Tomas Kyjovsky a8317e0cc2 1) Pageload timeout set to 60s. Other timeouts set by arq props in arquillian.xml 2) Refactoring: FlashMessage --> AdminConsoleAlert and AccountManagementAlert 2015-11-30 16:43:18 +01:00
mposolda 5b61a10b55 KEYCLOAK-2061 Direct Access Grants disabled by default 2015-11-30 15:56:21 +01:00
mposolda ec327c99f4 KEYCLOAK-2152 KEYCLOAK-2061 Client switches changes. Support for response_types and grant_types in OIDC Client registration 2015-11-30 15:31:38 +01:00
Stian Thorgersen 0492d84b59 Merge pull request #1902 from stianst/master
KEYCLOAK-2158
2015-11-30 15:22:33 +01:00
vramik 6a7a823fb4 merge upstream/master 2015-11-30 14:59:44 +01:00
Bill Burke f394e2552a Merge pull request #1798 from girirajsharma/Keycloak-2044
[KEYCLOAK-2044] Cannot map multiple external roles into Keycloak roles through custom OIDC Identity Provider
2015-11-30 08:42:03 -05:00
Stian Thorgersen 5a686c4260 KEYCLOAK-2158
Add add-user-keycloak.sh to server overlays
2015-11-30 14:03:54 +01:00
Stian Thorgersen 642e93be93 Merge pull request #1901 from mstruk/adapter-install-cli
KEYCLOAK-2166 Name clash of bin/adapter-install.cli in adapter-dist and saml-adapter-dist
2015-11-30 13:52:41 +01:00
Stian Thorgersen 2a6851b01f Merge pull request #1900 from stianst/KEYCLOAK-2063
KEYCLOAK-2063 Fix verify email link from admin endpoint
2015-11-30 13:17:17 +01:00
Marko Strukelj 2726db0be9 KEYCLOAK-2166 Name clash of bin/adapter-install.cli in adapter-dist and saml-adapter-dist 2015-11-30 12:53:51 +01:00
Stian Thorgersen 61c2ec04a4 Merge pull request #1898 from velias/KEYCLOAK-2164
KEYCLOAK-2164 - removed Cancel button from 'Change password' screen in Account app
2015-11-30 12:45:39 +01:00
Stian Thorgersen 8d6a1d5a1d Merge pull request #1899 from stianst/master
Exclude admin console tests from Travis due to stability issues
2015-11-30 12:44:29 +01:00
Stian Thorgersen 233b1e2553 KEYCLOAK-2063 Fix verify email link from admin endpoint 2015-11-30 12:10:45 +01:00
Stian Thorgersen 956ea431c8 Merge pull request #1897 from mstruk/npe
KEYCLOAK-2039 NPE on startup if keycloak-server.json can't be found
2015-11-30 11:44:56 +01:00
Stian Thorgersen 265b6d5e2a Exclude admin console tests from Travis due to stability issues 2015-11-30 11:29:59 +01:00
Vlastimil Elias b22c28b20e KEYCLOAK-2164 - removed Cancel button from 'Change password' screen in
Account app
2015-11-30 11:05:22 +01:00
Stian Thorgersen 243acdd04e Merge pull request #1889 from stianst/KEYCLOAK-2131-VAL-MAP-NAME
KEYCLOAK-2131 Create mapper form doesn't validate name input
2015-11-30 10:55:33 +01:00
Stian Thorgersen c49394c308 Merge pull request #1888 from stianst/KEYCLOAK-2132-ROLE-SELECTOR
KEYCLOAK-2132
2015-11-30 10:51:44 +01:00
Marko Strukelj fd5cb84dd1 KEYCLOAK-2039 NPE on startup if keycloak-server.json can't be found
- fix NPE and throw RuntimeException if config file not found
2015-11-30 10:26:39 +01:00
Stian Thorgersen 54b5a6c41e Merge pull request #1896 from vramik/authFlows
arquillian-testsuite: auth flows tests
2015-11-30 09:52:12 +01:00
Stian Thorgersen 83fa03e8cc Merge pull request #1894 from mstruk/saml-subsystem
KEYCLOAK-1924 SAML adapter full subsystem EAP/Wildfly
2015-11-30 09:51:33 +01:00
Stian Thorgersen 6863b711e3 Merge pull request #1892 from gtudan/KEYCLOAK-2163
KEYCLOAK-2163: require user-admin role for clearing brute force detection status
2015-11-30 09:50:59 +01:00
Stian Thorgersen 2c5510284d Merge pull request #1891 from mstruk/wildfly-modules-rename
KEYCLOAK-2099 WildFly 10 adapter subsystem
2015-11-30 09:48:15 +01:00
Stian Thorgersen 96cfb895db Merge pull request #1890 from stianst/KEYCLOAK-2137-ROLE-NAME-MAP-DUP
Keycloak 2137 role name map dup
2015-11-30 09:47:23 +01:00
Gregor Tudan 46f947113c KEYCLOAK-2163: require user admin role for clearing bruteforce detection status 2015-11-30 08:56:26 +01:00
Marek Posolda fa4e32ddcb Merge pull request #1895 from mposolda/master
Implicit flow and hybrid flow. Client switches.
2015-11-28 09:02:52 +01:00
mposolda 57b60797ce KEYCLOAK-1129 Implicit flow: more work 2015-11-28 00:15:41 +01:00
Marko Strukelj 38d160fab2 KEYCLOAK-1924 SAML adapter full subsystem EAP/Wildfly 2015-11-27 22:49:35 +01:00
mposolda ef80b64d1c KEYCLOAK-1129 Implicit flow and Hybrid flow support 2015-11-27 22:28:38 +01:00
mposolda 8d2e4c0316 KEYCLOAK-2061 Add switches to enable/disable grant types for clients 2015-11-27 22:28:38 +01:00
Bill Burke ae83ad258b Merge pull request #1893 from patriot1burke/master
KEYCLOAK-2058
2015-11-27 15:27:08 -05:00
Bill Burke 5fa59262ce fix saml admin console 2015-11-27 15:24:56 -05:00
Marko Strukelj 373fc23fc0 KEYCLOAK-2099 WildFly 10 adapter subsystem 2015-11-27 20:46:20 +01:00
Stian Thorgersen 58dc8776d6 KEYCLOAK-2137 Select mapperTypeCreate contains Role Name Mapper twice 2015-11-27 16:13:50 +01:00
Stian Thorgersen 20212d8d70 KEYCLOAK-2131 Create mapper form doesn't validate name input 2015-11-27 16:01:22 +01:00
Stian Thorgersen cb20d360c4 KEYCLOAK-2132
Error message is not displyed when trying to select empty role.
2015-11-27 15:53:33 +01:00
Stian Thorgersen 8e127bf699 Merge pull request #1887 from stianst/KEYCLOAK-2111
KEYCLOAK-2111 Cannot select language on Login dialog on small resolution
2015-11-27 15:39:13 +01:00
Stian Thorgersen 4d24a874f9 KEYCLOAK-2111 Cannot select language on Login dialog on small resolution 2015-11-27 14:42:37 +01:00
Stian Thorgersen 7200996ae0 Merge pull request #1886 from stianst/master
KEYCLOAK-2156
2015-11-27 12:32:07 +01:00
Stian Thorgersen 34cc750b13 KEYCLOAK-2156
Unrecognized field identityFederationEnabled importing old realm json
2015-11-27 12:31:00 +01:00
Stian Thorgersen 0ad6d708da Merge pull request #1884 from stianst/KEYCLOAK-2106-JWT-FIX
KEYCLOAK-2106 HTTP 500 for unparsable refresh tokens
2015-11-27 10:54:08 +01:00
Stian Thorgersen c83e3bd2d1 KEYCLOAK-2106 HTTP 500 for unparsable refresh tokens 2015-11-27 08:59:23 +01:00
Stian Thorgersen 5ea880cfff Merge pull request #1880 from stianst/KEYCLOAK-2129-USRCACHE
KEYCLOAK-2139
2015-11-26 21:14:08 +01:00
Stian Thorgersen 4276328794 Merge pull request #1883 from stianst/KEYCLOAK-2147-FF
KEYCLOAK-2147
2015-11-26 21:07:46 +01:00
Stian Thorgersen 7c4c77d70e KEYCLOAK-2147 2015-11-26 20:24:33 +01:00
Stian Thorgersen 632216d53f KEYCLOAK-2144 Set locale cookie to http-only 2015-11-26 20:06:05 +01:00
Stian Thorgersen d5105164e9 Merge pull request #1882 from abstractj/KEYCLOAK-2048
KEYCLOAK-2148: Update HmacOTP to make use of SecureRandom
2015-11-26 19:40:52 +01:00
Stian Thorgersen 7a9e2db18f Merge pull request #1879 from abstractj/KEYCLOAK-2136
KEYCLOAK-2136: Unexpected error when trying to create mapper with aleady existing name
2015-11-26 19:40:04 +01:00
Bruno Oliveira 0d582a1326 KEYCLOAK-2148: Update HmacOTP to make use of SecureRandom 2015-11-26 15:53:56 -02:00
Bruno Oliveira a99df49bc9 KEYCLOAK-2136: Unexpected error when trying to create mapper with already existing name 2015-11-26 13:55:10 -02:00
Stian Thorgersen b996e88dbd KEYCLOAK-2139
UserCache invalidation does not work proper
2015-11-26 16:39:06 +01:00
Stian Thorgersen 426a2b46fc Merge pull request #1877 from stianst/KEYCLOAK-2129
KEYCLOAK-2129
2015-11-26 15:33:39 +01:00
Stian Thorgersen 4a020d545b Merge pull request #1876 from stianst/KEYCLOAK-2082
KEYCLOAK-2082
2015-11-26 12:43:05 +01:00
Stian Thorgersen ee363a4c56 KEYCLOAK-2129 2015-11-26 12:41:55 +01:00
Stian Thorgersen bf4d5f4df9 KEYCLOAK-2082
Cross site scripting issues
2015-11-26 10:12:43 +01:00
Stian Thorgersen 30ec60b4e2 Merge pull request #1849 from girirajsharma/KEYCLOAK-2117
[KEYCLOAK-2117] It is possible to add a user or group attribute with an empty key
2015-11-26 09:25:49 +01:00
Stian Thorgersen a744ecba9e Merge pull request #1875 from abstractj/KEYCLOAK-2057
KEYCLOAK-2057: DB error with JPA EventStore and long value of not-existing client
2015-11-26 09:25:08 +01:00
Stian Thorgersen e764461b1a Merge pull request #1874 from stianst/KEYCLOAK-2134-IFRAME
KEYCLOAK-2134 login-status-iframe.html without any parameter throws 5…
2015-11-26 08:19:28 +01:00
Bruno Oliveira f376facb48 KEYCLOAK-2057: DB error with JPA EventStore and long value of not-existing client 2015-11-26 01:32:05 -02:00
girirajsharma 31614df7c4 [KEYCLOAK-2117] It is possible to add a user or group attribute with an empty key 2015-11-26 00:41:19 +05:30
Stian Thorgersen 335f852600 Merge pull request #1869 from stianst/EMAIL
Email fixes
2015-11-25 20:05:45 +01:00
Stian Thorgersen c26aeb654b KEYCLOAK-2134 login-status-iframe.html without any parameter throws 500 with NullpointerException 2015-11-25 19:58:46 +01:00
Stian Thorgersen 969cc6eb9e Merge pull request #1873 from stianst/master
Ignore LdapUserFederationTest#invalidSettingsTest
2015-11-25 19:58:17 +01:00
Stian Thorgersen f5326e1f42 Ignore LdapUserFederationTest#invalidSettingsTest 2015-11-25 19:57:31 +01:00
Stian Thorgersen e664a4a6b2 Merge pull request #1868 from stianst/KEYCLOAK-2043
KEYCLOAK-2043 Set cache-control header in well-known endpoints
2015-11-25 19:55:45 +01:00
Stian Thorgersen c15571f65c Merge pull request #1866 from mhajas/master
Added ConfigTest to integration arquillian testsuite
2015-11-25 19:06:54 +01:00
Stian Thorgersen 1eacdc6904 KEYCLOAK-2043 Set cache-control header in well-known endpoints 2015-11-25 18:58:44 +01:00
Stian Thorgersen be040eaa18 KEYCLOAK-2133 KEYCLOAK-1782 2015-11-25 18:58:05 +01:00
Bill Burke 889679c715 Merge pull request #1872 from patriot1burke/master
KEYCLOAK-1970
2015-11-25 12:01:51 -05:00
Bill Burke 8ae3551c4d KEYCLOAK-1970 2015-11-25 12:01:28 -05:00
Bill Burke cfd4de033b Merge pull request #1871 from patriot1burke/master
2115 and 2114
2015-11-25 12:00:34 -05:00
Bill Burke d6e2bccb16 Merge pull request #1840 from velias/KEYCLOAK-2075
KEYCLOAK-2075 KEYCLOAK-2107 - support for SAML IsPassive mode
2015-11-25 10:35:00 -05:00
Bill Burke eeec89583e Merge remote-tracking branch 'upstream/master' 2015-11-25 10:18:37 -05:00
Bill Burke d2bdb74fef Merge pull request #1870 from patriot1burke/master
KEYCLOAK-2095
2015-11-25 10:18:15 -05:00
Bill Burke b04b124351 KEYCLOAK-2114 2015-11-25 10:13:44 -05:00
Bill Burke 067cb120f8 KEYCLOAK-2115 2015-11-25 09:58:57 -05:00
Bill Burke 0bab4e63fa KEYCLOAK-2095 2015-11-25 09:52:11 -05:00
Bill Burke b48f32380c Merge pull request #1867 from ramirost/feature/locale_ca
Added Catalan translations
2015-11-25 08:58:27 -05:00
Bill Burke 0c8f3f734d Merge pull request #1855 from Smartling/KEYCLOAK-1391
KEYCLOAK-1391: Return an HTTP 401 for API requests
2015-11-25 08:57:05 -05:00
Bill Burke 4f401c7547 Merge pull request #1848 from girirajsharma/KEYCLOAK-2121
[KEYCLOAK-2121] Adding user or group attributes using ENTER key deletes first attribute
2015-11-25 08:53:42 -05:00
Bill Burke df74338cbc Merge pull request #1850 from girirajsharma/KEYCLOAK-2113
[KEYCLOAK-2113] Cannot delete group
2015-11-25 08:52:26 -05:00
Vlastimil Elias e3060e5e58 rebased to latest master 2015-11-25 13:46:29 +01:00
Ramiro Sánchez 15309a94cc Added Catalan translations 2015-11-25 09:48:53 +01:00
vramik 2e39221b98 added UI tests for clients 2015-11-25 09:27:23 +01:00
Stian Thorgersen c05e21c049 Merge pull request #1863 from stianst/KEYCLOAK-2050
KEYCLOAK-2050 KEYCLOAK-2051 Fix notifications
2015-11-25 09:08:00 +01:00
mhajas 62d519ed37 fix phantomjs problem with ConfigTest 2015-11-25 08:42:41 +01:00
Vlastimil Elias 18fa03bf97 KEYCLOAK-2107 - support IsPassive mode in SAML SP adapter library
KEYCLOAK-2075 - added integration tests for both server and adapter side
2015-11-25 08:39:55 +01:00
Vlastimil Elias 0bdb05e152 KEYCLOAK-2075 - support for IsPassive mode in SAML IdP endpoint 2015-11-25 08:29:46 +01:00
mhajas 09af45201b Merge remote-tracking branch 'upstream/master' 2015-11-25 07:36:32 +01:00
Stian Thorgersen dd85c125cb KEYCLOAK-2050 KEYCLOAK-2051 Fix notifications 2015-11-25 07:28:27 +01:00
Stian Thorgersen 274838aa64 Merge pull request #1860 from stianst/KEYCLOAK-2118
KEYCLOAK-2118 OTP Policy form doesn't remember Number of Digits
2015-11-25 06:59:17 +01:00
Stian Thorgersen ecb39cda0c Merge pull request #1865 from ramirost/feature/locale_es
Feature/locale es
2015-11-25 06:58:36 +01:00
Stian Thorgersen 3685a185d4 Merge pull request #1859 from stianst/reset-pass
KEYCLOAK-1758 add-user script
2015-11-25 06:56:35 +01:00
Bill Burke 030a35476a Merge pull request #1864 from patriot1burke/master
sendError() handling
2015-11-24 18:46:59 -05:00
Ramiro Sánchez 4ffe86583b fixed Spanish translations 2015-11-25 00:17:09 +01:00
Ramiro Sánchez 24f765ceef Merge branch 'upstream/master' into fork/master
* upstream_master: (115 commits)
  KEYCLOAK-1964 Database field for passwordPolicy is too small
  KEYCLOAK-1971 REST end point does't validate password policies properly
  KEYCLOAK-2104 Add caching of message bundles and properties to ExtendingThemeManager
  KEYCLOAK-2116 - Fix Label of Regenerate Secret button.
  Tweak Travis again
  KEYCLOAK-1937 OpenID Connect Dynamic Client Registration
  fix null pointer
  remove empty password check in direct grant flow
  Updated Travis configuration
  Exclude .lastUpdated files from Travis cache
  KEYCLOAK-2119 OTP Policy form validates both TOTP and HOTP at the same time
  [KEYCLOAK-2119] OTP Policy form validates both TOTP and HOTP at the same time
  KEYCLOAK-2010
  remove empty password check
  default groups ui
  KEYCLOAK-1749 Add documentation and fixed clean-up of expired initial access tokens
  Remove unused import
  Fix missing group in angular $scope in GroupMembersCtrl.
  arquillian-testsuite: Customizable waiting timeouts in class WaitUtils. Changed time unit to MILLISECONDS.
  default groups
  ...
2015-11-24 23:52:24 +01:00
Bill Burke c729835c3e fix2 2015-11-24 17:25:05 -05:00
Bill Burke 507fa4c250 fix 2015-11-24 17:21:30 -05:00
Bill Burke bba781beee messed up 2015-11-24 17:19:55 -05:00
Bill Burke 980a1eca5e Merge remote-tracking branch 'upstream/master' 2015-11-24 16:48:40 -05:00
Bill Burke ff63c5552a sendError() handling' 2015-11-24 16:48:24 -05:00
Stian Thorgersen 985661c1b9 Merge pull request #1862 from stianst/KEYCLOAK-1964
KEYCLOAK-1964 Database field for passwordPolicy is too small
2015-11-24 22:04:52 +01:00
Stian Thorgersen b168656eab KEYCLOAK-2118 OTP Policy form doesn't remember Number of Digits 2015-11-24 22:04:37 +01:00
Stian Thorgersen 94ba87ac05 Merge pull request #1861 from stianst/KEYCLOAK-1971
KEYCLOAK-1971 REST end point does't validate password policies properly
2015-11-24 21:55:16 +01:00
Stian Thorgersen cfc28b861b KEYCLOAK-1758 add-user script 2015-11-24 21:54:58 +01:00
Stian Thorgersen 38408658f9 Merge pull request #1857 from thomasdarimont/issue/KEYCLOAK-2116
KEYCLOAK-2116 - Fix Label of Regenerate Secret button.
2015-11-24 21:23:44 +01:00
Stian Thorgersen 998bb9986f Merge pull request #1853 from stianst/KEYCLOAK-2104
KEYCLOAK-2104 Add caching of message bundles and properties to Extend…
2015-11-24 21:22:02 +01:00
Stian Thorgersen 8d2a95d66b KEYCLOAK-1964 Database field for passwordPolicy is too small 2015-11-24 20:57:41 +01:00
Stian Thorgersen 500bced6ee KEYCLOAK-1971 REST end point does't validate password policies properly 2015-11-24 20:50:41 +01:00
Stian Thorgersen 81960a6996 KEYCLOAK-2104 Add caching of message bundles and properties to ExtendingThemeManager 2015-11-24 20:23:20 +01:00
Stian Thorgersen ccd456dba6 Merge pull request #1858 from stianst/master
Tweak Travis again
2015-11-24 20:23:14 +01:00
Thomas Darimont bac39bc71e KEYCLOAK-2116 - Fix Label of Regenerate Secret button. 2015-11-24 20:11:55 +01:00
Stian Thorgersen a8c2e79565 Tweak Travis again 2015-11-24 20:08:41 +01:00
Marek Posolda d6089597ff Merge pull request #1847 from gerbermichi/password
remove empty password check
2015-11-24 17:23:51 +01:00
Stian Thorgersen c901fc7480 Merge pull request #1845 from stianst/client-reg
Client reg
2015-11-24 16:33:55 +01:00
Stian Thorgersen 4f2b97de7f KEYCLOAK-1937
OpenID Connect Dynamic Client Registration

KEYCLOAK-1938
Register clients from SAML Entity Descriptors
2015-11-24 15:39:36 +01:00
Michael Gerber 9a3e023c43 fix null pointer 2015-11-24 13:54:33 +00:00
Michael Gerber 142ef50728 remove empty password check in direct grant flow 2015-11-24 11:11:16 +00:00
Stian Thorgersen d2ba4669ab Merge pull request #1856 from stianst/master
Updated Travis configuration
2015-11-24 10:57:08 +01:00
Stian Thorgersen ba0b59bfd0 Updated Travis configuration 2015-11-24 10:00:58 +01:00
Scott Rossillo f1c3295cec KEYCLOAK-1391: Return an HTTP 401 for API requests
Non browser HTTP requests shouldn't redirect to the Keycloak login
page. Instead, return an HTTP 401 with a proper WWW-Authenticate
header.
2015-11-23 10:46:14 -05:00
Stian Thorgersen 04ddf7ba4d Merge pull request #1854 from stianst/master
Exclude .lastUpdated files from Travis cache
2015-11-23 14:01:46 +01:00
mhajas 8f346a5f59 Merge remote-tracking branch 'origin/master' 2015-11-23 13:12:23 +01:00
mhajas 22e3abdaa8 added ConfigTest for events 2015-11-23 13:11:55 +01:00
Stian Thorgersen f1af3e9fb7 Exclude .lastUpdated files from Travis cache 2015-11-23 13:08:13 +01:00
Stian Thorgersen 5e479ba4df Merge pull request #1852 from stianst/master
KEYCLOAK-2119
2015-11-23 12:48:16 +01:00
Stian Thorgersen f6743eff69 KEYCLOAK-2119
OTP Policy form validates both TOTP and HOTP at the same time
2015-11-23 12:02:39 +01:00
Stian Thorgersen 5a761f2f3a Merge pull request #1851 from girirajsharma/KEYCLOAK-2119
[KEYCLOAK-2119] OTP Policy form validates both TOTP and HOTP at the same time
2015-11-23 11:59:00 +01:00
Stian Thorgersen 261d32f8e7 Merge pull request #1841 from vramik/master
arquillian-testsuite: Customizable waiting timeouts in class WaitUtil…
2015-11-23 11:26:22 +01:00
Stian Thorgersen 282e702ef6 Merge pull request #1836 from tkyjovsk/master
KEYCLOAK-1646 Added adapter test module for EAP6
2015-11-23 11:23:29 +01:00
Stian Thorgersen cc014fe0e5 Merge pull request #1844 from lkubik/unusedImport
Remove unused import
2015-11-23 11:21:13 +01:00
girirajsharma 95f62901c2 [KEYCLOAK-2119] OTP Policy form validates both TOTP and HOTP at the same time 2015-11-22 23:04:45 +05:30
girirajsharma cf8b0abaad [KEYCLOAK-2113] Cannot delete group 2015-11-22 20:52:31 +05:30
girirajsharma e761fb24e6 [KEYCLOAK-2121] Adding user or group attributes using ENTER key deletes first attribute 2015-11-22 16:14:34 +05:30
Bill Burke b1deed67df Merge remote-tracking branch 'upstream/master' 2015-11-21 08:58:15 -05:00
Bill Burke d3cadc9a47 saml error handling 2015-11-21 08:58:02 -05:00
Bill Burke 32e069eadc Merge pull request #1846 from patriot1burke/master
default groups UI
2015-11-20 19:18:21 -05:00
Bill Burke 17c97c2f68 KEYCLOAK-2010 2015-11-20 16:18:42 -05:00
Bill Burke 48bb4d86e0 Merge pull request #1842 from thomasdarimont/issue/missing-groupid-membersctrl
Fix missing group in angular $scope in GroupMembersCtrl.
2015-11-20 16:07:37 -05:00
Michael Gerber eda018ba0a remove empty password check 2015-11-20 18:42:56 +01:00
Bill Burke ac1baa059f Merge pull request #1797 from raehalme/KEYCLOAK-2041
KEYCLOAK-2041 Use sendError instead of setStatus to report errors
2015-11-20 11:50:37 -05:00
Bill Burke 670b620da7 Merge remote-tracking branch 'upstream/master' 2015-11-20 10:41:19 -05:00
Bill Burke 1545593cde default groups ui 2015-11-20 10:41:08 -05:00
Stian Thorgersen aedd23a43d Merge pull request #1843 from stianst/client-reg
KEYCLOAK-1749 Add documentation and fixed clean-up of expired initial…
2015-11-19 19:58:42 +01:00
Stian Thorgersen 7e8c80c0df KEYCLOAK-1749 Add documentation and fixed clean-up of expired initial access tokens 2015-11-19 16:11:41 +01:00
Lukas Kubik 9f6813fcad Remove unused import 2015-11-19 15:15:55 +01:00
Thomas Darimont 14292843ff Fix missing group in angular $scope in GroupMembersCtrl.
Previously navigating to the group members tab of a group breaks other groups links (RoleMappings, Attributes etc.) because the groupId part of the url is missing.
 One sees:
 /auth/admin/master/console/#/realms/master/groups//role-mappings
 Instead of:
 /auth/admin/master/console/#/realms/master/groups/0f77aeed-7d16-4938-9fcc-c74b1125e5e0/role-mappings
2015-11-19 13:54:18 +01:00
vramik 71e25bcd65 arquillian-testsuite: Customizable waiting timeouts in class WaitUtils. Changed time unit to MILLISECONDS. 2015-11-19 13:14:30 +01:00
Bill Burke 9f1fa5ebb9 Merge pull request #1839 from patriot1burke/master
default groups back end
2015-11-18 20:59:46 -05:00
Bill Burke 98958a2bc4 default groups 2015-11-18 19:40:30 -05:00
Bill Burke 7da9f8085d Merge pull request #1838 from patriot1burke/master
groups: resolve roles, and mongo fixes
2015-11-18 16:19:17 -05:00
Bill Burke 6989589e72 Merge remote-tracking branch 'upstream/master' 2015-11-18 15:24:45 -05:00
Bill Burke 4f00f6cceb group mongo 2015-11-18 15:24:27 -05:00
Stian Thorgersen 95e729b0b7 Merge pull request #1832 from stianst/client-reg
KEYCLOAK-2085
2015-11-18 19:34:47 +01:00
Tomas Kyjovsky 38c460de82 KEYCLOAK-1646 Added module for adapter tests on EAP6. Using 'wildfly-arquillian-container-managed' instead of 'jboss-as-arquillian-container-managed' for both EAP6 and AS7 adapter tests. 2015-11-18 18:21:46 +01:00
Bill Burke 41331111da resolve conflicts 2015-11-18 09:39:19 -05:00
Bill Burke bff334d365 group token/assertion and tests 2015-11-18 09:36:47 -05:00
Stian Thorgersen 41c9289f14 KEYCLOAK-1749 Moved clien registration api 2015-11-18 15:09:32 +01:00
Marek Posolda 1d06d9dd64 Merge pull request #1834 from mposolda/master
KEYCLOAK-2102 added AbstractKerberosTest.caseInsensitiveTest
2015-11-18 14:05:46 +01:00
Stian Thorgersen ec9b2933cc Merge pull request #1833 from thomasdarimont/issue/KEYCLOAK-2101
KEYCLOAK-2101 - Ensure consistent property order in json configuration export.
2015-11-18 13:30:15 +01:00
Stian Thorgersen 1ff5d6eb06 KEYCLOAK-2085 Internationalization in client initial access controller 2015-11-18 13:25:08 +01:00
mposolda bc22abf8cb KEYCLOAK-2102 added AbstractKerberosTest.caseInsensitiveTest 2015-11-18 12:35:17 +01:00
Marek Posolda 81eb1e1e30 Merge pull request #1830 from bagges/master
[KEYCLOAK-2102] treat principal name case insensitive
2015-11-18 12:35:06 +01:00
Stian Thorgersen e8cb3a416d KEYCLOAK-2085 Added initial access token support to admin console 2015-11-18 10:33:27 +01:00
Stian Thorgersen 764c20d748 KEYCLOAK-2085 Initial access tokens for client registration 2015-11-18 10:33:24 +01:00
Thomas Darimont c81d0c0898 KEYCLOAK-2101 - Ensure consistent order for properties in json configuration export.
We now explicitly order the AuthenticatorFlows, AuthenticatorConfig, as well
as RequiredActions to ensure a consistent order for the configuration export to make
it easier to diff / version keycloak configuration files.
Previously the order of the json properties of an configuration export were
non deterministic. The configuration file could look partially different after a
 export, import, export sequence even if no changes were made.
2015-11-17 22:34:21 +01:00
Stian Thorgersen 67fca8f1f3 Merge pull request #1831 from abstractj/KEYCLOAK-2100
KEYCLOAK-2100: 500 Internal Server Error with Update the events provider via Admin REST API
2015-11-17 20:35:48 +01:00
Bruno Oliveira 22c5c803ca KEYCLOAK-2100: 500 Internal Server Error with Update the events provider via Admin REST API 2015-11-17 14:04:24 -02:00
Stian Thorgersen f6d716a386 Merge pull request #1829 from stianst/client-reg
KEYCLOAK-1749 Rotate registration access token, add registration acce…
2015-11-17 13:29:53 +01:00
Stian Thorgersen 62c5bc0e91 KEYCLOAK-1749 Rotate registration access token, add registration access token to admin console 2015-11-17 09:44:50 +01:00
Markus Backes 5e329d7b29 Merge branch 'master' of https://github.com/keycloak/keycloak 2015-11-17 09:32:41 +01:00
Markus Backes 1bd9b18803 treat principal name case insensitive
* Kerberos login with active directory failed with invalid username or password because AD treats principal names in a case insensitive way (https://ssimo.org/blog/id_016.html)
2015-11-17 09:32:14 +01:00
Stian Thorgersen 96fe4269ec Merge pull request #1828 from abstractj/KEYCLOAK-2065
KEYCLOAK-2065: Update the client via Admin REST API causes 500 Internal Server Error
2015-11-17 08:31:54 +01:00
Stian Thorgersen 83ff02ea53 Merge pull request #1825 from stianst/client-reg
KEYCLOAK-1749 Client registration service
2015-11-16 20:23:55 +01:00
Stian Thorgersen 1df741a307 Merge pull request #1826 from lkubik/changeAllJettyToProvided
KEYCLOAK-2081
2015-11-16 20:23:31 +01:00
Bruno Oliveira 409356f734 KEYCLOAK-2065: Update the client via Admin REST API causes 500 Internal Server Error 2015-11-16 16:32:52 -02:00
Stian Thorgersen bad0a95123 KEYCLOAK-1749 Client registration service
Changed endpoints of client registration to just clients

Started installation

Added adapter config retrival to client reg
2015-11-16 13:24:56 +01:00
Stian Thorgersen 1bc08fff16 Merge pull request #1823 from abstractj/KEYCLOAK-2056
KEYCLOAK-2056: Removal of file model provider
2015-11-16 08:33:56 +01:00
Marek Posolda ab436705c8 Merge pull request #1827 from mposolda/broker-reauthentication
KEYCLOAK-1750 First broker login - migration, documentation. Other minor fixes
2015-11-13 20:10:28 +01:00
mposolda ea7709a104 KEYCLOAK-2026 Fix realm.getMasterAdminClient() in JPA and Mongo models 2015-11-13 18:51:09 +01:00
mposolda 1d5a01577e KEYCLOAK-1750 First broker login - migration 2015-11-13 18:51:09 +01:00
mposolda 4288260aa6 KEYCLOAK-1822 Don't redirect to login theme when error during link identity in account mgmt. 2015-11-13 18:51:09 +01:00
mposolda 600d1f8a56 KEYCLOAK-1750 First broker login - docs 2015-11-13 18:51:09 +01:00
Bruno Oliveira f7b1af7e11 Removal of module keycloak-connections-file 2015-11-13 13:44:15 -02:00
Bruno Oliveira 4b0e33e388 KEYCLOAK-2056: Removal of file model provider 2015-11-13 13:44:15 -02:00
Stian Thorgersen 8caaabb2e5 Merge pull request #1820 from thomasdarimont/issue/KEYCLOAK-2068-NPE-in-KeycloakOidcFilter
KEYCLOAK-2068 - Fix Potential NPE when using Servlet-Filter Adapter.
2015-11-13 16:00:34 +01:00
Stian Thorgersen 1bd0e23f31 Merge pull request #1824 from bystrikhorvath/master
KEYCLOAK-2077: correcting paths in custom-attributes.xml
2015-11-13 15:53:31 +01:00
Lukas Kubik 13a52c1bb2 KEYCLOAK-2081
Change scope of jetty dependencies to provided
2015-11-13 15:43:11 +01:00
Bill Burke fa7a7d35a9 Merge remote-tracking branch 'upstream/master' 2015-11-13 09:30:37 -05:00
Bill Burke fe5809db4d token group roles 2015-11-13 09:30:25 -05:00
Bill Burke 1510d9672a Merge pull request #1803 from gerbermichi/user
KEYCLOAK-2024 - username guessing
2015-11-13 08:53:05 -05:00
Bill Burke 9b93468131 Merge pull request #1818 from patriot1burke/master
group membership ui
2015-11-13 08:49:23 -05:00
bystrikhorvath 2e16a55815 KEYCLOAK-2077: correcting paths in custom-attributes.xml 2015-11-13 14:00:20 +01:00
Marek Posolda f65665b5eb Merge pull request #1822 from mposolda/broker-reauthentication
KEYCLOAK-1750 first broker login - events and tests
2015-11-13 10:27:38 +01:00
mposolda ce4a865579 KEYCLOAK-1750 First broker login - tests 2015-11-13 09:32:46 +01:00
mposolda f2e4e67ba0 KEYCLOAK-1750 First broker login - events 2015-11-13 09:32:46 +01:00
Stian Thorgersen 37f1eaae0e Merge pull request #1821 from stianst/master
KEYCLOAK-2037 Update documentation
2015-11-13 09:04:17 +01:00
Stian Thorgersen 6c3a3517b8 KEYCLOAK-2037 Update documentation 2015-11-13 09:03:58 +01:00
Thomas Darimont c4416a25e0 KEYCLOAK-2068 - Fix Potential NPE when using Servlet-Filter Adapter.
When using the `org.keycloak.adapters.servlet.KeycloakOIDCFilter` a `NullPointerException`
can be thrown in the `org.keycloak.adapters.servlet.FilterSessionStore` within the `getParam`
method of the generated wrapper in `buildWrapper` when the `content-type` is not set.
Since the `content-type` is only used to parse the body. We just check whether the `body`
is `null` and if so avoid touching the `content-type` which prevents the NPE.

If the `body` is null we return an empty `MultivaluedHashMap` for the parameters.
2015-11-13 00:14:34 +01:00
Bill Burke 550f773293 Merge remote-tracking branch 'upstream/master' 2015-11-12 13:16:50 -05:00
Bill Burke d7ea66ad44 group membership ui 2015-11-12 13:16:30 -05:00
Bill Burke 2022a8d36b Merge pull request #1817 from patriot1burke/master
user group membership ui
2015-11-12 13:09:37 -05:00
Bill Burke 0d20e3c7ff Merge remote-tracking branch 'upstream/master' 2015-11-12 11:31:55 -05:00
Bill Burke 21119604c6 user group membership 2015-11-12 11:31:44 -05:00
Stian Thorgersen 973609d39b Merge pull request #1816 from stianst/master
KEYCLOAK-2066
2015-11-12 14:44:03 +01:00
Stian Thorgersen 77bccda7a4 KEYCLOAK-2066
View details on import client not working
2015-11-12 14:03:09 +01:00
Stian Thorgersen 0c9f0ea3e6 Merge pull request #1813 from vmuzikar/missing-ids
Add missing IDs to some UI elements; add POs to Client Mappers
2015-11-12 13:36:19 +01:00
Stian Thorgersen 73197332c4 Merge pull request #1814 from pdrozd/federation-tests
Add Federation tests for admin console.
2015-11-12 13:36:03 +01:00
Stian Thorgersen ee0dd7e200 Merge pull request #1815 from abstractj/KEYCLOAK-2064
KEYCLOAK-2064: Update pax-web to make use of SecureRandom
2015-11-12 13:35:33 +01:00
Bruno Oliveira 9203971809 KEYCLOAK-2064: Update pax-web to make use of SecureRandom 2015-11-12 09:46:45 -02:00
Pavel Drozd 4e7fe1de8d Add Federation tests for admin console. 2015-11-12 12:23:37 +01:00
Stian Thorgersen 4646a4aceb Merge pull request #1811 from stianst/master
KEYCLOAK-2060
2015-11-12 11:59:00 +01:00
Stian Thorgersen 64baa28301 Merge pull request #1810 from lkubik/updateJettyScope
Change scope of jetty dependencies in jetty-adapter-spi
2015-11-12 09:23:44 +01:00
Stian Thorgersen db84571546 Merge pull request #1807 from vramik/KEYCLOAK-2031
KEYCLOAK-2031: Input validation in OTP Policy page fix, test
2015-11-12 09:23:13 +01:00
Stian Thorgersen 99cddcef6c Merge pull request #1805 from velias/KEYCLOAK-2033
KEYCLOAK-2033 - Allow custom SPI Providers to show additional info on
2015-11-12 09:21:38 +01:00
Stian Thorgersen 1891019067 Merge pull request #1802 from equinux/pr/fix-js-parameter-encoding
Fix parameter encoding in JS adapter
2015-11-12 09:19:21 +01:00
Stian Thorgersen b0b4d26fa3 KEYCLOAK-2060
Upgrade to WildFly 9.0.2.Final
2015-11-12 09:17:47 +01:00
Bill Burke 6cc76b2e3d Merge pull request #1788 from patriot1burke/master
groups data model
2015-11-11 19:38:01 -05:00
Bill Burke 33ac048c8c resolve conflicts 2015-11-11 18:06:39 -05:00
Bill Burke e25157655b group ui 2015-11-11 18:03:53 -05:00
Stian Thorgersen 213abb87ba Merge pull request #1808 from stianst/master
KEYCLOAK-2055
2015-11-11 20:24:08 +01:00
Lukas Kubik 825a68c6c9 Change scope of jetty dependencies in jetty-adapter-spi. 2015-11-11 17:01:46 +01:00
Stian Thorgersen 816ed9419b Merge pull request #1809 from lkubik/unifyJettyVersionWithOthers
Unify jetty version in keycloak-jetty-adapter-spi with other jetty versions
2015-11-11 16:10:17 +01:00
Stian Thorgersen 15f1a38b51 KEYCLOAK-2055
Invalid links in docs index.html
2015-11-11 14:32:43 +01:00
Lukas Kubik 1f75f85a20 Unify jetty version in keycloak-jetty-adapter-spi with other versions 2015-11-11 13:58:22 +01:00
Vaclav Muzikar dfb39d13a2 Removed IDs from Password Policy
(cherry picked from commit 35376b7)
2015-11-11 12:00:44 +01:00
Bill Burke b8391e0935 Merge pull request #1778 from girirajsharma/keycloak-1994
[KEYCLOAK-1994] It's not possible to create flow with same name as deleted nested flow
2015-11-10 10:58:57 -05:00
vramik ab56460325 KEYCLOAK-2031: Input validation in OTP Policy page fix, test 2015-11-10 16:57:29 +01:00
Vaclav Muzikar 059ebacffc Removed IDs from redirect URIs and Web Origins in Client
(cherry picked from commit 5c68854)
2015-11-10 15:46:55 +01:00
Stian Thorgersen e1a07bd5a8 Merge pull request #1806 from tkyjovsk/karaf-fuse-update
Karaf fuse update
2015-11-10 15:28:36 +01:00
Tomas Kyjovsky 37d7182fc9 Merge upstream-master into karaf-fuse-update
Conflicts:
	testsuite/integration-arquillian/tests/base/src/main/java/org/keycloak/testsuite/arquillian/KeycloakArquillianExtension.java
2015-11-10 13:44:23 +01:00
Tomas Kyjovsky e1ba26bcae KEYCLOAK-1661 Added support for testing adapters/examples on fuse 6.2. Moved CustomKarafContainer from the base module to the adapters/karaf module. 2015-11-10 13:39:59 +01:00
Vlastimil Elias b39146f6f5 KEYCLOAK-2033 - Allow custom SPI Providers to show additional info on
Server Info page
2015-11-10 12:55:36 +01:00
Marek Posolda caea1a3458 Merge pull request #1804 from mposolda/broker-reauthentication
KEYCLOAK-1750 First broker login changes
2015-11-10 11:52:47 +01:00
Dominique d'Argent 7ef747e7c4 Fix parameter encoding in JS adapter
- fixes https://issues.jboss.org/browse/KEYCLOAK-2047
- relates to keycloak/keycloak-js-bower#7
2015-11-10 11:20:06 +01:00
mposolda 4ca442d1b2 KEYCLOAK-1750 Option updateProfileOnFirstLogin moved from IdentityProvider to IdpReviewProfile authenticator 2015-11-10 11:06:23 +01:00
mposolda 99e75c69a0 KEYCLOAK-1750 First broker login - support for change password after first social login 2015-11-10 10:25:31 +01:00
Michael Gerber 1437f7da35 KEYCLOAK-2024 - username guessing 2015-11-10 09:04:10 +01:00
Stian Thorgersen fa9abbf016 Merge pull request #1801 from vramik/KEYCLOAK-2046
KEYCLOAK-2046 Remove JIRA checker extension
2015-11-10 07:50:24 +01:00
vramik 6bce32ba62 arquillian-testsuite: auth flows test 2015-11-09 15:59:34 +01:00
vramik ee801c2c32 arquillian-testsuite: KEYCLOAK-2046 2015-11-09 15:03:17 +01:00
Marek Posolda 2b23497f92 Merge pull request #1799 from mposolda/broker-reauthentication
KEYCLOAK-1750 Improve first time login with social. Added 'first brok…
2015-11-09 13:15:33 +01:00
Stian Thorgersen 04ba5c235e Merge pull request #1800 from stianst/master
Disable JIRA checker extension - this should be removed completely
2015-11-09 13:05:04 +01:00
Stian Thorgersen 1521f56225 Disable JIRA checker extension - this should be removed completely 2015-11-09 12:11:20 +01:00
Stian Thorgersen 251adbba0b Fix OTPPolicyTest 2015-11-09 12:10:19 +01:00
mposolda adbf2b22ad KEYCLOAK-1750 Improve first time login with social. Added 'first broker login' flow 2015-11-09 10:34:55 +01:00
Stian Thorgersen 2b29c3acf4 Merge pull request #1795 from abstractj/KEYCLOAK-2031
Input validation in OTP Policy page
2015-11-09 10:08:38 +01:00
Stian Thorgersen 076690e21e Merge pull request #1794 from tkyjovsk/karaf-fuse-update
Adapter tests for Karaf: Fuse Example installation now done via JMX i…
2015-11-09 10:08:27 +01:00
Stian Thorgersen b586f93182 Merge pull request #1793 from stianst/KEYCLOAK-2037
KEYCLOAK-2037 Fix domain mode for server-dist
2015-11-09 10:08:03 +01:00
Stian Thorgersen 5a318df041 Merge pull request #1791 from vramik/uitests
arquillian-testsuite add UI tests, page objects refactoring
2015-11-09 10:02:23 +01:00
Stian Thorgersen cd01ea49b4 Merge pull request #1777 from girirajsharma/keycloak-1993
[KEYCLOAK-1993] It's possible to create new authentication flow with empty name within another flow
2015-11-09 09:54:07 +01:00
girirajsharma dd2824ab20 [KEYCLOAK-2044] Cannot map multiple external roles into Keycloak roles through custom OIDC Identity Provider 2015-11-08 20:10:14 +05:30
Bruno Oliveira 8db6972441 Input validation in OTP Policy page 2015-11-06 11:52:21 -02:00
Tomas Kyjovsky 027311c0c0 Adapter tests for Karaf: Fuse Example installation now done via JMX instead of maven-karaf plugin. Needed for testing on Fuse. 2015-11-06 13:03:42 +01:00
Thomas Raehalme 68edf9ce48 Errors are now reported using sendError instead of setStatus.
This change was made to enable the use of error pages defined in web.xml.
2015-11-06 10:53:18 +02:00
Thomas Raehalme 7b7fbd3257 Added sendError(int) to HttpFacade.Response. 2015-11-06 10:47:08 +02:00
Stian Thorgersen d0c50fe56d KEYCLOAK-2037 Fix domain mode for server-dist 2015-11-06 08:44:50 +01:00
girirajsharma 4075d65241 [KEYCLOAK-1993] It's possible to create new authentication flow with empty name within another flow 2015-11-05 21:59:04 +05:30
vramik 267be83863 arquillian-testsuite: add UI test for OTP Policy
Conflicts:
	testsuite/integration-arquillian/tests/base/src/main/java/org/keycloak/testsuite/console/page/authentication/flows/CreateFlow.java
2015-11-05 13:37:59 +01:00
Stian Thorgersen 15828e899b Merge pull request #1790 from dvantooster/master
KEYCLOAK-2032 Changed some column names from lower- to uppercase
2015-11-05 13:03:20 +01:00
Stian Thorgersen ce089019e6 Merge pull request #1786 from mhajas/master
Add consent tests to integration-arquillian testsuite
2015-11-05 13:02:44 +01:00
Stian Thorgersen c9c49a9c64 Merge branch 'ramirost-feature/i18n_es' 2015-11-05 12:59:29 +01:00
Stian Thorgersen 623f39862d Merge branch 'feature/i18n_es' of https://github.com/ramirost/keycloak into ramirost-feature/i18n_es 2015-11-05 12:59:06 +01:00
Stian Thorgersen 818c3ab1c5 Merge pull request #1785 from ccheneau/master
Fix french translation for account and login resource bundles
2015-11-05 12:54:17 +01:00
Stian Thorgersen 1ce028ead7 Merge pull request #1789 from abstractj/pbeutils-removal
Removal of PBEUtils
2015-11-05 12:49:22 +01:00
Stian Thorgersen d844e6b4af Merge pull request #1776 from girirajsharma/keycloak-1995
[KEYCLOAK-1995] Replace provider select options with Labels displayed in flows table
2015-11-05 12:08:23 +01:00
vramik 7b4dcb6965 arquillian-testsuite: add UI test for Bindings flows 2015-11-04 18:14:41 +01:00
Daniël van 't Ooster 7bd0b7ddfc KEYCLOAK-2032 Changed some column names from lower- to uppercase, so it is in sync with liquibase scripts 2015-11-04 11:43:09 +01:00
Bruno Oliveira d2912673b0 Removal of PBEUtils 2015-11-04 02:06:21 -02:00
Stian Thorgersen 28ee95138a Merge pull request #1773 from iperdomo/master
KEYCLOAK-2016
2015-11-03 15:55:21 +01:00
Bill Burke d46b4eb5fe Merge pull request #1780 from agolPL/master
extract hardcoded keycloak configuration file name
2015-11-02 11:51:04 -05:00
Bill Burke 151c56a304 conflicts 2015-11-02 11:21:10 -05:00
Bill Burke c2ad918975 group model 2015-11-02 11:19:19 -05:00
Tomas Kyjovsky 634eadb634 Merge pull request #1787 from vramik/migration
arquillian-testsuite: Migration test
2015-11-02 15:36:18 +01:00
vramik d26cfcda42 arquillian testsuite, migration test: update execution of dependency plugin for migration scenario 2015-11-02 11:56:26 +01:00
vramik 4a9a39c08d arquillian testsuite, migration test: fix 2015-10-30 14:01:48 +01:00
vramik 9796b7f06e arquillian testsuite, migration test: initial version of migration test 2015-10-30 13:27:38 +01:00
vramik c2e14cb924 arquillian testsuite, migration test: fixed typo in arquillian.xml, add migration test for 1.5.1.Final 2015-10-30 11:32:01 +01:00
Bill Burke d896800ec6 groups initial 2015-10-29 16:33:02 -04:00
mhajas b74e0dad10 remove ConfigTest 2015-10-29 16:50:29 +01:00
mhajas 2c8b0fc3e1 Merge remote-tracking branch 'upstream/master' 2015-10-29 16:41:46 +01:00
vramik cd640339fc arquillian testsuite, migration test: fixed assembly.xml for 1.6.1.Final 2015-10-29 15:11:50 +01:00
vramik 52c02f03ae arquillian testsuite, migration test: fixed assembly.xml for 1.6.1.Final 2015-10-29 15:09:33 +01:00
vramik 84da341912 arquillian testsuite, migration test: add support for 1.5.1.Final 2015-10-29 14:48:05 +01:00
vramik 2c3958ce27 arquillian testsuite, migration test: update test realm to 1.6.1.Final 2015-10-29 14:43:23 +01:00
vramik 515f049ce6 arquillian testsuite, migration test: update version from 1.6.0.Final to 1.6.1.Final 2015-10-29 14:27:23 +01:00
vramik 03acad9b9d arquillian testsuite: increased startup timeout for containers 2015-10-29 13:41:38 +01:00
vramik 0392ebab32 arquillian testsuite: remove adding test realm in migration scenario 2015-10-29 12:22:33 +01:00
vramik 52804da497 arquillian testsuite: improve log messages for migration test 2015-10-29 11:36:29 +01:00
Cédric Chéneau 31df2046f0 Correction page login 2015-10-28 09:38:02 +01:00
Cédric Chéneau f14681f122 Correction page account 2015-10-28 09:35:17 +01:00
Cédric Chéneau d7d52b3295 Correction page account 2015-10-28 09:34:16 +01:00
ccheneau 8e71910e00 Fix french translation for account and login resource bundles 2015-10-27 20:14:41 +01:00
vramik e6620ca005 arquillian-testsuite added initial version of migration test 2015-10-27 14:31:15 +01:00
Ramiro Sánchez 490b8ce86f Added Spanish language support 2015-10-27 12:05:32 +01:00
vramik 480444ffc5 Merge upstream/master into migration 2015-10-27 11:50:30 +01:00
vramik 2fd7e5b355 arquillian-testsuite fixed whitespaces 2015-10-27 11:43:49 +01:00
vramik f45e0aa387 arquillian-testsuite migration servers: removed unused properties 2015-10-27 11:41:33 +01:00
vramik 6c77c295d5 arquillian-testsuite refactoring migration servers 2015-10-27 11:40:41 +01:00
vmuzikar ccfaf72b09 Init changes
(cherry picked from commit 31d8cab)
2015-10-26 15:47:05 +01:00
vmuzikar 700740a378 Added POs for client mappers
(cherry picked from commit f2cd982)
2015-10-26 15:45:55 +01:00
vmuzikar 8062f5f50e Added POs for client mappers
(cherry picked from commit f491c3c)
2015-10-26 15:43:00 +01:00
vmuzikar 5e0851c25f Rewritten some POs to use @id attributes
(cherry picked from commit 12b9c7e)
2015-10-26 14:17:07 +01:00
Marek Posolda 81650a89f9 Merge pull request #1782 from mposolda/master
KEYCLOAK-2005 Fixed migration to take less time. Added UserProvider.g…
2015-10-26 14:12:14 +01:00
vmuzikar 709449243c Added @id to some UI elements
(cherry picked from commit 4034258)
2015-10-26 14:02:30 +01:00
mhajas df24d8a01f Merge remote-tracking branch 'upstream/master' 2015-10-26 12:26:47 +01:00
mposolda f8f4de9389 KEYCLOAK-2005 Fixed migration to take less time. Added UserProvider.grantToAllUsers 2015-10-26 11:06:19 +01:00
agolPl 9755d79879 extract keycloak configuration file name 2015-10-25 00:26:18 +02:00
girirajsharma 70cbeaf336 [KEYCLOAK-1994] It's not possible to create flow with same name as deleted nested flow 2015-10-24 22:57:40 +05:30
girirajsharma b0a71fbeb0 Replace provider select options with Labels displayed in flows table 2015-10-24 13:28:43 +05:30
Marek Posolda 44f56e1d74 Merge pull request #1775 from mposolda/master
Migration and other fixes
2015-10-23 23:41:08 +02:00
mposolda 74924f2f8c KEYCLOAK-2011 2015-10-23 22:48:06 +02:00
mposolda c498b06f68 KEYCLOAK-2007 Migration upgrade for 1.6.1 2015-10-23 22:47:53 +02:00
Iván Perdomo 525bee66a4 KEYCLOAK-2016
Change label to Forgot password
2015-10-23 16:02:30 +02:00
Stian Thorgersen cd51a95764 Merge pull request #1771 from ramirost/release/locale
Added support to indicate desired locale on login options
2015-10-23 15:16:37 +02:00
Ramiro Sánchez 57c282eca8 Updated documentation with the new 'locale' parameter 2015-10-23 14:32:16 +02:00
Ramiro Sánchez ebd02a1a7f Changed query parameter from kc_locale to ui_locales as suggested by stianst 2015-10-23 14:21:59 +02:00
Stian Thorgersen cc4583bc0b Merge pull request #1772 from stianst/master
KEYCLOAK-2015
2015-10-23 13:41:27 +02:00
Stian Thorgersen 11ef67722b KEYCLOAK-2015
autofocus on input text field in login-totp.ftl
2015-10-23 13:40:57 +02:00
Stian Thorgersen 5316dd6d50 Merge pull request #1770 from gerbermichi/autofocus
autofocus on input text field in login-reset-password.ftl
2015-10-23 13:39:29 +02:00
Stian Thorgersen 3cee33847f Merge pull request #1769 from gerbermichi/client
expose client attributes in ClientBean
2015-10-23 13:38:25 +02:00
Stian Thorgersen a2b5b6dc71 Merge pull request #1768 from stianst/master
Fix saml examples not excluded from deploy
2015-10-23 13:37:48 +02:00
Ramiro Sánchez a5dc91f9a6 Added support to indicate desired locale on login 2015-10-23 12:23:24 +02:00
Michael Gerber 3b4b1b20d8 expose client attributes in ClientBean 2015-10-23 09:41:03 +02:00
Michael Gerber b32423d96b autofocus on input field 2015-10-23 09:38:40 +02:00
Stian Thorgersen 4f2fe0197d Fix saml examples not excluded from deploy 2015-10-23 08:48:43 +02:00
Stian Thorgersen aa25c899ee Merge pull request #1765 from vramik/migration-kc16
add support for migration tests - Keycloak 1.6.0.Final
2015-10-23 08:31:08 +02:00
Marek Posolda fa6b99eaab Merge pull request #1767 from mposolda/master
KEYCLOAK-1999 KC server doesn't start on EAP 6.4 in local mode on Pos…
2015-10-22 15:08:54 +02:00
mposolda e04dbffb88 KEYCLOAK-1999 KC server doesn't start on EAP 6.4 in local mode on PostgreSQL 2015-10-22 14:28:08 +02:00
vramik f823b17b90 add path for migration test realm 2015-10-22 14:04:50 +02:00
mhajas 7dfb7ddccd Merge remote-tracking branch 'upstream/master' 2015-10-21 15:41:34 +02:00
vramik 4b444d36b0 removed changes in admin-client 2015-10-21 10:35:19 +02:00
Stian Thorgersen 23546402fa Merge pull request #1749 from cfsnyder/master
KEYCLOAK-1863 added both issuer and account name to otp configuration
2015-10-21 09:24:58 +02:00
vramik edfc7ea103 add support for migration tests - KC1.6.0.Final 2015-10-20 17:00:57 +02:00
Stian Thorgersen 3a7c84c9e1 Merge pull request #1763 from mstruk/KEYCLOAK-1988
KEYCLOAK-1988 Loader constraint violation in multi-tenant example
2015-10-20 06:06:40 +02:00
Marko Strukelj 6b1287a553 KEYCLOAK-1988 Loader constraint violation in multi-tenant example 2015-10-19 22:11:31 +02:00
Stian Thorgersen c860c671d1 Fix parent of docbook modules 2015-10-19 19:37:51 +02:00
Marek Posolda 072950e9f3 Merge pull request #1762 from mposolda/master
KEYCLOAK-1987 Minor fixes in fuse demo
2015-10-19 19:23:05 +02:00
mposolda 8226abef40 KEYCLOAK-1987 Minor fixes in fuse demo 2015-10-19 17:29:04 +02:00
Bill Burke 0d05d38eb6 Merge remote-tracking branch 'upstream/master' 2015-10-19 10:21:03 -04:00
Stian Thorgersen 4f4368b29f Merge pull request #1761 from stianst/master
Version bump
2015-10-19 16:16:27 +02:00
Stian Thorgersen 3f8312427a Version bump 2015-10-19 16:15:29 +02:00
Marek Posolda 73bb579dc5 Merge pull request #1758 from mposolda/master
KEYCLOAK-1981 Migration fix of create-client
2015-10-19 14:11:37 +02:00
Stian Thorgersen c75528f81e Merge pull request #1760 from stianst/master
KEYCLOAK-1985
2015-10-19 13:35:37 +02:00
Stian Thorgersen 28bfac7214 KEYCLOAK-1985 2015-10-19 13:35:04 +02:00
Stian Thorgersen 1c9a347391 Merge pull request #1759 from stianst/master
KEYCLOAK-1984
2015-10-19 13:25:17 +02:00
Stian Thorgersen df03f51563 KEYCLOAK-1984
Examples includes pom.xml.releaseBackup
2015-10-19 13:25:02 +02:00
mposolda 7d590761dd KEYCLOAK-1981 Migration fix of create-client 2015-10-19 12:46:47 +02:00
Marek Posolda 944c416b45 Merge pull request #1757 from mposolda/master
KEYCLOAK-1983 Fix Oracle and Sybase
2015-10-19 12:27:45 +02:00
mposolda 028cbe1ce2 KEYCLOAK-1983 Fix Oracle and Sybase 2015-10-19 11:45:49 +02:00
Stian Thorgersen 256ca2b665 Merge pull request #1756 from stianst/master
KEYCLOAK-1977
2015-10-19 08:47:21 +02:00
Stian Thorgersen e4412523d4 Merge pull request #1754 from vramik/migration-kc15
arquillian-testsuite add migration-kc15
2015-10-19 08:44:51 +02:00
Stian Thorgersen 073d82b367 KEYCLOAK-1977 2015-10-19 08:43:34 +02:00
Stian Thorgersen 484c5ebb15 Merge pull request #1755 from stianst/master
Tweak authentication flow page a bit
2015-10-19 08:42:22 +02:00
vramik 4c33704c56 add support for migration kc1.5.1 2015-10-18 16:01:26 +02:00
Marek Posolda 511763d4bc Merge pull request #1753 from mposolda/master
KEYCLOAK-1952 Migration fix. Change some INFO messages to DEBUG/TRACE
2015-10-17 10:02:55 +02:00
mposolda 605c80a68d KEYCLOAK-1952 Migration fix. Change some INFO messages to DEBUG/TRACE 2015-10-16 20:51:40 +02:00
Marek Posolda 2325143803 Merge pull request #1751 from mposolda/master
KEYCLOAK-1972 docs and export/import fixes for offline tokens. DB fixes
2015-10-16 19:58:41 +02:00
mposolda 9cc5ca3ce4 KEYCLOAK-1972 docs and export/import fixes for offline tokens. DB fixes 2015-10-16 19:09:52 +02:00
Marek Posolda d13c120b6c Merge pull request #1750 from mposolda/master
KEYCLOAK-1929 Change package names. Fix Fuse demo
2015-10-16 17:35:14 +02:00
Bill Burke 186de7235c Merge remote-tracking branch 'upstream/master' 2015-10-16 11:03:42 -04:00
Bill Burke 9433ef284a set browser flow switch 2015-10-16 11:03:30 -04:00
mposolda 9942c7b519 Fix integration-arquillian 2015-10-16 16:57:28 +02:00
mposolda 4587fd23b6 KEYCLOAK-1929 Change package names. Fix Fuse demo 2015-10-16 16:30:42 +02:00
mhajas 32647d8682 Add tests for access grant and revoking grant 2015-10-16 16:22:30 +02:00
Cory Snyder d8ebf1e3d6 KEYCLOAK-1863 added both issuer and account name to otp configuration 2015-10-16 09:46:56 -04:00
Stian Thorgersen c21b56d596 Merge pull request #1748 from stianst/tweak-auth-page
Tweak authentication flow page a bit
2015-10-16 14:54:51 +02:00
Stian Thorgersen 4ee5c32b1e Merge pull request #1745 from stianst/kc-1969
KEYCLOAK-1969
2015-10-16 14:54:09 +02:00
Stian Thorgersen 6386d95904 Tweak authentication flow page a bit 2015-10-16 14:04:57 +02:00
Stian Thorgersen f99395aebe Merge pull request #1746 from mhajas/master
KEYCLOAK-1865 - Stabilize some integration-arquillian tests
2015-10-16 14:04:04 +02:00
Stian Thorgersen 82a7173dba Merge pull request #1747 from stianst/kc-1975
KEYCLOAK-1975
2015-10-16 14:03:47 +02:00
Stian Thorgersen 2bf6f4b0fd Tweak authentication flow page a bit 2015-10-16 14:03:30 +02:00
Stian Thorgersen d8e90028af Merge pull request #1744 from stianst/kc-1973
KEYCLOAK-1973 Clear user from authentication context is password is n…
2015-10-16 12:52:46 +02:00
Stian Thorgersen d2afb4892a KEYCLOAK-1975
Increase/decrease flow priority doesn't work
2015-10-16 12:52:07 +02:00
Stian Thorgersen eb9f69eee0 KEYCLOAK-1969
Admin console displays Clients flow page when execution or execution flow is created.
2015-10-16 12:23:41 +02:00
mhajas 39f985e04a Clean code 2015-10-16 12:09:35 +02:00
mhajas 41a51d924b Merge remote-tracking branch 'upstream/master' 2015-10-16 12:03:03 +02:00
mhajas ce996f6a41 Fix PasswordPolicyTest stability 2015-10-16 11:33:11 +02:00
mhajas 244848afc4 Fix events tests stability 2015-10-16 11:31:45 +02:00
Stian Thorgersen 2910db5595 KEYCLOAK-1973 Clear user from authentication context is password is not valid 2015-10-16 11:24:45 +02:00
Stian Thorgersen a6556a49c2 Merge pull request #1738 from gerbermichi/locale
KEYCLOAK-1962 update realm overwrites supported locales with empty list
2015-10-16 10:21:20 +02:00
Bill Burke e4961056db Merge pull request #1743 from patriot1burke/master
KEYCLOAK-1941
2015-10-15 20:41:35 -04:00
Bill Burke c8eee38471 Merge pull request #1742 from patriot1burke/master
KEYCLOAK-1954
2015-10-15 20:41:12 -04:00
Bill Burke 1e4b3fc3b6 KEYCLOAK-1941 2015-10-15 20:26:20 -04:00
Bill Burke 14426f26f2 KEYCLOAK-1954 2015-10-15 20:05:44 -04:00
Bill Burke 19ad846306 Merge pull request #1741 from patriot1burke/master
KEYCLOAK-1960
2015-10-15 19:33:55 -04:00
Bill Burke 235ffb2ff6 KEYCLOAK-1960 2015-10-15 18:56:56 -04:00
Bill Burke 181fdeb0d0 KEYCLOAK-1960 2015-10-15 18:54:57 -04:00
Bill Burke 8674578d0d Merge pull request #1730 from patriot1burke/master
KEYCLOAK-1908
2015-10-15 18:32:57 -04:00
Bill Burke 9cf4186eb2 fix arquillian test 2015-10-15 17:56:51 -04:00
Marek Posolda 92ed01a61b Merge pull request #1740 from mposolda/master
Offline tokens fixes & improvements
2015-10-15 23:15:50 +02:00
Bill Burke 99028e9cab Merge remote-tracking branch 'upstream/master' 2015-10-15 16:30:35 -04:00
Bill Burke 20f18eec15 support browser refresh 2015-10-15 16:30:21 -04:00
mposolda 67435791ed KEYCLOAK-1961 revokeRefreshToken support for offline tokens and other fixes 2015-10-15 22:30:17 +02:00
mposolda b4520baee5 KEYCLOAK-1959 Role offline_access was effective only when explicitly added to user 2015-10-15 22:30:17 +02:00
mposolda 802a39b1ce KEYCLOAK-904 Offline session idle timeout + admin console 2015-10-15 22:30:17 +02:00
Stian Thorgersen 229b964867 Merge pull request #1739 from mstruk/cli
KEYCLOAK-1849 Overlay installation scripts not working
2015-10-15 16:26:44 +02:00
mhajas b413bcb41d Unignored test 2015-10-15 14:57:58 +02:00
Marko Strukelj 0c39e30241 KEYCLOAK-1849 Overlay installation scripts not working
- fix unsupported dependency 'org.infinispan:main' warning
2015-10-15 13:46:38 +02:00
Marko Strukelj 11a8d3842e KEYCLOAK-1849 Overlay installation scripts not working 2015-10-15 13:46:38 +02:00
mhajas 2c460c3adc Test password policies using REST 2015-10-15 12:44:27 +02:00
Vlasta Ramik aaddaa6c25 Merge remote-tracking branch 'upstream/master' 2015-10-15 12:30:17 +02:00
Stian Thorgersen 96099e0798 Merge pull request #1732 from stianst/master
KEYCLOAK-1961
2015-10-15 10:57:23 +02:00
Stian Thorgersen e582de2837 KEYCLOAK-1961
Same token can be used multiple times to obtain access token
2015-10-15 09:11:18 +02:00
Stian Thorgersen e1fc863421 Merge pull request #1719 from gautric/french-i18n
French i18n
2015-10-15 08:54:26 +02:00
Stian Thorgersen 7de4051c9b Merge pull request #1737 from thomasdarimont/issue/KEYCLOAK-1918
KEYCLOAK-1918 - Add description field to client definition.
2015-10-15 08:53:47 +02:00
Stian Thorgersen 5b7b5b1b60 Merge pull request #1736 from stianst/test
Add test to make sure expired password is checked on direct grant
2015-10-15 08:53:28 +02:00
Michael Gerber f8effaee58 return null instead of an empty set. 2015-10-15 08:19:18 +02:00
Stian Thorgersen bf7d43fffb Add test to make sure expired password is checked on direct grant 2015-10-15 08:03:54 +02:00
Thomas Darimont 870702fd81 KEYCLOAK-1918 - Add description field to client definition.
Introduced description field with support for i18n for more descriptive client information.
Applications can use the description to display a "slightly" longer gist of
what the client / application is about, especially useful for tooltips.

The description is currently limited to 255 characters.
2015-10-15 07:33:38 +02:00
Stian Thorgersen 2a3e5fa7a4 Merge pull request #1733 from stianst/add-user-to-email-templates
KEYCLOAK-1965
2015-10-15 06:50:51 +02:00
Stian Thorgersen 90063cafec KEYCLOAK-1965
Include the user resource in the attribute map used by email provider freemarker
2015-10-14 20:29:15 +02:00
Stian Thorgersen 2b6fcc05e1 Merge pull request #1731 from stianst/master
Fix docbook
2015-10-14 20:15:54 +02:00
Stian Thorgersen f585ed5582 Fix docbook 2015-10-14 20:15:35 +02:00
Stian Thorgersen 192387047f Merge pull request #1728 from stianst/master
KEYCLOAK-1930
2015-10-14 20:15:00 +02:00
Bill Burke 78664e2571 Merge remote-tracking branch 'upstream/master' 2015-10-14 11:50:02 -04:00
Bill Burke bc71739fb2 Merge pull request #1729 from patriot1burke/master
KEYCLOAK-1839
2015-10-14 11:49:41 -04:00
Bill Burke 5563118d79 KEYCLOAK-1908 2015-10-14 11:49:36 -04:00
Bill Burke aadd63e2b0 Merge remote-tracking branch 'upstream/master' 2015-10-14 10:51:14 -04:00
Bill Burke 59d548228a KEYCLOAK-1839 2015-10-14 10:50:53 -04:00
Marek Posolda 68c3f2f65b Merge pull request #1726 from mposolda/master
KEYCLOAK-904 Offline tokens storage changes. Added UserSessionPersisterProvider . offline sessions preloaded to cache at startup
2015-10-14 14:24:54 +02:00
Stian Thorgersen b54bb25121 KEYCLOAK-1930 2015-10-14 14:22:10 +02:00
Stian Thorgersen 7f65a2be16 Merge pull request #1727 from stianst/master
Disable cli install scripts for overlay
2015-10-14 13:53:23 +02:00
Stian Thorgersen b907f8f92c Disable cli install scripts 2015-10-14 13:52:36 +02:00
Stian Thorgersen 3381ed50d1 KEYCLOAK-1930 2015-10-14 12:36:25 +02:00
mposolda c2c2b835b2 Unable to compile on JDK 7 2015-10-14 11:23:10 +02:00
mposolda f92fe6bea9 KEYCLOAK-904 Offline tokens storage changes. Added UserSessionPersisterProvider . offline sessions preloaded to cache at startup 2015-10-14 11:07:44 +02:00
Stian Thorgersen 6aa029784a Merge pull request #1724 from stianst/master
KEYCLOAK-1849 KEYCLOAK-1958 Fix install scripts for overlays
2015-10-14 09:31:07 +02:00
Stian Thorgersen 325072c74d KEYCLOAK-1849 KEYCLOAK-1958 Fix install scripts for overlays 2015-10-14 09:24:06 +02:00
Stian Thorgersen 1e48143db0 Merge pull request #1723 from stianst/master
KEYCLOAK-1877
2015-10-14 09:23:35 +02:00
Stian Thorgersen 8c72ef2980 KEYCLOAK-1877
Empty bubble in admin event types select box
2015-10-14 07:22:56 +02:00
Stian Thorgersen e7febbd5a5 Merge pull request #1700 from kodemaniak/master
URI based configuration of MongoDB to support Replica Sets
2015-10-14 07:07:03 +02:00
Stian Thorgersen d9211d6bc9 Merge pull request #1718 from lkubik/capitalizeAllLetters
KEYCLOAK-1945
2015-10-14 06:53:24 +02:00
Stian Thorgersen 8121a9391f Merge pull request #1721 from stianst/master
KEYCLOAK-1883
2015-10-14 06:49:23 +02:00
Stian Thorgersen 65b05fd4e4 Merge pull request #1722 from ssilvert/catch-missing-bundle-keys
Catch missing bundle keys
2015-10-14 06:38:40 +02:00
Stan Silvert 940c9f8bf1 KEYCLOAK-1933 Validate resource bundles for admin console 2015-10-13 18:25:14 -04:00
Stian Thorgersen c85e0248dd KEYCLOAK-1883
Improve setting of users locale
2015-10-13 19:47:10 +02:00
Stian Thorgersen 2ec143a3ba Fix tests 2015-10-13 13:17:46 +02:00
Stian Thorgersen a279ff3d7f Merge pull request #1717 from stianst/master
KEYCLOAK-1947 Add tests without client secret
2015-10-13 10:36:42 +02:00
gautric 128c26043b [KEYCLOAK-1903] Add French language support, cross link with other translation 2015-10-13 10:08:34 +02:00
gautric fe9b5a6588 Merge remote-tracking branch 'keycloak/master' into french-i18n 2015-10-13 10:02:04 +02:00
Lukas Kubik 0f93e72b02 KEYCLOAK-1945
Change capitalize function behavior
2015-10-13 09:18:54 +02:00
Stian Thorgersen bdba5ff8b1 KEYCLOAK-1947 Add tests without client secret 2015-10-13 09:02:09 +02:00
Stian Thorgersen 7071161a7c Merge pull request #1716 from stianst/master
KEYCLOAK-1865
2015-10-13 09:00:29 +02:00
Stian Thorgersen 672103e363 KEYCLOAK-1865
Failing tests in testsuite/integration-arquillian
2015-10-13 09:00:12 +02:00
Stian Thorgersen f579d7ffe9 Merge pull request #1715 from stianst/fix-email-removed-profile
KEYCLOAK-1823
2015-10-13 08:58:58 +02:00
Stian Thorgersen d1f0b353e8 Merge pull request #1714 from stianst/master
KEYCLOAK-1335
2015-10-13 08:26:50 +02:00
Stian Thorgersen ef56dca050 KEYCLOAK-1823
Annoying behaviour of validations in user registration form
2015-10-13 08:14:39 +02:00
Stian Thorgersen 07c3772b08 KEYCLOAK-1823
Annoying behaviour of validations in user registration form
2015-10-13 07:36:20 +02:00
Stian Thorgersen 85a886da18 KEYCLOAK-1823
Annoying behaviour of validations in user registration form
2015-10-13 07:30:31 +02:00
Stian Thorgersen 4ce93171ba KEYCLOAK-1335
Slow startup in OpenStack
2015-10-13 07:00:47 +02:00
Stian Thorgersen c987d57b9e Merge pull request #1713 from girirajsharma/master
[KEYCLOAK-1923] It's possible to create new authentication flow with empty name
2015-10-13 06:49:24 +02:00
Stian Thorgersen a416327124 Merge pull request #1712 from gautric/french-i18n
[KEYCLOAK-1903] Add French language support, add and fix some translations
2015-10-13 06:49:05 +02:00
girirajsharma 285ef50341 [KEYCLOAK-1923] It's possible to create new authentication flow with empty name 2015-10-13 00:29:08 +05:30
Stian Thorgersen 0d22074826 Merge pull request #1711 from stianst/remove-zip-export
KEYCLOAK-1944
2015-10-12 19:38:32 +02:00
gautric b76fb68ff7 [KEYCLOAK-1903] Add French language support, 2xSimpleQuote correction 2015-10-12 19:32:04 +02:00
gautric f03128f5ed [KEYCLOAK-1903] Add French language support, 2xSimpleQuote correction 2015-10-12 19:31:07 +02:00
gautric 8fb05bacd1 [KEYCLOAK-1903] Add French language support, correct accent 2015-10-12 19:29:09 +02:00
gautric f8842b3df1 [KEYCLOAK-1903] Add French language support. add and fixes some translation 2015-10-12 19:25:31 +02:00
gautric b376d1fb6d Some fixes into "fr" messages 2015-10-12 16:52:14 +02:00
gautric d4e0901599 Merge remote-tracking branch 'keycloak/master' into french-i18n 2015-10-12 16:27:18 +02:00
Vlasta Ramik 217c359530 Merge remote-tracking branch 'upstream/master' 2015-10-12 15:35:04 +02:00
Stian Thorgersen 4fbf6841be KEYCLOAK-1944
Remove winzipaes import/export provider
2015-10-12 14:43:52 +02:00
Stian Thorgersen 2deb20a2c9 Merge pull request #1710 from stianst/master
Fix for issue introduced by fixing KEYCLOAK-1931
2015-10-12 14:03:57 +02:00
Stian Thorgersen 20b92c410f Fix for issue introduced by fixing KEYCLOAK-1931 2015-10-12 14:03:38 +02:00
Vlasta Ramik 1d829a8365 Merge remote-tracking branch 'upstream/master' 2015-10-12 13:55:36 +02:00
Stian Thorgersen 10b4bd24a4 Merge pull request #1706 from girirajsharma/Patch-Keycloak-1931
[KEYCLOAK-1931] UI doesn't reflect when flow is deleted.
2015-10-12 13:48:45 +02:00
Stian Thorgersen 788501f13d Merge pull request #1704 from AOEpeople/KEYCLOAK-1910
KEYCLOAK-1910, added same fix for registrations endpoint
2015-10-12 13:36:02 +02:00
Carsten Saathoff 345bea50b6 Added documentation about the mongodb:// URI based configuration and how to use a MongoDB replica set. 2015-10-12 13:04:48 +02:00
gautric ab7bfa6d90 Merge remote-tracking branch 'keycloak/master' 2015-10-12 11:45:08 +02:00
Stian Thorgersen 4f7979d9fc Merge pull request #1707 from stianst/client-reg
Refactored client registration service
2015-10-12 11:15:19 +02:00
Stian Thorgersen 286458b94a Merge pull request #1709 from stianst/fix-test-timeouts
Disable failing tests
2015-10-12 10:51:17 +02:00
Stian Thorgersen 61a8c422df Disable failing tests 2015-10-12 09:39:57 +02:00
Stian Thorgersen baaf445727 Merge pull request #1678 from gautric/master
[KEYCLOAK-1903] Add French language support
2015-10-12 08:49:44 +02:00
Stian Thorgersen 2faf0eccdb Refactored client registration service 2015-10-12 08:31:39 +02:00
girirajsharma 639b5b617b [KEYCLOAK-1931] UI doesn't reflect when flow is deleted 2015-10-11 12:42:07 +05:30
girirajsharma 115663a32d [KEYCLOAK-1932] Unable to create flow named exactly the same as removed NON-top level flow 2015-10-11 12:42:07 +05:30
Sebastian Rose b277afa6d9 KEYCLOAK-1910, added same fix for registrations endpoint 2015-10-10 10:40:16 +02:00
Bill Burke 960cd8c822 Merge pull request #1703 from patriot1burke/master
filter docs
2015-10-09 19:02:47 -04:00
Bill Burke 4acc69c604 Merge pull request #1702 from patriot1burke/master
SAML and OIDC Servlet Filter SP
2015-10-09 19:02:18 -04:00
Bill Burke 0230e008c5 filter docs 2015-10-09 18:49:15 -04:00
Bill Burke 382b8d60d0 Merge remote-tracking branch 'upstream/master' 2015-10-09 18:11:53 -04:00
Bill Burke 0ad29c9737 node registration 2015-10-09 18:11:38 -04:00
Bill Burke 9ced56d8d7 saml and oidc filters 2015-10-09 18:07:50 -04:00
Carsten Saathoff eb197c46f7 Setting operational attributes for mongo also when configured via URI. 2015-10-09 15:06:22 +02:00
Stian Thorgersen 63947cd37a Merge pull request #1698 from stianst/master
Renamed 'Keycloak Version to Server Version' on server info page
2015-10-09 13:59:29 +02:00
Stian Thorgersen 938ce9612c Renamed 'Keycloak Version to Server Version' on server info page 2015-10-09 13:59:12 +02:00
Stian Thorgersen d6119c04d6 Merge pull request #1697 from stianst/master
KEYCLOAK-1859 Invalid "Go to the home page" link on the "Resource not…
2015-10-09 13:45:44 +02:00
Stian Thorgersen 14646781ad KEYCLOAK-1859 Invalid "Go to the home page" link on the "Resource not found" page 2015-10-09 13:45:20 +02:00
vramik 1b41832946 fixed verifyEmail test 2015-10-09 13:43:16 +02:00
Stian Thorgersen 57d0bac96a Merge pull request #1696 from stianst/fix-admin-console-not-loading-properly
KEYCLOAK-1876 Some admin console pages don't load properly when accessed via URL
2015-10-09 11:11:03 +02:00
Stian Thorgersen 2ca3ce2dba Merge pull request #1693 from stianst/fix-umlats
KEYCLOAK-1739 User registration form is not able to process diacritics
2015-10-09 10:36:17 +02:00
Stian Thorgersen e5d404fdb3 Remove unused import 2015-10-09 09:54:39 +02:00
Stian Thorgersen 8829fe8658 KEYCLOAK-1739 User registration form is not able to process diacritics 2015-10-09 09:52:25 +02:00
Stian Thorgersen 9ccb0b1f65 Merge pull request #1692 from stianst/fix-json-includes-null
KEYCLOAK-1896 Search for users returns null values
2015-10-09 09:50:30 +02:00
Stian Thorgersen 7bb70f2d00 Merge pull request #1681 from mstruk/i18n
KEYCLOAK-1152 Internationalization support for admin console
2015-10-09 09:50:20 +02:00
Stian Thorgersen 3ab7edbbcd Merge pull request #1695 from stianst/fix-undertow-start
KEYCLOAK-1935 Stop KeycloakServer if Undertow fails to start
2015-10-09 09:49:34 +02:00
Stian Thorgersen d4060cce92 KEYCLOAK-1876 Some admin console pages don't load properly when accessed via URL 2015-10-09 09:44:00 +02:00
Stian Thorgersen 1342904fae KEYCLOAK-1935 Stop KeycloakServer if Undertow fails to start 2015-10-09 09:03:48 +02:00
Stian Thorgersen fc0a3c3e73 Merge pull request #1694 from stianst/master
Fix docbook parent pom artifactId
2015-10-09 08:54:15 +02:00
Stian Thorgersen 756a9f095c Fix docbook parent pom artifactId 2015-10-09 08:53:57 +02:00
Stian Thorgersen 021e48d6d6 Merge pull request #1689 from AOEpeople/KEYCLOAK-1927
KEYCLOAK-1927
2015-10-09 07:06:51 +02:00
Bill Burke 91f78c61b7 Merge pull request #1691 from patriot1burke/master
SAML SP Servlet Filter
2015-10-08 20:50:55 -04:00
Bill Burke d39aee0a72 Merge remote-tracking branch 'upstream/master' 2015-10-08 16:19:56 -04:00
Bill Burke 7c600e2f4b SAML SP Filter 2015-10-08 16:19:43 -04:00
Stan Silvert 14079b950a KEYCLOAK-1933: Validate resource bundles for admin console 2015-10-08 15:23:27 -04:00
Sebastian Rose 173c112f8e KEYCLOAK-1927 2015-10-08 20:34:08 +02:00
Stian Thorgersen 67d8ca0207 KEYCLOAK-1896 Search for users returns null values 2015-10-08 20:15:53 +02:00
Marko Strukelj e690f4e645 KEYCLOAK-1152 Internationalization support for admin console
- Added custom mapper fields localization
2015-10-08 17:11:06 +02:00
Stian Thorgersen 4c554b4af6 Merge pull request #1687 from stianst/client-reg2
KEYCLOAK-1749 Client registration service and client java api
2015-10-08 15:48:58 +02:00
Marko Strukelj 3aee5eeecf KEYCLOAK-1152 Internationalization support for admin console
- Added i18n to 'clients', and 'identity providers' sections
2015-10-08 15:31:03 +02:00
Stian Thorgersen 366a1629e5 KEYCLOAK-1749 Client registration service and client java api 2015-10-08 11:55:42 +02:00
Stian Thorgersen 7fec1677ee Merge pull request #1679 from lkrzyzanek/KEYCLOAK-1904
Add 'register' and 'createRegisterUrl' methods to Javascript Adapter API
2015-10-08 11:51:18 +02:00
Carsten Saathoff 8e391ffa4e After rebase to upstream: Merge branch 'master' of github.com:kodemaniak/keycloak 2015-10-08 10:45:36 +02:00
Carsten Saathoff d65ce5d1d4 Added configuration via mongodb:// uri to mongo provider factory. 2015-10-08 10:44:49 +02:00
Carsten Saathoff 6741dffe38 Added configuration via mongodb:// uri to mongo provider factory. 2015-10-08 10:02:36 +02:00
Stian Thorgersen 894af03323 Merge pull request #1680 from ssilvert/i18n-in-java
KEYCLOAK-1152 i18n for text hard-coded in java source
2015-10-08 06:47:10 +02:00
Bill Burke 80dea9c0bd Merge pull request #1682 from patriot1burke/master
SAML eap adapter and docs
2015-10-07 21:00:33 -04:00
Bill Burke 0b83325470 cleanup 2015-10-07 16:30:42 -04:00
Bill Burke 368ea64b51 Merge remote-tracking branch 'upstream/master' 2015-10-07 16:21:13 -04:00
Bill Burke 450e031da9 saml adapter docs 2015-10-07 16:20:59 -04:00
Marek Posolda 1796a45a68 Merge pull request #1677 from mkdgit/Customized_LDAP_filter_1_6
KEYCLOAK-1906 : Customized LDAP filter
2015-10-07 22:05:30 +02:00
Stan Silvert c9437595b7 KEYCLOAK-1152 i18n for text hard-coded in java source
(ProtocolMapperUtils)
2015-10-07 11:34:34 -04:00
Bill Burke a1b315adbd Merge remote-tracking branch 'upstream/master' 2015-10-07 10:19:26 -04:00
Bill Burke 1781588597 as7/eap saml adapter 2015-10-07 10:19:15 -04:00
Libor Krzyzanek f29aff4bed Add 'register' and 'createRegisterUrl' methods to Javascript Adapter API. fixes #KEYCLOAK-1904 2015-10-07 13:53:25 +02:00
Stian Thorgersen ac91839e69 Merge pull request #1663 from thomasdarimont/issue/KEYCLOAK-1893
KEYCLOAK-1893 - Allow to configure OTP period in admin console.
2015-10-07 09:35:59 +02:00
Stian Thorgersen 9c0c8e37b6 Merge pull request #1676 from Smartling/KEYCLOAK-1901
KEYCLOAK-1901: Add a Keycloak client builder
2015-10-07 09:06:19 +02:00
Bill Burke d40237b08d saml adapters docs/dist 2015-10-06 15:56:44 -04:00
gautric 59527e12f0 [KEYCLOAK-1903] Add French language support, few fixes 2015-10-06 20:01:04 +02:00
gautric 6d0483667f [KEYCLOAK-1903] Add French language support 2015-10-06 18:09:36 +02:00
gautric dcf8747d7e Merge remote-tracking branch 'keycloak/master' 2015-10-06 16:32:11 +02:00
Stian Thorgersen 7a3b4823b0 Merge pull request #1662 from Smartling/KEYCLOAK-1892
WrappedHttpServletRequest may throw an exception returning cookies
2015-10-06 14:58:54 +02:00
Stian Thorgersen 64ecc3b153 Merge pull request #1672 from ssilvert/KEYCLOAK-1882-add-locale-mapper-on-new-realm
KEYCLOAK-1882 Also add locale mapper when new realm is created.
2015-10-06 14:58:27 +02:00
Stian Thorgersen cc41a1fd78 Merge pull request #1656 from gerbermichi/import2
swap import and migrate order (KEYCLOAK-1884)
2015-10-06 12:05:59 +02:00
gautric 255b1cb3bf Merge remote-tracking branch 'keycloak/master' 2015-10-06 10:25:23 +02:00
Michal Drela a1bb202bd4 Customized LDAP filter 2015-10-06 10:01:29 +02:00
Scott Rossillo 332e3f6099 KEYCLOAK-1901: Add a Keycloak client builder
Adds support for creating a Keycloak client using the builder
pattern and supports customizing the underlying ResteasyClient
used for connecting to the Keycloak server.
2015-10-05 14:56:38 -04:00
Bill Burke 6b41d79058 Merge pull request #1675 from patriot1burke/master
saml adapter doc module
2015-10-05 13:34:53 -04:00
Bill Burke 3b4b5c11e6 Merge remote-tracking branch 'upstream/master' 2015-10-05 13:33:55 -04:00
Bill Burke 0c9e764e11 move docs 2015-10-05 13:33:38 -04:00
Marek Posolda 00cbc22d8b Merge pull request #1674 from girirajsharma/master
[KEYCLOAK-1864] No names for required actions
2015-10-05 08:56:26 +02:00
girirajsharma 0a3de09b5a [KEYCLOAK-1864] No names for required actions 2015-10-04 23:44:44 +05:30
Bill Burke 4e0ad5ac0b Merge pull request #1673 from patriot1burke/master
saml adapter schema and simplifications
2015-10-02 21:16:34 -04:00
Bill Burke 72256fd6ac Merge remote-tracking branch 'upstream/master' 2015-10-02 18:40:05 -04:00
Bill Burke d06237a3fd saml adapter schema and simplifications 2015-10-02 18:39:50 -04:00
Stan Silvert 28fad68486 KEYCLOAK-1882 Also add locale mapper when new realm is created. 2015-10-02 15:01:39 -04:00
Stian Thorgersen 53b86cbace Merge pull request #1671 from stianst/master
KEYCLOAK-1882 Add locale mapper to admin console clients during migra…
2015-10-02 15:09:43 +02:00
Stian Thorgersen a53aebcddf KEYCLOAK-1882 Add locale mapper to admin console clients during migration 2015-10-02 13:43:41 +02:00
Marek Posolda af307c695a Merge pull request #1670 from mposolda/master
KEYCLOAK-1856 KEYCLOAK-1860 Fix onoffswitchvalue directive
2015-10-02 11:58:04 +02:00
mposolda 7816f053a6 KEYCLOAK-1856 KEYCLOAK-1860 Fix onoffswitchvalue directive 2015-10-02 11:09:54 +02:00
Bill Burke ed54ba9064 Merge pull request #1669 from patriot1burke/master
keycloak-common
2015-10-01 16:03:20 -04:00
Bill Burke 8acdaf462b fix arquillian 2015-10-01 15:14:16 -04:00
Bill Burke c5efd34a46 Merge remote-tracking branch 'upstream/master' 2015-10-01 14:28:04 -04:00
Bill Burke 75343986b0 keycloak-common 2015-10-01 14:27:51 -04:00
Stian Thorgersen 424d357c9c Merge pull request #1668 from vramik/master
arquillian-testsuite: fixed org.keycloak.services.ForbiddenException in test log
2015-10-01 16:35:29 +02:00
Stian Thorgersen 56116038d6 Merge pull request #1667 from stianst/fb-fix
KEYCLOAK-1894 Fix login with Facebook missing profile details
2015-10-01 13:37:57 +02:00
Stian Thorgersen c76da8f3b8 Merge pull request #1666 from stianst/migration-fix
Fix db migration not running as latest jpa version wasn't updated
2015-10-01 13:37:49 +02:00
Stian Thorgersen 589eb3206e KEYCLOAK-1894 Fix login with Facebook missing profile details 2015-10-01 11:54:14 +02:00
Stian Thorgersen 5419ec32e4 Fix db migration not running as latest jpa version wasn't updated 2015-10-01 09:01:06 +02:00
Stian Thorgersen c9e0a7a97d Merge pull request #1657 from stianst/zxing
KEYCLOAK-1888
2015-10-01 08:07:43 +02:00
Bill Burke 5b5f99fdfe Merge pull request #1665 from patriot1burke/master
saml wildfly sp/dist
2015-09-30 17:41:41 -04:00
Bill Burke d3bd0a67a7 saml example docs 2015-09-30 16:51:21 -04:00
Bill Burke 2a36185419 Merge remote-tracking branch 'upstream/master' 2015-09-30 16:36:42 -04:00
Bill Burke 76e3c6394c saml sp distro 2015-09-30 16:36:21 -04:00
Thomas Darimont 9e15b20591 KEYCLOAK-1893 - Allow to configure OTP period in admin console.
Added input form that allows to specify the OTP token period
in the `OTP Policy` section of the `Authentication` settings.

Since the value is already backed by the provided `otpPolicyPeriod`
field in the `RealmRepresentation` class we only needed to show the value
in the admin ui.
2015-09-30 21:07:06 +02:00
Scott Rossillo 05bd51ac1c WrappedHttpServletRequest may throw an exception returning cookies
HttpServletRequest.getCookies() may return null
2015-09-30 14:31:15 -04:00
Bill Burke d648ba73de wildfly saml distro 2015-09-30 11:56:21 -04:00
Marek Posolda c6b34f32a1 Merge pull request #1660 from mposolda/master
Fixes
2015-09-30 17:16:44 +02:00
Stian Thorgersen 974c0a50e7 Merge pull request #1659 from stianst/liquibase
KEYCLOAK-1890
2015-09-30 17:05:30 +02:00
Bill Burke 07d3b26722 Merge remote-tracking branch 'upstream/master' 2015-09-30 11:01:55 -04:00
Bill Burke 510b03476f saml distro 2015-09-30 11:01:45 -04:00
mposolda 4f6d3c8dca KEYCLOAK-1815 Reduce info logging 2015-09-30 16:35:56 +02:00
mposolda 95fe2fe74b KEYCLOAK-904 offline tokens - migration 2015-09-30 16:35:56 +02:00
Stian Thorgersen e937216cf7 KEYCLOAK-1888
Upgrade ZXing dependency
2015-09-30 15:03:02 +02:00
Stian Thorgersen fd8d93663e KEYCLOAK-1890
Upgrade to Liquibase 3.4.1
2015-09-30 15:02:30 +02:00
Stian Thorgersen a048cfc102 Fix merge error 2015-09-30 15:00:35 +02:00
Stian Thorgersen 272272634d KEYCLOAK-1889
Upgrade FreeMarker dependency
2015-09-30 14:58:02 +02:00
Stian Thorgersen 01947f46b9 Merge pull request #1655 from stianst/twitter4j
KEYCLOAK-1887 Upgrade Twitter4j dependency
2015-09-30 14:49:24 +02:00
Bill Burke 5ec73a81e9 Merge pull request #1651 from patriot1burke/master
wf saml adapter first iter
2015-09-30 08:39:45 -04:00
vramik 4cba764ac3 add view-realm role to test user for test realm to avoid org.keycloak.services.ForbiddenException in test log 2015-09-30 14:23:24 +02:00
Stian Thorgersen 84b9963609 Merge pull request #1654 from stianst/master
Set product name/version in keycloak-paren pom
2015-09-30 14:21:39 +02:00
Stian Thorgersen 99c216635f KEYCLOAK-1887
Upgrade Twitter4j dependency
2015-09-30 14:08:21 +02:00
Stian Thorgersen 25a6fcc382 Set product name/version in keycloak-paren pom 2015-09-30 13:41:37 +02:00
Michael Gerber acefd3cacd swap import and migrate order 2015-09-30 13:31:22 +02:00
Marek Posolda 15a5c87cc5 Merge pull request #1653 from mposolda/master
KEYCLOAK-904 offline tokens - example, refactoring, polishing
2015-09-30 12:37:18 +02:00
mposolda 3044138e10 Fix compilation errors 2015-09-30 10:51:53 +02:00
mposolda 6fbb8ccf71 KEYCLOAK-904 Offline tokens - model changes, admin console, export/import, docs 2015-09-30 10:51:36 +02:00
mposolda 018866aa81 KEYCLOAK-904 Offline portal example added 2015-09-30 09:23:23 +02:00
Bill Burke 18b2b572ac fix compilation errors 2015-09-29 20:38:10 -04:00
Bill Burke d9e67aa5ee Merge remote-tracking branch 'upstream/master' 2015-09-29 20:26:16 -04:00
Bill Burke e675ce44d5 Merge remote-tracking branch 'upstream/master' 2015-09-29 20:25:28 -04:00
Bill Burke df46a8ea0d Merge pull request #1647 from patriot1burke/master
tomcat 7 and 8 SAML adapter tests
2015-09-29 20:25:19 -04:00
Bill Burke e277d5b55e wf saml adapter 2015-09-29 20:24:59 -04:00
Stian Thorgersen 4bd1d899db Merge pull request #1618 from ssilvert/i18n
KEYCLOAK-1152: i18n using angular-translate
2015-09-29 14:57:24 +02:00
Stian Thorgersen 3e3d92c2e4 Merge pull request #1650 from stianst/client-reg2
KEYCLOAK-1868 Import clients through admin console
2015-09-29 14:12:59 +02:00
Stian Thorgersen 55deedd3b8 KEYCLOAK-1868 Import clients through admin console
KEYCLOAK-1869 Add root url to clients that should be used to resolve relative urls
2015-09-29 12:16:05 +02:00
Stian Thorgersen 8b6251eb23 Merge pull request #1649 from eugene-chow/master
Updated documentation for "Server Installation > Installing Keycloak Server as Root Context"
2015-09-29 08:59:54 +02:00
Stian Thorgersen 35919da0a4 Merge pull request #1645 from mhajas/master
Arquillian testsuite refactoring
2015-09-29 08:59:09 +02:00
Eugene Chow ec018d2739 Updated documentation for "Server Installation > Installing Keycloak Server as Root Context" to work with Keycloak 1.5 2015-09-29 10:32:16 +08:00
Bill Burke b1a23a13d6 jetty saml fixes 2015-09-28 16:30:03 -04:00
Bill Burke 3ebbe96786 Merge remote-tracking branch 'upstream/master' 2015-09-28 16:05:22 -04:00
Bill Burke cfaa4c60c9 jetty saml adapter 2015-09-28 16:05:07 -04:00
Stian Thorgersen e104450fc8 Merge pull request #1648 from girirajsharma/master
[KEYCLOAK-1880] Admin API Doesn't Detect Null Client
2015-09-28 09:06:26 +02:00
girirajsharma c22b0f4da8 [KEYCLOAK-1880] Admin API Doesn't Detect Null Client 2015-09-27 14:57:16 +05:30
Stan Silvert 302d0b58cc Get locale from token via builtin mapper. 2015-09-26 20:11:06 -04:00
Bill Burke 72999f0acb fix tomcat test shutdown 2015-09-25 17:32:19 -04:00
Bill Burke a942322d99 Merge pull request #1646 from patriot1burke/master
tomcat 6 saml adapter
2015-09-25 15:51:37 -04:00
Bill Burke 8902502c4d tomcat8 saml tests 2015-09-25 15:49:40 -04:00
Bill Burke 8d19741f53 tomcat 7 saml adapter 2015-09-25 15:45:16 -04:00
Bill Burke e60549d764 fix poms 2015-09-25 15:17:51 -04:00
Bill Burke 0a42a28eeb Merge remote-tracking branch 'upstream/master' 2015-09-25 15:12:34 -04:00
Bill Burke 88355d7eb4 tomcat6 adapter 2015-09-25 15:12:14 -04:00
mhajas 67db5917ac Merge remote-tracking branch 'upstream/master' 2015-09-25 09:30:58 +02:00
mhajas 8f1daf5d77 Refactoring 2015-09-25 09:10:17 +02:00
Stian Thorgersen 6d5e3b2a17 Merge pull request #1643 from stianst/master
KEYCLOAK-1878
2015-09-25 07:37:23 +02:00
Stian Thorgersen 75c0d5089f KEYCLOAK-1878
Add Base64 to Keycloak core
2015-09-25 07:02:25 +02:00
Tomas Kyjovsky 5b1fcbfc51 Merge pull request #1642 from tkyjovsk/master
FIxed compilation error of arquillian tests by adding keycloak-adapte…
2015-09-24 22:46:29 +02:00
Tomas Kyjovsky 0c80255f3a FIxed compilation error of arquillian tests by adding keycloak-adapter-spi dependency. 2015-09-24 21:57:02 +02:00
Stan Silvert 121f8e9174 Converted some more pages to user ng-translate. 2015-09-24 15:35:37 -04:00
Bill Burke c1cb50b39f Merge pull request #1641 from patriot1burke/master
initial saml sp adapter
2015-09-24 14:23:05 -04:00
Bill Burke 791a740f32 Merge remote-tracking branch 'upstream/master' 2015-09-24 12:05:24 -04:00
Bill Burke 546cdd7d8f fix modules for refactor 2015-09-24 12:05:12 -04:00
Stian Thorgersen 8ef6602f82 Merge pull request #1640 from stianst/master
Removed unused netty dependency from keycloak parent
2015-09-24 09:16:33 +02:00
Stian Thorgersen 2938759db4 Removed unused files from common/lib theme 2015-09-24 08:37:01 +02:00
Stian Thorgersen f7bcca8553 Removed unused netty dependency from keycloak parent 2015-09-24 08:05:34 +02:00
Stian Thorgersen 4eaf893492 Merge pull request #1610 from raehalme/KEYCLOAK-1828
KEYCLOAK-1828 attemptAuthentication throws KeycloakAuthenticationException if authentication fails
2015-09-24 06:32:27 +02:00
Stian Thorgersen 0ba6ab198a Merge pull request #1611 from raehalme/KEYCLOAK-1829
KEYCLOAK-1829 unsuccessfulAuthentication now returns HTTP response status 401 instead of 403
2015-09-24 06:31:33 +02:00
Bill Burke 49a530f2b4 merge 2015-09-23 21:13:42 -04:00
Bill Burke c14d3d7963 merge conflicts 2015-09-23 21:01:47 -04:00
Bill Burke fe26d6ecec more 2015-09-23 20:54:27 -04:00
Bill Burke 35a00b449d all tests 2015-09-23 20:45:20 -04:00
Bill Burke 1e9c09d23a more complete 2015-09-23 17:54:16 -04:00
Stian Thorgersen ec4f8a7f15 Merge pull request #1639 from stianst/master
Make it possible to set hibernate spec artifact id with a property in…
2015-09-23 20:36:58 +02:00
Stian Thorgersen d109bf7b56 Updated release process to use maven release plugin 2015-09-23 15:50:25 +02:00
Stian Thorgersen 4625ab917d Merge pull request #1636 from vramik/master
arquillian-testsuite: Suppress error from GreenMail on shutdown, login settings test coverage
2015-09-23 15:37:12 +02:00
Stian Thorgersen 7d239f8990 Make it possible to set hibernate spec artifact id with a property in parent pom 2015-09-23 15:36:40 +02:00
Marek Posolda 22f7efd977 Merge pull request #1638 from mposolda/master
KEYCLOAK-904 Consents support. Added scopeParamRequired flag to RoleM…
2015-09-23 15:30:36 +02:00
mposolda 2a349673b9 Fix integration-arquillian 2015-09-23 14:47:20 +02:00
Vlasta Ramik 361019fc6a Merge remote-tracking branch 'upstream/master' 2015-09-23 13:07:48 +02:00
vramik abb099745f added test coverage of login settings 2015-09-23 13:07:30 +02:00
mposolda 046edbbd54 KEYCLOAK-904 Consents support. Added scopeParamRequired flag to RoleModel 2015-09-23 12:52:47 +02:00
Stian Thorgersen 8cc4c8c5e2 Merge pull request #1635 from stianst/realm-import
KEYCLOAK-1866
2015-09-23 11:45:56 +02:00
Vlasta Ramik d2d3a3f216 Merge remote-tracking branch 'upstream/master' 2015-09-23 11:23:57 +02:00
vramik cbf5c920ea Suppress error from GreenMail on shutdown 2015-09-23 11:21:48 +02:00
Stian Thorgersen 7ac1d1f14c KEYCLOAK-1866
Allow changing name and view details of imported realm
2015-09-23 11:08:53 +02:00
vramik e811b87679 moved smtp server configuration to suiteContext 2015-09-23 10:50:49 +02:00
Stian Thorgersen d08fca4e0a Merge pull request #1625 from girirajsharma/master
[KEYCLOAK-1787] Confirming password policy values with ENTER key deletes the first item in the table.
2015-09-23 08:33:07 +02:00
Stian Thorgersen 30aa41a2ee Merge pull request #1633 from stianst/update-username
KEYCLOAK-1857 Allow users to edit username on first login
2015-09-23 08:26:03 +02:00
Stian Thorgersen 9d8d690100 KEYCLOAK-1857 Prefill update profile form with username from user or formdata 2015-09-23 07:43:38 +02:00
dcampagna 43541d3028 Show error when username already exists (KEYCLOAK-1857) 2015-09-23 07:43:38 +02:00
dcampagna 880e831e71 Removed comment (KEYCLOAK-1857) 2015-09-23 07:43:38 +02:00
dcampagna fe2278b320 Fix broken tests (KEYCLOAK-1857) 2015-09-23 07:43:38 +02:00
dcampagna f7a8bbbcc8 Allow username change at first login (KEYCLOAK-1857) 2015-09-23 07:43:38 +02:00
dcampagna fde4bc99aa Allow username change at first login (KEYCLOAK-1849) 2015-09-23 07:43:38 +02:00
Bill Burke cc9d6d0cf7 saml undertow sp 2015-09-22 20:27:08 -04:00
Marek Posolda b17bbc9b86 Merge pull request #1634 from pdrozd/sync-ldap-sleep
Added configurable sleep time
2015-09-22 16:18:45 +02:00
Pavel Drozd d4c5349e1a Added configurable sleep time 2015-09-22 15:29:21 +02:00
Bill Burke 2865a3c047 Merge pull request #1626 from dbarentine/master
KEYCLOAK-1861 Allow setting of signature algorithm when signing SAML …
2015-09-22 08:37:46 -04:00
Marek Posolda 522fc7412c Merge pull request #1632 from mposolda/master
KEYCLOAK-904 Offline tokens - step 1
2015-09-21 12:06:33 +02:00
mposolda 7ec3f86efb KEYCLOAK-904 Offline tokens 2015-09-21 10:28:30 +02:00
mposolda c11539cccb docs and javadoc fixes 2015-09-21 10:13:41 +02:00
Stian Thorgersen 09488b8df3 Merge pull request #1629 from tkyjovsk/master-squashed
Updates and refactoring of arquillian testsuite.
2015-09-18 15:12:12 +02:00
Tomas Kyjovsky e16cc493d2 Updates and refactoring of arquillian testsuite. 2015-09-18 14:27:28 +02:00
Stian Thorgersen 379fc8961e Merge pull request #1628 from stianst/master
Configure maven release plugin
2015-09-18 13:24:31 +02:00
Stian Thorgersen 43114f176b Configure maven release plugin 2015-09-18 13:23:54 +02:00
Stian Thorgersen f01d959f7c Merge pull request #1624 from tkyjovsk/serial-versions
Removed occurences of serialVersionUID from all classes.
2015-09-18 13:03:37 +02:00
Stian Thorgersen 28f4409768 Merge pull request #1623 from mstruk/asciidoc
KEYCLOAK-1241 Can't build release with Java 8
2015-09-18 13:03:02 +02:00
Stian Thorgersen 364aecda2a Merge pull request #1627 from stianst/master
KEYCLOAK-1858
2015-09-18 13:02:38 +02:00
Stian Thorgersen 9bfbac6be5 KEYCLOAK-1858
JavaDoc aggregate fails during release if build not already executed
2015-09-18 10:11:51 +02:00
Dane Barentine db20fd9eeb KEYCLOAK-1861 Allow setting of signature algorithm when signing SAML AuthnRequests to IDPs 2015-09-17 15:55:59 -07:00
Giriraj Sharma 53a198fde8 [KEYCLOAK-1787] Confirming password policy values with ENTER key deletes the first item in table 2015-09-17 23:56:17 +05:30
Bill Burke 861a13501a merge 2015-09-17 14:25:16 -04:00
Bill Burke 0f24bd2ea4 merge 2015-09-17 14:06:33 -04:00
Bill Burke 9dc54815eb Merge pull request #1616 from dbarentine/master
Bug fixes
2015-09-17 14:01:13 -04:00
Bill Burke cb8ca619ae saml sp 2015-09-17 14:00:57 -04:00
Tomas Kyjovsky ac91deac96 Removed occurences of serialVersionUID from all classes. 2015-09-17 17:27:39 +02:00
Marko Strukelj 71e2be5d3d KEYCLOAK-1241 Can't build release with Java 8
- Fix Null title in some build environments
2015-09-17 14:10:15 +02:00
Stian Thorgersen 4878073867 Merge pull request #1587 from mstruk/asciidoc
KEYCLOAK-1241 Can't build release with Java 8
2015-09-17 09:06:22 +02:00
Stian Thorgersen dc327ddddb Merge pull request #1621 from stianst/master
KEYCLOAK-1854
2015-09-17 08:36:08 +02:00
Stian Thorgersen e6467403ef Merge pull request #1600 from cfsnyder/master
KEYCLOAK-1807 Fix bug with commas in regex password policies
2015-09-17 08:26:56 +02:00
Stian Thorgersen cf0fab2d66 Merge pull request #1620 from lkubik/unifyJetty8Versions
Unify jetty 8.1 artifacts version with fabric8-bom-1.2.0.redhat-133.pom
2015-09-17 08:23:22 +02:00
Stian Thorgersen 2eaa03539c KEYCLOAK-1854
NPE in SystemInfoRepresentation if user.country or user.language not set
2015-09-17 07:38:37 +02:00
Lukas Kubik b7e49dc88d Unify jetty 8.1 artifacts version with fabric8-bom-1.2.0.redhat-133.pom 2015-09-16 17:14:29 +02:00
Marek Posolda ca05455aa0 Merge pull request #1619 from mstruk/kerberos
KEYCLOAK-1852 Improve Kerberos example documentation
2015-09-16 15:08:50 +02:00
Stian Thorgersen 7ae3eb8321 Merge pull request #1615 from ssilvert/breadcrumbs
Fix breadcrumbs.
2015-09-16 14:16:14 +02:00
Stan Silvert ae54babbbb Update client-credentials-jwt-key-import.html 2015-09-16 07:40:30 -04:00
Stan Silvert a8378fe84b Update client-credentials-jwt-key-export.html 2015-09-16 07:40:14 -04:00
Stian Thorgersen 85df0b6a67 Merge pull request #1613 from raehalme/KEYCLOAK-1832
KEYCLOAK-1832 Added check for null authentication on the logout method
2015-09-16 13:34:51 +02:00
Marko Strukelj 95967b9c79 KEYCLOAK-1852 Improve Kerberos example documentation and user experience 2015-09-16 12:22:56 +02:00
Marko Strukelj 8396b999a2 KEYCLOAK-1241 Can't build release with Java 8
- Speed up build by only building REST API doc during -Pjboss-release
2015-09-16 11:53:53 +02:00
Marko Strukelj 3bbe82057c KEYCLOAK-1241 Can't build release with Java 8
- Improve javadoc comments for new REST API documentation generation
2015-09-15 21:22:43 +02:00
Marko Strukelj 0c49fce78f KEYCLOAK-1241 Can't build release with Java 8 2015-09-15 21:22:43 +02:00
Stian Thorgersen f9af8ba1a0 Merge pull request #1614 from stianst/master
Fixes
2015-09-15 13:40:04 +02:00
Dane Barentine 80f91b5fa5 KEYCLOAK-1848 Fix consuming of metadata when EntityDescriptor includes multiple Descriptors 2015-09-14 15:04:54 -07:00
Dane Barentine 6478e8f5c7 KEYCLOAK-1847 Per SAML Spec 3.4.4.1 SigAlg in redirect binding should be URI not Java signature algorithm 2015-09-14 15:02:27 -07:00
Dane Barentine 55dc42e147 KEYCLOAK-1491 AttributeStatement must contain one or more attribute or encryptedattribute statements 2015-09-14 15:00:41 -07:00
Dane Barentine f55ab0d689 KEYCLOAK-1846 Per SAML spec 6.2 Encrypting assertions must happen after the assertions are signed 2015-09-14 15:00:41 -07:00
Dane Barentine fe79c9b01e KEYCLOAK-1845 Fixed relative path error which was omitting the themes on the EAP overlay 2015-09-14 14:58:56 -07:00
Dane Barentine 6291e90f9c KEYCLOAK-1844 Login endpoint needs to handle POST as well for SAML clients using HTTP-POST binding 2015-09-14 14:57:38 -07:00
Stan Silvert a32fefb597 Fix breadcrumbs. 2015-09-14 14:28:32 -04:00
Cory Snyder 3e04d045ee KEYCLOAK-1807 Fix bug with commas in regex password policies by using alternate way to declare multiple regex patterns 2015-09-11 11:00:31 -04:00
Stian Thorgersen fb4645a3dc KEYCLOAK-1833 Fix error messages for identity brokering 2015-09-10 21:15:55 +02:00
Thomas Raehalme e0eac89e5a Added check for null authentication on the logout method. 2015-09-10 12:30:07 +03:00
Thomas Raehalme 90d34bfd06 unsuccessfulAuthentication now returns HTTP response status 401 instead of 403. 2015-09-09 18:31:25 +03:00
Thomas Raehalme e58b5762f3 attemptAuthentication now throws KeycloakAuthenticationException if authentication fails.
Also authenticationFailureHandler is by default set to SimpleUrlAuthenticationFailureHandler
with default login url set to /sso/login.
2015-09-09 15:45:13 +03:00
Stian Thorgersen 3fd4d23bed Version bump 2015-09-09 11:27:21 +02:00
Stan Silvert 75bd8d4627 Load admin messages through Themes. 2015-09-08 15:22:50 -04:00
Stan Silvert e455cbf319 Add new getMessages() method to Theme interface. 2015-09-08 13:28:17 -04:00
Stan Silvert cee2d69718 Update for use with Angualr 1.4 anti-watch feature. Also, limit sanitize
to params.  This avoids issue with Unicode.
2015-09-08 12:57:22 -04:00
Stan Silvert ff17123123 i18n for onoffswitch 2015-09-08 12:57:21 -04:00
Stan Silvert e118a06a09 Bundles now read from base theme instead of from classpath. Bundle names
no longer hard-coded.
2015-09-08 12:57:20 -04:00
Stan Silvert 4898d74c6d KEYCLOAK-1152 Initial commit for i18n support 2015-09-08 12:57:19 -04:00
Bill Burke be0c359160 adapter refactor 2015-09-07 10:27:57 -04:00
Bill Burke 3f792030d3 adapter refactor 2015-09-07 10:26:25 -04:00
Bill Burke 333ad0efac refactor adapters 2015-09-04 15:56:28 -04:00
6841 changed files with 336314 additions and 225469 deletions

No files matched your search

+9 -8
View File
@@ -1,19 +1,20 @@
language: java
env:
global:
- MAVEN_SKIP_RC=true
- MAVEN_OPTS="-Xms512m -Xmx2048m"
jdk:
- oraclejdk8
cache:
directories:
- $HOME/.m2
before_script:
- export MAVEN_SKIP_RC=true
before_cache:
- rm -rf $HOME/.m2/repository/org/keycloak
install: mvn install -Pdistribution -DskipTests=true -B -V
install:
- mvn install -Pdistribution -DskipTests=true -B -V -q
script:
- mvn test -B
- mvn -file testsuite/integration-arquillian test -B
sudo: false
+16 -14
View File
@@ -1,13 +1,15 @@
Keycloak
========
Keycloak is an SSO Service for web apps and REST services. For more information visit [http://keycloak.org](http://keycloak.org).
Open Source Identity and Access Management for modern Applications and Services.
For more information about Keycloak visit [Keycloak homepage](http://keycloak.org) and [Keycloak blog](http://blog.keycloak.org).
Building
--------
Ensure you have JDK 7 (or newer), Maven 3.2.1 (or newer) and Git installed
Ensure you have JDK 8 (or newer), Maven 3.2.1 (or newer) and Git installed
java -version
mvn -version
@@ -48,22 +50,22 @@ To start Keycloak from the appliance distribution first build the distribution i
To stop the server press `Ctrl + C`.
Help and Documentation
----------------------
* [Documentation](http://keycloak.jboss.org/docs) - User Guide, Admin REST API and Javadocs
* [User Mailing List](https://lists.jboss.org/mailman/listinfo/keycloak-user) - Mailing list to ask for help and general questions about Keycloak
* [JIRA](https://issues.jboss.org/projects/KEYCLOAK) - Issue tracker for bugs and feature requests
Contributing
------------
* See [Hacking on Keycloak](misc/HackingOnKeycloak.md)
Documentation
-------------
* [User Guide, Admin REST API and Javadocs](http://keycloak.jboss.org/docs)
* Developer documentation
* [Hacking on Keycloak](misc/HackingOnKeycloak.md) - how to become a Keycloak contributor
* [Testsuite](misc/Testsuite.md) - details about testsuite, but also how to quickly run Keycloak during development and a few test tools (OTP generation, LDAP server, Mail server)
* [Database Testing](misc/DatabaseTesting.md) - how to do testing of Keycloak on different databases
* [Updating Database](misc/UpdatingDatabaseSchema.md) - how to change the Keycloak database
* [Release Process](misc/ReleaseProcess.md) - how to release Keycloak
* [Hacking on Keycloak](misc/HackingOnKeycloak.md) - How to become a Keycloak contributor
* [Testsuite](misc/Testsuite.md) - Details about testsuite, but also how to quickly run Keycloak during development and a few test tools (OTP generation, LDAP server, Mail server)
* [Database Testing](misc/DatabaseTesting.md) - How to do testing of Keycloak on different databases
* [Updating Database](misc/UpdatingDatabaseSchema.md) - How to change the Keycloak database
* [Developer Mailing List](https://lists.jboss.org/mailman/listinfo/keycloak-dev) - Mailing list to discuss development of Keycloak
License
+140
View File
@@ -0,0 +1,140 @@
<?xml version="1.0"?>
<!--
~ Copyright 2016 Red Hat, Inc. and/or its affiliates
~ and other contributors as indicated by the @author tags.
~
~ Licensed under the Apache License, Version 2.0 (the "License");
~ you may not use this file except in compliance with the License.
~ You may obtain a copy of the License at
~
~ http://www.apache.org/licenses/LICENSE-2.0
~
~ Unless required by applicable law or agreed to in writing, software
~ distributed under the License is distributed on an "AS IS" BASIS,
~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
~ See the License for the specific language governing permissions and
~ limitations under the License.
-->
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<parent>
<artifactId>keycloak-parent</artifactId>
<groupId>org.keycloak</groupId>
<version>1.9.5.Final</version>
<relativePath>../../../pom.xml</relativePath>
</parent>
<modelVersion>4.0.0</modelVersion>
<artifactId>keycloak-adapter-core</artifactId>
<name>Keycloak Adapter Core</name>
<description/>
<properties>
<keycloak.osgi.export>
org.keycloak.adapters.*
</keycloak.osgi.export>
<keycloak.osgi.import>
org.keycloak.*;version="${project.version}",
org.apache.http.*;version=${apache.httpcomponents.version},
org.apache.karaf.jaas.boot.principal;resolution:=optional,
org.apache.karaf.jaas.modules;resolution:=optional,
*;resolution:=optional
</keycloak.osgi.import>
</properties>
<dependencies>
<dependency>
<groupId>org.bouncycastle</groupId>
<artifactId>bcprov-jdk15on</artifactId>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.jboss.logging</groupId>
<artifactId>jboss-logging</artifactId>
<version>${jboss.logging.version}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.keycloak</groupId>
<artifactId>keycloak-adapter-spi</artifactId>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.keycloak</groupId>
<artifactId>keycloak-core</artifactId>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-core</artifactId>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-databind</artifactId>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-annotations</artifactId>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.apache.httpcomponents</groupId>
<artifactId>httpclient</artifactId>
<scope>provided</scope>
</dependency>
</dependencies>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<source>${maven.compiler.source}</source>
<target>${maven.compiler.target}</target>
</configuration>
</plugin>
<!-- Adding OSGI metadata to the JAR without changing the packaging type. -->
<plugin>
<artifactId>maven-jar-plugin</artifactId>
<configuration>
<archive>
<manifestFile>${project.build.outputDirectory}/META-INF/MANIFEST.MF</manifestFile>
</archive>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.felix</groupId>
<artifactId>maven-bundle-plugin</artifactId>
<extensions>true</extensions>
<executions>
<execution>
<id>bundle-manifest</id>
<phase>process-classes</phase>
<goals>
<goal>manifest</goal>
</goals>
</execution>
</executions>
<configuration>
<instructions>
<Bundle-ClassPath>.</Bundle-ClassPath>
<Bundle-Name>${project.name}</Bundle-Name>
<Bundle-SymbolicName>${project.groupId}.${project.artifactId}</Bundle-SymbolicName>
<Import-Package>${keycloak.osgi.import}</Import-Package>
<Export-Package>${keycloak.osgi.export}</Export-Package>
</instructions>
</configuration>
</plugin>
</plugins>
</build>
</project>
@@ -1,3 +1,20 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.adapters;
import org.apache.http.HttpEntity;
@@ -6,13 +23,14 @@ import org.apache.http.client.HttpClient;
import org.apache.http.client.methods.HttpGet;
import org.jboss.logging.Logger;
import org.keycloak.adapters.authentication.ClientCredentialsProvider;
import org.keycloak.enums.RelativeUrlsUsed;
import org.keycloak.enums.SslRequired;
import org.keycloak.adapters.spi.HttpFacade;
import org.keycloak.common.enums.RelativeUrlsUsed;
import org.keycloak.common.enums.SslRequired;
import org.keycloak.enums.TokenStore;
import org.keycloak.representations.adapters.config.AdapterConfig;
import org.keycloak.representations.idm.PublishedRealmRepresentation;
import org.keycloak.util.JsonSerialization;
import org.keycloak.util.KeycloakUriBuilder;
import org.keycloak.common.util.KeycloakUriBuilder;
import java.io.ByteArrayOutputStream;
import java.io.IOException;
@@ -151,11 +169,7 @@ public class AdapterDeploymentContext {
public void setAuthServerBaseUrl(String authServerBaseUrl) {
this.authServerBaseUrl = authServerBaseUrl;
KeycloakUriBuilder serverBuilder = KeycloakUriBuilder.fromUri(authServerBaseUrl);
resolveBrowserUrls(serverBuilder);
if (delegate.getRelativeUrls() == RelativeUrlsUsed.ALL_REQUESTS) {
resolveNonBrowserUrls(serverBuilder);
}
resolveUrls(serverBuilder);
}
@Override
@@ -432,6 +446,16 @@ public class AdapterDeploymentContext {
public void setPrincipalAttribute(String principalAttribute) {
delegate.setPrincipalAttribute(principalAttribute);
}
@Override
public boolean isTurnOffChangeSessionIdOnLogin() {
return delegate.isTurnOffChangeSessionIdOnLogin();
}
@Override
public void setTurnOffChangeSessionIdOnLogin(boolean turnOffChangeSessionIdOnLogin) {
delegate.setTurnOffChangeSessionIdOnLogin(turnOffChangeSessionIdOnLogin);
}
}
protected KeycloakUriBuilder getBaseBuilder(HttpFacade facade, String base) {
@@ -0,0 +1,61 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.adapters;
import org.keycloak.adapters.spi.AdapterSessionStore;
/**
* Abstraction for storing token info on adapter side. Intended to be per-request object
*
* @author <a href="mailto:mposolda@redhat.com">Marek Posolda</a>
*/
public interface AdapterTokenStore extends AdapterSessionStore {
/**
* Impl can validate if current token exists and perform refreshing if it exists and is expired
*/
void checkCurrentToken();
/**
* Check if we are logged already (we have already valid and successfully refreshed accessToken). Establish security context if yes
*
* @param authenticator used for actual request authentication
* @return true if we are logged-in already
*/
boolean isCached(RequestAuthenticator authenticator);
/**
* Finish successful OAuth2 login and store validated account
*
* @param account
*/
void saveAccountInfo(OidcKeycloakAccount account);
/**
* Handle logout on store side and possibly propagate logout call to Keycloak
*/
void logout();
/**
* Callback invoked after successful token refresh
*
* @param securityContext context where refresh was performed
*/
void refreshCallback(RefreshableKeycloakSecurityContext securityContext);
}
@@ -0,0 +1,94 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.adapters;
import org.jboss.logging.Logger;
import org.keycloak.KeycloakPrincipal;
import org.keycloak.KeycloakSecurityContext;
import org.keycloak.representations.AccessToken;
import org.keycloak.common.util.UriUtils;
import java.util.Collections;
import java.util.Set;
import java.util.UUID;
/**
* @author <a href="mailto:mposolda@redhat.com">Marek Posolda</a>
*/
public class AdapterUtils {
private static Logger log = Logger.getLogger(AdapterUtils.class);
public static String generateId() {
return UUID.randomUUID().toString();
}
public static Set<String> getRolesFromSecurityContext(RefreshableKeycloakSecurityContext session) {
Set<String> roles = null;
AccessToken accessToken = session.getToken();
if (session.getDeployment().isUseResourceRoleMappings()) {
if (log.isTraceEnabled()) {
log.trace("useResourceRoleMappings");
}
AccessToken.Access access = accessToken.getResourceAccess(session.getDeployment().getResourceName());
if (access != null) roles = access.getRoles();
} else {
if (log.isTraceEnabled()) {
log.trace("use realm role mappings");
}
AccessToken.Access access = accessToken.getRealmAccess();
if (access != null) roles = access.getRoles();
}
if (roles == null) roles = Collections.emptySet();
if (log.isTraceEnabled()) {
log.trace("Setting roles: ");
for (String role : roles) {
log.trace(" role: " + role);
}
}
return roles;
}
public static String getPrincipalName(KeycloakDeployment deployment, AccessToken token) {
String attr = "sub";
if (deployment.getPrincipalAttribute() != null) attr = deployment.getPrincipalAttribute();
String name = null;
if ("sub".equals(attr)) {
name = token.getSubject();
} else if ("email".equals(attr)) {
name = token.getEmail();
} else if ("preferred_username".equals(attr)) {
name = token.getPreferredUsername();
} else if ("name".equals(attr)) {
name = token.getName();
} else if ("given_name".equals(attr)) {
name = token.getGivenName();
} else if ("family_name".equals(attr)) {
name = token.getFamilyName();
} else if ("nickname".equals(attr)) {
name = token.getNickName();
}
if (name == null) name = token.getSubject();
return name;
}
public static KeycloakPrincipal<RefreshableKeycloakSecurityContext> createPrincipal(KeycloakDeployment deployment, RefreshableKeycloakSecurityContext securityContext) {
return new KeycloakPrincipal<RefreshableKeycloakSecurityContext>(getPrincipalName(deployment, securityContext.getToken()), securityContext);
}
}
@@ -1,10 +1,27 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.adapters;
import org.jboss.logging.Logger;
import org.keycloak.KeycloakSecurityContext;
import org.keycloak.constants.AdapterConstants;
import org.keycloak.representations.AccessToken;
import org.keycloak.util.UriUtils;
import org.keycloak.common.util.UriUtils;
import java.io.IOException;
import java.util.Set;
@@ -23,9 +40,9 @@ import java.util.Set;
public class AuthenticatedActionsHandler {
private static final Logger log = Logger.getLogger(AuthenticatedActionsHandler.class);
protected KeycloakDeployment deployment;
protected HttpFacade facade;
protected OIDCHttpFacade facade;
public AuthenticatedActionsHandler(KeycloakDeployment deployment, HttpFacade facade) {
public AuthenticatedActionsHandler(KeycloakDeployment deployment, OIDCHttpFacade facade) {
this.deployment = deployment;
this.facade = facade;
}
@@ -57,7 +74,7 @@ public class AuthenticatedActionsHandler {
protected boolean abortTokenResponse() {
if (facade.getSecurityContext() == null) {
log.debugv("Not logged in, sending back 401: {0}",facade.getRequest().getURI());
facade.getResponse().setStatus(401);
facade.getResponse().sendError(401);
facade.getResponse().end();
return true;
}
@@ -94,7 +111,7 @@ public class AuthenticatedActionsHandler {
log.debugv("allowedOrigins did not contain origin");
}
facade.getResponse().setStatus(403);
facade.getResponse().sendError(403);
facade.getResponse().end();
return true;
}
@@ -0,0 +1,126 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.adapters;
import org.apache.http.HttpEntity;
import org.apache.http.HttpResponse;
import org.apache.http.NameValuePair;
import org.apache.http.client.HttpClient;
import org.apache.http.client.entity.UrlEncodedFormEntity;
import org.apache.http.client.methods.HttpPost;
import org.apache.http.message.BasicNameValuePair;
import org.apache.http.util.EntityUtils;
import org.jboss.logging.Logger;
import org.keycloak.OAuth2Constants;
import org.keycloak.adapters.authentication.ClientCredentialsProviderUtils;
import org.keycloak.adapters.spi.AuthOutcome;
import org.keycloak.adapters.spi.HttpFacade;
import org.keycloak.common.util.Base64;
import org.keycloak.constants.ServiceUrlConstants;
import org.keycloak.representations.AccessTokenResponse;
import org.keycloak.util.JsonSerialization;
import org.keycloak.common.util.KeycloakUriBuilder;
import java.util.List;
/**
* Basic auth request authenticator.
*/
public class BasicAuthRequestAuthenticator extends BearerTokenRequestAuthenticator {
protected Logger log = Logger.getLogger(BasicAuthRequestAuthenticator.class);
public BasicAuthRequestAuthenticator(KeycloakDeployment deployment) {
super(deployment);
}
public AuthOutcome authenticate(HttpFacade exchange) {
List<String> authHeaders = exchange.getRequest().getHeaders("Authorization");
if (authHeaders == null || authHeaders.size() == 0) {
challenge = challengeResponse(exchange, OIDCAuthenticationError.Reason.NO_AUTHORIZATION_HEADER, null, null);
return AuthOutcome.NOT_ATTEMPTED;
}
tokenString = null;
for (String authHeader : authHeaders) {
String[] split = authHeader.trim().split("\\s+");
if (split == null || split.length != 2) continue;
if (!split[0].equalsIgnoreCase("Basic")) continue;
tokenString = split[1];
}
if (tokenString == null) {
challenge = challengeResponse(exchange, OIDCAuthenticationError.Reason.INVALID_TOKEN, null, null);
return AuthOutcome.NOT_ATTEMPTED;
}
AccessTokenResponse atr=null;
try {
String userpw=new String(Base64.decode(tokenString));
String[] parts=userpw.split(":");
atr = getToken(parts[0], parts[1]);
tokenString = atr.getToken();
} catch (Exception e) {
log.debug("Failed to obtain token", e);
challenge = challengeResponse(exchange, OIDCAuthenticationError.Reason.INVALID_TOKEN, "no_token", e.getMessage());
return AuthOutcome.FAILED;
}
return authenticateToken(exchange, atr.getToken());
}
private AccessTokenResponse getToken(String username, String password) throws Exception {
AccessTokenResponse tokenResponse=null;
HttpClient client = deployment.getClient();
HttpPost post = new HttpPost(
KeycloakUriBuilder.fromUri(deployment.getAuthServerBaseUrl())
.path(ServiceUrlConstants.TOKEN_PATH).build(deployment.getRealm()));
java.util.List <NameValuePair> formparams = new java.util.ArrayList <NameValuePair>();
formparams.add(new BasicNameValuePair(OAuth2Constants.GRANT_TYPE, OAuth2Constants.PASSWORD));
formparams.add(new BasicNameValuePair("username", username));
formparams.add(new BasicNameValuePair("password", password));
ClientCredentialsProviderUtils.setClientCredentials(deployment, post, formparams);
UrlEncodedFormEntity form = new UrlEncodedFormEntity(formparams, "UTF-8");
post.setEntity(form);
HttpResponse response = client.execute(post);
int status = response.getStatusLine().getStatusCode();
HttpEntity entity = response.getEntity();
if (status != 200) {
EntityUtils.consumeQuietly(entity);
throw new java.io.IOException("Bad status: " + status);
}
if (entity == null) {
throw new java.io.IOException("No Entity");
}
java.io.InputStream is = entity.getContent();
try {
tokenResponse = JsonSerialization.readValue(is, AccessTokenResponse.class);
} finally {
try {
is.close();
} catch (java.io.IOException ignored) { }
}
return (tokenResponse);
}
}
@@ -0,0 +1,172 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.adapters;
import org.jboss.logging.Logger;
import org.keycloak.RSATokenVerifier;
import org.keycloak.adapters.spi.AuthChallenge;
import org.keycloak.adapters.spi.AuthOutcome;
import org.keycloak.adapters.spi.HttpFacade;
import org.keycloak.common.VerificationException;
import org.keycloak.representations.AccessToken;
import javax.security.cert.X509Certificate;
import java.util.List;
/**
* @author <a href="mailto:bill@burkecentral.com">Bill Burke</a>
* @version $Revision: 1 $
*/
public class BearerTokenRequestAuthenticator {
protected Logger log = Logger.getLogger(BearerTokenRequestAuthenticator.class);
protected String tokenString;
protected AccessToken token;
protected String surrogate;
protected AuthChallenge challenge;
protected KeycloakDeployment deployment;
public BearerTokenRequestAuthenticator(KeycloakDeployment deployment) {
this.deployment = deployment;
}
public AuthChallenge getChallenge() {
return challenge;
}
public String getTokenString() {
return tokenString;
}
public AccessToken getToken() {
return token;
}
public String getSurrogate() {
return surrogate;
}
public AuthOutcome authenticate(HttpFacade exchange) {
List<String> authHeaders = exchange.getRequest().getHeaders("Authorization");
if (authHeaders == null || authHeaders.size() == 0) {
challenge = challengeResponse(exchange, OIDCAuthenticationError.Reason.NO_BEARER_TOKEN, null, null);
return AuthOutcome.NOT_ATTEMPTED;
}
tokenString = null;
for (String authHeader : authHeaders) {
String[] split = authHeader.trim().split("\\s+");
if (split == null || split.length != 2) continue;
if (!split[0].equalsIgnoreCase("Bearer")) continue;
tokenString = split[1];
}
if (tokenString == null) {
challenge = challengeResponse(exchange, OIDCAuthenticationError.Reason.NO_BEARER_TOKEN, null, null);
return AuthOutcome.NOT_ATTEMPTED;
}
return (authenticateToken(exchange, tokenString));
}
protected AuthOutcome authenticateToken(HttpFacade exchange, String tokenString) {
try {
token = RSATokenVerifier.verifyToken(tokenString, deployment.getRealmKey(), deployment.getRealmInfoUrl());
} catch (VerificationException e) {
log.error("Failed to verify token", e);
challenge = challengeResponse(exchange, OIDCAuthenticationError.Reason.INVALID_TOKEN, "invalid_token", e.getMessage());
return AuthOutcome.FAILED;
}
if (token.getIssuedAt() < deployment.getNotBefore()) {
log.error("Stale token");
challenge = challengeResponse(exchange, OIDCAuthenticationError.Reason.STALE_TOKEN, "invalid_token", "Stale token");
return AuthOutcome.FAILED;
}
boolean verifyCaller = false;
if (deployment.isUseResourceRoleMappings()) {
verifyCaller = token.isVerifyCaller(deployment.getResourceName());
} else {
verifyCaller = token.isVerifyCaller();
}
surrogate = null;
if (verifyCaller) {
if (token.getTrustedCertificates() == null || token.getTrustedCertificates().size() == 0) {
log.warn("No trusted certificates in token");
challenge = clientCertChallenge();
return AuthOutcome.FAILED;
}
// for now, we just make sure Undertow did two-way SSL
// assume JBoss Web verifies the client cert
X509Certificate[] chain = new X509Certificate[0];
try {
chain = exchange.getCertificateChain();
} catch (Exception ignore) {
}
if (chain == null || chain.length == 0) {
log.warn("No certificates provided by undertow to verify the caller");
challenge = clientCertChallenge();
return AuthOutcome.FAILED;
}
surrogate = chain[0].getSubjectDN().getName();
}
return AuthOutcome.AUTHENTICATED;
}
protected AuthChallenge clientCertChallenge() {
return new AuthChallenge() {
@Override
public int getResponseCode() {
return 0;
}
@Override
public boolean challenge(HttpFacade exchange) {
// do the same thing as client cert auth
return false;
}
};
}
protected AuthChallenge challengeResponse(HttpFacade facade, final OIDCAuthenticationError.Reason reason, final String error, final String description) {
StringBuilder header = new StringBuilder("Bearer realm=\"");
header.append(deployment.getRealm()).append("\"");
if (error != null) {
header.append(", error=\"").append(error).append("\"");
}
if (description != null) {
header.append(", error_description=\"").append(description).append("\"");
}
final String challenge = header.toString();
return new AuthChallenge() {
@Override
public int getResponseCode() {
return 401;
}
@Override
public boolean challenge(HttpFacade facade) {
OIDCAuthenticationError error = new OIDCAuthenticationError(reason, description);
facade.getRequest().setError(error);
facade.getResponse().addHeader("WWW-Authenticate", challenge);
facade.getResponse().sendError(401);
return true;
}
};
}
}
@@ -1,3 +1,20 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.adapters;
import java.io.IOException;
@@ -5,12 +22,14 @@ import java.io.IOException;
import org.jboss.logging.Logger;
import org.keycloak.KeycloakPrincipal;
import org.keycloak.RSATokenVerifier;
import org.keycloak.VerificationException;
import org.keycloak.adapters.spi.HttpFacade;
import org.keycloak.common.VerificationException;
import org.keycloak.constants.AdapterConstants;
import org.keycloak.jose.jws.JWSInput;
import org.keycloak.jose.jws.JWSInputException;
import org.keycloak.representations.AccessToken;
import org.keycloak.representations.IDToken;
import org.keycloak.util.KeycloakUriBuilder;
import org.keycloak.common.util.KeycloakUriBuilder;
/**
* @author <a href="mailto:mposolda@redhat.com">Marek Posolda</a>
@@ -34,7 +53,7 @@ public class CookieTokenStore {
}
public static KeycloakPrincipal<RefreshableKeycloakSecurityContext> getPrincipalFromCookie(KeycloakDeployment deployment, HttpFacade facade, AdapterTokenStore tokenStore) {
HttpFacade.Cookie cookie = facade.getRequest().getCookie(AdapterConstants.KEYCLOAK_ADAPTER_STATE_COOKIE);
OIDCHttpFacade.Cookie cookie = facade.getRequest().getCookie(AdapterConstants.KEYCLOAK_ADAPTER_STATE_COOKIE);
if (cookie == null) {
log.debug("Not found adapter state cookie in current request");
return null;
@@ -54,13 +73,13 @@ public class CookieTokenStore {
try {
// Skip check if token is active now. It's supposed to be done later by the caller
AccessToken accessToken = RSATokenVerifier.verifyToken(accessTokenString, deployment.getRealmKey(), deployment.getRealmInfoUrl(), false);
AccessToken accessToken = RSATokenVerifier.verifyToken(accessTokenString, deployment.getRealmKey(), deployment.getRealmInfoUrl(), false, true);
IDToken idToken;
if (idTokenString != null && idTokenString.length() > 0) {
JWSInput input = new JWSInput(idTokenString);
try {
JWSInput input = new JWSInput(idTokenString);
idToken = input.readJsonContent(IDToken.class);
} catch (IOException e) {
} catch (JWSInputException e) {
throw new VerificationException(e);
}
} else {
@@ -0,0 +1,33 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.adapters;
/**
* @author <a href="mailto:bill@burkecentral.com">Bill Burke</a>
* @version $Revision: 1 $
*/
public interface CorsHeaders {
String ACCESS_CONTROL_ALLOW_ORIGIN = "Access-Control-Allow-Origin";
String ACCESS_CONTROL_ALLOW_CREDENTIALS = "Access-Control-Allow-Credentials";
String ACCESS_CONTROL_ALLOW_METHODS = "Access-Control-Allow-Methods";
String ACCESS_CONTROL_ALLOW_HEADERS = "Access-Control-Allow-Headers";
String ACCESS_CONTROL_MAX_AGE = "Access-Control-Max-Age";
String ORIGIN = "Origin";
String ACCESS_CONTROL_REQUEST_METHOD = "Access-Control-Request-Method";
String ACCESS_CONTROL_REQUEST_HEADERS = "Access-Control-Request-Headers";
}
@@ -0,0 +1,369 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.adapters;
import org.apache.http.client.CookieStore;
import org.apache.http.client.HttpClient;
import org.apache.http.conn.ClientConnectionManager;
import org.apache.http.conn.scheme.PlainSocketFactory;
import org.apache.http.conn.scheme.Scheme;
import org.apache.http.conn.scheme.SchemeRegistry;
import org.apache.http.conn.ssl.AllowAllHostnameVerifier;
import org.apache.http.conn.ssl.BrowserCompatHostnameVerifier;
import org.apache.http.conn.ssl.SSLSocketFactory;
import org.apache.http.conn.ssl.StrictHostnameVerifier;
import org.apache.http.conn.ssl.X509HostnameVerifier;
import org.apache.http.cookie.Cookie;
import org.apache.http.impl.client.DefaultHttpClient;
import org.apache.http.impl.conn.SingleClientConnManager;
import org.apache.http.impl.conn.tsccm.ThreadSafeClientConnManager;
import org.apache.http.params.BasicHttpParams;
import org.apache.http.params.HttpConnectionParams;
import org.keycloak.representations.adapters.config.AdapterConfig;
import org.keycloak.common.util.EnvUtil;
import org.keycloak.common.util.KeystoreUtil;
import javax.net.ssl.HostnameVerifier;
import javax.net.ssl.SSLContext;
import javax.net.ssl.SSLException;
import javax.net.ssl.SSLSession;
import javax.net.ssl.SSLSocket;
import javax.net.ssl.TrustManager;
import javax.net.ssl.X509TrustManager;
import java.io.IOException;
import java.security.KeyStore;
import java.security.SecureRandom;
import java.security.cert.CertificateException;
import java.security.cert.X509Certificate;
import java.util.Collections;
import java.util.Date;
import java.util.List;
import java.util.concurrent.TimeUnit;
/**
* Abstraction for creating HttpClients. Allows SSL configuration.
*
* @author <a href="mailto:bill@burkecentral.com">Bill Burke</a>
* @version $Revision: 1 $
*/
public class HttpClientBuilder {
public static enum HostnameVerificationPolicy {
/**
* Hostname verification is not done on the server's certificate
*/
ANY,
/**
* Allows wildcards in subdomain names i.e. *.foo.com
*/
WILDCARD,
/**
* CN must match hostname connecting to
*/
STRICT
}
/**
* @author <a href="mailto:bill@burkecentral.com">Bill Burke</a>
* @version $Revision: 1 $
*/
private static class PassthroughTrustManager implements X509TrustManager {
public void checkClientTrusted(X509Certificate[] chain,
String authType) throws CertificateException {
}
public void checkServerTrusted(X509Certificate[] chain,
String authType) throws CertificateException {
}
public X509Certificate[] getAcceptedIssuers() {
return null;
}
}
protected KeyStore truststore;
protected KeyStore clientKeyStore;
protected String clientPrivateKeyPassword;
protected boolean disableTrustManager;
protected boolean disableCookieCache = true;
protected HostnameVerificationPolicy policy = HostnameVerificationPolicy.WILDCARD;
protected SSLContext sslContext;
protected int connectionPoolSize = 100;
protected int maxPooledPerRoute = 0;
protected long connectionTTL = -1;
protected TimeUnit connectionTTLUnit = TimeUnit.MILLISECONDS;
protected HostnameVerifier verifier = null;
protected long socketTimeout = -1;
protected TimeUnit socketTimeoutUnits = TimeUnit.MILLISECONDS;
protected long establishConnectionTimeout = -1;
protected TimeUnit establishConnectionTimeoutUnits = TimeUnit.MILLISECONDS;
/**
* Socket inactivity timeout
*
* @param timeout
* @param unit
* @return
*/
public HttpClientBuilder socketTimeout(long timeout, TimeUnit unit)
{
this.socketTimeout = timeout;
this.socketTimeoutUnits = unit;
return this;
}
/**
* When trying to make an initial socket connection, what is the timeout?
*
* @param timeout
* @param unit
* @return
*/
public HttpClientBuilder establishConnectionTimeout(long timeout, TimeUnit unit)
{
this.establishConnectionTimeout = timeout;
this.establishConnectionTimeoutUnits = unit;
return this;
}
public HttpClientBuilder connectionTTL(long ttl, TimeUnit unit) {
this.connectionTTL = ttl;
this.connectionTTLUnit = unit;
return this;
}
public HttpClientBuilder maxPooledPerRoute(int maxPooledPerRoute) {
this.maxPooledPerRoute = maxPooledPerRoute;
return this;
}
public HttpClientBuilder connectionPoolSize(int connectionPoolSize) {
this.connectionPoolSize = connectionPoolSize;
return this;
}
/**
* Disable trust management and hostname verification. <i>NOTE</i> this is a security
* hole, so only set this option if you cannot or do not want to verify the identity of the
* host you are communicating with.
*/
public HttpClientBuilder disableTrustManager() {
this.disableTrustManager = true;
return this;
}
public HttpClientBuilder disableCookieCache() {
this.disableCookieCache = true;
return this;
}
/**
* SSL policy used to verify hostnames
*
* @param policy
* @return
*/
public HttpClientBuilder hostnameVerification(HostnameVerificationPolicy policy) {
this.policy = policy;
return this;
}
public HttpClientBuilder sslContext(SSLContext sslContext) {
this.sslContext = sslContext;
return this;
}
public HttpClientBuilder trustStore(KeyStore truststore) {
this.truststore = truststore;
return this;
}
public HttpClientBuilder keyStore(KeyStore keyStore, String password) {
this.clientKeyStore = keyStore;
this.clientPrivateKeyPassword = password;
return this;
}
public HttpClientBuilder keyStore(KeyStore keyStore, char[] password) {
this.clientKeyStore = keyStore;
this.clientPrivateKeyPassword = new String(password);
return this;
}
static class VerifierWrapper implements X509HostnameVerifier {
protected HostnameVerifier verifier;
VerifierWrapper(HostnameVerifier verifier) {
this.verifier = verifier;
}
@Override
public void verify(String host, SSLSocket ssl) throws IOException {
if (!verifier.verify(host, ssl.getSession())) throw new SSLException("Hostname verification failure");
}
@Override
public void verify(String host, X509Certificate cert) throws SSLException {
throw new SSLException("This verification path not implemented");
}
@Override
public void verify(String host, String[] cns, String[] subjectAlts) throws SSLException {
throw new SSLException("This verification path not implemented");
}
@Override
public boolean verify(String s, SSLSession sslSession) {
return verifier.verify(s, sslSession);
}
}
public HttpClient build() {
X509HostnameVerifier verifier = null;
if (this.verifier != null) verifier = new VerifierWrapper(this.verifier);
else {
switch (policy) {
case ANY:
verifier = new AllowAllHostnameVerifier();
break;
case WILDCARD:
verifier = new BrowserCompatHostnameVerifier();
break;
case STRICT:
verifier = new StrictHostnameVerifier();
break;
}
}
try {
SSLSocketFactory sslsf = null;
SSLContext theContext = sslContext;
if (disableTrustManager) {
theContext = SSLContext.getInstance("SSL");
theContext.init(null, new TrustManager[]{new PassthroughTrustManager()},
new SecureRandom());
verifier = new AllowAllHostnameVerifier();
sslsf = new SniSSLSocketFactory(theContext, verifier);
} else if (theContext != null) {
sslsf = new SniSSLSocketFactory(theContext, verifier);
} else if (clientKeyStore != null || truststore != null) {
sslsf = new SniSSLSocketFactory(SSLSocketFactory.TLS, clientKeyStore, clientPrivateKeyPassword, truststore, null, verifier);
} else {
final SSLContext tlsContext = SSLContext.getInstance(SSLSocketFactory.TLS);
tlsContext.init(null, null, null);
sslsf = new SniSSLSocketFactory(tlsContext, verifier);
}
SchemeRegistry registry = new SchemeRegistry();
registry.register(
new Scheme("http", 80, PlainSocketFactory.getSocketFactory()));
Scheme httpsScheme = new Scheme("https", 443, sslsf);
registry.register(httpsScheme);
ClientConnectionManager cm = null;
if (connectionPoolSize > 0) {
ThreadSafeClientConnManager tcm = new ThreadSafeClientConnManager(registry, connectionTTL, connectionTTLUnit);
tcm.setMaxTotal(connectionPoolSize);
if (maxPooledPerRoute == 0) maxPooledPerRoute = connectionPoolSize;
tcm.setDefaultMaxPerRoute(maxPooledPerRoute);
cm = tcm;
} else {
cm = new SingleClientConnManager(registry);
}
BasicHttpParams params = new BasicHttpParams();
if (socketTimeout > -1)
{
HttpConnectionParams.setSoTimeout(params, (int) socketTimeoutUnits.toMillis(socketTimeout));
}
if (establishConnectionTimeout > -1)
{
HttpConnectionParams.setConnectionTimeout(params, (int)establishConnectionTimeoutUnits.toMillis(establishConnectionTimeout));
}
DefaultHttpClient client = new DefaultHttpClient(cm, params);
if (disableCookieCache) {
client.setCookieStore(new CookieStore() {
@Override
public void addCookie(Cookie cookie) {
//To change body of implemented methods use File | Settings | File Templates.
}
@Override
public List<Cookie> getCookies() {
return Collections.emptyList();
}
@Override
public boolean clearExpired(Date date) {
return false; //To change body of implemented methods use File | Settings | File Templates.
}
@Override
public void clear() {
//To change body of implemented methods use File | Settings | File Templates.
}
});
}
return client;
} catch (Exception e) {
throw new RuntimeException(e);
}
}
public HttpClient build(AdapterConfig adapterConfig) {
disableCookieCache(); // disable cookie cache as we don't want sticky sessions for load balancing
String truststorePath = adapterConfig.getTruststore();
if (truststorePath != null) {
truststorePath = EnvUtil.replace(truststorePath);
String truststorePassword = adapterConfig.getTruststorePassword();
try {
this.truststore = KeystoreUtil.loadKeyStore(truststorePath, truststorePassword);
} catch (Exception e) {
throw new RuntimeException("Failed to load truststore", e);
}
}
String clientKeystore = adapterConfig.getClientKeystore();
if (clientKeystore != null) {
clientKeystore = EnvUtil.replace(clientKeystore);
String clientKeystorePassword = adapterConfig.getClientKeystorePassword();
try {
KeyStore clientCertKeystore = KeystoreUtil.loadKeyStore(clientKeystore, clientKeystorePassword);
keyStore(clientCertKeystore, clientKeystorePassword);
} catch (Exception e) {
throw new RuntimeException("Failed to load keystore", e);
}
}
int size = 10;
if (adapterConfig.getConnectionPoolSize() > 0)
size = adapterConfig.getConnectionPoolSize();
HttpClientBuilder.HostnameVerificationPolicy policy = HttpClientBuilder.HostnameVerificationPolicy.WILDCARD;
if (adapterConfig.isAllowAnyHostname())
policy = HttpClientBuilder.HostnameVerificationPolicy.ANY;
connectionPoolSize(size);
hostnameVerification(policy);
if (adapterConfig.isDisableTrustManager()) {
disableTrustManager();
} else {
trustStore(truststore);
}
return build();
}
}
@@ -1,12 +1,12 @@
/*
* Copyright 2014 Red Hat Inc. and/or its affiliates and other contributors
* as indicated by the @author tags. All rights reserved.
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
@@ -16,7 +16,7 @@
*/
package org.keycloak.adapters;
import org.keycloak.adapters.HttpFacade.Request;
import org.keycloak.adapters.spi.HttpFacade.Request;
/**
* On multi-tenant scenarios, Keycloak will defer the resolution of a
@@ -1,14 +1,31 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.adapters;
import org.apache.http.client.HttpClient;
import org.jboss.logging.Logger;
import org.keycloak.adapters.authentication.ClientCredentialsProvider;
import org.keycloak.constants.ServiceUrlConstants;
import org.keycloak.enums.RelativeUrlsUsed;
import org.keycloak.enums.SslRequired;
import org.keycloak.common.enums.RelativeUrlsUsed;
import org.keycloak.common.enums.SslRequired;
import org.keycloak.enums.TokenStore;
import org.keycloak.representations.adapters.config.AdapterConfig;
import org.keycloak.util.KeycloakUriBuilder;
import org.keycloak.common.util.KeycloakUriBuilder;
import java.net.URI;
import java.security.PublicKey;
@@ -57,6 +74,8 @@ public class KeycloakDeployment {
protected boolean alwaysRefreshToken;
protected boolean registerNodeAtStartup;
protected int registerNodePeriod;
protected boolean turnOffChangeSessionIdOnLogin;
protected volatile int notBefore;
public KeycloakDeployment() {
@@ -92,39 +111,17 @@ public class KeycloakDeployment {
public void setAuthServerBaseUrl(AdapterConfig config) {
this.authServerBaseUrl = config.getAuthServerUrl();
String authServerURLForBackendReqs = config.getAuthServerUrlForBackendRequests();
if (authServerBaseUrl == null && authServerURLForBackendReqs == null) return;
if (authServerBaseUrl == null) return;
URI authServerUri = null;
if (authServerBaseUrl != null) {
authServerUri = URI.create(authServerBaseUrl);
}
URI authServerUri = URI.create(authServerBaseUrl);
if (authServerUri == null || authServerUri.getHost() == null) {
if (authServerURLForBackendReqs != null) {
relativeUrls = RelativeUrlsUsed.BROWSER_ONLY;
KeycloakUriBuilder serverBuilder = KeycloakUriBuilder.fromUri(authServerURLForBackendReqs);
if (serverBuilder.getHost() == null || serverBuilder.getScheme() == null) {
throw new IllegalStateException("Relative URL not supported for auth-server-url-for-backend-requests option. URL used: "
+ authServerURLForBackendReqs + ", Client: " + config.getResource());
}
resolveNonBrowserUrls(serverBuilder);
} else {
relativeUrls = RelativeUrlsUsed.ALL_REQUESTS;
}
if (authServerUri.getHost() == null) {
relativeUrls = RelativeUrlsUsed.ALWAYS;
} else {
// We have absolute URI in config
relativeUrls = RelativeUrlsUsed.NEVER;
KeycloakUriBuilder serverBuilder = KeycloakUriBuilder.fromUri(authServerBaseUrl);
resolveBrowserUrls(serverBuilder);
if (authServerURLForBackendReqs == null) {
resolveNonBrowserUrls(serverBuilder);
} else {
serverBuilder = KeycloakUriBuilder.fromUri(authServerURLForBackendReqs);
resolveNonBrowserUrls(serverBuilder);
}
resolveUrls(serverBuilder);
}
}
@@ -133,23 +130,14 @@ public class KeycloakDeployment {
/**
* @param authUrlBuilder absolute URI
*/
protected void resolveBrowserUrls(KeycloakUriBuilder authUrlBuilder) {
protected void resolveUrls(KeycloakUriBuilder authUrlBuilder) {
if (log.isDebugEnabled()) {
log.debug("resolveBrowserUrls");
log.debug("resolveUrls");
}
String login = authUrlBuilder.clone().path(ServiceUrlConstants.AUTH_PATH).build(getRealm()).toString();
authUrl = KeycloakUriBuilder.fromUri(login);
realmInfoUrl = authUrlBuilder.clone().path(ServiceUrlConstants.REALM_INFO_PATH).build(getRealm()).toString();
}
/**
* @param authUrlBuilder absolute URI
*/
protected void resolveNonBrowserUrls(KeycloakUriBuilder authUrlBuilder) {
if (log.isDebugEnabled()) {
log.debug("resolveNonBrowserUrls");
}
tokenUrl = authUrlBuilder.clone().path(ServiceUrlConstants.TOKEN_PATH).build(getRealm()).toString();
logoutUrl = KeycloakUriBuilder.fromUri(authUrlBuilder.clone().path(ServiceUrlConstants.TOKEN_SERVICE_LOGOUT_PATH).build(getRealm()).toString());
@@ -361,4 +349,12 @@ public class KeycloakDeployment {
public void setPrincipalAttribute(String principalAttribute) {
this.principalAttribute = principalAttribute;
}
public boolean isTurnOffChangeSessionIdOnLogin() {
return turnOffChangeSessionIdOnLogin;
}
public void setTurnOffChangeSessionIdOnLogin(boolean turnOffChangeSessionIdOnLogin) {
this.turnOffChangeSessionIdOnLogin = turnOffChangeSessionIdOnLogin;
}
}
@@ -1,13 +1,30 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.adapters;
import org.codehaus.jackson.map.ObjectMapper;
import org.codehaus.jackson.map.annotate.JsonSerialize;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.databind.ObjectMapper;
import org.jboss.logging.Logger;
import org.keycloak.adapters.authentication.ClientCredentialsProviderUtils;
import org.keycloak.enums.SslRequired;
import org.keycloak.common.enums.SslRequired;
import org.keycloak.enums.TokenStore;
import org.keycloak.representations.adapters.config.AdapterConfig;
import org.keycloak.util.PemUtils;
import org.keycloak.common.util.PemUtils;
import org.keycloak.util.SystemPropertiesJsonParserFactory;
import java.io.IOException;
@@ -81,13 +98,16 @@ public class KeycloakDeploymentBuilder {
if (realmKeyPem == null && adapterConfig.isBearerOnly() && adapterConfig.getAuthServerUrl() == null) {
throw new IllegalArgumentException("For bearer auth, you must set the realm-public-key or auth-server-url");
}
if (realmKeyPem == null || !deployment.isBearerOnly() || deployment.isRegisterNodeAtStartup() || deployment.getRegisterNodePeriod() != -1) {
if (realmKeyPem == null || !deployment.isBearerOnly() || deployment.isEnableBasicAuth() || deployment.isRegisterNodeAtStartup() || deployment.getRegisterNodePeriod() != -1) {
deployment.setClient(new HttpClientBuilder().build(adapterConfig));
}
if (adapterConfig.getAuthServerUrl() == null && (!deployment.isBearerOnly() || realmKeyPem == null)) {
throw new RuntimeException("You must specify auth-url");
}
deployment.setAuthServerBaseUrl(adapterConfig);
if (adapterConfig.getTurnOffChangeSessionIdOnLogin() != null) {
deployment.setTurnOffChangeSessionIdOnLogin(adapterConfig.getTurnOffChangeSessionIdOnLogin());
}
log.debug("Use authServerUrl: " + deployment.getAuthServerBaseUrl() + ", tokenUrl: " + deployment.getTokenUrl() + ", relativeUrls: " + deployment.getRelativeUrls());
return deployment;
@@ -100,7 +120,7 @@ public class KeycloakDeploymentBuilder {
public static AdapterConfig loadAdapterConfig(InputStream is) {
ObjectMapper mapper = new ObjectMapper(new SystemPropertiesJsonParserFactory());
mapper.setSerializationInclusion(JsonSerialize.Inclusion.NON_DEFAULT);
mapper.setSerializationInclusion(JsonInclude.Include.NON_DEFAULT);
AdapterConfig adapterConfig;
try {
adapterConfig = mapper.readValue(is, AdapterConfig.class);
@@ -1,3 +1,20 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.adapters;
import java.io.IOException;
@@ -8,8 +25,8 @@ import java.util.concurrent.Executor;
import java.util.concurrent.Executors;
import org.jboss.logging.Logger;
import org.keycloak.util.HostUtils;
import org.keycloak.util.Time;
import org.keycloak.common.util.HostUtils;
import org.keycloak.common.util.Time;
/**
* @author <a href="mailto:mposolda@redhat.com">Marek Posolda</a>
@@ -1,20 +1,41 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.adapters;
import org.jboss.logging.Logger;
import org.keycloak.OAuth2Constants;
import org.keycloak.RSATokenVerifier;
import org.keycloak.VerificationException;
import org.keycloak.adapters.spi.AdapterSessionStore;
import org.keycloak.adapters.spi.AuthChallenge;
import org.keycloak.adapters.spi.AuthOutcome;
import org.keycloak.adapters.spi.HttpFacade;
import org.keycloak.common.VerificationException;
import org.keycloak.constants.AdapterConstants;
import org.keycloak.enums.TokenStore;
import org.keycloak.jose.jws.JWSInput;
import org.keycloak.jose.jws.JWSInputException;
import org.keycloak.representations.AccessToken;
import org.keycloak.representations.AccessTokenResponse;
import org.keycloak.representations.IDToken;
import org.keycloak.util.KeycloakUriBuilder;
import org.keycloak.util.UriUtils;
import org.keycloak.common.util.KeycloakUriBuilder;
import org.keycloak.common.util.UriUtils;
import java.io.IOException;
import java.util.UUID;
import java.util.concurrent.atomic.AtomicLong;
@@ -27,7 +48,7 @@ public class OAuthRequestAuthenticator {
protected KeycloakDeployment deployment;
protected RequestAuthenticator reqAuthenticator;
protected int sslRedirectPort;
protected AdapterTokenStore tokenStore;
protected AdapterSessionStore tokenStore;
protected String tokenString;
protected String idTokenString;
protected IDToken idToken;
@@ -37,7 +58,7 @@ public class OAuthRequestAuthenticator {
protected String refreshToken;
protected String strippedOauthParametersRequestUri;
public OAuthRequestAuthenticator(RequestAuthenticator requestAuthenticator, HttpFacade facade, KeycloakDeployment deployment, int sslRedirectPort, AdapterTokenStore tokenStore) {
public OAuthRequestAuthenticator(RequestAuthenticator requestAuthenticator, HttpFacade facade, KeycloakDeployment deployment, int sslRedirectPort, AdapterSessionStore tokenStore) {
this.reqAuthenticator = requestAuthenticator;
this.facade = facade;
this.deployment = deployment;
@@ -93,12 +114,12 @@ public class OAuthRequestAuthenticator {
return facade.getRequest().isSecure();
}
protected HttpFacade.Cookie getCookie(String cookieName) {
protected OIDCHttpFacade.Cookie getCookie(String cookieName) {
return facade.getRequest().getCookie(cookieName);
}
protected String getCookieValue(String cookieName) {
HttpFacade.Cookie cookie = getCookie(cookieName);
OIDCHttpFacade.Cookie cookie = getCookie(cookieName);
if (cookie == null) return null;
return cookie.getValue();
}
@@ -135,6 +156,9 @@ public class OAuthRequestAuthenticator {
String idpHint = getQueryParamValue(AdapterConstants.KC_IDP_HINT);
url = UriUtils.stripQueryParam(url, AdapterConstants.KC_IDP_HINT);
String scope = getQueryParamValue(OAuth2Constants.SCOPE);
url = UriUtils.stripQueryParam(url, OAuth2Constants.SCOPE);
KeycloakUriBuilder redirectUriBuilder = deployment.getAuthUrl().clone()
.queryParam(OAuth2Constants.RESPONSE_TYPE, OAuth2Constants.CODE)
.queryParam(OAuth2Constants.CLIENT_ID, deployment.getResourceName())
@@ -147,6 +171,9 @@ public class OAuthRequestAuthenticator {
if (idpHint != null && idpHint.length() > 0) {
redirectUriBuilder.queryParam(AdapterConstants.KC_IDP_HINT,idpHint);
}
if (scope != null && scope.length() > 0) {
redirectUriBuilder.queryParam(OAuth2Constants.SCOPE, scope);
}
return redirectUriBuilder.build().toString();
}
@@ -165,24 +192,13 @@ public class OAuthRequestAuthenticator {
final String state = getStateCode();
final String redirect = getRedirectUri(state);
if (redirect == null) {
return new AuthChallenge() {
@Override
public boolean challenge(HttpFacade exchange) {
exchange.getResponse().setStatus(403);
return true;
}
@Override
public boolean errorPage() {
return true;
}
};
return challenge(403, OIDCAuthenticationError.Reason.NO_REDIRECT_URI, null);
}
return new AuthChallenge() {
@Override
public boolean errorPage() {
return false;
public int getResponseCode() {
return 0;
}
@Override
@@ -190,7 +206,7 @@ public class OAuthRequestAuthenticator {
tokenStore.saveRequest();
log.debug("Sending redirect to login page: " + redirect);
exchange.getResponse().setStatus(302);
exchange.getResponse().setCookie(deployment.getStateCookieName(), state, /* need to set path? */ null, null, -1, deployment.getSslRequired().isRequired(facade.getRequest().getRemoteAddr()), false);
exchange.getResponse().setCookie(deployment.getStateCookieName(), state, /* need to set path? */ null, null, -1, deployment.getSslRequired().isRequired(facade.getRequest().getRemoteAddr()), true);
exchange.getResponse().setHeader("Location", redirect);
return true;
}
@@ -198,11 +214,11 @@ public class OAuthRequestAuthenticator {
}
protected AuthChallenge checkStateCookie() {
HttpFacade.Cookie stateCookie = getCookie(deployment.getStateCookieName());
OIDCHttpFacade.Cookie stateCookie = getCookie(deployment.getStateCookieName());
if (stateCookie == null) {
log.warn("No state cookie");
return challenge(400);
return challenge(400, OIDCAuthenticationError.Reason.INVALID_STATE_COOKIE, null);
}
// reset the cookie
log.debug("** reseting application state cookie");
@@ -212,13 +228,13 @@ public class OAuthRequestAuthenticator {
String state = getQueryParamValue(OAuth2Constants.STATE);
if (state == null) {
log.warn("state parameter was null");
return challenge(400);
return challenge(400, OIDCAuthenticationError.Reason.INVALID_STATE_COOKIE, null);
}
if (!state.equals(stateCookieValue)) {
log.warn("state parameter invalid");
log.warn("cookie: " + stateCookieValue);
log.warn("queryParam: " + state);
return challenge(400);
return challenge(400, OIDCAuthenticationError.Reason.INVALID_STATE_COOKIE, null);
}
return null;
@@ -232,7 +248,7 @@ public class OAuthRequestAuthenticator {
if (error != null) {
// todo how do we send a response?
log.warn("There was an error: " + error);
challenge = challenge(400);
challenge = challenge(400, OIDCAuthenticationError.Reason.OAUTH_ERROR, error);
return AuthOutcome.FAILED;
} else {
log.debug("redirecting to auth server");
@@ -250,16 +266,18 @@ public class OAuthRequestAuthenticator {
}
protected AuthChallenge challenge(final int code) {
protected AuthChallenge challenge(final int code, final OIDCAuthenticationError.Reason reason, final String description) {
return new AuthChallenge() {
@Override
public boolean errorPage() {
return true;
public int getResponseCode() {
return code;
}
@Override
public boolean challenge(HttpFacade exchange) {
exchange.getResponse().setStatus(code);
OIDCAuthenticationError error = new OIDCAuthenticationError(reason, description);
exchange.getRequest().setError(error);
exchange.getResponse().sendError(code);
return true;
}
};
@@ -281,7 +299,7 @@ public class OAuthRequestAuthenticator {
// abort if not HTTPS
if (!isRequestSecure() && deployment.getSslRequired().isRequired(facade.getRequest().getRemoteAddr())) {
log.error("Adapter requires SSL. Request: " + facade.getRequest().getURI());
return challenge(403);
return challenge(403, OIDCAuthenticationError.Reason.SSL_REQUIRED, null);
}
log.debug("checking state cookie for after code");
@@ -292,7 +310,7 @@ public class OAuthRequestAuthenticator {
strippedOauthParametersRequestUri = stripOauthParametersFromRedirect();
try {
// For COOKIE store we don't have httpSessionId and single sign-out won't be available
String httpSessionId = deployment.getTokenStore() == TokenStore.SESSION ? reqAuthenticator.getHttpSessionId(true) : null;
String httpSessionId = deployment.getTokenStore() == TokenStore.SESSION ? reqAuthenticator.changeHttpSessionId(true) : null;
tokenResponse = ServerRequest.invokeAccessCodeToToken(deployment, code, strippedOauthParametersRequestUri, httpSessionId);
} catch (ServerRequest.HttpFailure failure) {
log.error("failed to turn code into token");
@@ -300,11 +318,11 @@ public class OAuthRequestAuthenticator {
if (failure.getStatus() == 400 && failure.getError() != null) {
log.error(" " + failure.getError());
}
return challenge(403);
return challenge(403, OIDCAuthenticationError.Reason.CODE_TO_TOKEN_FAILURE, null);
} catch (IOException e) {
log.error("failed to turn code into token", e);
return challenge(403);
return challenge(403, OIDCAuthenticationError.Reason.CODE_TO_TOKEN_FAILURE, null);
}
tokenString = tokenResponse.getToken();
@@ -313,24 +331,24 @@ public class OAuthRequestAuthenticator {
try {
token = RSATokenVerifier.verifyToken(tokenString, deployment.getRealmKey(), deployment.getRealmInfoUrl());
if (idTokenString != null) {
JWSInput input = new JWSInput(idTokenString);
try {
JWSInput input = new JWSInput(idTokenString);
idToken = input.readJsonContent(IDToken.class);
} catch (IOException e) {
} catch (JWSInputException e) {
throw new VerificationException();
}
}
log.debug("Token Verification succeeded!");
} catch (VerificationException e) {
log.error("failed verification of token: " + e.getMessage());
return challenge(403);
return challenge(403, OIDCAuthenticationError.Reason.INVALID_TOKEN, null);
}
if (tokenResponse.getNotBeforePolicy() > deployment.getNotBefore()) {
deployment.setNotBefore(tokenResponse.getNotBeforePolicy());
}
if (token.getIssuedAt() < deployment.getNotBefore()) {
log.error("Stale token");
return challenge(403);
return challenge(403, OIDCAuthenticationError.Reason.STALE_TOKEN, null);
}
log.debug("successful authenticated");
return null;
@@ -0,0 +1,63 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.adapters;
import org.keycloak.adapters.spi.AuthenticationError;
/**
* Object that describes the OIDC error that happened.
*
* @author <a href="mailto:bill@burkecentral.com">Bill Burke</a>
* @version $Revision: 1 $
*/
public class OIDCAuthenticationError implements AuthenticationError {
public static enum Reason {
NO_BEARER_TOKEN,
NO_REDIRECT_URI,
INVALID_STATE_COOKIE,
OAUTH_ERROR,
SSL_REQUIRED,
CODE_TO_TOKEN_FAILURE,
INVALID_TOKEN,
STALE_TOKEN,
NO_AUTHORIZATION_HEADER
}
private Reason reason;
private String description;
public OIDCAuthenticationError(Reason reason, String description) {
this.reason = reason;
this.description = description;
}
public Reason getReason() {
return reason;
}
public String getDescription() {
return description;
}
@Override
public String toString() {
return "OIDCAuthenticationError [reason=" + reason + ", description=" + description + "]";
}
}
@@ -0,0 +1,32 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.adapters;
import org.keycloak.KeycloakSecurityContext;
import org.keycloak.adapters.spi.HttpFacade;
/**
* Bridge between core adapter and HTTP Engine
*
* @author <a href="mailto:bill@burkecentral.com">Bill Burke</a>
* @version $Revision: 1 $
*/
public interface OIDCHttpFacade extends HttpFacade {
KeycloakSecurityContext getSecurityContext();
}
@@ -0,0 +1,29 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.adapters;
import org.keycloak.KeycloakSecurityContext;
import org.keycloak.adapters.spi.KeycloakAccount;
/**
* @author <a href="mailto:bill@burkecentral.com">Bill Burke</a>
* @version $Revision: 1 $
*/
public interface OidcKeycloakAccount extends KeycloakAccount {
KeycloakSecurityContext getKeycloakSecurityContext();
}
@@ -1,7 +1,27 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.adapters;
import org.jboss.logging.Logger;
import org.keycloak.Version;
import org.keycloak.adapters.spi.HttpFacade;
import org.keycloak.adapters.spi.UserSessionManagement;
import org.keycloak.jose.jws.JWSInputException;
import org.keycloak.representations.VersionRepresentation;
import org.keycloak.constants.AdapterConstants;
import org.keycloak.jose.jws.JWSInput;
import org.keycloak.jose.jws.crypto.RSAProvider;
@@ -10,7 +30,7 @@ import org.keycloak.representations.adapters.action.LogoutAction;
import org.keycloak.representations.adapters.action.PushNotBeforeAction;
import org.keycloak.representations.adapters.action.TestAvailabilityAction;
import org.keycloak.util.JsonSerialization;
import org.keycloak.util.StreamUtil;
import org.keycloak.common.util.StreamUtil;
/**
* @author <a href="mailto:bill@burkecentral.com">Bill Burke</a>
@@ -176,18 +196,17 @@ public class PreAuthActionsHandler {
return null;
}
JWSInput input = new JWSInput(token);
boolean verified = false;
try {
verified = RSAProvider.verify(input, deployment.getRealmKey());
} catch (Exception ignore) {
JWSInput input = new JWSInput(token);
if (RSAProvider.verify(input, deployment.getRealmKey())) {
return input;
}
} catch (JWSInputException ignore) {
}
if (!verified) {
log.warn("admin request failed, unable to verify token");
facade.getResponse().sendError(403, "no token");
return null;
}
return input;
log.warn("admin request failed, unable to verify token");
facade.getResponse().sendError(403, "no token");
return null;
}
@@ -215,7 +234,7 @@ public class PreAuthActionsHandler {
try {
facade.getResponse().setStatus(200);
facade.getResponse().setHeader("Content-Type", "application/json");
JsonSerialization.writeValueToStream(facade.getResponse().getOutputStream(), Version.SINGLETON);
JsonSerialization.writeValueToStream(facade.getResponse().getOutputStream(), VersionRepresentation.SINGLETON);
} catch (Exception e) {
throw new RuntimeException(e);
}
@@ -1,9 +1,26 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.adapters;
import org.jboss.logging.Logger;
import org.keycloak.KeycloakSecurityContext;
import org.keycloak.RSATokenVerifier;
import org.keycloak.VerificationException;
import org.keycloak.common.VerificationException;
import org.keycloak.representations.AccessToken;
import org.keycloak.representations.AccessTokenResponse;
import org.keycloak.representations.IDToken;
@@ -57,7 +74,7 @@ public class RefreshableKeycloakSecurityContext extends KeycloakSecurityContext
}
public boolean isActive() {
return this.token.isActive() && this.token.getIssuedAt() > deployment.getNotBefore();
return token != null && this.token.isActive() && this.token.getIssuedAt() > deployment.getNotBefore();
}
public KeycloakDeployment getDeployment() {
@@ -111,13 +128,19 @@ public class RefreshableKeycloakSecurityContext extends KeycloakSecurityContext
log.debug("Token Verification succeeded!");
} catch (VerificationException e) {
log.error("failed verification of token");
return false;
}
if (response.getNotBeforePolicy() > deployment.getNotBefore()) {
deployment.setNotBefore(response.getNotBeforePolicy());
}
this.token = token;
this.refreshToken = response.getRefreshToken();
if (response.getRefreshToken() != null) {
if (log.isTraceEnabled()) {
log.trace("Setup new refresh token to the security context");
}
this.refreshToken = response.getRefreshToken();
}
this.tokenString = tokenString;
tokenStore.refreshCallback(this);
return true;
@@ -1,7 +1,27 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.adapters;
import org.jboss.logging.Logger;
import org.keycloak.KeycloakPrincipal;
import org.keycloak.adapters.spi.AuthChallenge;
import org.keycloak.adapters.spi.AuthOutcome;
import org.keycloak.adapters.spi.HttpFacade;
/**
* @author <a href="mailto:bill@burkecentral.com">Bill Burke</a>
@@ -9,11 +29,11 @@ import org.keycloak.KeycloakPrincipal;
*/
public abstract class RequestAuthenticator {
protected static Logger log = Logger.getLogger(RequestAuthenticator.class);
protected HttpFacade facade;
protected AuthChallenge challenge;
protected KeycloakDeployment deployment;
protected AdapterTokenStore tokenStore;
protected AuthChallenge challenge;
protected int sslRedirectPort;
public RequestAuthenticator(HttpFacade facade, KeycloakDeployment deployment, AdapterTokenStore tokenStore, int sslRedirectPort) {
@@ -134,16 +154,24 @@ public abstract class RequestAuthenticator {
RefreshableKeycloakSecurityContext session = new RefreshableKeycloakSecurityContext(deployment, tokenStore, oauth.getTokenString(), oauth.getToken(), oauth.getIdTokenString(), oauth.getIdToken(), oauth.getRefreshToken());
final KeycloakPrincipal<RefreshableKeycloakSecurityContext> principal = new KeycloakPrincipal<RefreshableKeycloakSecurityContext>(AdapterUtils.getPrincipalName(deployment, oauth.getToken()), session);
completeOAuthAuthentication(principal);
log.debugv("User ''{0}'' invoking ''{1}'' on client ''{2}''", principal.getName(), facade.getRequest().getURI(), deployment.getResourceName());
}
protected abstract void completeOAuthAuthentication(KeycloakPrincipal<RefreshableKeycloakSecurityContext> principal);
protected abstract void completeBearerAuthentication(KeycloakPrincipal<RefreshableKeycloakSecurityContext> principal, String method);
protected abstract String getHttpSessionId(boolean create);
/**
* After code is received, we change the session id if possible to guard against https://www.owasp.org/index.php/Session_Fixation
* @param create
* @return
*/
protected abstract String changeHttpSessionId(boolean create);
protected void completeAuthentication(BearerTokenRequestAuthenticator bearer, String method) {
RefreshableKeycloakSecurityContext session = new RefreshableKeycloakSecurityContext(deployment, null, bearer.getTokenString(), bearer.getToken(), null, null, null);
final KeycloakPrincipal<RefreshableKeycloakSecurityContext> principal = new KeycloakPrincipal<RefreshableKeycloakSecurityContext>(AdapterUtils.getPrincipalName(deployment, bearer.getToken()), session);
completeBearerAuthentication(principal, method);
log.debugv("User ''{0}'' invoking ''{1}'' on client ''{2}''", principal.getName(), facade.getRequest().getURI(), deployment.getResourceName());
}
}
@@ -1,3 +1,20 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.adapters;
import org.apache.http.HttpEntity;
@@ -11,10 +28,10 @@ import org.keycloak.OAuth2Constants;
import org.keycloak.adapters.authentication.ClientCredentialsProviderUtils;
import org.keycloak.constants.AdapterConstants;
import org.keycloak.representations.AccessTokenResponse;
import org.keycloak.util.HostUtils;
import org.keycloak.common.util.HostUtils;
import org.keycloak.util.JsonSerialization;
import org.keycloak.util.KeycloakUriBuilder;
import org.keycloak.util.StreamUtil;
import org.keycloak.common.util.KeycloakUriBuilder;
import org.keycloak.common.util.StreamUtil;
import java.io.ByteArrayOutputStream;
import java.io.IOException;
@@ -0,0 +1,134 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.adapters;
import org.apache.http.HttpHost;
import org.apache.http.conn.scheme.HostNameResolver;
import org.apache.http.conn.ssl.SSLSocketFactory;
import org.apache.http.conn.ssl.TrustStrategy;
import org.apache.http.conn.ssl.X509HostnameVerifier;
import org.apache.http.protocol.HttpContext;
import javax.net.ssl.SSLContext;
import javax.net.ssl.SSLSocket;
import java.io.IOException;
import java.lang.reflect.Method;
import java.net.InetSocketAddress;
import java.net.Socket;
import java.security.AccessController;
import java.security.KeyManagementException;
import java.security.KeyStore;
import java.security.KeyStoreException;
import java.security.NoSuchAlgorithmException;
import java.security.PrivilegedExceptionAction;
import java.security.SecureRandom;
import java.security.UnrecoverableKeyException;
import java.util.logging.Level;
import java.util.logging.Logger;
/**
* @author <a href="mailto:mstrukel@redhat.com">Marko Strukelj</a>
*/
public class SniSSLSocketFactory extends SSLSocketFactory {
private static Logger log = Logger.getLogger(SniSSLSocketFactory.class.getName());
public SniSSLSocketFactory(String algorithm, KeyStore keystore, String keyPassword, KeyStore truststore, SecureRandom random, HostNameResolver nameResolver) throws NoSuchAlgorithmException, KeyManagementException, KeyStoreException, UnrecoverableKeyException {
super(algorithm, keystore, keyPassword, truststore, random, nameResolver);
}
public SniSSLSocketFactory(String algorithm, KeyStore keystore, String keyPassword, KeyStore truststore, SecureRandom random, TrustStrategy trustStrategy, X509HostnameVerifier hostnameVerifier) throws NoSuchAlgorithmException, KeyManagementException, KeyStoreException, UnrecoverableKeyException {
super(algorithm, keystore, keyPassword, truststore, random, trustStrategy, hostnameVerifier);
}
public SniSSLSocketFactory(String algorithm, KeyStore keystore, String keyPassword, KeyStore truststore, SecureRandom random, X509HostnameVerifier hostnameVerifier) throws NoSuchAlgorithmException, KeyManagementException, KeyStoreException, UnrecoverableKeyException {
super(algorithm, keystore, keyPassword, truststore, random, hostnameVerifier);
}
public SniSSLSocketFactory(KeyStore keystore, String keystorePassword, KeyStore truststore) throws NoSuchAlgorithmException, KeyManagementException, KeyStoreException, UnrecoverableKeyException {
super(keystore, keystorePassword, truststore);
}
public SniSSLSocketFactory(KeyStore keystore, String keystorePassword) throws NoSuchAlgorithmException, KeyManagementException, KeyStoreException, UnrecoverableKeyException {
super(keystore, keystorePassword);
}
public SniSSLSocketFactory(KeyStore truststore) throws NoSuchAlgorithmException, KeyManagementException, KeyStoreException, UnrecoverableKeyException {
super(truststore);
}
public SniSSLSocketFactory(TrustStrategy trustStrategy, X509HostnameVerifier hostnameVerifier) throws NoSuchAlgorithmException, KeyManagementException, KeyStoreException, UnrecoverableKeyException {
super(trustStrategy, hostnameVerifier);
}
public SniSSLSocketFactory(TrustStrategy trustStrategy) throws NoSuchAlgorithmException, KeyManagementException, KeyStoreException, UnrecoverableKeyException {
super(trustStrategy);
}
public SniSSLSocketFactory(SSLContext sslContext) {
super(sslContext);
}
public SniSSLSocketFactory(SSLContext sslContext, HostNameResolver nameResolver) {
super(sslContext, nameResolver);
}
public SniSSLSocketFactory(SSLContext sslContext, X509HostnameVerifier hostnameVerifier) {
super(sslContext, hostnameVerifier);
}
public SniSSLSocketFactory(SSLContext sslContext, String[] supportedProtocols, String[] supportedCipherSuites, X509HostnameVerifier hostnameVerifier) {
super(sslContext, supportedProtocols, supportedCipherSuites, hostnameVerifier);
}
public SniSSLSocketFactory(javax.net.ssl.SSLSocketFactory socketfactory, X509HostnameVerifier hostnameVerifier) {
super(socketfactory, hostnameVerifier);
}
public SniSSLSocketFactory(javax.net.ssl.SSLSocketFactory socketfactory, String[] supportedProtocols, String[] supportedCipherSuites, X509HostnameVerifier hostnameVerifier) {
super(socketfactory, supportedProtocols, supportedCipherSuites, hostnameVerifier);
}
@Override
public Socket connectSocket(int connectTimeout, Socket socket, HttpHost host, InetSocketAddress remoteAddress, InetSocketAddress localAddress, HttpContext context) throws IOException {
return super.connectSocket(connectTimeout, applySNI(socket, host.getHostName()), host, remoteAddress, localAddress, context);
}
@Override
public Socket createLayeredSocket(Socket socket, String target, int port, HttpContext context) throws IOException {
return super.createLayeredSocket(applySNI(socket, target), target, port, context);
}
private Socket applySNI(final Socket socket, String hostname) {
if (socket instanceof SSLSocket) {
try {
Method setHostMethod = AccessController.doPrivileged(new PrivilegedExceptionAction<Method>() {
public Method run() throws NoSuchMethodException {
return socket.getClass().getMethod("setHost", String.class);
}
});
setHostMethod.invoke(socket, hostname);
log.finest("Applied SNI to socket for: " + hostname);
} catch (Exception e) {
log.log(Level.WARNING, "Failed to apply SNI to SSLSocket", e);
}
}
return socket;
}
}
@@ -1,3 +1,20 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.adapters.authentication;
import java.util.Map;
@@ -14,7 +31,7 @@ import org.keycloak.adapters.KeycloakDeployment;
*
* You must specify a file
* META-INF/services/org.keycloak.adapters.authentication.ClientCredentialsProvider in the WAR that this class is contained in (or in the JAR that is attached to the WEB-INF/lib or as jboss module
* if you want to share the implementation among more WARs). This file must have the fully qualified class name of all your ClientAuthenticatorFactory classes
* if you want to share the implementation among more WARs).
*
* NOTE: The SPI is not finished and method signatures are still subject to change in future versions (for example to support
* authentication with client certificate)
@@ -1,3 +1,20 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.adapters.authentication;
import java.util.HashMap;
@@ -0,0 +1,66 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.adapters.authentication;
import java.util.Map;
import org.jboss.logging.Logger;
import org.keycloak.OAuth2Constants;
import org.keycloak.adapters.KeycloakDeployment;
import org.keycloak.representations.idm.CredentialRepresentation;
import org.keycloak.util.BasicAuthHelper;
/**
* Traditional OAuth2 authentication of clients based on client_id and client_secret
*
* @author <a href="mailto:mposolda@redhat.com">Marek Posolda</a>
*/
public class ClientIdAndSecretCredentialsProvider implements ClientCredentialsProvider {
private static Logger logger = Logger.getLogger(ClientCredentialsProviderUtils.class);
public static final String PROVIDER_ID = CredentialRepresentation.SECRET;
private String clientSecret;
@Override
public String getId() {
return PROVIDER_ID;
}
@Override
public void init(KeycloakDeployment deployment, Object config) {
clientSecret = (String) config;
}
@Override
public void setClientCredentials(KeycloakDeployment deployment, Map<String, String> requestHeaders, Map<String, String> formParams) {
String clientId = deployment.getResourceName();
if (!deployment.isPublicClient()) {
if (clientSecret != null) {
String authorization = BasicAuthHelper.createHeader(clientId, clientSecret);
requestHeaders.put("Authorization", authorization);
} else {
logger.warnf("Client '%s' doesn't have secret available", clientId);
}
} else {
formParams.put(OAuth2Constants.CLIENT_ID, clientId);
}
}
}
@@ -1,3 +1,20 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.adapters.authentication;
import java.security.PrivateKey;
@@ -8,12 +25,12 @@ import org.keycloak.adapters.AdapterUtils;
import org.keycloak.adapters.KeycloakDeployment;
import org.keycloak.jose.jws.JWSBuilder;
import org.keycloak.representations.JsonWebToken;
import org.keycloak.util.KeystoreUtil;
import org.keycloak.util.Time;
import org.keycloak.common.util.KeystoreUtil;
import org.keycloak.common.util.Time;
/**
* Client authentication based on JWT signed by client private key .
* See <a href="https://tools.ietf.org/html/draft-jones-oauth-jwt-bearer-03">specs</a> for more details.
* See <a href="https://tools.ietf.org/html/rfc7519">specs</a> for more details.
*
* @author <a href="mailto:mposolda@redhat.com">Marek Posolda</a>
*/
@@ -107,6 +124,7 @@ public class JWTClientCredentialsProvider implements ClientCredentialsProvider {
JsonWebToken reqToken = new JsonWebToken();
reqToken.id(AdapterUtils.generateId());
reqToken.issuer(clientId);
reqToken.subject(clientId);
reqToken.audience(realmInfoUrl);
int now = Time.currentTime();
@@ -1,3 +1,20 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.adapters.jaas;
import java.io.InputStream;
@@ -21,15 +38,15 @@ import javax.security.auth.spi.LoginModule;
import org.jboss.logging.Logger;
import org.keycloak.KeycloakPrincipal;
import org.keycloak.RSATokenVerifier;
import org.keycloak.VerificationException;
import org.keycloak.common.VerificationException;
import org.keycloak.adapters.AdapterDeploymentContext;
import org.keycloak.adapters.AdapterUtils;
import org.keycloak.util.FindFile;
import org.keycloak.common.util.FindFile;
import org.keycloak.adapters.KeycloakDeployment;
import org.keycloak.adapters.KeycloakDeploymentBuilder;
import org.keycloak.adapters.RefreshableKeycloakSecurityContext;
import org.keycloak.representations.AccessToken;
import org.keycloak.util.reflections.Reflections;
import org.keycloak.common.util.reflections.Reflections;
/**
* @author <a href="mailto:mposolda@redhat.com">Marek Posolda</a>
@@ -0,0 +1,45 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.adapters.jaas;
import org.jboss.logging.Logger;
import org.keycloak.common.VerificationException;
/**
* Login module, which allows to authenticate Keycloak access token in environments, which rely on JAAS
* <p/>
* It expects login based on username and password where username doesn't matter and password is keycloak access token.
*
* @author <a href="mailto:mposolda@redhat.com">Marek Posolda</a>
*/
public class BearerTokenLoginModule extends AbstractKeycloakLoginModule {
private static final Logger log = Logger.getLogger(BearerTokenLoginModule.class);
@Override
protected Auth doAuth(String username, String password) throws VerificationException {
// Should do some checking of authenticated username if it's equivalent to passed value?
return bearerAuth(password);
}
@Override
protected Logger getLogger() {
return log;
}
}
@@ -1,3 +1,20 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.adapters.jaas;
import java.io.IOException;
@@ -22,13 +39,12 @@ import org.apache.http.client.methods.HttpPost;
import org.apache.http.message.BasicNameValuePair;
import org.jboss.logging.Logger;
import org.keycloak.OAuth2Constants;
import org.keycloak.VerificationException;
import org.keycloak.common.VerificationException;
import org.keycloak.adapters.authentication.ClientCredentialsProviderUtils;
import org.keycloak.constants.ServiceUrlConstants;
import org.keycloak.representations.AccessTokenResponse;
import org.keycloak.util.BasicAuthHelper;
import org.keycloak.util.JsonSerialization;
import org.keycloak.util.KeycloakUriBuilder;
import org.keycloak.common.util.KeycloakUriBuilder;
/**
* Login module based on Resource Owner password credentials grant from OAuth2 specs. It's supposed to be used in environments. which
@@ -0,0 +1,53 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.adapters.jaas;
import java.io.Serializable;
import java.security.Principal;
/**
* @author <a href="mailto:mposolda@redhat.com">Marek Posolda</a>
*/
public class RolePrincipal implements Principal, Serializable {
private String roleName = null;
public RolePrincipal(String roleName) {
this.roleName = roleName;
}
public boolean equals (Object p) {
if (! (p instanceof RolePrincipal))
return false;
return getName().equals(((RolePrincipal)p).getName());
}
public int hashCode () {
return getName().hashCode();
}
public String getName () {
return this.roleName;
}
public String toString ()
{
return getName();
}
}
@@ -0,0 +1,19 @@
#
# Copyright 2016 Red Hat, Inc. and/or its affiliates
# and other contributors as indicated by the @author tags.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
org.keycloak.adapters.authentication.ClientIdAndSecretCredentialsProvider
org.keycloak.adapters.authentication.JWTClientCredentialsProvider
@@ -1,13 +1,30 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.adapters;
import org.apache.http.impl.conn.tsccm.ThreadSafeClientConnManager;
import org.junit.Test;
import org.keycloak.adapters.authentication.ClientIdAndSecretCredentialsProvider;
import org.keycloak.adapters.authentication.JWTClientCredentialsProvider;
import org.keycloak.enums.RelativeUrlsUsed;
import org.keycloak.enums.SslRequired;
import org.keycloak.common.enums.RelativeUrlsUsed;
import org.keycloak.common.enums.SslRequired;
import org.keycloak.enums.TokenStore;
import org.keycloak.util.PemUtils;
import org.keycloak.common.util.PemUtils;
import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertTrue;
@@ -37,7 +54,7 @@ public class KeycloakDeploymentBuilderTest {
assertEquals("234234-234234-234234", deployment.getResourceCredentials().get("secret"));
assertEquals(ClientIdAndSecretCredentialsProvider.PROVIDER_ID, deployment.getClientAuthenticator().getId());
assertEquals(20, ((ThreadSafeClientConnManager) deployment.getClient().getConnectionManager()).getMaxTotal());
assertEquals("https://backend:8443/auth/realms/demo/protocol/openid-connect/token", deployment.getTokenUrl());
assertEquals("https://localhost:8443/auth/realms/demo/protocol/openid-connect/token", deployment.getTokenUrl());
assertEquals(RelativeUrlsUsed.NEVER, deployment.getRelativeUrls());
assertTrue(deployment.isAlwaysRefreshToken());
assertTrue(deployment.isRegisterNodeAtStartup());
@@ -0,0 +1,32 @@
{
"realm": "demo",
"resource": "customer-portal",
"realm-public-key": "MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQCrVrCuTtArbgaZzL1hvh0xtL5mc7o0NqPVnYXkLvgcwiC3BjLGw1tGEGoJaXDuSaRllobm53JBhjx33UNv+5z/UMG4kytBWxheNVKnL6GgqlNabMaFfPLPCF8kAgKnsi79NMo+n6KnSY8YeUmec/p2vjO2NjsSAVcWEQMVhJ31LwIDAQAB",
"auth-server-url": "https://localhost:8443/auth",
"ssl-required": "external",
"use-resource-role-mappings": true,
"enable-cors": true,
"cors-max-age": 1000,
"cors-allowed-methods": "POST, PUT, DELETE, GET",
"cors-allowed-headers": "X-Custom, X-Custom2",
"bearer-only": true,
"public-client": true,
"enable-basic-auth": true,
"expose-token": true,
"credentials": {
"secret": "234234-234234-234234"
},
"connection-pool-size": 20,
"disable-trust-manager": true,
"allow-any-hostname": true,
"truststore": "classpath:/cacerts.jks",
"truststore-password": "changeit",
"client-keystore": "classpath:/keystore.jks",
"client-keystore-password": "storepass",
"client-key-password": "keypass",
"always-refresh-token": true,
"register-node-at-startup": true,
"register-node-period": 1000,
"token-store": "cookie",
"principal-attribute": "email"
}
+102
View File
@@ -0,0 +1,102 @@
<?xml version="1.0"?>
<!--
~ Copyright 2016 Red Hat, Inc. and/or its affiliates
~ and other contributors as indicated by the @author tags.
~
~ Licensed under the Apache License, Version 2.0 (the "License");
~ you may not use this file except in compliance with the License.
~ You may obtain a copy of the License at
~
~ http://www.apache.org/licenses/LICENSE-2.0
~
~ Unless required by applicable law or agreed to in writing, software
~ distributed under the License is distributed on an "AS IS" BASIS,
~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
~ See the License for the specific language governing permissions and
~ limitations under the License.
-->
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<parent>
<artifactId>keycloak-as7-integration-pom</artifactId>
<groupId>org.keycloak</groupId>
<version>1.9.5.Final</version>
<relativePath>../pom.xml</relativePath>
</parent>
<modelVersion>4.0.0</modelVersion>
<artifactId>keycloak-as7-adapter-spi</artifactId>
<name>Keycloak AS7 SPI</name>
<description/>
<dependencies>
<dependency>
<groupId>org.keycloak</groupId>
<artifactId>keycloak-adapter-spi</artifactId>
</dependency>
<dependency>
<groupId>org.apache.httpcomponents</groupId>
<artifactId>httpclient</artifactId>
</dependency>
<dependency>
<groupId>org.jboss.spec.javax.servlet</groupId>
<artifactId>jboss-servlet-api_3.0_spec</artifactId>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.jboss.logging</groupId>
<artifactId>jboss-logging</artifactId>
<version>${jboss.logging.version}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.jboss.web</groupId>
<artifactId>jbossweb</artifactId>
<version>7.0.17.Final</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.jboss.as</groupId>
<artifactId>jboss-as-web</artifactId>
<version>7.1.2.Final</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.keycloak</groupId>
<artifactId>keycloak-tomcat-adapter-spi</artifactId>
<exclusions>
<exclusion>
<groupId>org.apache.tomcat</groupId>
<artifactId>tomcat-servlet-api</artifactId>
</exclusion>
<exclusion>
<groupId>org.apache.tomcat</groupId>
<artifactId>tomcat-catalina</artifactId>
</exclusion>
<exclusion>
<groupId>org.apache.tomcat</groupId>
<artifactId>catalina</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<scope>test</scope>
</dependency>
</dependencies>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<source>${maven.compiler.source}</source>
<target>${maven.compiler.target}</target>
</configuration>
</plugin>
</plugins>
</build>
</project>
@@ -1,3 +1,20 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.adapters.jbossweb;
import org.apache.catalina.Realm;
@@ -9,8 +26,7 @@ import org.jboss.security.SecurityContext;
import org.jboss.security.SecurityContextAssociation;
import org.jboss.security.SimpleGroup;
import org.jboss.security.SimplePrincipal;
import org.keycloak.KeycloakSecurityContext;
import org.keycloak.adapters.KeycloakAccount;
import org.keycloak.adapters.spi.KeycloakAccount;
import org.keycloak.adapters.tomcat.GenericPrincipalFactory;
import javax.security.auth.Subject;
@@ -38,7 +54,7 @@ public class JBossWebPrincipalFactory extends GenericPrincipalFactory {
}
@Override
public GenericPrincipal createPrincipal(Realm realm, final Principal identity, final Set<String> roleSet, final KeycloakSecurityContext securityContext) {
public GenericPrincipal createPrincipal(Realm realm, final Principal identity, final Set<String> roleSet) {
KeycloakAccount account = new KeycloakAccount() {
@Override
public Principal getPrincipal() {
@@ -49,11 +65,6 @@ public class JBossWebPrincipalFactory extends GenericPrincipalFactory {
public Set<String> getRoles() {
return roleSet;
}
@Override
public KeycloakSecurityContext getKeycloakSecurityContext() {
return securityContext;
}
};
Subject subject = new Subject();
Set<Principal> principals = subject.getPrincipals();
@@ -131,7 +142,7 @@ public class JBossWebPrincipalFactory extends GenericPrincipalFactory {
Iterator<Principal> iter = principals.iterator();
while (iter.hasNext()) {
Object next = iter.next();
if ((next instanceof Group) == false)
if (!(next instanceof Group))
continue;
Group grp = (Group) next;
if (grp.getName().equals(name)) {
@@ -0,0 +1,46 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.adapters.jbossweb;
import org.apache.catalina.Realm;
import org.junit.Assert;
import org.junit.Test;
import javax.security.auth.Subject;
import java.lang.reflect.Constructor;
import java.security.Principal;
import java.util.List;
/**
* @author <a href="mailto:sthorger@redhat.com">Stian Thorgersen</a>
*/
public class JBossWebPrincipalFactoryTest {
@Test
public void test() {
Constructor constructor = JBossWebPrincipalFactory.findJBossGenericPrincipalConstructor();
Assert.assertNotNull(constructor);
Assert.assertEquals(Realm.class, constructor.getParameterTypes()[0]);
Assert.assertEquals(String.class, constructor.getParameterTypes()[1]);
Assert.assertEquals(List.class, constructor.getParameterTypes()[3]);
Assert.assertEquals(Principal.class, constructor.getParameterTypes()[4]);
Assert.assertEquals(Object.class, constructor.getParameterTypes()[6]);
Assert.assertEquals(Subject.class, constructor.getParameterTypes()[8]);
}
}
+134
View File
@@ -0,0 +1,134 @@
<?xml version="1.0"?>
<!--
~ Copyright 2016 Red Hat, Inc. and/or its affiliates
~ and other contributors as indicated by the @author tags.
~
~ Licensed under the Apache License, Version 2.0 (the "License");
~ you may not use this file except in compliance with the License.
~ You may obtain a copy of the License at
~
~ http://www.apache.org/licenses/LICENSE-2.0
~
~ Unless required by applicable law or agreed to in writing, software
~ distributed under the License is distributed on an "AS IS" BASIS,
~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
~ See the License for the specific language governing permissions and
~ limitations under the License.
-->
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<parent>
<artifactId>keycloak-as7-integration-pom</artifactId>
<groupId>org.keycloak</groupId>
<version>1.9.5.Final</version>
<relativePath>../pom.xml</relativePath>
</parent>
<modelVersion>4.0.0</modelVersion>
<artifactId>keycloak-as7-adapter</artifactId>
<name>Keycloak AS7 Integration</name>
<description/>
<dependencies>
<dependency>
<groupId>org.keycloak</groupId>
<artifactId>keycloak-core</artifactId>
</dependency>
<dependency>
<groupId>org.keycloak</groupId>
<artifactId>keycloak-as7-adapter-spi</artifactId>
</dependency>
<dependency>
<groupId>org.keycloak</groupId>
<artifactId>keycloak-adapter-spi</artifactId>
</dependency>
<dependency>
<groupId>org.keycloak</groupId>
<artifactId>keycloak-adapter-core</artifactId>
</dependency>
<dependency>
<groupId>org.keycloak</groupId>
<artifactId>keycloak-jboss-adapter-core</artifactId>
</dependency>
<dependency>
<groupId>org.apache.httpcomponents</groupId>
<artifactId>httpclient</artifactId>
</dependency>
<dependency>
<groupId>org.bouncycastle</groupId>
<artifactId>bcprov-jdk15on</artifactId>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-core</artifactId>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-databind</artifactId>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-annotations</artifactId>
</dependency>
<dependency>
<groupId>org.jboss.spec.javax.servlet</groupId>
<artifactId>jboss-servlet-api_3.0_spec</artifactId>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.jboss.logging</groupId>
<artifactId>jboss-logging</artifactId>
<version>${jboss.logging.version}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.jboss.web</groupId>
<artifactId>jbossweb</artifactId>
<version>7.0.17.Final</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.jboss.as</groupId>
<artifactId>jboss-as-web</artifactId>
<version>7.1.2.Final</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.keycloak</groupId>
<artifactId>keycloak-tomcat-core-adapter</artifactId>
<exclusions>
<exclusion>
<groupId>org.apache.tomcat</groupId>
<artifactId>tomcat-servlet-api</artifactId>
</exclusion>
<exclusion>
<groupId>org.apache.tomcat</groupId>
<artifactId>tomcat-catalina</artifactId>
</exclusion>
<exclusion>
<groupId>org.apache.tomcat</groupId>
<artifactId>catalina</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<scope>test</scope>
</dependency>
</dependencies>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<source>${maven.compiler.source}</source>
<target>${maven.compiler.target}</target>
</configuration>
</plugin>
</plugins>
</build>
</project>
@@ -0,0 +1,72 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.adapters.jbossweb;
import org.apache.catalina.LifecycleException;
import org.apache.catalina.connector.Request;
import org.apache.catalina.connector.Response;
import org.apache.catalina.core.StandardContext;
import org.apache.catalina.deploy.LoginConfig;
import org.apache.catalina.realm.GenericPrincipal;
import org.keycloak.adapters.tomcat.AbstractKeycloakAuthenticatorValve;
import org.keycloak.adapters.tomcat.GenericPrincipalFactory;
import javax.servlet.ServletException;
import javax.servlet.http.HttpServletResponse;
import java.io.IOException;
import java.security.Principal;
import java.util.List;
/**
* Keycloak authentication valve
*
* @author <a href="mailto:bill@burkecentral.com">Bill Burke</a>
* @version $Revision: 1 $
*/
public class KeycloakAuthenticatorValve extends AbstractKeycloakAuthenticatorValve {
public boolean authenticate(Request request, HttpServletResponse response, LoginConfig config) throws java.io.IOException {
return authenticateInternal(request, response, config);
}
@Override
protected boolean forwardToErrorPageInternal(Request request, HttpServletResponse response, Object loginConfig) throws IOException {
if (loginConfig == null) return false;
LoginConfig config = (LoginConfig)loginConfig;
if (config.getErrorPage() == null) return false;
forwardToErrorPage(request, (Response)response, config);
return true;
}
@Override
public void start() throws LifecycleException {
StandardContext standardContext = (StandardContext) context;
standardContext.addLifecycleListener(this);
super.start();
}
public void logout(Request request) {
logoutInternal(request);
}
@Override
protected GenericPrincipalFactory createPrincipalFactory() {
return new JBossWebPrincipalFactory();
}
}
+116
View File
@@ -0,0 +1,116 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
~ Copyright 2016 Red Hat, Inc. and/or its affiliates
~ and other contributors as indicated by the @author tags.
~
~ Licensed under the Apache License, Version 2.0 (the "License");
~ you may not use this file except in compliance with the License.
~ You may obtain a copy of the License at
~
~ http://www.apache.org/licenses/LICENSE-2.0
~
~ Unless required by applicable law or agreed to in writing, software
~ distributed under the License is distributed on an "AS IS" BASIS,
~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
~ See the License for the specific language governing permissions and
~ limitations under the License.
-->
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.keycloak</groupId>
<artifactId>keycloak-as7-integration-pom</artifactId>
<version>1.9.5.Final</version>
<relativePath>../pom.xml</relativePath>
</parent>
<artifactId>keycloak-as7-subsystem</artifactId>
<name>Keycloak AS7 Subsystem</name>
<description/>
<packaging>jar</packaging>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>2.8.1</version>
<configuration>
<redirectTestOutputToFile>false</redirectTestOutputToFile>
<enableAssertions>true</enableAssertions>
<argLine>-Xmx512m</argLine>
<systemProperties>
<property>
<name>jboss.home</name>
<value>${jboss.home}</value>
</property>
</systemProperties>
<includes>
<include>**/*TestCase.java</include>
</includes>
<forkMode>once</forkMode>
</configuration>
</plugin>
</plugins>
</build>
<dependencies>
<dependency>
<groupId>org.keycloak</groupId>
<artifactId>keycloak-as7-adapter</artifactId>
</dependency>
<dependency>
<groupId>org.jboss.as</groupId>
<artifactId>jboss-as-naming</artifactId>
<version>${jboss.as.version}</version>
</dependency>
<dependency>
<groupId>org.jboss.as</groupId>
<artifactId>jboss-as-server</artifactId>
<version>${jboss.as.version}</version>
</dependency>
<dependency>
<groupId>org.jboss.as</groupId>
<artifactId>jboss-as-ee</artifactId>
<version>${jboss.as.version}</version>
</dependency>
<dependency>
<groupId>org.jboss.as</groupId>
<artifactId>jboss-as-web</artifactId>
<version>${jboss.as.version}</version>
</dependency>
<dependency>
<groupId>org.jboss.logging</groupId>
<artifactId>jboss-logging</artifactId>
<version>3.1.0.GA</version>
</dependency>
<dependency>
<groupId>org.jboss.logging</groupId>
<artifactId>jboss-logging-processor</artifactId>
<!-- This is a compile-time dependency of this project, but is not needed at compile or runtime by other
projects that depend on this project.-->
<scope>provided</scope>
<optional>true</optional>
<version>1.0.0.Final</version>
</dependency>
<dependency>
<groupId>org.jboss.msc</groupId>
<artifactId>jboss-msc</artifactId>
<version>1.0.2.GA</version>
</dependency>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<scope>test</scope>
</dependency>
</dependencies>
</project>
@@ -0,0 +1,62 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.subsystem.as7;
import org.jboss.as.controller.AbstractAddStepHandler;
import org.jboss.as.controller.AttributeDefinition;
import org.jboss.as.controller.OperationContext;
import org.jboss.as.controller.OperationFailedException;
import org.jboss.as.controller.ServiceVerificationHandler;
import org.jboss.dmr.ModelNode;
import org.jboss.msc.service.ServiceController;
import java.util.Collection;
import java.util.LinkedList;
import java.util.List;
/**
* Add a credential to a deployment.
*
* @author Stan Silvert ssilvert@redhat.com (C) 2014 Red Hat Inc.
*/
public class CredentialAddHandler extends AbstractAddStepHandler {
protected Collection<AttributeDefinition> attributes = new LinkedList<>();
public CredentialAddHandler(AttributeDefinition... attrs) {
for (AttributeDefinition attr : attrs) {
attributes.add(attr);
}
}
@Override
protected void populateModel(ModelNode operation, ModelNode model) throws OperationFailedException {
if (attributes != null) {
for (AttributeDefinition attr : attributes) {
attr.validateAndSet(operation, model);
}
}
}
@Override
protected void performRuntime(OperationContext context, ModelNode operation, ModelNode model, ServiceVerificationHandler verificationHandler, List<ServiceController<?>> newControllers) throws OperationFailedException {
KeycloakAdapterConfigService ckService = KeycloakAdapterConfigService.getInstance();
ckService.addCredential(operation, context.resolveExpressions(model));
}
}
@@ -0,0 +1,63 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.subsystem.as7;
import org.jboss.as.controller.AttributeDefinition;
import org.jboss.as.controller.PathElement;
import org.jboss.as.controller.SimpleAttributeDefinitionBuilder;
import org.jboss.as.controller.SimpleResourceDefinition;
import org.jboss.as.controller.descriptions.ModelDescriptionConstants;
import org.jboss.as.controller.operations.common.GenericSubsystemDescribeHandler;
import org.jboss.as.controller.operations.validation.StringLengthValidator;
import org.jboss.as.controller.registry.ManagementResourceRegistration;
import org.jboss.as.controller.registry.OperationEntry;
import org.jboss.dmr.ModelType;
/**
* Defines attributes and operations for a credential.
*
* @author Stan Silvert ssilvert@redhat.com (C) 2013 Red Hat Inc.
*/
public class CredentialDefinition extends SimpleResourceDefinition {
public static final String TAG_NAME = "credential";
protected static final AttributeDefinition VALUE =
new SimpleAttributeDefinitionBuilder("value", ModelType.STRING, false)
.setAllowExpression(true)
.setValidator(new StringLengthValidator(1, Integer.MAX_VALUE, false, true))
.build();
public CredentialDefinition() {
super(PathElement.pathElement(TAG_NAME),
KeycloakExtension.getResourceDescriptionResolver(TAG_NAME),
new CredentialAddHandler(VALUE),
CredentialRemoveHandler.INSTANCE);
}
@Override
public void registerOperations(ManagementResourceRegistration resourceRegistration) {
super.registerOperations(resourceRegistration);
resourceRegistration.registerOperationHandler(ModelDescriptionConstants.DESCRIBE, GenericSubsystemDescribeHandler.INSTANCE, GenericSubsystemDescribeHandler.INSTANCE, false, OperationEntry.EntryType.PRIVATE);
}
@Override
public void registerAttributes(ManagementResourceRegistration resourceRegistration) {
super.registerAttributes(resourceRegistration);
resourceRegistration.registerReadWriteAttribute(VALUE, null, new CredentialReadWriteAttributeHandler());
}
}
@@ -0,0 +1,50 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.subsystem.as7;
import org.jboss.as.controller.AbstractWriteAttributeHandler;
import org.jboss.as.controller.OperationContext;
import org.jboss.as.controller.OperationFailedException;
import org.jboss.dmr.ModelNode;
/**
* Update a credential value.
*
* @author Stan Silvert ssilvert@redhat.com (C) 2014 Red Hat Inc.
*/
public class CredentialReadWriteAttributeHandler extends AbstractWriteAttributeHandler<KeycloakAdapterConfigService> {
@Override
protected boolean applyUpdateToRuntime(OperationContext context, ModelNode operation, String attributeName,
ModelNode resolvedValue, ModelNode currentValue, AbstractWriteAttributeHandler.HandbackHolder<KeycloakAdapterConfigService> hh) throws OperationFailedException {
KeycloakAdapterConfigService ckService = KeycloakAdapterConfigService.getInstance();
ckService.updateCredential(operation, attributeName, resolvedValue);
hh.setHandback(ckService);
return false;
}
@Override
protected void revertUpdateToRuntime(OperationContext context, ModelNode operation, String attributeName,
ModelNode valueToRestore, ModelNode valueToRevert, KeycloakAdapterConfigService ckService) throws OperationFailedException {
ckService.updateCredential(operation, attributeName, valueToRestore);
}
}
@@ -0,0 +1,42 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.subsystem.as7;
import org.jboss.as.controller.AbstractRemoveStepHandler;
import org.jboss.as.controller.OperationContext;
import org.jboss.as.controller.OperationFailedException;
import org.jboss.dmr.ModelNode;
/**
* Remove a credential from a deployment.
*
* @author Stan Silvert ssilvert@redhat.com (C) 2014 Red Hat Inc.
*/
public final class CredentialRemoveHandler extends AbstractRemoveStepHandler {
public static CredentialRemoveHandler INSTANCE = new CredentialRemoveHandler();
private CredentialRemoveHandler() {}
@Override
protected void performRuntime(OperationContext context, ModelNode operation, ModelNode model) throws OperationFailedException {
KeycloakAdapterConfigService ckService = KeycloakAdapterConfigService.getInstance();
ckService.removeCredential(operation);
}
}
@@ -0,0 +1,129 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.subsystem.as7;
import org.jboss.as.server.deployment.DeploymentPhaseContext;
import org.jboss.as.server.deployment.DeploymentUnit;
import org.jboss.as.server.deployment.DeploymentUnitProcessingException;
import org.jboss.as.server.deployment.DeploymentUnitProcessor;
import org.jboss.as.web.deployment.WarMetaData;
import org.jboss.logging.Logger;
import org.jboss.metadata.javaee.spec.ParamValueMetaData;
import org.jboss.metadata.web.jboss.JBossWebMetaData;
import org.jboss.metadata.web.jboss.ValveMetaData;
import org.jboss.metadata.web.spec.LoginConfigMetaData;
import org.keycloak.adapters.jbossweb.KeycloakAuthenticatorValve;
import org.keycloak.subsystem.as7.logging.KeycloakLogger;
import java.util.ArrayList;
import java.util.List;
/**
* Pass authentication data (keycloak.json) as a servlet context param so it can be read by the KeycloakServletExtension.
*
* @author Stan Silvert ssilvert@redhat.com (C) 2014 Red Hat Inc.
*/
public class KeycloakAdapterConfigDeploymentProcessor implements DeploymentUnitProcessor {
protected Logger log = Logger.getLogger(KeycloakAdapterConfigDeploymentProcessor.class);
// This param name is defined again in Keycloak Undertow Integration class
// org.keycloak.adapters.undertow.KeycloakServletExtension. We have this value in
// two places to avoid dependency between Keycloak Subsystem and Keyclaok Undertow Integration.
public static final String AUTH_DATA_PARAM_NAME = "org.keycloak.json.adapterConfig";
@Override
public void deploy(DeploymentPhaseContext phaseContext) throws DeploymentUnitProcessingException {
DeploymentUnit deploymentUnit = phaseContext.getDeploymentUnit();
String deploymentName = deploymentUnit.getName();
// if it's not a web-app there's nothing to secure
WarMetaData warMetaData = deploymentUnit.getAttachment(WarMetaData.ATTACHMENT_KEY);
if (warMetaData == null) {
return;
}
JBossWebMetaData webMetaData = warMetaData.getMergedJBossWebMetaData();
if (webMetaData == null) {
webMetaData = new JBossWebMetaData();
warMetaData.setMergedJBossWebMetaData(webMetaData);
}
KeycloakAdapterConfigService service = KeycloakAdapterConfigService.getInstance();
// otherwise
LoginConfigMetaData loginConfig = webMetaData.getLoginConfig();
boolean hasSubsystemConfig = service.isSecureDeployment(deploymentName);
boolean webRequiresKC = loginConfig != null && "KEYCLOAK".equalsIgnoreCase(loginConfig.getAuthMethod());
if (hasSubsystemConfig || webRequiresKC) {
log.debug("Setting up KEYCLOAK auth method for WAR: " + deploymentName);
// if secure-deployment configuration exists for web app, we force KEYCLOAK auth method on it
if (hasSubsystemConfig) {
addJSONData(service.getJSON(deploymentName), warMetaData);
if (loginConfig != null) {
loginConfig.setAuthMethod("KEYCLOAK");
loginConfig.setRealmName(service.getRealmName(deploymentName));
} else {
log.warn("Failed to set up KEYCLOAK auth method for WAR: " + deploymentName + " (loginConfig == null)");
}
}
addValve(webMetaData);
KeycloakLogger.ROOT_LOGGER.deploymentSecured(deploymentName);
}
}
private void addValve(JBossWebMetaData webMetaData) {
List<ValveMetaData> valves = webMetaData.getValves();
if (valves == null) {
valves = new ArrayList<ValveMetaData>(1);
webMetaData.setValves(valves);
}
ValveMetaData valve = new ValveMetaData();
valve.setValveClass(KeycloakAuthenticatorValve.class.getName());
valve.setModule("org.keycloak.keycloak-as7-adapter");
//log.info("******* adding Keycloak valve to: " + deploymentName);
valves.add(valve);
}
private void addJSONData(String json, WarMetaData warMetaData) {
JBossWebMetaData webMetaData = warMetaData.getMergedJBossWebMetaData();
if (webMetaData == null) {
webMetaData = new JBossWebMetaData();
warMetaData.setMergedJBossWebMetaData(webMetaData);
}
List<ParamValueMetaData> contextParams = webMetaData.getContextParams();
if (contextParams == null) {
contextParams = new ArrayList<ParamValueMetaData>();
}
ParamValueMetaData param = new ParamValueMetaData();
param.setParamName(AUTH_DATA_PARAM_NAME);
param.setParamValue(json);
contextParams.add(param);
webMetaData.setContextParams(contextParams);
}
@Override
public void undeploy(DeploymentUnit du) {
}
}
@@ -0,0 +1,192 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.subsystem.as7;
import org.jboss.dmr.ModelNode;
import org.jboss.dmr.Property;
import org.jboss.logging.Logger;
import java.util.HashMap;
import java.util.Map;
import static org.jboss.as.controller.descriptions.ModelDescriptionConstants.ADDRESS;
/**
* This service keeps track of the entire Keycloak management model so as to provide
* adapter configuration to each deployment at deploy time.
*
* @author Stan Silvert ssilvert@redhat.com (C) 2013 Red Hat Inc.
*/
public final class KeycloakAdapterConfigService {
protected Logger log = Logger.getLogger(KeycloakAdapterConfigService.class);
private static final String CREDENTIALS_JSON_NAME = "credentials";
private static final KeycloakAdapterConfigService INSTANCE = new KeycloakAdapterConfigService();
public static KeycloakAdapterConfigService getInstance() {
return INSTANCE;
}
private final Map<String, ModelNode> realms = new HashMap<String, ModelNode>();
// keycloak-secured deployments
private final Map<String, ModelNode> secureDeployments = new HashMap<String, ModelNode>();
private KeycloakAdapterConfigService() {
}
public void addRealm(ModelNode operation, ModelNode model) {
this.realms.put(realmNameFromOp(operation), model.clone());
}
public void updateRealm(ModelNode operation, String attrName, ModelNode resolvedValue) {
ModelNode realm = this.realms.get(realmNameFromOp(operation));
realm.get(attrName).set(resolvedValue);
}
public void removeRealm(ModelNode operation) {
this.realms.remove(realmNameFromOp(operation));
}
public void addSecureDeployment(ModelNode operation, ModelNode model) {
ModelNode deployment = model.clone();
this.secureDeployments.put(deploymentNameFromOp(operation), deployment);
}
public void updateSecureDeployment(ModelNode operation, String attrName, ModelNode resolvedValue) {
ModelNode deployment = this.secureDeployments.get(deploymentNameFromOp(operation));
deployment.get(attrName).set(resolvedValue);
}
public void removeSecureDeployment(ModelNode operation) {
this.secureDeployments.remove(deploymentNameFromOp(operation));
}
public void addCredential(ModelNode operation, ModelNode model) {
ModelNode credentials = credentialsFromOp(operation);
if (!credentials.isDefined()) {
credentials = new ModelNode();
}
String credentialName = credentialNameFromOp(operation);
if (!credentialName.contains(".")) {
credentials.get(credentialName).set(model.get("value").asString());
} else {
String[] parts = credentialName.split("\\.");
String provider = parts[0];
String property = parts[1];
ModelNode credential = credentials.get(provider);
if (!credential.isDefined()) {
credential = new ModelNode();
}
credential.get(property).set(model.get("value").asString());
credentials.set(provider, credential);
}
ModelNode deployment = this.secureDeployments.get(deploymentNameFromOp(operation));
deployment.get(CREDENTIALS_JSON_NAME).set(credentials);
}
public void removeCredential(ModelNode operation) {
ModelNode credentials = credentialsFromOp(operation);
if (!credentials.isDefined()) {
throw new RuntimeException("Can not remove credential. No credential defined for deployment in op " + operation.toString());
}
String credentialName = credentialNameFromOp(operation);
credentials.remove(credentialName);
}
public void updateCredential(ModelNode operation, String attrName, ModelNode resolvedValue) {
ModelNode credentials = credentialsFromOp(operation);
if (!credentials.isDefined()) {
throw new RuntimeException("Can not update credential. No credential defined for deployment in op " + operation.toString());
}
String credentialName = credentialNameFromOp(operation);
credentials.get(credentialName).set(resolvedValue);
}
private ModelNode credentialsFromOp(ModelNode operation) {
ModelNode deployment = this.secureDeployments.get(deploymentNameFromOp(operation));
return deployment.get(CREDENTIALS_JSON_NAME);
}
private String realmNameFromOp(ModelNode operation) {
return valueFromOpAddress(RealmDefinition.TAG_NAME, operation);
}
private String deploymentNameFromOp(ModelNode operation) {
return valueFromOpAddress(SecureDeploymentDefinition.TAG_NAME, operation);
}
private String credentialNameFromOp(ModelNode operation) {
return valueFromOpAddress(CredentialDefinition.TAG_NAME, operation);
}
private String valueFromOpAddress(String addrElement, ModelNode operation) {
String deploymentName = getValueOfAddrElement(operation.get(ADDRESS), addrElement);
if (deploymentName == null) throw new RuntimeException("Can't find '" + addrElement + "' in address " + operation.toString());
return deploymentName;
}
private String getValueOfAddrElement(ModelNode address, String elementName) {
for (ModelNode element : address.asList()) {
if (element.has(elementName)) return element.get(elementName).asString();
}
return null;
}
public String getRealmName(String deploymentName) {
ModelNode deployment = this.secureDeployments.get(deploymentName);
return deployment.get(RealmDefinition.TAG_NAME).asString();
}
public String getJSON(String deploymentName) {
ModelNode deployment = this.secureDeployments.get(deploymentName);
String realmName = deployment.get(RealmDefinition.TAG_NAME).asString();
ModelNode realm = this.realms.get(realmName);
ModelNode json = new ModelNode();
json.get(RealmDefinition.TAG_NAME).set(realmName);
// Realm values set first. Some can be overridden by deployment values.
if (realm != null) setJSONValues(json, realm);
setJSONValues(json, deployment);
return json.toJSONString(true);
}
private void setJSONValues(ModelNode json, ModelNode values) {
for (Property prop : values.asPropertyList()) {
String name = prop.getName();
ModelNode value = prop.getValue();
if (value.isDefined()) {
json.get(name).set(value);
}
}
}
public boolean isSecureDeployment(String deploymentName) {
//log.info("********* CHECK KEYCLOAK DEPLOYMENT: deployments.size()" + deployments.size());
return this.secureDeployments.containsKey(deploymentName);
}
}
@@ -0,0 +1,86 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.subsystem.as7;
import org.jboss.as.server.deployment.Attachments;
import org.jboss.as.server.deployment.DeploymentPhaseContext;
import org.jboss.as.server.deployment.DeploymentUnit;
import org.jboss.as.server.deployment.DeploymentUnitProcessingException;
import org.jboss.as.server.deployment.DeploymentUnitProcessor;
import org.jboss.as.server.deployment.module.ModuleDependency;
import org.jboss.as.server.deployment.module.ModuleSpecification;
import org.jboss.as.web.deployment.WarMetaData;
import org.jboss.metadata.web.jboss.JBossWebMetaData;
import org.jboss.metadata.web.spec.LoginConfigMetaData;
import org.jboss.modules.Module;
import org.jboss.modules.ModuleIdentifier;
import org.jboss.modules.ModuleLoader;
/**
*
* @author Stan Silvert ssilvert@redhat.com (C) 2013 Red Hat Inc.
*/
public abstract class KeycloakDependencyProcessor implements DeploymentUnitProcessor {
private static final ModuleIdentifier KEYCLOAK_JBOSS_CORE_ADAPTER = ModuleIdentifier.create("org.keycloak.keycloak-jboss-adapter-core");
private static final ModuleIdentifier KEYCLOAK_CORE_ADAPTER = ModuleIdentifier.create("org.keycloak.keycloak-adapter-core");
private static final ModuleIdentifier KEYCLOAK_CORE = ModuleIdentifier.create("org.keycloak.keycloak-core");
private static final ModuleIdentifier KEYCLOAK_COMMON = ModuleIdentifier.create("org.keycloak.keycloak-common");
@Override
public void deploy(DeploymentPhaseContext phaseContext) throws DeploymentUnitProcessingException {
final DeploymentUnit deploymentUnit = phaseContext.getDeploymentUnit();
String deploymentName = deploymentUnit.getName();
if (!KeycloakAdapterConfigService.getInstance().isSecureDeployment(deploymentName)) {
WarMetaData warMetaData = deploymentUnit.getAttachment(WarMetaData.ATTACHMENT_KEY);
if (warMetaData == null) {
return;
}
JBossWebMetaData webMetaData = warMetaData.getMergedJBossWebMetaData();
if (webMetaData == null) {
return;
}
LoginConfigMetaData loginConfig = webMetaData.getLoginConfig();
if (loginConfig == null) return;
if (loginConfig.getAuthMethod() == null) return;
if (!loginConfig.getAuthMethod().equals("KEYCLOAK")) return;
}
final ModuleSpecification moduleSpecification = deploymentUnit.getAttachment(Attachments.MODULE_SPECIFICATION);
final ModuleLoader moduleLoader = Module.getBootModuleLoader();
addCommonModules(moduleSpecification, moduleLoader);
addPlatformSpecificModules(moduleSpecification, moduleLoader);
}
private void addCommonModules(ModuleSpecification moduleSpecification, ModuleLoader moduleLoader) {
// ModuleDependency(ModuleLoader moduleLoader, ModuleIdentifier identifier, boolean optional, boolean export, boolean importServices, boolean userSpecified)
moduleSpecification.addSystemDependency(new ModuleDependency(moduleLoader, KEYCLOAK_JBOSS_CORE_ADAPTER, false, false, false, false));
moduleSpecification.addSystemDependency(new ModuleDependency(moduleLoader, KEYCLOAK_CORE_ADAPTER, false, false, false, false));
moduleSpecification.addSystemDependency(new ModuleDependency(moduleLoader, KEYCLOAK_CORE, false, false, false, false));
moduleSpecification.addSystemDependency(new ModuleDependency(moduleLoader, KEYCLOAK_COMMON, false, false, false, false));
}
abstract protected void addPlatformSpecificModules(ModuleSpecification moduleSpecification, ModuleLoader moduleLoader);
@Override
public void undeploy(DeploymentUnit du) {
}
}
@@ -0,0 +1,36 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.subsystem.as7;
import org.jboss.as.server.deployment.module.ModuleDependency;
import org.jboss.as.server.deployment.module.ModuleSpecification;
import org.jboss.modules.ModuleIdentifier;
import org.jboss.modules.ModuleLoader;
/**
* @author <a href="mailto:marko.strukelj@gmail.com">Marko Strukelj</a>
*/
public class KeycloakDependencyProcessorAS7 extends KeycloakDependencyProcessor {
private static final ModuleIdentifier KEYCLOAK_AS7_ADAPTER = ModuleIdentifier.create("org.keycloak.keycloak-as7-adapter");
@Override
protected void addPlatformSpecificModules(ModuleSpecification moduleSpecification, ModuleLoader moduleLoader) {
// ModuleDependency(ModuleLoader moduleLoader, ModuleIdentifier identifier, boolean optional, boolean export, boolean importServices, boolean userSpecified)
moduleSpecification.addSystemDependency(new ModuleDependency(moduleLoader, KEYCLOAK_AS7_ADAPTER, false, false, true, false));
}}
@@ -0,0 +1,84 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.subsystem.as7;
import org.jboss.as.controller.Extension;
import org.jboss.as.controller.ExtensionContext;
import org.jboss.as.controller.PathElement;
import org.jboss.as.controller.ResourceDefinition;
import org.jboss.as.controller.SubsystemRegistration;
import org.jboss.as.controller.descriptions.StandardResourceDescriptionResolver;
import org.jboss.as.controller.parsing.ExtensionParsingContext;
import org.jboss.as.controller.registry.ManagementResourceRegistration;
import org.keycloak.subsystem.as7.logging.KeycloakLogger;
import static org.jboss.as.controller.descriptions.ModelDescriptionConstants.SUBSYSTEM;
/**
* Main Extension class for the subsystem.
*
* @author Stan Silvert ssilvert@redhat.com (C) 2013 Red Hat Inc.
*/
public class KeycloakExtension implements Extension {
public static final String SUBSYSTEM_NAME = "keycloak";
public static final String NAMESPACE = "urn:jboss:domain:keycloak:1.1";
private static final KeycloakSubsystemParser PARSER = new KeycloakSubsystemParser();
static final PathElement PATH_SUBSYSTEM = PathElement.pathElement(SUBSYSTEM, SUBSYSTEM_NAME);
private static final String RESOURCE_NAME = KeycloakExtension.class.getPackage().getName() + ".LocalDescriptions";
private static final int MGMT_API_VERSION_MAJOR = 1;
private static final int MGMT_API_VERSION_MINOR = 1;
static final PathElement SUBSYSTEM_PATH = PathElement.pathElement(SUBSYSTEM, SUBSYSTEM_NAME);
private static final ResourceDefinition KEYCLOAK_SUBSYSTEM_RESOURCE = new KeycloakSubsystemDefinition();
static final RealmDefinition REALM_DEFINITION = new RealmDefinition();
static final SecureDeploymentDefinition SECURE_DEPLOYMENT_DEFINITION = new SecureDeploymentDefinition();
static final CredentialDefinition CREDENTIAL_DEFINITION = new CredentialDefinition();
public static StandardResourceDescriptionResolver getResourceDescriptionResolver(final String... keyPrefix) {
StringBuilder prefix = new StringBuilder(SUBSYSTEM_NAME);
for (String kp : keyPrefix) {
prefix.append('.').append(kp);
}
return new StandardResourceDescriptionResolver(prefix.toString(), RESOURCE_NAME, KeycloakExtension.class.getClassLoader(), true, false);
}
/**
* {@inheritDoc}
*/
@Override
public void initializeParsers(final ExtensionParsingContext context) {
context.setSubsystemXmlMapping(SUBSYSTEM_NAME, KeycloakExtension.NAMESPACE, PARSER);
}
/**
* {@inheritDoc}
*/
@Override
public void initialize(final ExtensionContext context) {
KeycloakLogger.ROOT_LOGGER.debug("Activating Keycloak Extension");
final SubsystemRegistration subsystem = context.registerSubsystem(SUBSYSTEM_NAME, MGMT_API_VERSION_MAJOR, MGMT_API_VERSION_MINOR);
ManagementResourceRegistration registration = subsystem.registerSubsystemModel(KEYCLOAK_SUBSYSTEM_RESOURCE);
registration.registerSubModel(REALM_DEFINITION);
ManagementResourceRegistration secureDeploymentRegistration = registration.registerSubModel(SECURE_DEPLOYMENT_DEFINITION);
secureDeploymentRegistration.registerSubModel(CREDENTIAL_DEFINITION);
subsystem.registerXMLElementWriter(PARSER);
}
}
@@ -0,0 +1,60 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.subsystem.as7;
import org.jboss.as.controller.AbstractBoottimeAddStepHandler;
import org.jboss.as.controller.OperationContext;
import org.jboss.as.controller.OperationFailedException;
import org.jboss.as.controller.ServiceVerificationHandler;
import org.jboss.as.server.AbstractDeploymentChainStep;
import org.jboss.as.server.DeploymentProcessorTarget;
import org.jboss.as.server.deployment.Phase;
import org.jboss.dmr.ModelNode;
import org.jboss.msc.service.ServiceController;
import java.util.List;
/**
* The Keycloak subsystem add update handler.
*
* @author Stan Silvert ssilvert@redhat.com (C) 2013 Red Hat Inc.
*/
class KeycloakSubsystemAdd extends AbstractBoottimeAddStepHandler {
static final KeycloakSubsystemAdd INSTANCE = new KeycloakSubsystemAdd();
@Override
protected void performBoottime(final OperationContext context, ModelNode operation, final ModelNode model, ServiceVerificationHandler verificationHandler, List<ServiceController<?>> newControllers) {
context.addStep(new AbstractDeploymentChainStep() {
@Override
protected void execute(DeploymentProcessorTarget processorTarget) {
processorTarget.addDeploymentProcessor(Phase.DEPENDENCIES, 0, new KeycloakDependencyProcessorAS7());
processorTarget.addDeploymentProcessor(
Phase.POST_MODULE, // PHASE
Phase.POST_MODULE_VALIDATOR_FACTORY - 1, // PRIORITY
new KeycloakAdapterConfigDeploymentProcessor());
}
}, OperationContext.Stage.RUNTIME);
}
@Override
protected void populateModel(ModelNode operation, ModelNode model) throws OperationFailedException {
model.setEmptyObject();
}
}
@@ -0,0 +1,47 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.subsystem.as7;
import org.jboss.as.controller.ReloadRequiredRemoveStepHandler;
import org.jboss.as.controller.SimpleResourceDefinition;
import org.jboss.as.controller.descriptions.ModelDescriptionConstants;
import org.jboss.as.controller.operations.common.GenericSubsystemDescribeHandler;
import org.jboss.as.controller.registry.ManagementResourceRegistration;
import org.jboss.as.controller.registry.OperationEntry;
/**
* Definition of subsystem=keycloak.
*
* @author Stan Silvert ssilvert@redhat.com (C) 2013 Red Hat Inc.
*/
public class KeycloakSubsystemDefinition extends SimpleResourceDefinition {
protected KeycloakSubsystemDefinition() {
super(KeycloakExtension.SUBSYSTEM_PATH,
KeycloakExtension.getResourceDescriptionResolver("subsystem"),
KeycloakSubsystemAdd.INSTANCE,
ReloadRequiredRemoveStepHandler.INSTANCE
);
}
@Override
public void registerOperations(ManagementResourceRegistration resourceRegistration) {
super.registerOperations(resourceRegistration);
resourceRegistration.registerOperationHandler(ModelDescriptionConstants.DESCRIBE, GenericSubsystemDescribeHandler.INSTANCE, GenericSubsystemDescribeHandler.INSTANCE, false, OperationEntry.EntryType.PRIVATE);
}
}
@@ -0,0 +1,294 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.subsystem.as7;
import org.jboss.as.controller.AttributeDefinition;
import org.jboss.as.controller.PathAddress;
import org.jboss.as.controller.PathElement;
import org.jboss.as.controller.SimpleAttributeDefinition;
import org.jboss.as.controller.descriptions.ModelDescriptionConstants;
import org.jboss.as.controller.parsing.ParseUtils;
import org.jboss.as.controller.persistence.SubsystemMarshallingContext;
import org.jboss.dmr.ModelNode;
import org.jboss.dmr.Property;
import org.jboss.staxmapper.XMLElementReader;
import org.jboss.staxmapper.XMLElementWriter;
import org.jboss.staxmapper.XMLExtendedStreamReader;
import org.jboss.staxmapper.XMLExtendedStreamWriter;
import javax.xml.stream.XMLStreamConstants;
import javax.xml.stream.XMLStreamException;
import java.util.ArrayList;
import java.util.Collections;
import java.util.HashMap;
import java.util.LinkedHashMap;
import java.util.List;
import java.util.Map;
/**
* The subsystem parser, which uses stax to read and write to and from xml
*/
class KeycloakSubsystemParser implements XMLStreamConstants, XMLElementReader<List<ModelNode>>, XMLElementWriter<SubsystemMarshallingContext> {
/**
* {@inheritDoc}
*/
@Override
public void readElement(final XMLExtendedStreamReader reader, final List<ModelNode> list) throws XMLStreamException {
// Require no attributes
ParseUtils.requireNoAttributes(reader);
ModelNode addKeycloakSub = Util.createAddOperation(PathAddress.pathAddress(KeycloakExtension.PATH_SUBSYSTEM));
list.add(addKeycloakSub);
while (reader.hasNext() && nextTag(reader) != END_ELEMENT) {
if (reader.getLocalName().equals(RealmDefinition.TAG_NAME)) {
readRealm(reader, list);
}
else if (reader.getLocalName().equals(SecureDeploymentDefinition.TAG_NAME)) {
readDeployment(reader, list);
}
}
}
// used for debugging
private int nextTag(XMLExtendedStreamReader reader) throws XMLStreamException {
return reader.nextTag();
}
private void readRealm(XMLExtendedStreamReader reader, List<ModelNode> list) throws XMLStreamException {
String realmName = readNameAttribute(reader);
ModelNode addRealm = new ModelNode();
addRealm.get(ModelDescriptionConstants.OP).set(ModelDescriptionConstants.ADD);
PathAddress addr = PathAddress.pathAddress(PathElement.pathElement(ModelDescriptionConstants.SUBSYSTEM, KeycloakExtension.SUBSYSTEM_NAME),
PathElement.pathElement(RealmDefinition.TAG_NAME, realmName));
addRealm.get(ModelDescriptionConstants.OP_ADDR).set(addr.toModelNode());
while (reader.hasNext() && nextTag(reader) != END_ELEMENT) {
String tagName = reader.getLocalName();
SimpleAttributeDefinition def = RealmDefinition.lookup(tagName);
if (def == null) throw new XMLStreamException("Unknown realm tag " + tagName);
def.parseAndSetParameter(reader.getElementText(), addRealm, reader);
}
if (!SharedAttributeDefinitons.validateTruststoreSetIfRequired(addRealm)) {
//TODO: externalize the message
throw new XMLStreamException("truststore and truststore-password must be set if ssl-required is not none and disable-trust-maanger is false.");
}
list.add(addRealm);
}
private void readDeployment(XMLExtendedStreamReader reader, List<ModelNode> resourcesToAdd) throws XMLStreamException {
String name = readNameAttribute(reader);
ModelNode addSecureDeployment = new ModelNode();
addSecureDeployment.get(ModelDescriptionConstants.OP).set(ModelDescriptionConstants.ADD);
PathAddress addr = PathAddress.pathAddress(PathElement.pathElement(ModelDescriptionConstants.SUBSYSTEM, KeycloakExtension.SUBSYSTEM_NAME),
PathElement.pathElement(SecureDeploymentDefinition.TAG_NAME, name));
addSecureDeployment.get(ModelDescriptionConstants.OP_ADDR).set(addr.toModelNode());
List<ModelNode> credentialsToAdd = new ArrayList<ModelNode>();
while (reader.hasNext() && nextTag(reader) != END_ELEMENT) {
String tagName = reader.getLocalName();
if (tagName.equals(CredentialDefinition.TAG_NAME)) {
readCredential(reader, addr, credentialsToAdd);
continue;
}
SimpleAttributeDefinition def = SecureDeploymentDefinition.lookup(tagName);
if (def == null) throw new XMLStreamException("Unknown secure-deployment tag " + tagName);
def.parseAndSetParameter(reader.getElementText(), addSecureDeployment, reader);
}
/**
* TODO need to check realm-ref first.
if (!SharedAttributeDefinitons.validateTruststoreSetIfRequired(addSecureDeployment)) {
//TODO: externalize the message
throw new XMLStreamException("truststore and truststore-password must be set if ssl-required is not none and disable-trust-maanger is false.");
}
*/
// Must add credentials after the deployment is added.
resourcesToAdd.add(addSecureDeployment);
resourcesToAdd.addAll(credentialsToAdd);
}
public void readCredential(XMLExtendedStreamReader reader, PathAddress parent, List<ModelNode> credentialsToAdd) throws XMLStreamException {
String name = readNameAttribute(reader);
Map<String, String> values = new HashMap<>();
String textValue = null;
while (reader.hasNext()) {
int next = reader.next();
if (next == CHARACTERS) {
// text value of credential element (like for "secret" )
String text = reader.getText();
if (text == null || text.trim().isEmpty()) {
continue;
}
textValue = text;
} else if (next == START_ELEMENT) {
String key = reader.getLocalName();
reader.next();
String value = reader.getText();
reader.next();
values.put(key, value);
} else if (next == END_ELEMENT) {
break;
}
}
if (textValue != null) {
ModelNode addCredential = getCredentialToAdd(parent, name, textValue);
credentialsToAdd.add(addCredential);
} else {
for (Map.Entry<String, String> entry : values.entrySet()) {
ModelNode addCredential = getCredentialToAdd(parent, name + "" + entry.getKey(), entry.getValue());
credentialsToAdd.add(addCredential);
}
}
}
private ModelNode getCredentialToAdd(PathAddress parent, String name, String value) {
ModelNode addCredential = new ModelNode();
addCredential.get(ModelDescriptionConstants.OP).set(ModelDescriptionConstants.ADD);
PathAddress addr = PathAddress.pathAddress(parent, PathElement.pathElement(CredentialDefinition.TAG_NAME, name));
addCredential.get(ModelDescriptionConstants.OP_ADDR).set(addr.toModelNode());
addCredential.get(CredentialDefinition.VALUE.getName()).set(value);
return addCredential;
}
// expects that the current tag will have one single attribute called "name"
private String readNameAttribute(XMLExtendedStreamReader reader) throws XMLStreamException {
String name = null;
for (int i = 0; i < reader.getAttributeCount(); i++) {
String attr = reader.getAttributeLocalName(i);
if (attr.equals("name")) {
name = reader.getAttributeValue(i);
continue;
}
throw ParseUtils.unexpectedAttribute(reader, i);
}
if (name == null) {
throw ParseUtils.missingRequired(reader, Collections.singleton("name"));
}
return name;
}
/**
* {@inheritDoc}
*/
@Override
public void writeContent(final XMLExtendedStreamWriter writer, final SubsystemMarshallingContext context) throws XMLStreamException {
context.startSubsystemElement(KeycloakExtension.NAMESPACE, false);
writeRealms(writer, context);
writeSecureDeployments(writer, context);
writer.writeEndElement();
}
private void writeRealms(XMLExtendedStreamWriter writer, SubsystemMarshallingContext context) throws XMLStreamException {
if (!context.getModelNode().get(RealmDefinition.TAG_NAME).isDefined()) {
return;
}
for (Property realm : context.getModelNode().get(RealmDefinition.TAG_NAME).asPropertyList()) {
writer.writeStartElement(RealmDefinition.TAG_NAME);
writer.writeAttribute("name", realm.getName());
ModelNode realmElements = realm.getValue();
for (AttributeDefinition element : RealmDefinition.ALL_ATTRIBUTES) {
element.marshallAsElement(realmElements, writer);
}
writer.writeEndElement();
}
}
private void writeSecureDeployments(XMLExtendedStreamWriter writer, SubsystemMarshallingContext context) throws XMLStreamException {
if (!context.getModelNode().get(SecureDeploymentDefinition.TAG_NAME).isDefined()) {
return;
}
for (Property deployment : context.getModelNode().get(SecureDeploymentDefinition.TAG_NAME).asPropertyList()) {
writer.writeStartElement(SecureDeploymentDefinition.TAG_NAME);
writer.writeAttribute("name", deployment.getName());
ModelNode deploymentElements = deployment.getValue();
for (AttributeDefinition element : SecureDeploymentDefinition.ALL_ATTRIBUTES) {
element.marshallAsElement(deploymentElements, writer);
}
ModelNode credentials = deploymentElements.get(CredentialDefinition.TAG_NAME);
if (credentials.isDefined()) {
writeCredentials(writer, credentials);
}
writer.writeEndElement();
}
}
private void writeCredentials(XMLExtendedStreamWriter writer, ModelNode credentials) throws XMLStreamException {
Map<String, Object> parsed = new LinkedHashMap<>();
for (Property credential : credentials.asPropertyList()) {
String credName = credential.getName();
String credValue = credential.getValue().get(CredentialDefinition.VALUE.getName()).asString();
if (credName.indexOf('.') > -1) {
String[] parts = credName.split("\\.");
String provider = parts[0];
String propKey = parts[1];
Map<String, String> currentProviderMap = (Map<String, String>) parsed.get(provider);
if (currentProviderMap == null) {
currentProviderMap = new LinkedHashMap<>();
parsed.put(provider, currentProviderMap);
}
currentProviderMap.put(propKey, credValue);
} else {
parsed.put(credName, credValue);
}
}
for (Map.Entry<String, Object> entry : parsed.entrySet()) {
writer.writeStartElement(CredentialDefinition.TAG_NAME);
writer.writeAttribute("name", entry.getKey());
Object value = entry.getValue();
if (value instanceof String) {
writeCharacters(writer, (String) value);
} else {
Map<String, String> credentialProps = (Map<String, String>) value;
for (Map.Entry<String, String> prop : credentialProps.entrySet()) {
writer.writeStartElement(prop.getKey());
writeCharacters(writer, prop.getValue());
writer.writeEndElement();
}
}
writer.writeEndElement();
}
}
// code taken from org.jboss.as.controller.AttributeMarshaller
private void writeCharacters(XMLExtendedStreamWriter writer, String content) throws XMLStreamException {
if (content.indexOf('\n') > -1) {
// Multiline content. Use the overloaded variant that staxmapper will format
writer.writeCharacters(content);
} else {
// Staxmapper will just output the chars without adding newlines if this is used
char[] chars = content.toCharArray();
writer.writeCharacters(chars, 0, chars.length);
}
}
}
@@ -0,0 +1,58 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.subsystem.as7;
import org.jboss.as.controller.AbstractAddStepHandler;
import org.jboss.as.controller.AttributeDefinition;
import org.jboss.as.controller.OperationContext;
import org.jboss.as.controller.OperationFailedException;
import org.jboss.as.controller.ServiceVerificationHandler;
import org.jboss.dmr.ModelNode;
import org.jboss.msc.service.ServiceController;
import java.util.List;
/**
* Add a new realm.
*
* @author Stan Silvert ssilvert@redhat.com (C) 2013 Red Hat Inc.
*/
public final class RealmAddHandler extends AbstractAddStepHandler {
public static RealmAddHandler INSTANCE = new RealmAddHandler();
private RealmAddHandler() {}
@Override
protected void populateModel(ModelNode operation, ModelNode model) throws OperationFailedException {
for (AttributeDefinition attrib : RealmDefinition.ALL_ATTRIBUTES) {
attrib.validateAndSet(operation, model);
}
if (!SharedAttributeDefinitons.validateTruststoreSetIfRequired(model.clone())) {
//TODO: externalize message
throw new OperationFailedException("truststore and truststore-password must be set if ssl-required is not none and disable-trust-maanger is false.");
}
}
@Override
protected void performRuntime(OperationContext context, ModelNode operation, ModelNode model, ServiceVerificationHandler verificationHandler, List<ServiceController<?>> newControllers) throws OperationFailedException {
KeycloakAdapterConfigService ckService = KeycloakAdapterConfigService.getInstance();
ckService.addRealm(operation, context.resolveExpressions(model));
}
}
@@ -0,0 +1,89 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.subsystem.as7;
import org.jboss.as.controller.AttributeDefinition;
import org.jboss.as.controller.PathElement;
import org.jboss.as.controller.SimpleAttributeDefinition;
import org.jboss.as.controller.SimpleResourceDefinition;
import org.jboss.as.controller.descriptions.ModelDescriptionConstants;
import org.jboss.as.controller.operations.common.GenericSubsystemDescribeHandler;
import org.jboss.as.controller.registry.ManagementResourceRegistration;
import org.jboss.as.controller.registry.OperationEntry;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
/**
* Defines attributes and operations for the Realm
*
* @author Stan Silvert ssilvert@redhat.com (C) 2013 Red Hat Inc.
*/
class RealmDefinition extends SimpleResourceDefinition {
public static final String TAG_NAME = "realm";
protected static final List<SimpleAttributeDefinition> REALM_ONLY_ATTRIBUTES = new ArrayList<SimpleAttributeDefinition>();
static {
}
protected static final List<SimpleAttributeDefinition> ALL_ATTRIBUTES = new ArrayList<SimpleAttributeDefinition>();
static {
ALL_ATTRIBUTES.addAll(REALM_ONLY_ATTRIBUTES);
ALL_ATTRIBUTES.addAll(SharedAttributeDefinitons.ATTRIBUTES);
}
private static final Map<String, SimpleAttributeDefinition> DEFINITION_LOOKUP = new HashMap<String, SimpleAttributeDefinition>();
static {
for (SimpleAttributeDefinition def : ALL_ATTRIBUTES) {
DEFINITION_LOOKUP.put(def.getXmlName(), def);
}
}
private static final RealmWriteAttributeHandler realmAttrHandler = new RealmWriteAttributeHandler(ALL_ATTRIBUTES.toArray(new SimpleAttributeDefinition[0]));
public RealmDefinition() {
super(PathElement.pathElement("realm"),
KeycloakExtension.getResourceDescriptionResolver("realm"),
RealmAddHandler.INSTANCE,
RealmRemoveHandler.INSTANCE);
}
@Override
public void registerOperations(ManagementResourceRegistration resourceRegistration) {
super.registerOperations(resourceRegistration);
resourceRegistration.registerOperationHandler(ModelDescriptionConstants.DESCRIBE, GenericSubsystemDescribeHandler.INSTANCE, GenericSubsystemDescribeHandler.INSTANCE, false, OperationEntry.EntryType.PRIVATE);
}
@Override
public void registerAttributes(ManagementResourceRegistration resourceRegistration) {
super.registerAttributes(resourceRegistration);
for (AttributeDefinition attrDef : ALL_ATTRIBUTES) {
//TODO: use subclass of realmAttrHandler that can call RealmDefinition.validateTruststoreSetIfRequired
resourceRegistration.registerReadWriteAttribute(attrDef, null, realmAttrHandler);
}
}
public static SimpleAttributeDefinition lookup(String name) {
return DEFINITION_LOOKUP.get(name);
}
}
@@ -0,0 +1,41 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.subsystem.as7;
import org.jboss.as.controller.AbstractRemoveStepHandler;
import org.jboss.as.controller.OperationContext;
import org.jboss.as.controller.OperationFailedException;
import org.jboss.dmr.ModelNode;
/**
* Remove a realm.
*
* @author Stan Silvert ssilvert@redhat.com (C) 2013 Red Hat Inc.
*/
final class RealmRemoveHandler extends AbstractRemoveStepHandler {
public static RealmRemoveHandler INSTANCE = new RealmRemoveHandler();
private RealmRemoveHandler() {}
@Override
protected void performRuntime(OperationContext context, ModelNode operation, ModelNode model) throws OperationFailedException {
KeycloakAdapterConfigService ckService = KeycloakAdapterConfigService.getInstance();
ckService.removeRealm(operation);
}
}
@@ -0,0 +1,56 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.subsystem.as7;
import org.jboss.as.controller.AbstractWriteAttributeHandler;
import org.jboss.as.controller.AttributeDefinition;
import org.jboss.as.controller.OperationContext;
import org.jboss.as.controller.OperationFailedException;
import org.jboss.dmr.ModelNode;
import java.util.List;
/**
* Update an attribute on a realm.
*
* @author Stan Silvert ssilvert@redhat.com (C) 2013 Red Hat Inc.
*/
class RealmWriteAttributeHandler extends AbstractWriteAttributeHandler<KeycloakAdapterConfigService> {
public RealmWriteAttributeHandler(AttributeDefinition... definitions) {
super(definitions);
}
@Override
protected boolean applyUpdateToRuntime(OperationContext context, ModelNode operation, String attributeName,
ModelNode resolvedValue, ModelNode currentValue, HandbackHolder<KeycloakAdapterConfigService> hh) throws OperationFailedException {
KeycloakAdapterConfigService ckService = KeycloakAdapterConfigService.getInstance();
ckService.updateRealm(operation, attributeName, resolvedValue);
hh.setHandback(ckService);
return false;
}
@Override
protected void revertUpdateToRuntime(OperationContext context, ModelNode operation, String attributeName,
ModelNode valueToRestore, ModelNode valueToRevert, KeycloakAdapterConfigService ckService) throws OperationFailedException {
ckService.updateRealm(operation, attributeName, valueToRestore);
}
}
@@ -0,0 +1,54 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.subsystem.as7;
import org.jboss.as.controller.AbstractAddStepHandler;
import org.jboss.as.controller.AttributeDefinition;
import org.jboss.as.controller.OperationContext;
import org.jboss.as.controller.OperationFailedException;
import org.jboss.as.controller.ServiceVerificationHandler;
import org.jboss.dmr.ModelNode;
import org.jboss.msc.service.ServiceController;
import java.util.List;
/**
* Add a deployment to a realm.
*
* @author Stan Silvert ssilvert@redhat.com (C) 2013 Red Hat Inc.
*/
final class SecureDeploymentAddHandler extends AbstractAddStepHandler {
public static SecureDeploymentAddHandler INSTANCE = new SecureDeploymentAddHandler();
private SecureDeploymentAddHandler() {
}
@Override
protected void populateModel(ModelNode operation, ModelNode model) throws OperationFailedException {
for (AttributeDefinition attr : SecureDeploymentDefinition.ALL_ATTRIBUTES) {
attr.validateAndSet(operation, model);
}
}
@Override
protected void performRuntime(OperationContext context, ModelNode operation, ModelNode model, ServiceVerificationHandler verificationHandler, List<ServiceController<?>> newControllers) throws OperationFailedException {
KeycloakAdapterConfigService ckService = KeycloakAdapterConfigService.getInstance();
ckService.addSecureDeployment(operation, context.resolveExpressions(model));
}
}
@@ -0,0 +1,132 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.subsystem.as7;
import org.jboss.as.controller.AttributeDefinition;
import org.jboss.as.controller.PathElement;
import org.jboss.as.controller.SimpleAttributeDefinition;
import org.jboss.as.controller.SimpleAttributeDefinitionBuilder;
import org.jboss.as.controller.SimpleResourceDefinition;
import org.jboss.as.controller.descriptions.ModelDescriptionConstants;
import org.jboss.as.controller.operations.common.GenericSubsystemDescribeHandler;
import org.jboss.as.controller.operations.validation.StringLengthValidator;
import org.jboss.as.controller.registry.ManagementResourceRegistration;
import org.jboss.as.controller.registry.OperationEntry;
import org.jboss.dmr.ModelNode;
import org.jboss.dmr.ModelType;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
/**
* Defines attributes and operations for a secure-deployment.
*
* @author Stan Silvert ssilvert@redhat.com (C) 2013 Red Hat Inc.
*/
class SecureDeploymentDefinition extends SimpleResourceDefinition {
public static final String TAG_NAME = "secure-deployment";
protected static final SimpleAttributeDefinition REALM =
new SimpleAttributeDefinitionBuilder("realm", ModelType.STRING, true)
.setXmlName("realm")
.setAllowExpression(true)
.setValidator(new StringLengthValidator(1, Integer.MAX_VALUE, true, true))
.build();
protected static final SimpleAttributeDefinition RESOURCE =
new SimpleAttributeDefinitionBuilder("resource", ModelType.STRING, true)
.setXmlName("resource")
.setAllowExpression(true)
.setValidator(new StringLengthValidator(1, Integer.MAX_VALUE, true, true))
.build();
protected static final SimpleAttributeDefinition USE_RESOURCE_ROLE_MAPPINGS =
new SimpleAttributeDefinitionBuilder("use-resource-role-mappings", ModelType.BOOLEAN, true)
.setXmlName("use-resource-role-mappings")
.setAllowExpression(true)
.setDefaultValue(new ModelNode(false))
.build();
protected static final SimpleAttributeDefinition BEARER_ONLY =
new SimpleAttributeDefinitionBuilder("bearer-only", ModelType.BOOLEAN, true)
.setXmlName("bearer-only")
.setAllowExpression(true)
.setDefaultValue(new ModelNode(false))
.build();
protected static final SimpleAttributeDefinition ENABLE_BASIC_AUTH =
new SimpleAttributeDefinitionBuilder("enable-basic-auth", ModelType.BOOLEAN, true)
.setXmlName("enable-basic-auth")
.setAllowExpression(true)
.setDefaultValue(new ModelNode(false))
.build();
protected static final SimpleAttributeDefinition PUBLIC_CLIENT =
new SimpleAttributeDefinitionBuilder("public-client", ModelType.BOOLEAN, true)
.setXmlName("public-client")
.setAllowExpression(true)
.setDefaultValue(new ModelNode(false))
.build();
protected static final List<SimpleAttributeDefinition> DEPLOYMENT_ONLY_ATTRIBUTES = new ArrayList<SimpleAttributeDefinition>();
static {
DEPLOYMENT_ONLY_ATTRIBUTES.add(REALM);
DEPLOYMENT_ONLY_ATTRIBUTES.add(RESOURCE);
DEPLOYMENT_ONLY_ATTRIBUTES.add(USE_RESOURCE_ROLE_MAPPINGS);
DEPLOYMENT_ONLY_ATTRIBUTES.add(BEARER_ONLY);
DEPLOYMENT_ONLY_ATTRIBUTES.add(ENABLE_BASIC_AUTH);
DEPLOYMENT_ONLY_ATTRIBUTES.add(PUBLIC_CLIENT);
}
protected static final List<SimpleAttributeDefinition> ALL_ATTRIBUTES = new ArrayList<SimpleAttributeDefinition>();
static {
ALL_ATTRIBUTES.addAll(DEPLOYMENT_ONLY_ATTRIBUTES);
ALL_ATTRIBUTES.addAll(SharedAttributeDefinitons.ATTRIBUTES);
}
private static final Map<String, SimpleAttributeDefinition> DEFINITION_LOOKUP = new HashMap<String, SimpleAttributeDefinition>();
static {
for (SimpleAttributeDefinition def : ALL_ATTRIBUTES) {
DEFINITION_LOOKUP.put(def.getXmlName(), def);
}
}
private static SecureDeploymentWriteAttributeHandler attrHandler = new SecureDeploymentWriteAttributeHandler(ALL_ATTRIBUTES);
public SecureDeploymentDefinition() {
super(PathElement.pathElement(TAG_NAME),
KeycloakExtension.getResourceDescriptionResolver(TAG_NAME),
SecureDeploymentAddHandler.INSTANCE,
SecureDeploymentRemoveHandler.INSTANCE);
}
@Override
public void registerOperations(ManagementResourceRegistration resourceRegistration) {
super.registerOperations(resourceRegistration);
resourceRegistration.registerOperationHandler(ModelDescriptionConstants.DESCRIBE, GenericSubsystemDescribeHandler.INSTANCE, GenericSubsystemDescribeHandler.INSTANCE, false, OperationEntry.EntryType.PRIVATE);
}
@Override
public void registerAttributes(ManagementResourceRegistration resourceRegistration) {
super.registerAttributes(resourceRegistration);
for (AttributeDefinition attrDef : ALL_ATTRIBUTES) {
resourceRegistration.registerReadWriteAttribute(attrDef, null, attrHandler);
}
}
public static SimpleAttributeDefinition lookup(String name) {
return DEFINITION_LOOKUP.get(name);
}
}
@@ -0,0 +1,41 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.subsystem.as7;
import org.jboss.as.controller.AbstractRemoveStepHandler;
import org.jboss.as.controller.OperationContext;
import org.jboss.as.controller.OperationFailedException;
import org.jboss.dmr.ModelNode;
/**
* Remove a secure-deployment from a realm.
*
* @author Stan Silvert ssilvert@redhat.com (C) 2013 Red Hat Inc.
*/
final class SecureDeploymentRemoveHandler extends AbstractRemoveStepHandler {
public static SecureDeploymentRemoveHandler INSTANCE = new SecureDeploymentRemoveHandler();
private SecureDeploymentRemoveHandler() {}
@Override
protected void performRuntime(OperationContext context, ModelNode operation, ModelNode model) throws OperationFailedException {
KeycloakAdapterConfigService ckService = KeycloakAdapterConfigService.getInstance();
ckService.removeSecureDeployment(operation);
}
}
@@ -0,0 +1,59 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.subsystem.as7;
import org.jboss.as.controller.AbstractWriteAttributeHandler;
import org.jboss.as.controller.AttributeDefinition;
import org.jboss.as.controller.OperationContext;
import org.jboss.as.controller.OperationFailedException;
import org.jboss.as.controller.SimpleAttributeDefinition;
import org.jboss.dmr.ModelNode;
import java.util.List;
/**
* Update an attribute on a secure-deployment.
*
* @author Stan Silvert ssilvert@redhat.com (C) 2013 Red Hat Inc.
*/
class SecureDeploymentWriteAttributeHandler extends AbstractWriteAttributeHandler<KeycloakAdapterConfigService> {
public SecureDeploymentWriteAttributeHandler(List<SimpleAttributeDefinition> definitions) {
this(definitions.toArray(new AttributeDefinition[definitions.size()]));
}
public SecureDeploymentWriteAttributeHandler(AttributeDefinition... definitions) {
super(definitions);
}
@Override
protected boolean applyUpdateToRuntime(OperationContext context, ModelNode operation, String attributeName,
ModelNode resolvedValue, ModelNode currentValue, HandbackHolder<KeycloakAdapterConfigService> hh) throws OperationFailedException {
KeycloakAdapterConfigService ckService = KeycloakAdapterConfigService.getInstance();
hh.setHandback(ckService);
ckService.updateSecureDeployment(operation, attributeName, resolvedValue);
return false;
}
@Override
protected void revertUpdateToRuntime(OperationContext context, ModelNode operation, String attributeName,
ModelNode valueToRestore, ModelNode valueToRevert, KeycloakAdapterConfigService ckService) throws OperationFailedException {
ckService.updateSecureDeployment(operation, attributeName, valueToRestore);
}
}
@@ -0,0 +1,227 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.subsystem.as7;
import org.jboss.as.controller.SimpleAttributeDefinition;
import org.jboss.as.controller.SimpleAttributeDefinitionBuilder;
import org.jboss.as.controller.operations.validation.IntRangeValidator;
import org.jboss.as.controller.operations.validation.StringLengthValidator;
import org.jboss.dmr.ModelNode;
import org.jboss.dmr.ModelType;
import java.util.ArrayList;
import java.util.List;
/**
* Defines attributes that can be present in both a realm and an application (secure-deployment).
*
* @author Stan Silvert ssilvert@redhat.com (C) 2013 Red Hat Inc.
*/
class SharedAttributeDefinitons {
protected static final SimpleAttributeDefinition REALM_PUBLIC_KEY =
new SimpleAttributeDefinitionBuilder("realm-public-key", ModelType.STRING, true)
.setXmlName("realm-public-key")
.setAllowExpression(true)
.setValidator(new StringLengthValidator(1, Integer.MAX_VALUE, true, true))
.build();
protected static final SimpleAttributeDefinition AUTH_SERVER_URL =
new SimpleAttributeDefinitionBuilder("auth-server-url", ModelType.STRING, true)
.setXmlName("auth-server-url")
.setAllowExpression(true)
.setValidator(new StringLengthValidator(1, Integer.MAX_VALUE, true, true))
.build();
protected static final SimpleAttributeDefinition SSL_REQUIRED =
new SimpleAttributeDefinitionBuilder("ssl-required", ModelType.STRING, true)
.setXmlName("ssl-required")
.setAllowExpression(true)
.setDefaultValue(new ModelNode("external"))
.build();
protected static final SimpleAttributeDefinition ALLOW_ANY_HOSTNAME =
new SimpleAttributeDefinitionBuilder("allow-any-hostname", ModelType.BOOLEAN, true)
.setXmlName("allow-any-hostname")
.setAllowExpression(true)
.setDefaultValue(new ModelNode(false))
.build();
protected static final SimpleAttributeDefinition DISABLE_TRUST_MANAGER =
new SimpleAttributeDefinitionBuilder("disable-trust-manager", ModelType.BOOLEAN, true)
.setXmlName("disable-trust-manager")
.setAllowExpression(true)
.setDefaultValue(new ModelNode(false))
.build();
protected static final SimpleAttributeDefinition TRUSTSTORE =
new SimpleAttributeDefinitionBuilder("truststore", ModelType.STRING, true)
.setXmlName("truststore")
.setAllowExpression(true)
.setValidator(new StringLengthValidator(1, Integer.MAX_VALUE, true, true))
.build();
protected static final SimpleAttributeDefinition TRUSTSTORE_PASSWORD =
new SimpleAttributeDefinitionBuilder("truststore-password", ModelType.STRING, true)
.setXmlName("truststore-password")
.setAllowExpression(true)
.setValidator(new StringLengthValidator(1, Integer.MAX_VALUE, true, true))
.build();
protected static final SimpleAttributeDefinition CONNECTION_POOL_SIZE =
new SimpleAttributeDefinitionBuilder("connection-pool-size", ModelType.INT, true)
.setXmlName("connection-pool-size")
.setAllowExpression(true)
.setValidator(new IntRangeValidator(0, true))
.build();
protected static final SimpleAttributeDefinition ENABLE_CORS =
new SimpleAttributeDefinitionBuilder("enable-cors", ModelType.BOOLEAN, true)
.setXmlName("enable-cors")
.setAllowExpression(true)
.setDefaultValue(new ModelNode(false))
.build();
protected static final SimpleAttributeDefinition CLIENT_KEYSTORE =
new SimpleAttributeDefinitionBuilder("client-keystore", ModelType.STRING, true)
.setXmlName("client-keystore")
.setAllowExpression(true)
.setValidator(new StringLengthValidator(1, Integer.MAX_VALUE, true, true))
.build();
protected static final SimpleAttributeDefinition CLIENT_KEYSTORE_PASSWORD =
new SimpleAttributeDefinitionBuilder("client-keystore-password", ModelType.STRING, true)
.setXmlName("client-keystore-password")
.setAllowExpression(true)
.setValidator(new StringLengthValidator(1, Integer.MAX_VALUE, true, true))
.build();
protected static final SimpleAttributeDefinition CLIENT_KEY_PASSWORD =
new SimpleAttributeDefinitionBuilder("client-key-password", ModelType.STRING, true)
.setXmlName("client-key-password")
.setAllowExpression(true)
.setValidator(new StringLengthValidator(1, Integer.MAX_VALUE, true, true))
.build();
protected static final SimpleAttributeDefinition CORS_MAX_AGE =
new SimpleAttributeDefinitionBuilder("cors-max-age", ModelType.INT, true)
.setXmlName("cors-max-age")
.setAllowExpression(true)
.setValidator(new IntRangeValidator(-1, true))
.build();
protected static final SimpleAttributeDefinition CORS_ALLOWED_HEADERS =
new SimpleAttributeDefinitionBuilder("cors-allowed-headers", ModelType.STRING, true)
.setXmlName("cors-allowed-headers")
.setAllowExpression(true)
.setValidator(new StringLengthValidator(1, Integer.MAX_VALUE, true, true))
.build();
protected static final SimpleAttributeDefinition CORS_ALLOWED_METHODS =
new SimpleAttributeDefinitionBuilder("cors-allowed-methods", ModelType.STRING, true)
.setAllowExpression(true)
.setValidator(new StringLengthValidator(1, Integer.MAX_VALUE, true, true))
.build();
protected static final SimpleAttributeDefinition EXPOSE_TOKEN =
new SimpleAttributeDefinitionBuilder("expose-token", ModelType.BOOLEAN, true)
.setXmlName("expose-token")
.setAllowExpression(true)
.setDefaultValue(new ModelNode(false))
.build();
protected static final SimpleAttributeDefinition AUTH_SERVER_URL_FOR_BACKEND_REQUESTS =
new SimpleAttributeDefinitionBuilder("auth-server-url-for-backend-requests", ModelType.STRING, true)
.setXmlName("auth-server-url-for-backend-requests")
.setAllowExpression(true)
.setValidator(new StringLengthValidator(1, Integer.MAX_VALUE, true, true))
.build();
protected static final SimpleAttributeDefinition ALWAYS_REFRESH_TOKEN =
new SimpleAttributeDefinitionBuilder("always-refresh-token", ModelType.BOOLEAN, true)
.setXmlName("always-refresh-token")
.setAllowExpression(true)
.setDefaultValue(new ModelNode(false))
.build();
protected static final SimpleAttributeDefinition REGISTER_NODE_AT_STARTUP =
new SimpleAttributeDefinitionBuilder("register-node-at-startup", ModelType.BOOLEAN, true)
.setXmlName("register-node-at-startup")
.setAllowExpression(true)
.setDefaultValue(new ModelNode(false))
.build();
protected static final SimpleAttributeDefinition REGISTER_NODE_PERIOD =
new SimpleAttributeDefinitionBuilder("register-node-period", ModelType.INT, true)
.setXmlName("register-node-period")
.setAllowExpression(true)
.setValidator(new IntRangeValidator(-1, true))
.build();
protected static final SimpleAttributeDefinition TOKEN_STORE =
new SimpleAttributeDefinitionBuilder("token-store", ModelType.STRING, true)
.setXmlName("token-store")
.setAllowExpression(true)
.setValidator(new StringLengthValidator(1, Integer.MAX_VALUE, true, true))
.build();
protected static final SimpleAttributeDefinition PRINCIPAL_ATTRIBUTE =
new SimpleAttributeDefinitionBuilder("principal-attribute", ModelType.STRING, true)
.setXmlName("principal-attribute")
.setAllowExpression(true)
.setValidator(new StringLengthValidator(1, Integer.MAX_VALUE, true, true))
.build();
protected static final List<SimpleAttributeDefinition> ATTRIBUTES = new ArrayList<SimpleAttributeDefinition>();
static {
ATTRIBUTES.add(REALM_PUBLIC_KEY);
ATTRIBUTES.add(AUTH_SERVER_URL);
ATTRIBUTES.add(TRUSTSTORE);
ATTRIBUTES.add(TRUSTSTORE_PASSWORD);
ATTRIBUTES.add(SSL_REQUIRED);
ATTRIBUTES.add(ALLOW_ANY_HOSTNAME);
ATTRIBUTES.add(DISABLE_TRUST_MANAGER);
ATTRIBUTES.add(CONNECTION_POOL_SIZE);
ATTRIBUTES.add(ENABLE_CORS);
ATTRIBUTES.add(CLIENT_KEYSTORE);
ATTRIBUTES.add(CLIENT_KEYSTORE_PASSWORD);
ATTRIBUTES.add(CLIENT_KEY_PASSWORD);
ATTRIBUTES.add(CORS_MAX_AGE);
ATTRIBUTES.add(CORS_ALLOWED_HEADERS);
ATTRIBUTES.add(CORS_ALLOWED_METHODS);
ATTRIBUTES.add(EXPOSE_TOKEN);
ATTRIBUTES.add(AUTH_SERVER_URL_FOR_BACKEND_REQUESTS);
ATTRIBUTES.add(ALWAYS_REFRESH_TOKEN);
ATTRIBUTES.add(REGISTER_NODE_AT_STARTUP);
ATTRIBUTES.add(REGISTER_NODE_PERIOD);
ATTRIBUTES.add(TOKEN_STORE);
ATTRIBUTES.add(PRINCIPAL_ATTRIBUTE);
}
/**
* truststore and truststore-password must be set if ssl-required is not none and disable-trust-manager is false.
*
* @param attributes The full set of attributes.
*
* @return <code>true</code> if the attributes are valid, <code>false</code> otherwise.
*/
public static boolean validateTruststoreSetIfRequired(ModelNode attributes) {
if (isSet(attributes, DISABLE_TRUST_MANAGER)) {
return true;
}
if (isSet(attributes, SSL_REQUIRED) && attributes.get(SSL_REQUIRED.getName()).asString().equals("none")) {
return true;
}
//TODO, look into alternatives & requires properties on AttributeDefinition
return isSet(attributes, TRUSTSTORE) && isSet(attributes, TRUSTSTORE_PASSWORD);
}
private static boolean isSet(ModelNode attributes, SimpleAttributeDefinition def) {
ModelNode attribute = attributes.get(def.getName());
if (def.getType() == ModelType.BOOLEAN) {
return attribute.isDefined() && attribute.asBoolean();
}
return attribute.isDefined() && !attribute.asString().isEmpty();
}
}
@@ -0,0 +1,59 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.subsystem.as7;
import org.jboss.as.controller.PathAddress;
import org.jboss.as.controller.descriptions.ModelDescriptionConstants;
import org.jboss.dmr.ModelNode;
import static org.jboss.as.controller.descriptions.ModelDescriptionConstants.OP;
import static org.jboss.as.controller.descriptions.ModelDescriptionConstants.OP_ADDR;
/**
* @author <a href="mailto:bill@burkecentral.com">Bill Burke</a>
* @version $Revision: 1 $
*/
public class Util {
public static ModelNode createAddOperation(final PathAddress address) {
return createOperation(ModelDescriptionConstants.ADD, address);
}
public static ModelNode createAddOperation() {
return createEmptyOperation(ModelDescriptionConstants.ADD, null);
}
public static ModelNode createRemoveOperation(final PathAddress address) {
return createOperation(ModelDescriptionConstants.REMOVE, address);
}
public static ModelNode createOperation(final String operationName, final PathAddress address) {
return createEmptyOperation(operationName, address);
}
public static ModelNode createEmptyOperation(String operationName, final PathAddress address) {
ModelNode op = new ModelNode();
op.get(OP).set(operationName);
if (address != null) {
op.get(OP_ADDR).set(address.toModelNode());
} else {
// Just establish the standard structure; caller can fill in address later
op.get(OP_ADDR);
}
return op;
}
}
@@ -0,0 +1,49 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.subsystem.as7.logging;
import org.jboss.logging.BasicLogger;
import org.jboss.logging.LogMessage;
import org.jboss.logging.Logger;
import org.jboss.logging.Message;
import org.jboss.logging.MessageLogger;
import static org.jboss.logging.Logger.Level.DEBUG;
import static org.jboss.logging.Logger.Level.INFO;
/**
* This interface to be fleshed out later when error messages are fully externalized.
*
* @author Stan Silvert ssilvert@redhat.com (C) 2013 Red Hat Inc.
*/
@MessageLogger(projectCode = "KEYCLOAK")
public interface KeycloakLogger extends BasicLogger {
/**
* A logger with a category of the package name.
*/
KeycloakLogger ROOT_LOGGER = Logger.getMessageLogger(KeycloakLogger.class, "org.jboss.keycloak");
@LogMessage(level = INFO)
@Message(value = "Keycloak subsystem override for deployment %s")
void deploymentSecured(String deployment);
@LogMessage(level = DEBUG)
@Message(value = "Keycloak has overriden and secured deployment %s")
void warSecured(String deployment);
}
@@ -0,0 +1,34 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.subsystem.as7.logging;
import org.jboss.logging.MessageBundle;
import org.jboss.logging.Messages;
/**
* This interface to be fleshed out later when error messages are fully externalized.
*
* @author Stan Silvert ssilvert@redhat.com (C) 2012 Red Hat Inc.
*/
@MessageBundle(projectCode = "TLIP")
public interface KeycloakMessages {
/**
* The messages
*/
KeycloakMessages MESSAGES = Messages.getBundle(KeycloakMessages.class);
}
@@ -0,0 +1,18 @@
#
# Copyright 2016 Red Hat, Inc. and/or its affiliates
# and other contributors as indicated by the @author tags.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
org.keycloak.subsystem.as7.KeycloakExtension
@@ -0,0 +1,89 @@
#
# Copyright 2016 Red Hat, Inc. and/or its affiliates
# and other contributors as indicated by the @author tags.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
keycloak.subsystem=Keycloak adapter subsystem
keycloak.subsystem.add=Operation Adds Keycloak adapter subsystem
keycloak.subsystem.remove=Operation removes Keycloak adapter subsystem
keycloak.subsystem.realm=A Keycloak realm.
keycloak.subsystem.secure-deployment=A deployment secured by Keycloak.
keycloak.realm=A Keycloak realm.
keycloak.realm.add=Add a realm definition to the subsystem.
keycloak.realm.remove=Remove a realm from the subsystem.
keycloak.realm.realm-public-key=Public key of the realm
keycloak.realm.auth-server-url=Base URL of the Realm Auth Server
keycloak.realm.disable-trust-manager=Adapter will not use a trust manager when making adapter HTTPS requests
keycloak.realm.ssl-required=Specify if SSL is required (valid values are all, external and none)
keycloak.realm.allow-any-hostname=SSL Setting
keycloak.realm.truststore=Truststore used for adapter client HTTPS requests
keycloak.realm.truststore-password=Password of the Truststore
keycloak.realm.connection-pool-size=Connection pool size for the client used by the adapter
keycloak.realm.enable-cors=Enable Keycloak CORS support
keycloak.realm.client-keystore=n/a
keycloak.realm.client-keystore-password=n/a
keycloak.realm.client-key-password=n/a
keycloak.realm.cors-max-age=CORS max-age header
keycloak.realm.cors-allowed-headers=CORS allowed headers
keycloak.realm.cors-allowed-methods=CORS allowed methods
keycloak.realm.expose-token=Enable secure URL that exposes access token
keycloak.realm.auth-server-url-for-backend-requests=URL to use to make background calls to auth server
keycloak.realm.always-refresh-token=Refresh token on every single web request
keycloak.realm.register-node-at-startup=Cluster setting
keycloak.realm.register-node-period=how often to re-register node
keycloak.realm.token-store=cookie or session storage for auth session data
keycloak.realm.principal-attribute=token attribute to use to set Principal name
keycloak.secure-deployment=A deployment secured by Keycloak
keycloak.secure-deployment.add=Add a deployment to be secured by Keycloak
keycloak.secure-deployment.realm=Keycloak realm
keycloak.secure-deployment.remove=Remove a deployment to be secured by Keycloak
keycloak.secure-deployment.realm-public-key=Public key of the realm
keycloak.secure-deployment.auth-server-url=Base URL of the Realm Auth Server
keycloak.secure-deployment.disable-trust-manager=Adapter will not use a trust manager when making adapter HTTPS requests
keycloak.secure-deployment.ssl-required=Specify if SSL is required (valid values are all, external and none)
keycloak.secure-deployment.allow-any-hostname=SSL Setting
keycloak.secure-deployment.truststore=Truststore used for adapter client HTTPS requests
keycloak.secure-deployment.truststore-password=Password of the Truststore
keycloak.secure-deployment.connection-pool-size=Connection pool size for the client used by the adapter
keycloak.secure-deployment.resource=Application name
keycloak.secure-deployment.use-resource-role-mappings=Use resource level permissions from token
keycloak.secure-deployment.credentials=Adapter credentials
keycloak.secure-deployment.bearer-only=Bearer Token Auth only
keycloak.secure-deployment.enable-basic-auth=Enable Basic Authentication
keycloak.secure-deployment.public-client=Public client
keycloak.secure-deployment.enable-cors=Enable Keycloak CORS support
keycloak.secure-deployment.client-keystore=n/a
keycloak.secure-deployment.client-keystore-password=n/a
keycloak.secure-deployment.client-key-password=n/a
keycloak.secure-deployment.cors-max-age=CORS max-age header
keycloak.secure-deployment.cors-allowed-headers=CORS allowed headers
keycloak.secure-deployment.cors-allowed-methods=CORS allowed methods
keycloak.secure-deployment.expose-token=Enable secure URL that exposes access token
keycloak.secure-deployment.auth-server-url-for-backend-requests=URL to use to make background calls to auth server
keycloak.secure-deployment.always-refresh-token=Refresh token on every single web request
keycloak.secure-deployment.register-node-at-startup=Cluster setting
keycloak.secure-deployment.register-node-period=how often to re-register node
keycloak.secure-deployment.token-store=cookie or session storage for auth session data
keycloak.secure-deployment.principal-attribute=token attribute to use to set Principal name
keycloak.secure-deployment.turn-off-change-session-id-on-login=The session id is changed by default on a successful login. Change this to true if you want to turn this off
keycloak.secure-deployment.credential=Credential value
keycloak.credential=Credential
keycloak.credential.value=Credential value
keycloak.credential.add=Credential add
keycloak.credential.remove=Credential remove
@@ -1,5 +1,22 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
~ Copyright 2016 Red Hat, Inc. and/or its affiliates
~ and other contributors as indicated by the @author tags.
~
~ Licensed under the Apache License, Version 2.0 (the "License");
~ you may not use this file except in compliance with the License.
~ You may obtain a copy of the License at
~
~ http://www.apache.org/licenses/LICENSE-2.0
~
~ Unless required by applicable law or agreed to in writing, software
~ distributed under the License is distributed on an "AS IS" BASIS,
~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
~ See the License for the specific language governing permissions and
~ limitations under the License.
-->
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
targetNamespace="urn:jboss:domain:keycloak:1.1"
xmlns="urn:jboss:domain:keycloak:1.1"
@@ -87,6 +104,7 @@
<xs:element name="token-store" type="xs:string" minOccurs="0" maxOccurs="1"/>
<xs:element name="principal-attribute" type="xs:string" minOccurs="0" maxOccurs="1"/>
<xs:element name="enable-basic-auth" type="xs:boolean" minOccurs="0" maxOccurs="1"/>
<xs:element name="turn-off-change-session-id-on-login" type="xs:boolean" minOccurs="0" maxOccurs="1" />
</xs:all>
<xs:attribute name="name" type="xs:string" use="required">
<xs:annotation>
@@ -0,0 +1,88 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.subsystem.as7;
import org.jboss.dmr.ModelNode;
import org.junit.Assert;
import org.junit.Before;
import org.junit.Test;
/**
*
* @author Stan Silvert ssilvert@redhat.com (C) 2013 Red Hat Inc.
*/
public class RealmDefinitionTestCase {
private ModelNode model;
@Before
public void setUp() {
model = new ModelNode();
model.get("realm").set("demo");
model.get("resource").set("customer-portal");
model.get("realm-public-key").set("MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQCrVrCuTtArbgaZzL1hvh0xtL5mc7o0NqPVnYXkLvgcwiC3BjLGw1tGEGoJaXDuSaRllobm53JBhjx33UNv+5z/UMG4kytBWxheNVKnL6GgqlNabMaFfPLPCF8kAgKnsi79NMo+n6KnSY8YeUmec/p2vjO2NjsSAVcWEQMVhJ31LwIDAQAB");
model.get("auth-url").set("http://localhost:8080/auth-server/realms/demo/protocol/openid-connect/login");
model.get("code-url").set("http://localhost:8080/auth-server/realms/demo/protocol/openid-connect/access/codes");
model.get("expose-token").set(true);
ModelNode credential = new ModelNode();
credential.get("password").set("password");
model.get("credentials").set(credential);
}
@Test
public void testIsTruststoreSetIfRequired() throws Exception {
model.get("ssl-required").set("none");
model.get("disable-trust-manager").set(true);
Assert.assertTrue(SharedAttributeDefinitons.validateTruststoreSetIfRequired(model));
model.get("ssl-required").set("none");
model.get("disable-trust-manager").set(false);
Assert.assertTrue(SharedAttributeDefinitons.validateTruststoreSetIfRequired(model));
model.get("ssl-required").set("all");
model.get("disable-trust-manager").set(true);
Assert.assertTrue(SharedAttributeDefinitons.validateTruststoreSetIfRequired(model));
model.get("ssl-required").set("all");
model.get("disable-trust-manager").set(false);
Assert.assertFalse(SharedAttributeDefinitons.validateTruststoreSetIfRequired(model));
model.get("ssl-required").set("external");
model.get("disable-trust-manager").set(false);
Assert.assertFalse(SharedAttributeDefinitons.validateTruststoreSetIfRequired(model));
model.get("ssl-required").set("all");
model.get("disable-trust-manager").set(false);
model.get("truststore").set("foo");
Assert.assertFalse(SharedAttributeDefinitons.validateTruststoreSetIfRequired(model));
model.get("ssl-required").set("all");
model.get("disable-trust-manager").set(false);
model.get("truststore").set("foo");
model.get("truststore-password").set("password");
Assert.assertTrue(SharedAttributeDefinitons.validateTruststoreSetIfRequired(model));
model.get("ssl-required").set("external");
model.get("disable-trust-manager").set(false);
model.get("truststore").set("foo");
model.get("truststore-password").set("password");
Assert.assertTrue(SharedAttributeDefinitons.validateTruststoreSetIfRequired(model));
}
}
+38
View File
@@ -0,0 +1,38 @@
<!--
~ Copyright 2016 Red Hat, Inc. and/or its affiliates
~ and other contributors as indicated by the @author tags.
~
~ Licensed under the Apache License, Version 2.0 (the "License");
~ you may not use this file except in compliance with the License.
~ You may obtain a copy of the License at
~
~ http://www.apache.org/licenses/LICENSE-2.0
~
~ Unless required by applicable law or agreed to in writing, software
~ distributed under the License is distributed on an "AS IS" BASIS,
~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
~ See the License for the specific language governing permissions and
~ limitations under the License.
-->
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<parent>
<artifactId>keycloak-parent</artifactId>
<groupId>org.keycloak</groupId>
<version>1.9.5.Final</version>
<relativePath>../../../pom.xml</relativePath>
</parent>
<name>Keycloak AS7 / JBoss EAP 6 Integration</name>
<description/>
<modelVersion>4.0.0</modelVersion>
<artifactId>keycloak-as7-integration-pom</artifactId>
<packaging>pom</packaging>
<modules>
<module>as7-adapter-spi</module>
<module>as7-adapter</module>
<module>as7-subsystem</module>
</modules>
</project>
+81
View File
@@ -0,0 +1,81 @@
<?xml version="1.0"?>
<!--
~ Copyright 2016 Red Hat, Inc. and/or its affiliates
~ and other contributors as indicated by the @author tags.
~
~ Licensed under the Apache License, Version 2.0 (the "License");
~ you may not use this file except in compliance with the License.
~ You may obtain a copy of the License at
~
~ http://www.apache.org/licenses/LICENSE-2.0
~
~ Unless required by applicable law or agreed to in writing, software
~ distributed under the License is distributed on an "AS IS" BASIS,
~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
~ See the License for the specific language governing permissions and
~ limitations under the License.
-->
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<parent>
<artifactId>keycloak-parent</artifactId>
<groupId>org.keycloak</groupId>
<version>1.9.5.Final</version>
<relativePath>../../../pom.xml</relativePath>
</parent>
<modelVersion>4.0.0</modelVersion>
<artifactId>keycloak-installed-adapter</artifactId>
<name>Keycloak Installed Application</name>
<description/>
<dependencies>
<dependency>
<groupId>org.keycloak</groupId>
<artifactId>keycloak-core</artifactId>
</dependency>
<dependency>
<groupId>org.keycloak</groupId>
<artifactId>keycloak-adapter-spi</artifactId>
</dependency>
<dependency>
<groupId>org.keycloak</groupId>
<artifactId>keycloak-adapter-core</artifactId>
</dependency>
<dependency>
<groupId>org.bouncycastle</groupId>
<artifactId>bcprov-jdk15on</artifactId>
</dependency>
<dependency>
<groupId>org.apache.httpcomponents</groupId>
<artifactId>httpclient</artifactId>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-core</artifactId>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-databind</artifactId>
</dependency>
<dependency>
<groupId>org.jboss.logging</groupId>
<artifactId>jboss-logging</artifactId>
</dependency>
</dependencies>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<source>${maven.compiler.source}</source>
<target>${maven.compiler.target}</target>
</configuration>
</plugin>
</plugins>
</build>
</project>
@@ -1,13 +1,31 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.adapters.installed;
import org.keycloak.OAuth2Constants;
import org.keycloak.OAuthErrorException;
import org.keycloak.RSATokenVerifier;
import org.keycloak.VerificationException;
import org.keycloak.common.VerificationException;
import org.keycloak.adapters.KeycloakDeployment;
import org.keycloak.adapters.KeycloakDeploymentBuilder;
import org.keycloak.adapters.ServerRequest;
import org.keycloak.jose.jws.JWSInput;
import org.keycloak.jose.jws.JWSInputException;
import org.keycloak.representations.AccessToken;
import org.keycloak.representations.AccessTokenResponse;
import org.keycloak.representations.IDToken;
@@ -195,10 +213,10 @@ public class KeycloakInstalled {
token = RSATokenVerifier.verifyToken(tokenString, deployment.getRealmKey(), deployment.getRealmInfoUrl());
if (idTokenString != null) {
JWSInput input = new JWSInput(idTokenString);
try {
JWSInput input = new JWSInput(idTokenString);
idToken = input.readJsonContent(IDToken.class);
} catch (IOException e) {
} catch (JWSInputException e) {
throw new VerificationException();
}
}
+103
View File
@@ -0,0 +1,103 @@
<?xml version="1.0"?>
<!--
~ Copyright 2016 Red Hat, Inc. and/or its affiliates
~ and other contributors as indicated by the @author tags.
~
~ Licensed under the Apache License, Version 2.0 (the "License");
~ you may not use this file except in compliance with the License.
~ You may obtain a copy of the License at
~
~ http://www.apache.org/licenses/LICENSE-2.0
~
~ Unless required by applicable law or agreed to in writing, software
~ distributed under the License is distributed on an "AS IS" BASIS,
~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
~ See the License for the specific language governing permissions and
~ limitations under the License.
-->
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<parent>
<artifactId>keycloak-parent</artifactId>
<groupId>org.keycloak</groupId>
<version>1.9.5.Final</version>
<relativePath>../../../pom.xml</relativePath>
</parent>
<modelVersion>4.0.0</modelVersion>
<artifactId>keycloak-jaxrs-oauth-client</artifactId>
<name>Keycloak JAX-RS OAuth Client</name>
<description/>
<dependencies>
<dependency>
<groupId>org.jboss.spec.javax.ws.rs</groupId>
<artifactId>jboss-jaxrs-api_2.0_spec</artifactId>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.jboss.resteasy</groupId>
<artifactId>resteasy-client</artifactId>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.keycloak</groupId>
<artifactId>keycloak-core</artifactId>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.keycloak</groupId>
<artifactId>keycloak-adapter-spi</artifactId>
</dependency>
<dependency>
<groupId>org.keycloak</groupId>
<artifactId>keycloak-adapter-core</artifactId>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-core</artifactId>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-databind</artifactId>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.jboss.resteasy</groupId>
<artifactId>resteasy-jackson2-provider</artifactId>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.jboss.spec.javax.servlet</groupId>
<artifactId>jboss-servlet-api_3.0_spec</artifactId>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.osgi</groupId>
<artifactId>org.osgi.core</artifactId>
<scope>provided</scope>
</dependency>
</dependencies>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<source>${maven.compiler.source}</source>
<target>${maven.compiler.target}</target>
</configuration>
</plugin>
</plugins>
</build>
</project>
@@ -0,0 +1,31 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.jaxrs;
import javax.annotation.Priority;
import javax.ws.rs.Priorities;
import javax.ws.rs.container.ContainerRequestFilter;
import javax.ws.rs.container.PreMatching;
/**
* @author <a href="mailto:mposolda@redhat.com">Marek Posolda</a>
*/
@PreMatching
@Priority(Priorities.AUTHENTICATION)
public interface JaxrsBearerTokenFilter extends ContainerRequestFilter {
}
@@ -1,10 +1,27 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.jaxrs;
import org.keycloak.KeycloakPrincipal;
import org.keycloak.adapters.AdapterDeploymentContext;
import org.keycloak.adapters.AdapterUtils;
import org.keycloak.adapters.AuthChallenge;
import org.keycloak.adapters.AuthOutcome;
import org.keycloak.adapters.spi.AuthChallenge;
import org.keycloak.adapters.spi.AuthOutcome;
import org.keycloak.adapters.AuthenticatedActionsHandler;
import org.keycloak.adapters.BasicAuthRequestAuthenticator;
import org.keycloak.adapters.BearerTokenRequestAuthenticator;
@@ -14,8 +31,8 @@ import org.keycloak.adapters.KeycloakDeploymentBuilder;
import org.keycloak.adapters.NodesRegistrationManagement;
import org.keycloak.adapters.PreAuthActionsHandler;
import org.keycloak.adapters.RefreshableKeycloakSecurityContext;
import org.keycloak.adapters.UserSessionManagement;
import org.keycloak.constants.GenericConstants;
import org.keycloak.adapters.spi.UserSessionManagement;
import org.keycloak.common.constants.GenericConstants;
import javax.annotation.Priority;
import javax.ws.rs.Priorities;
@@ -0,0 +1,214 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.jaxrs;
import java.io.InputStream;
import java.io.OutputStream;
import java.util.List;
import java.util.Map;
import javax.security.cert.X509Certificate;
import javax.ws.rs.container.ContainerRequestContext;
import javax.ws.rs.core.MultivaluedMap;
import javax.ws.rs.core.SecurityContext;
import org.keycloak.KeycloakSecurityContext;
import org.keycloak.adapters.OIDCHttpFacade;
import org.keycloak.adapters.spi.AuthenticationError;
import org.keycloak.adapters.spi.LogoutError;
import org.keycloak.common.util.HostUtils;
/**
* @author <a href="mailto:mposolda@redhat.com">Marek Posolda</a>
*/
public class JaxrsHttpFacade implements OIDCHttpFacade {
protected final ContainerRequestContext requestContext;
protected final SecurityContext securityContext;
protected final RequestFacade requestFacade = new RequestFacade();
protected final ResponseFacade responseFacade = new ResponseFacade();
protected KeycloakSecurityContext keycloakSecurityContext;
protected boolean responseFinished;
public JaxrsHttpFacade(ContainerRequestContext containerRequestContext, SecurityContext securityContext) {
this.requestContext = containerRequestContext;
this.securityContext = securityContext;
}
protected class RequestFacade implements OIDCHttpFacade.Request {
@Override
public String getFirstParam(String param) {
throw new RuntimeException("NOT IMPLEMENTED");
}
@Override
public String getMethod() {
return requestContext.getMethod();
}
@Override
public String getURI() {
return requestContext.getUriInfo().getRequestUri().toString();
}
@Override
public boolean isSecure() {
return securityContext.isSecure();
}
@Override
public String getQueryParamValue(String param) {
MultivaluedMap<String, String> queryParams = requestContext.getUriInfo().getQueryParameters();
if (queryParams == null)
return null;
return queryParams.getFirst(param);
}
@Override
public Cookie getCookie(String cookieName) {
Map<String, javax.ws.rs.core.Cookie> cookies = requestContext.getCookies();
if (cookies == null)
return null;
javax.ws.rs.core.Cookie cookie = cookies.get(cookieName);
if (cookie == null)
return null;
return new Cookie(cookie.getName(), cookie.getValue(), cookie.getVersion(), cookie.getDomain(), cookie.getPath());
}
@Override
public String getHeader(String name) {
return requestContext.getHeaderString(name);
}
@Override
public List<String> getHeaders(String name) {
MultivaluedMap<String, String> headers = requestContext.getHeaders();
return (headers == null) ? null : headers.get(name);
}
@Override
public InputStream getInputStream() {
return requestContext.getEntityStream();
}
@Override
public String getRemoteAddr() {
// TODO: implement properly
return HostUtils.getIpAddress();
}
@Override
public void setError(AuthenticationError error) {
requestContext.setProperty(AuthenticationError.class.getName(), error);
}
@Override
public void setError(LogoutError error) {
requestContext.setProperty(LogoutError.class.getName(), error);
}
}
protected class ResponseFacade implements OIDCHttpFacade.Response {
private javax.ws.rs.core.Response.ResponseBuilder responseBuilder = javax.ws.rs.core.Response.status(204);
@Override
public void setStatus(int status) {
responseBuilder.status(status);
}
@Override
public void addHeader(String name, String value) {
responseBuilder.header(name, value);
}
@Override
public void setHeader(String name, String value) {
responseBuilder.header(name, value);
}
@Override
public void resetCookie(String name, String path) {
// For now doesn't need to be supported
throw new IllegalStateException("Not supported yet");
}
@Override
public void setCookie(String name, String value, String path, String domain, int maxAge, boolean secure, boolean httpOnly) {
// For now doesn't need to be supported
throw new IllegalStateException("Not supported yet");
}
@Override
public OutputStream getOutputStream() {
// For now doesn't need to be supported
throw new IllegalStateException("Not supported yet");
}
@Override
public void sendError(int code) {
javax.ws.rs.core.Response response = responseBuilder.status(code).build();
requestContext.abortWith(response);
responseFinished = true;
}
@Override
public void sendError(int code, String message) {
javax.ws.rs.core.Response response = responseBuilder.status(code).entity(message).build();
requestContext.abortWith(response);
responseFinished = true;
}
@Override
public void end() {
javax.ws.rs.core.Response response = responseBuilder.build();
requestContext.abortWith(response);
responseFinished = true;
}
}
@Override
public KeycloakSecurityContext getSecurityContext() {
return keycloakSecurityContext;
}
public void setSecurityContext(KeycloakSecurityContext securityContext) {
this.keycloakSecurityContext = securityContext;
}
@Override
public Request getRequest() {
return requestFacade;
}
@Override
public Response getResponse() {
return responseFacade;
}
@Override
public X509Certificate[] getCertificateChain() {
throw new IllegalStateException("Not supported yet");
}
public boolean isResponseFinished() {
return responseFinished;
}
}
@@ -1,3 +1,20 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.jaxrs;
import org.keycloak.AbstractOAuthClient;
@@ -1,3 +1,20 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.jaxrs;
import java.io.IOException;
@@ -10,7 +27,7 @@ import javax.ws.rs.Priorities;
import javax.ws.rs.container.PreMatching;
import org.keycloak.adapters.KeycloakConfigResolver;
import org.keycloak.constants.GenericConstants;
import org.keycloak.common.constants.GenericConstants;
import org.osgi.framework.BundleContext;
/**
+160
View File
@@ -0,0 +1,160 @@
<?xml version="1.0"?>
<!--
~ Copyright 2016 Red Hat, Inc. and/or its affiliates
~ and other contributors as indicated by the @author tags.
~
~ Licensed under the Apache License, Version 2.0 (the "License");
~ you may not use this file except in compliance with the License.
~ You may obtain a copy of the License at
~
~ http://www.apache.org/licenses/LICENSE-2.0
~
~ Unless required by applicable law or agreed to in writing, software
~ distributed under the License is distributed on an "AS IS" BASIS,
~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
~ See the License for the specific language governing permissions and
~ limitations under the License.
-->
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<parent>
<artifactId>keycloak-parent</artifactId>
<groupId>org.keycloak</groupId>
<version>1.9.5.Final</version>
<relativePath>../../../../pom.xml</relativePath>
</parent>
<modelVersion>4.0.0</modelVersion>
<artifactId>keycloak-jetty-core</artifactId>
<name>Keycloak Jetty Core Integration</name>
<properties>
<jetty9.version>8.1.17.v20150415</jetty9.version>
<keycloak.osgi.export>
org.keycloak.adapters.jetty.core.*
</keycloak.osgi.export>
<keycloak.osgi.import>
org.eclipse.jetty.*;version="[8.1,10)";resolution:=optional,
javax.servlet.*;version="[2.5,4)";resolution:=optional,
org.keycloak.*;version="${project.version}",
*;resolution:=optional
</keycloak.osgi.import>
</properties>
<description />
<dependencies>
<dependency>
<groupId>org.jboss.logging</groupId>
<artifactId>jboss-logging</artifactId>
<version>${jboss.logging.version}</version>
</dependency>
<dependency>
<groupId>org.keycloak</groupId>
<artifactId>keycloak-core</artifactId>
</dependency>
<dependency>
<groupId>org.keycloak</groupId>
<artifactId>keycloak-adapter-spi</artifactId>
</dependency>
<dependency>
<groupId>org.keycloak</groupId>
<artifactId>keycloak-jetty-adapter-spi</artifactId>
</dependency>
<dependency>
<groupId>org.keycloak</groupId>
<artifactId>keycloak-adapter-core</artifactId>
</dependency>
<dependency>
<groupId>org.apache.httpcomponents</groupId>
<artifactId>httpclient</artifactId>
</dependency>
<dependency>
<groupId>org.bouncycastle</groupId>
<artifactId>bcprov-jdk15on</artifactId>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-core</artifactId>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-databind</artifactId>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-annotations</artifactId>
</dependency>
<dependency>
<groupId>org.eclipse.jetty</groupId>
<artifactId>jetty-server</artifactId>
<version>${jetty9.version}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.eclipse.jetty</groupId>
<artifactId>jetty-util</artifactId>
<version>${jetty9.version}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.eclipse.jetty</groupId>
<artifactId>jetty-security</artifactId>
<version>${jetty9.version}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<scope>test</scope>
</dependency>
</dependencies>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<source>1.6</source>
<target>1.6</target>
</configuration>
</plugin>
<!-- Adding OSGI metadata to the JAR without changing the packaging type. -->
<plugin>
<artifactId>maven-jar-plugin</artifactId>
<configuration>
<archive>
<manifestFile>${project.build.outputDirectory}/META-INF/MANIFEST.MF</manifestFile>
</archive>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.felix</groupId>
<artifactId>maven-bundle-plugin</artifactId>
<extensions>true</extensions>
<executions>
<execution>
<id>bundle-manifest</id>
<phase>process-classes</phase>
<goals>
<goal>manifest</goal>
</goals>
</execution>
</executions>
<configuration>
<instructions>
<Bundle-ClassPath>.</Bundle-ClassPath>
<Bundle-Name>${project.name}</Bundle-Name>
<Bundle-SymbolicName>${project.groupId}.${project.artifactId}</Bundle-SymbolicName>
<Import-Package>${keycloak.osgi.import}</Import-Package>
<Export-Package>${keycloak.osgi.export}</Export-Package>
</instructions>
</configuration>
</plugin>
</plugins>
</build>
</project>
@@ -1,6 +1,25 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.adapters.jetty.core;
import org.eclipse.jetty.security.DefaultUserIdentity;
import org.eclipse.jetty.security.IdentityService;
import org.eclipse.jetty.security.LoginService;
import org.eclipse.jetty.security.ServerAuthException;
import org.eclipse.jetty.security.UserAuthentication;
import org.eclipse.jetty.security.authentication.DeferredAuthentication;
@@ -18,10 +37,12 @@ import org.keycloak.KeycloakSecurityContext;
import org.keycloak.adapters.AdapterDeploymentContext;
import org.keycloak.adapters.AdapterTokenStore;
import org.keycloak.adapters.AdapterUtils;
import org.keycloak.adapters.AuthChallenge;
import org.keycloak.adapters.AuthOutcome;
import org.keycloak.adapters.jetty.spi.JettyHttpFacade;
import org.keycloak.adapters.jetty.spi.JettyUserSessionManagement;
import org.keycloak.adapters.spi.AuthChallenge;
import org.keycloak.adapters.spi.AuthOutcome;
import org.keycloak.adapters.AuthenticatedActionsHandler;
import org.keycloak.adapters.HttpFacade;
import org.keycloak.adapters.spi.HttpFacade;
import org.keycloak.adapters.KeycloakConfigResolver;
import org.keycloak.adapters.KeycloakDeployment;
import org.keycloak.adapters.KeycloakDeploymentBuilder;
@@ -92,7 +113,7 @@ public abstract class AbstractKeycloakJettyAuthenticator extends LoginAuthentica
AdapterDeploymentContext deploymentContext = (AdapterDeploymentContext) request.getAttribute(AdapterDeploymentContext.class.getName());
KeycloakSecurityContext ksc = (KeycloakSecurityContext) request.getAttribute(KeycloakSecurityContext.class.getName());
if (ksc != null) {
JettyHttpFacade facade = new JettyHttpFacade(request, null);
JettyHttpFacade facade = new OIDCJettyHttpFacade(request, null);
KeycloakDeployment deployment = deploymentContext.resolveDeployment(facade);
if (ksc instanceof RefreshableKeycloakSecurityContext) {
((RefreshableKeycloakSecurityContext) ksc).logout(deployment);
@@ -116,10 +137,44 @@ public abstract class AbstractKeycloakJettyAuthenticator extends LoginAuthentica
return new DefaultUserIdentity(theSubject, principal, theRoles);
}
private class DummyLoginService implements LoginService {
@Override
public String getName() {
return null;
}
@Override
public UserIdentity login(String username, Object credentials) {
return null;
}
@Override
public boolean validate(UserIdentity user) {
return false;
}
@Override
public IdentityService getIdentityService() {
return null;
}
@Override
public void setIdentityService(IdentityService service) {
}
@Override
public void logout(UserIdentity user) {
}
}
@Override
public void setConfiguration(AuthConfiguration configuration) {
//super.setConfiguration(configuration);
initializeKeycloak();
// need this so that getUserPrincipal does not throw NPE
_loginService = new DummyLoginService();
String error = configuration.getInitParameter(FormAuthenticator.__FORM_ERROR_PAGE);
setErrorPage(error);
}
@@ -229,7 +284,7 @@ public abstract class AbstractKeycloakJettyAuthenticator extends LoginAuthentica
log.trace("*** authenticate");
}
Request request = resolveRequest(req);
JettyHttpFacade facade = new JettyHttpFacade(request, (HttpServletResponse) res);
OIDCJettyHttpFacade facade = new OIDCJettyHttpFacade(request, (HttpServletResponse) res);
KeycloakDeployment deployment = deploymentContext.resolveDeployment(facade);
if (deployment == null || !deployment.isConfigured()) {
log.debug("*** deployment isn't configured return false");
@@ -262,15 +317,6 @@ public abstract class AbstractKeycloakJettyAuthenticator extends LoginAuthentica
}
AuthChallenge challenge = authenticator.getChallenge();
if (challenge != null) {
if (challenge.errorPage() && errorPage != null) {
Response response = (Response)res;
try {
response.sendRedirect(response.encodeRedirectURL(URIUtil.addPaths(request.getContextPath(), errorPage)));
} catch (IOException e) {
throw new RuntimeException(e);
}
}
challenge.challenge(facade);
}
return Authentication.SEND_CONTINUE;
@@ -1,3 +1,20 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.adapters.jetty.core;
import org.eclipse.jetty.server.Request;
@@ -6,9 +23,9 @@ import org.keycloak.KeycloakPrincipal;
import org.keycloak.KeycloakSecurityContext;
import org.keycloak.adapters.AdapterTokenStore;
import org.keycloak.adapters.CookieTokenStore;
import org.keycloak.adapters.HttpFacade;
import org.keycloak.adapters.KeycloakAccount;
import org.keycloak.adapters.spi.HttpFacade;
import org.keycloak.adapters.KeycloakDeployment;
import org.keycloak.adapters.OidcKeycloakAccount;
import org.keycloak.adapters.RefreshableKeycloakSecurityContext;
import org.keycloak.adapters.RequestAuthenticator;
@@ -61,7 +78,7 @@ public class JettyCookieTokenStore implements AdapterTokenStore {
}
@Override
public void saveAccountInfo(KeycloakAccount account) {
public void saveAccountInfo(OidcKeycloakAccount account) {
RefreshableKeycloakSecurityContext securityContext = (RefreshableKeycloakSecurityContext)account.getKeycloakSecurityContext();
CookieTokenStore.setTokenCookie(deployment, facade, securityContext);
}
@@ -1,3 +1,20 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.adapters.jetty.core;
import org.eclipse.jetty.server.Request;
@@ -6,10 +23,10 @@ import org.keycloak.KeycloakPrincipal;
import org.keycloak.KeycloakSecurityContext;
import org.keycloak.adapters.AdapterTokenStore;
import org.keycloak.adapters.AdapterUtils;
import org.keycloak.adapters.HttpFacade;
import org.keycloak.adapters.KeycloakAccount;
import org.keycloak.adapters.spi.HttpFacade;
import org.keycloak.adapters.KeycloakDeployment;
import org.keycloak.adapters.OAuthRequestAuthenticator;
import org.keycloak.adapters.OidcKeycloakAccount;
import org.keycloak.adapters.RefreshableKeycloakSecurityContext;
import org.keycloak.adapters.RequestAuthenticator;
@@ -41,7 +58,7 @@ public class JettyRequestAuthenticator extends RequestAuthenticator {
principal = skp;
final RefreshableKeycloakSecurityContext securityContext = skp.getKeycloakSecurityContext();
final Set<String> roles = AdapterUtils.getRolesFromSecurityContext(securityContext);
KeycloakAccount account = new KeycloakAccount() {
OidcKeycloakAccount account = new OidcKeycloakAccount() {
@Override
public Principal getPrincipal() {
@@ -76,7 +93,7 @@ public class JettyRequestAuthenticator extends RequestAuthenticator {
@Override
protected String getHttpSessionId(boolean create) {
protected String changeHttpSessionId(boolean create) {
HttpSession session = request.getSession(create);
return session != null ? session.getId() : null;
}
@@ -0,0 +1,125 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.adapters.jetty.core;
import org.eclipse.jetty.server.Request;
import org.jboss.logging.Logger;
import org.keycloak.KeycloakPrincipal;
import org.keycloak.KeycloakSecurityContext;
import org.keycloak.adapters.spi.AdapterSessionStore;
import org.keycloak.adapters.AdapterTokenStore;
import org.keycloak.adapters.AdapterUtils;
import org.keycloak.adapters.KeycloakDeployment;
import org.keycloak.adapters.OidcKeycloakAccount;
import org.keycloak.adapters.RefreshableKeycloakSecurityContext;
import org.keycloak.adapters.RequestAuthenticator;
import javax.servlet.http.HttpSession;
/**
* Handle storage of token info in HTTP Session. Per-request object
*
* @author <a href="mailto:mposolda@redhat.com">Marek Posolda</a>
*/
public class JettySessionTokenStore implements AdapterTokenStore {
private static final Logger log = Logger.getLogger(JettySessionTokenStore.class);
private Request request;
protected KeycloakDeployment deployment;
protected AdapterSessionStore sessionStore;
public JettySessionTokenStore(Request request, KeycloakDeployment deployment, AdapterSessionStore sessionStore) {
this.request = request;
this.deployment = deployment;
this.sessionStore = sessionStore;
}
@Override
public void checkCurrentToken() {
if (request.getSession(false) == null) return;
RefreshableKeycloakSecurityContext session = (RefreshableKeycloakSecurityContext) request.getSession().getAttribute(KeycloakSecurityContext.class.getName());
if (session == null) return;
// just in case session got serialized
if (session.getDeployment() == null) session.setCurrentRequestInfo(deployment, this);
if (session.isActive() && !session.getDeployment().isAlwaysRefreshToken()) return;
// FYI: A refresh requires same scope, so same roles will be set. Otherwise, refresh will fail and token will
// not be updated
boolean success = session.refreshExpiredToken(false);
if (success && session.isActive()) return;
// Refresh failed, so user is already logged out from keycloak. Cleanup and expire our session
request.getSession().removeAttribute(KeycloakSecurityContext.class.getName());
request.getSession().invalidate();
}
@Override
public boolean isCached(RequestAuthenticator authenticator) {
if (request.getSession(false) == null || request.getSession().getAttribute(KeycloakSecurityContext.class.getName()) == null)
return false;
log.debug("remote logged in already. Establish state from session");
RefreshableKeycloakSecurityContext securityContext = (RefreshableKeycloakSecurityContext) request.getSession().getAttribute(KeycloakSecurityContext.class.getName());
if (!deployment.getRealm().equals(securityContext.getRealm())) {
log.debug("Account from cookie is from a different realm than for the request.");
return false;
}
securityContext.setCurrentRequestInfo(deployment, this);
request.setAttribute(KeycloakSecurityContext.class.getName(), securityContext);
JettyRequestAuthenticator jettyAuthenticator = (JettyRequestAuthenticator) authenticator;
KeycloakPrincipal<RefreshableKeycloakSecurityContext> principal = AdapterUtils.createPrincipal(deployment, securityContext);
jettyAuthenticator.principal = principal;
restoreRequest();
return true;
}
@Override
public void saveAccountInfo(OidcKeycloakAccount account) {
RefreshableKeycloakSecurityContext securityContext = (RefreshableKeycloakSecurityContext) account.getKeycloakSecurityContext();
request.getSession().setAttribute(KeycloakSecurityContext.class.getName(), securityContext);
}
@Override
public void logout() {
HttpSession session = request.getSession(false);
if (session != null) {
session.removeAttribute(KeycloakSecurityContext.class.getName());
}
}
@Override
public void refreshCallback(RefreshableKeycloakSecurityContext securityContext) {
// no-op
}
@Override
public void saveRequest() {
sessionStore.saveRequest();
}
@Override
public boolean restoreRequest() {
return sessionStore.restoreRequest();
}
}
@@ -0,0 +1,41 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.adapters.jetty.core;
import org.keycloak.KeycloakSecurityContext;
import org.keycloak.adapters.OIDCHttpFacade;
import org.keycloak.adapters.jetty.spi.JettyHttpFacade;
import javax.servlet.http.HttpServletResponse;
/**
* @author <a href="mailto:bill@burkecentral.com">Bill Burke</a>
* @version $Revision: 1 $
*/
public class OIDCJettyHttpFacade extends JettyHttpFacade implements OIDCHttpFacade {
public OIDCJettyHttpFacade(org.eclipse.jetty.server.Request request, HttpServletResponse response) {
super(request, response);
}
@Override
public KeycloakSecurityContext getSecurityContext() {
return (KeycloakSecurityContext)request.getAttribute(KeycloakSecurityContext.class.getName());
}
}
+159
View File
@@ -0,0 +1,159 @@
<?xml version="1.0"?>
<!--
~ Copyright 2016 Red Hat, Inc. and/or its affiliates
~ and other contributors as indicated by the @author tags.
~
~ Licensed under the Apache License, Version 2.0 (the "License");
~ you may not use this file except in compliance with the License.
~ You may obtain a copy of the License at
~
~ http://www.apache.org/licenses/LICENSE-2.0
~
~ Unless required by applicable law or agreed to in writing, software
~ distributed under the License is distributed on an "AS IS" BASIS,
~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
~ See the License for the specific language governing permissions and
~ limitations under the License.
-->
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<parent>
<artifactId>keycloak-parent</artifactId>
<groupId>org.keycloak</groupId>
<version>1.9.5.Final</version>
<relativePath>../../../../pom.xml</relativePath>
</parent>
<modelVersion>4.0.0</modelVersion>
<artifactId>keycloak-jetty81-adapter</artifactId>
<name>Keycloak Jetty 8.1.x Integration</name>
<properties>
<jetty9.version>8.1.17.v20150415</jetty9.version>
<keycloak.osgi.export>
org.keycloak.adapters.jetty.*
</keycloak.osgi.export>
<keycloak.osgi.import>
javax.servlet.*;version="[2.5,4)";resolution:=optional,
org.keycloak.*;version="${project.version}",
*;resolution:=optional
</keycloak.osgi.import>
</properties>
<description />
<dependencies>
<dependency>
<groupId>org.jboss.logging</groupId>
<artifactId>jboss-logging</artifactId>
<version>${jboss.logging.version}</version>
</dependency>
<dependency>
<groupId>org.keycloak</groupId>
<artifactId>keycloak-core</artifactId>
</dependency>
<dependency>
<groupId>org.keycloak</groupId>
<artifactId>keycloak-adapter-core</artifactId>
</dependency>
<dependency>
<groupId>org.keycloak</groupId>
<artifactId>keycloak-adapter-spi</artifactId>
</dependency>
<dependency>
<groupId>org.keycloak</groupId>
<artifactId>keycloak-jetty-core</artifactId>
</dependency>
<dependency>
<groupId>org.apache.httpcomponents</groupId>
<artifactId>httpclient</artifactId>
</dependency>
<dependency>
<groupId>org.bouncycastle</groupId>
<artifactId>bcprov-jdk15on</artifactId>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-core</artifactId>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-databind</artifactId>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-annotations</artifactId>
</dependency>
<dependency>
<groupId>org.eclipse.jetty</groupId>
<artifactId>jetty-server</artifactId>
<version>${jetty9.version}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.eclipse.jetty</groupId>
<artifactId>jetty-util</artifactId>
<version>${jetty9.version}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.eclipse.jetty</groupId>
<artifactId>jetty-security</artifactId>
<version>${jetty9.version}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<scope>test</scope>
</dependency>
</dependencies>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<source>1.6</source>
<target>1.6</target>
</configuration>
</plugin>
<!-- Adding OSGI metadata to the JAR without changing the packaging type. -->
<plugin>
<artifactId>maven-jar-plugin</artifactId>
<configuration>
<archive>
<manifestFile>${project.build.outputDirectory}/META-INF/MANIFEST.MF</manifestFile>
</archive>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.felix</groupId>
<artifactId>maven-bundle-plugin</artifactId>
<extensions>true</extensions>
<executions>
<execution>
<id>bundle-manifest</id>
<phase>process-classes</phase>
<goals>
<goal>manifest</goal>
</goals>
</execution>
</executions>
<configuration>
<instructions>
<Bundle-ClassPath>.</Bundle-ClassPath>
<Bundle-Name>${project.name}</Bundle-Name>
<Bundle-SymbolicName>${project.groupId}.${project.artifactId}</Bundle-SymbolicName>
<Import-Package>${keycloak.osgi.import}</Import-Package>
<Export-Package>${keycloak.osgi.export}</Export-Package>
</instructions>
</configuration>
</plugin>
</plugins>
</build>
</project>
@@ -0,0 +1,111 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.adapters.jetty;
import org.eclipse.jetty.security.authentication.FormAuthenticator;
import org.eclipse.jetty.server.Request;
import org.eclipse.jetty.util.MultiMap;
import org.keycloak.adapters.spi.AdapterSessionStore;
import org.keycloak.adapters.jetty.spi.JettyHttpFacade;
import org.keycloak.common.util.MultivaluedHashMap;
import javax.servlet.http.HttpSession;
/**
* @author <a href="mailto:bill@burkecentral.com">Bill Burke</a>
* @version $Revision: 1 $
*/
public class JettyAdapterSessionStore implements AdapterSessionStore {
public static final String CACHED_FORM_PARAMETERS = "__CACHED_FORM_PARAMETERS";
protected Request myRequest;
public JettyAdapterSessionStore(Request request) {
this.myRequest = request; // for IDE/compilation purposes
}
protected MultiMap<String> extractFormParameters(Request base_request) {
MultiMap<String> formParameters = new MultiMap<String>();
base_request.extractParameters();
return base_request.getParameters();
}
protected void restoreFormParameters(MultiMap<String> j_post, Request base_request) {
base_request.setParameters(j_post);
}
public boolean restoreRequest() {
HttpSession session = myRequest.getSession(false);
if (session == null) return false;
synchronized (session) {
String j_uri = (String) session.getAttribute(FormAuthenticator.__J_URI);
if (j_uri != null) {
// check if the request is for the same url as the original and restore
// params if it was a post
StringBuffer buf = myRequest.getRequestURL();
if (myRequest.getQueryString() != null)
buf.append("?").append(myRequest.getQueryString());
if (j_uri.equals(buf.toString())) {
String method = (String)session.getAttribute(JettyHttpFacade.__J_METHOD);
myRequest.setMethod(method);
MultivaluedHashMap<String, String> j_post = (MultivaluedHashMap<String, String>) session.getAttribute(CACHED_FORM_PARAMETERS);
if (j_post != null) {
myRequest.setContentType("application/x-www-form-urlencoded");
MultiMap<String> map = new MultiMap<String>();
for (String key : j_post.keySet()) {
for (String val : j_post.getList(key)) {
map.add(key, val);
}
}
restoreFormParameters(map, myRequest);
}
session.removeAttribute(FormAuthenticator.__J_URI);
session.removeAttribute(JettyHttpFacade.__J_METHOD);
session.removeAttribute(FormAuthenticator.__J_POST);
}
return true;
}
}
return false;
}
public void saveRequest() {
// remember the current URI
HttpSession session = myRequest.getSession();
synchronized (session) {
// But only if it is not set already, or we save every uri that leads to a login form redirect
if (session.getAttribute(FormAuthenticator.__J_URI) == null) {
StringBuffer buf = myRequest.getRequestURL();
if (myRequest.getQueryString() != null)
buf.append("?").append(myRequest.getQueryString());
session.setAttribute(FormAuthenticator.__J_URI, buf.toString());
session.setAttribute(JettyHttpFacade.__J_METHOD, myRequest.getMethod());
if ("application/x-www-form-urlencoded".equals(myRequest.getContentType()) && "POST".equalsIgnoreCase(myRequest.getMethod())) {
MultiMap<String> formParameters = extractFormParameters(myRequest);
MultivaluedHashMap<String, String> map = new MultivaluedHashMap<String, String>();
for (String key : formParameters.keySet()) {
for (Object value : formParameters.getValues(key)) {
map.add(key, (String) value);
}
}
session.setAttribute(CACHED_FORM_PARAMETERS, map);
}
}
}
}
}
@@ -0,0 +1,63 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.adapters.jetty;
import org.eclipse.jetty.server.AbstractHttpConnection;
import org.eclipse.jetty.server.Authentication;
import org.eclipse.jetty.server.Request;
import org.eclipse.jetty.server.UserIdentity;
import org.keycloak.adapters.AdapterTokenStore;
import org.keycloak.adapters.KeycloakDeployment;
import org.keycloak.adapters.jetty.core.AbstractKeycloakJettyAuthenticator;
import org.keycloak.adapters.jetty.core.JettySessionTokenStore;
import javax.servlet.ServletRequest;
/**
* @author <a href="mailto:bill@burkecentral.com">Bill Burke</a>
* @version $Revision: 1 $
*/
public class KeycloakJettyAuthenticator extends AbstractKeycloakJettyAuthenticator {
public KeycloakJettyAuthenticator() {
super();
}
@Override
public AdapterTokenStore createSessionTokenStore(Request request, KeycloakDeployment resolvedDeployment) {
return new JettySessionTokenStore(request, resolvedDeployment, new JettyAdapterSessionStore(request));
}
@Override
protected Request resolveRequest(ServletRequest req) {
return (req instanceof Request)?(Request)req: AbstractHttpConnection.getCurrentConnection().getRequest();
}
@Override
protected Authentication createAuthentication(UserIdentity userIdentity) {
return new KeycloakAuthentication(getAuthMethod(), userIdentity) {
@Override
public void logout() {
logoutCurrent(AbstractHttpConnection.getCurrentConnection().getRequest());
}
};
}
}
+170
View File
@@ -0,0 +1,170 @@
<?xml version="1.0"?>
<!--
~ Copyright 2016 Red Hat, Inc. and/or its affiliates
~ and other contributors as indicated by the @author tags.
~
~ Licensed under the Apache License, Version 2.0 (the "License");
~ you may not use this file except in compliance with the License.
~ You may obtain a copy of the License at
~
~ http://www.apache.org/licenses/LICENSE-2.0
~
~ Unless required by applicable law or agreed to in writing, software
~ distributed under the License is distributed on an "AS IS" BASIS,
~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
~ See the License for the specific language governing permissions and
~ limitations under the License.
-->
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<parent>
<artifactId>keycloak-parent</artifactId>
<groupId>org.keycloak</groupId>
<version>1.9.5.Final</version>
<relativePath>../../../../pom.xml</relativePath>
</parent>
<modelVersion>4.0.0</modelVersion>
<artifactId>keycloak-jetty91-adapter</artifactId>
<name>Keycloak Jetty 9.1.x Integration</name>
<properties>
<jetty9.version>9.1.5.v20140505</jetty9.version>
<keycloak.osgi.export>
org.keycloak.adapters.jetty.*
</keycloak.osgi.export>
<keycloak.osgi.import>
org.eclipse.jetty.*;version="[9.1,9.2)";resolution:=optional,
javax.servlet.*;version="[3.0,4)";resolution:=optional,
org.keycloak.*;version="${project.version}",
*;resolution:=optional
</keycloak.osgi.import>
</properties>
<description />
<dependencies>
<dependency>
<groupId>org.jboss.logging</groupId>
<artifactId>jboss-logging</artifactId>
<version>${jboss.logging.version}</version>
</dependency>
<dependency>
<groupId>org.keycloak</groupId>
<artifactId>keycloak-core</artifactId>
</dependency>
<dependency>
<groupId>org.keycloak</groupId>
<artifactId>keycloak-adapter-core</artifactId>
</dependency>
<dependency>
<groupId>org.keycloak</groupId>
<artifactId>keycloak-jetty-core</artifactId>
<exclusions>
<exclusion>
<groupId>org.eclipse.jetty</groupId>
<artifactId>jetty-server</artifactId>
</exclusion>
<exclusion>
<groupId>org.eclipse.jetty</groupId>
<artifactId>jetty-util</artifactId>
</exclusion>
<exclusion>
<groupId>org.eclipse.jetty</groupId>
<artifactId>jetty-security</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>org.apache.httpcomponents</groupId>
<artifactId>httpclient</artifactId>
</dependency>
<dependency>
<groupId>org.bouncycastle</groupId>
<artifactId>bcprov-jdk15on</artifactId>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-core</artifactId>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-databind</artifactId>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-annotations</artifactId>
</dependency>
<dependency>
<groupId>org.eclipse.jetty</groupId>
<artifactId>jetty-server</artifactId>
<version>${jetty9.version}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.eclipse.jetty</groupId>
<artifactId>jetty-util</artifactId>
<version>${jetty9.version}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.eclipse.jetty</groupId>
<artifactId>jetty-security</artifactId>
<version>${jetty9.version}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<scope>test</scope>
</dependency>
</dependencies>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<source>1.6</source>
<target>1.6</target>
</configuration>
</plugin>
<!-- Adding OSGI metadata to the JAR without changing the packaging type. -->
<plugin>
<artifactId>maven-jar-plugin</artifactId>
<configuration>
<archive>
<manifestFile>${project.build.outputDirectory}/META-INF/MANIFEST.MF</manifestFile>
</archive>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.felix</groupId>
<artifactId>maven-bundle-plugin</artifactId>
<extensions>true</extensions>
<executions>
<execution>
<id>bundle-manifest</id>
<phase>process-classes</phase>
<goals>
<goal>manifest</goal>
</goals>
</execution>
</executions>
<configuration>
<instructions>
<Bundle-ClassPath>.</Bundle-ClassPath>
<Bundle-Name>${project.name}</Bundle-Name>
<Bundle-SymbolicName>${project.groupId}.${project.artifactId}</Bundle-SymbolicName>
<Import-Package>${keycloak.osgi.import}</Import-Package>
<Export-Package>${keycloak.osgi.export}</Export-Package>
</instructions>
</configuration>
</plugin>
</plugins>
</build>
</project>
@@ -0,0 +1,47 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.adapters.jetty;
import org.eclipse.jetty.server.Request;
import org.keycloak.adapters.AdapterTokenStore;
import org.keycloak.adapters.KeycloakDeployment;
import org.keycloak.adapters.jetty.core.JettyRequestAuthenticator;
import org.keycloak.adapters.spi.HttpFacade;
import javax.servlet.http.HttpSession;
/**
* @author <a href="mailto:bill@burkecentral.com">Bill Burke</a>
* @version $Revision: 1 $
*/
public class Jetty91RequestAuthenticator extends JettyRequestAuthenticator {
public Jetty91RequestAuthenticator(HttpFacade facade, KeycloakDeployment deployment, AdapterTokenStore tokenStore, int sslRedirectPort, Request request) {
super(facade, deployment, tokenStore, sslRedirectPort, request);
}
@Override
protected String changeHttpSessionId(boolean create) {
Request request = this.request;
HttpSession session = request.getSession(false);
if (session == null) {
return request.getSession(true).getId();
}
if (!deployment.isTurnOffChangeSessionIdOnLogin()) return request.changeSessionId();
else return session.getId();
}
}
@@ -0,0 +1,111 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.adapters.jetty;
import org.eclipse.jetty.http.HttpMethod;
import org.eclipse.jetty.security.authentication.FormAuthenticator;
import org.eclipse.jetty.server.Request;
import org.eclipse.jetty.util.MultiMap;
import org.keycloak.adapters.spi.AdapterSessionStore;
import org.keycloak.adapters.jetty.spi.JettyHttpFacade;
import org.keycloak.common.util.MultivaluedHashMap;
import javax.servlet.http.HttpSession;
/**
* @author <a href="mailto:bill@burkecentral.com">Bill Burke</a>
* @version $Revision: 1 $
*/
public class JettyAdapterSessionStore implements AdapterSessionStore {
public static final String CACHED_FORM_PARAMETERS = "__CACHED_FORM_PARAMETERS";
protected Request myRequest;
public JettyAdapterSessionStore(Request request) {
this.myRequest = request; // for IDE/compilation purposes
}
protected MultiMap<String> extractFormParameters(Request base_request) {
base_request.extractParameters();
return base_request.getParameters();
}
protected void restoreFormParameters(MultiMap<String> j_post, Request base_request) {
base_request.setParameters(j_post);
}
public boolean restoreRequest() {
HttpSession session = myRequest.getSession(false);
if (session == null) return false;
synchronized (session) {
String j_uri = (String) session.getAttribute(FormAuthenticator.__J_URI);
if (j_uri != null) {
// check if the request is for the same url as the original and restore
// params if it was a post
StringBuffer buf = myRequest.getRequestURL();
if (myRequest.getQueryString() != null)
buf.append("?").append(myRequest.getQueryString());
if (j_uri.equals(buf.toString())) {
String method = (String)session.getAttribute(JettyHttpFacade.__J_METHOD);
myRequest.setMethod(HttpMethod.valueOf(method.toUpperCase()), method);
MultivaluedHashMap<String, String> j_post = (MultivaluedHashMap<String, String>) session.getAttribute(CACHED_FORM_PARAMETERS);
if (j_post != null) {
myRequest.setContentType("application/x-www-form-urlencoded");
MultiMap<String> map = new MultiMap<String>();
for (String key : j_post.keySet()) {
for (String val : j_post.getList(key)) {
map.add(key, val);
}
}
restoreFormParameters(map, myRequest);
}
session.removeAttribute(FormAuthenticator.__J_URI);
session.removeAttribute(JettyHttpFacade.__J_METHOD);
session.removeAttribute(FormAuthenticator.__J_POST);
}
return true;
}
}
return false;
}
public void saveRequest() {
// remember the current URI
HttpSession session = myRequest.getSession();
synchronized (session) {
// But only if it is not set already, or we save every uri that leads to a login form redirect
if (session.getAttribute(FormAuthenticator.__J_URI) == null) {
StringBuffer buf = myRequest.getRequestURL();
if (myRequest.getQueryString() != null)
buf.append("?").append(myRequest.getQueryString());
session.setAttribute(FormAuthenticator.__J_URI, buf.toString());
session.setAttribute(JettyHttpFacade.__J_METHOD, myRequest.getMethod());
if ("application/x-www-form-urlencoded".equals(myRequest.getContentType()) && "POST".equalsIgnoreCase(myRequest.getMethod())) {
MultiMap<String> formParameters = extractFormParameters(myRequest);
MultivaluedHashMap<String, String> map = new MultivaluedHashMap<String, String>();
for (String key : formParameters.keySet()) {
for (Object value : formParameters.getValues(key)) {
map.add(key, (String) value);
}
}
session.setAttribute(CACHED_FORM_PARAMETERS, map);
}
}
}
}
}
@@ -0,0 +1,72 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.adapters.jetty;
import org.eclipse.jetty.server.Authentication;
import org.eclipse.jetty.server.HttpChannel;
import org.eclipse.jetty.server.Request;
import org.eclipse.jetty.server.UserIdentity;
import org.keycloak.adapters.AdapterTokenStore;
import org.keycloak.adapters.KeycloakDeployment;
import org.keycloak.adapters.jetty.core.AbstractKeycloakJettyAuthenticator;
import org.keycloak.adapters.jetty.core.JettyRequestAuthenticator;
import org.keycloak.adapters.jetty.core.JettySessionTokenStore;
import org.keycloak.adapters.jetty.spi.JettyHttpFacade;
import javax.servlet.ServletRequest;
/**
* @author <a href="mailto:bill@burkecentral.com">Bill Burke</a>
* @version $Revision: 1 $
*/
public class KeycloakJettyAuthenticator extends AbstractKeycloakJettyAuthenticator {
public KeycloakJettyAuthenticator() {
super();
}
@Override
public AdapterTokenStore createSessionTokenStore(Request request, KeycloakDeployment resolvedDeployment) {
return new JettySessionTokenStore(request, resolvedDeployment, new JettyAdapterSessionStore(request));
}
@Override
protected Request resolveRequest(ServletRequest req) {
return (req instanceof Request) ? (Request)req : HttpChannel.getCurrentHttpChannel().getRequest();
}
@Override
protected Authentication createAuthentication(UserIdentity userIdentity) {
return new KeycloakAuthentication(getAuthMethod(), userIdentity) {
@Override
public void logout() {
logoutCurrent(HttpChannel.getCurrentHttpChannel().getRequest());
}
};
}
@Override
protected JettyRequestAuthenticator createRequestAuthenticator(Request request, JettyHttpFacade facade,
KeycloakDeployment deployment, AdapterTokenStore tokenStore) {
return new Jetty91RequestAuthenticator(facade, deployment, tokenStore, -1, request);
}
}
+156
View File
@@ -0,0 +1,156 @@
<?xml version="1.0"?>
<!--
~ Copyright 2016 Red Hat, Inc. and/or its affiliates
~ and other contributors as indicated by the @author tags.
~
~ Licensed under the Apache License, Version 2.0 (the "License");
~ you may not use this file except in compliance with the License.
~ You may obtain a copy of the License at
~
~ http://www.apache.org/licenses/LICENSE-2.0
~
~ Unless required by applicable law or agreed to in writing, software
~ distributed under the License is distributed on an "AS IS" BASIS,
~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
~ See the License for the specific language governing permissions and
~ limitations under the License.
-->
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<parent>
<artifactId>keycloak-parent</artifactId>
<groupId>org.keycloak</groupId>
<version>1.9.5.Final</version>
<relativePath>../../../../pom.xml</relativePath>
</parent>
<modelVersion>4.0.0</modelVersion>
<artifactId>keycloak-jetty92-adapter</artifactId>
<name>Keycloak Jetty 9.2.x Integration</name>
<properties>
<jetty9.version>9.2.4.v20141103</jetty9.version>
<keycloak.osgi.export>
org.keycloak.adapters.jetty.*
</keycloak.osgi.export>
<keycloak.osgi.import>
org.eclipse.jetty.*;resolution:=optional,
javax.servlet.*;version="[3.0,4)";resolution:=optional,
org.keycloak.*;version="${project.version}",
*;resolution:=optional
</keycloak.osgi.import>
</properties>
<description />
<dependencies>
<dependency>
<groupId>org.jboss.logging</groupId>
<artifactId>jboss-logging</artifactId>
<version>${jboss.logging.version}</version>
</dependency>
<dependency>
<groupId>org.keycloak</groupId>
<artifactId>keycloak-core</artifactId>
</dependency>
<dependency>
<groupId>org.keycloak</groupId>
<artifactId>keycloak-adapter-core</artifactId>
</dependency>
<dependency>
<groupId>org.keycloak</groupId>
<artifactId>keycloak-jetty-core</artifactId>
</dependency>
<dependency>
<groupId>org.apache.httpcomponents</groupId>
<artifactId>httpclient</artifactId>
</dependency>
<dependency>
<groupId>org.bouncycastle</groupId>
<artifactId>bcprov-jdk15on</artifactId>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-core</artifactId>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-databind</artifactId>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-annotations</artifactId>
</dependency>
<dependency>
<groupId>org.eclipse.jetty</groupId>
<artifactId>jetty-server</artifactId>
<version>${jetty9.version}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.eclipse.jetty</groupId>
<artifactId>jetty-util</artifactId>
<version>${jetty9.version}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.eclipse.jetty</groupId>
<artifactId>jetty-security</artifactId>
<version>${jetty9.version}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<scope>test</scope>
</dependency>
</dependencies>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<source>1.6</source>
<target>1.6</target>
</configuration>
</plugin>
<!-- Adding OSGI metadata to the JAR without changing the packaging type. -->
<plugin>
<artifactId>maven-jar-plugin</artifactId>
<configuration>
<archive>
<manifestFile>${project.build.outputDirectory}/META-INF/MANIFEST.MF</manifestFile>
</archive>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.felix</groupId>
<artifactId>maven-bundle-plugin</artifactId>
<extensions>true</extensions>
<executions>
<execution>
<id>bundle-manifest</id>
<phase>process-classes</phase>
<goals>
<goal>manifest</goal>
</goals>
</execution>
</executions>
<configuration>
<instructions>
<Bundle-ClassPath>.</Bundle-ClassPath>
<Bundle-Name>${project.name}</Bundle-Name>
<Bundle-SymbolicName>${project.groupId}.${project.artifactId}</Bundle-SymbolicName>
<Import-Package>${keycloak.osgi.import}</Import-Package>
<Export-Package>${keycloak.osgi.export}</Export-Package>
</instructions>
</configuration>
</plugin>
</plugins>
</build>
</project>
@@ -0,0 +1,47 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.adapters.jetty;
import org.eclipse.jetty.server.Request;
import org.keycloak.adapters.AdapterTokenStore;
import org.keycloak.adapters.KeycloakDeployment;
import org.keycloak.adapters.jetty.core.JettyRequestAuthenticator;
import org.keycloak.adapters.spi.HttpFacade;
import javax.servlet.http.HttpSession;
/**
* @author <a href="mailto:bill@burkecentral.com">Bill Burke</a>
* @version $Revision: 1 $
*/
public class Jetty92RequestAuthenticator extends JettyRequestAuthenticator {
public Jetty92RequestAuthenticator(HttpFacade facade, KeycloakDeployment deployment, AdapterTokenStore tokenStore, int sslRedirectPort, Request request) {
super(facade, deployment, tokenStore, sslRedirectPort, request);
}
@Override
protected String changeHttpSessionId(boolean create) {
Request request = this.request;
HttpSession session = request.getSession(false);
if (session == null) {
return request.getSession(true).getId();
}
if (!deployment.isTurnOffChangeSessionIdOnLogin()) return request.changeSessionId();
else return session.getId();
}
}
@@ -0,0 +1,112 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.adapters.jetty;
import org.eclipse.jetty.http.HttpMethod;
import org.eclipse.jetty.security.authentication.FormAuthenticator;
import org.eclipse.jetty.server.Request;
import org.eclipse.jetty.util.MultiMap;
import org.keycloak.adapters.spi.AdapterSessionStore;
import org.keycloak.adapters.jetty.spi.JettyHttpFacade;
import org.keycloak.common.util.MultivaluedHashMap;
import javax.servlet.http.HttpSession;
/**
* @author <a href="mailto:bill@burkecentral.com">Bill Burke</a>
* @version $Revision: 1 $
*/
public class JettyAdapterSessionStore implements AdapterSessionStore {
public static final String CACHED_FORM_PARAMETERS = "__CACHED_FORM_PARAMETERS";
protected Request myRequest;
public JettyAdapterSessionStore(Request request) {
this.myRequest = request; // for IDE/compilation purposes
}
protected MultiMap<String> extractFormParameters(Request base_request) {
MultiMap<String> formParameters = new MultiMap<String>();
base_request.extractFormParameters(formParameters);
return formParameters;
}
protected void restoreFormParameters(MultiMap<String> j_post, Request base_request) {
base_request.setContentParameters(j_post);
}
public boolean restoreRequest() {
HttpSession session = myRequest.getSession(false);
if (session == null) return false;
synchronized (session) {
String j_uri = (String) session.getAttribute(FormAuthenticator.__J_URI);
if (j_uri != null) {
// check if the request is for the same url as the original and restore
// params if it was a post
StringBuffer buf = myRequest.getRequestURL();
if (myRequest.getQueryString() != null)
buf.append("?").append(myRequest.getQueryString());
if (j_uri.equals(buf.toString())) {
String method = (String)session.getAttribute(JettyHttpFacade.__J_METHOD);
myRequest.setMethod(HttpMethod.valueOf(method.toUpperCase()), method);
MultivaluedHashMap<String, String> j_post = (MultivaluedHashMap<String, String>) session.getAttribute(CACHED_FORM_PARAMETERS);
if (j_post != null) {
myRequest.setContentType("application/x-www-form-urlencoded");
MultiMap<String> map = new MultiMap<String>();
for (String key : j_post.keySet()) {
for (String val : j_post.getList(key)) {
map.add(key, val);
}
}
restoreFormParameters(map, myRequest);
}
session.removeAttribute(FormAuthenticator.__J_URI);
session.removeAttribute(JettyHttpFacade.__J_METHOD);
session.removeAttribute(FormAuthenticator.__J_POST);
}
return true;
}
}
return false;
}
public void saveRequest() {
// remember the current URI
HttpSession session = myRequest.getSession();
synchronized (session) {
// But only if it is not set already, or we save every uri that leads to a login form redirect
if (session.getAttribute(FormAuthenticator.__J_URI) == null) {
StringBuffer buf = myRequest.getRequestURL();
if (myRequest.getQueryString() != null)
buf.append("?").append(myRequest.getQueryString());
session.setAttribute(FormAuthenticator.__J_URI, buf.toString());
session.setAttribute(JettyHttpFacade.__J_METHOD, myRequest.getMethod());
if ("application/x-www-form-urlencoded".equals(myRequest.getContentType()) && "POST".equalsIgnoreCase(myRequest.getMethod())) {
MultiMap<String> formParameters = extractFormParameters(myRequest);
MultivaluedHashMap<String, String> map = new MultivaluedHashMap<String, String>();
for (String key : formParameters.keySet()) {
for (Object value : formParameters.getValues(key)) {
map.add(key, (String) value);
}
}
session.setAttribute(CACHED_FORM_PARAMETERS, map);
}
}
}
}
}
@@ -0,0 +1,70 @@
/*
* Copyright 2016 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.keycloak.adapters.jetty;
import org.eclipse.jetty.server.Authentication;
import org.eclipse.jetty.server.HttpChannel;
import org.eclipse.jetty.server.Request;
import org.eclipse.jetty.server.UserIdentity;
import org.keycloak.adapters.AdapterTokenStore;
import org.keycloak.adapters.KeycloakDeployment;
import org.keycloak.adapters.jetty.core.AbstractKeycloakJettyAuthenticator;
import org.keycloak.adapters.jetty.core.JettyRequestAuthenticator;
import org.keycloak.adapters.jetty.core.JettySessionTokenStore;
import org.keycloak.adapters.jetty.spi.JettyHttpFacade;
import javax.servlet.ServletRequest;
/**
* @author <a href="mailto:bill@burkecentral.com">Bill Burke</a>
* @version $Revision: 1 $
*/
public class KeycloakJettyAuthenticator extends AbstractKeycloakJettyAuthenticator {
public KeycloakJettyAuthenticator() {
super();
}
@Override
protected Request resolveRequest(ServletRequest req) {
return (req instanceof Request) ? (Request)req : HttpChannel.getCurrentHttpChannel().getRequest();
}
@Override
protected Authentication createAuthentication(UserIdentity userIdentity) {
return new KeycloakAuthentication(getAuthMethod(), userIdentity) {
@Override
public void logout() {
logoutCurrent(HttpChannel.getCurrentHttpChannel().getRequest());
}
};
}
@Override
public AdapterTokenStore createSessionTokenStore(Request request, KeycloakDeployment resolvedDeployment) {
return new JettySessionTokenStore(request, resolvedDeployment, new JettyAdapterSessionStore(request));
}
@Override
protected JettyRequestAuthenticator createRequestAuthenticator(Request request, JettyHttpFacade facade,
KeycloakDeployment deployment, AdapterTokenStore tokenStore) {
return new Jetty92RequestAuthenticator(facade, deployment, tokenStore, -1, request);
}
}
Loaded 100 of 6841 files, more files were not shown because too many files have changed in this diff. Show more