[2/4] syncope git commit: Always conditionally handling notification and audit events in a Quartz job
Always conditionally handling notification and audit events in a Quartz job Project: http://git-wip-us.apache.org/repos/asf/syncope/repo Commit: http://git-wip-us.apache.org/repos/asf/syncope/commit/ae947c72 Tree: http://git-wip-us.apache.org/repos/asf/syncope/tree/ae947c72 Diff: http://git-wip-us.apache.org/repos/asf/syncope/diff/ae947c72 Branch: refs/heads/2_0_X Commit: ae947c721cb65fcef39aa405f028894b933800e2 Parents: ddf2d5e Author: Francesco ChicchiriccòAuthored: Tue Jun 13 11:14:02 2017 +0200 Committer: Francesco Chicchiriccò Committed: Tue Jun 13 11:14:02 2017 +0200 -- .../pushpull/AbstractPushResultHandler.java | 55 +++- .../pushpull/RealmPushResultHandlerImpl.java| 41 ++- 2 files changed, 68 insertions(+), 28 deletions(-) -- http://git-wip-us.apache.org/repos/asf/syncope/blob/ae947c72/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/pushpull/AbstractPushResultHandler.java -- diff --git a/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/pushpull/AbstractPushResultHandler.java b/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/pushpull/AbstractPushResultHandler.java index 542009b..d84fa25 100644 --- a/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/pushpull/AbstractPushResultHandler.java +++ b/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/pushpull/AbstractPushResultHandler.java @@ -46,9 +46,11 @@ import org.apache.syncope.core.persistence.api.entity.anyobject.AnyObject; import org.apache.syncope.core.persistence.api.entity.group.Group; import org.apache.syncope.core.persistence.api.entity.resource.MappingItem; import org.apache.syncope.core.persistence.api.entity.resource.Provision; +import org.apache.syncope.core.provisioning.api.AuditManager; import org.apache.syncope.core.provisioning.api.MappingManager; import org.apache.syncope.core.provisioning.api.TimeoutException; import org.apache.syncope.core.provisioning.api.event.AfterHandlingEvent; +import org.apache.syncope.core.provisioning.api.notification.NotificationManager; import org.apache.syncope.core.provisioning.api.pushpull.IgnoreProvisionException; import org.apache.syncope.core.provisioning.api.pushpull.SyncopePushResultHandler; import org.apache.syncope.core.provisioning.api.utils.EntityUtils; @@ -66,6 +68,18 @@ import org.springframework.transaction.annotation.Transactional; public abstract class AbstractPushResultHandler extends AbstractSyncopeResultHandler implements SyncopePushResultHandler { +/** + * Notification Manager. + */ +@Autowired +protected NotificationManager notificationManager; + +/** + * Audit Manager. + */ +@Autowired +protected AuditManager auditManager; + @Autowired protected MappingManager mappingManager; @@ -196,7 +210,6 @@ public abstract class AbstractPushResultHandler extends AbstractSyncopeResultHan Object output = null; Result resultStatus = null; -String operation = null; // Try to read remote object BEFORE any actual operation Provision provision = profile.getTask().getResource().getProvision(any.getType()); @@ -214,9 +227,22 @@ public abstract class AbstractPushResultHandler extends AbstractSyncopeResultHan } result.setStatus(ProvisioningReport.Status.SUCCESS); } else { +String operation = beforeObj == null +? UnmatchingRule.toEventName(profile.getTask().getUnmatchingRule()) +: MatchingRule.toEventName(profile.getTask().getMatchingRule()); + +boolean notificationsAvailable = notificationManager.notificationsAvailable( +AuditElements.EventCategoryType.PUSH, +any.getType().getKind().name().toLowerCase(), +profile.getTask().getResource().getKey(), +operation); +boolean auditRequested = auditManager.auditRequested( +AuditElements.EventCategoryType.PUSH, +any.getType().getKind().name().toLowerCase(), +profile.getTask().getResource().getKey(), +operation); try { if (beforeObj == null) { -operation = UnmatchingRule.toEventName(profile.getTask().getUnmatchingRule()); result.setOperation(getResourceOperation(profile.getTask().getUnmatchingRule())); switch (profile.getTask().getUnmatchingRule()) { @@ -266,7 +292,6 @@ public abstract class
[1/4] syncope git commit: Fixing JNDI name for DataSource
Repository: syncope Updated Branches: refs/heads/2_0_X b6ae826a6 -> 1bf49e3fd Fixing JNDI name for DataSource Project: http://git-wip-us.apache.org/repos/asf/syncope/repo Commit: http://git-wip-us.apache.org/repos/asf/syncope/commit/ddf2d5ee Tree: http://git-wip-us.apache.org/repos/asf/syncope/tree/ddf2d5ee Diff: http://git-wip-us.apache.org/repos/asf/syncope/diff/ddf2d5ee Branch: refs/heads/2_0_X Commit: ddf2d5ee90825df1e3fbc77bd67d3f858afff689 Parents: b6ae826 Author: Francesco ChicchiriccòAuthored: Tue Jun 13 11:10:33 2017 +0200 Committer: Francesco Chicchiriccò Committed: Tue Jun 13 11:10:33 2017 +0200 -- .../systemadministration/javaeecontainer.adoc| 8 1 file changed, 4 insertions(+), 4 deletions(-) -- http://git-wip-us.apache.org/repos/asf/syncope/blob/ddf2d5ee/src/main/asciidoc/reference-guide/workingwithapachesyncope/systemadministration/javaeecontainer.adoc -- diff --git a/src/main/asciidoc/reference-guide/workingwithapachesyncope/systemadministration/javaeecontainer.adoc b/src/main/asciidoc/reference-guide/workingwithapachesyncope/systemadministration/javaeecontainer.adoc index 58c4b59..a7ea928 100644 --- a/src/main/asciidoc/reference-guide/workingwithapachesyncope/systemadministration/javaeecontainer.adoc +++ b/src/main/asciidoc/reference-guide/workingwithapachesyncope/systemadministration/javaeecontainer.adoc @@ -42,7 +42,7 @@ domain and MySQL): please also check that the connection parameters are the same [source,xml] - - jdbc/MasterDataSource - jdbc/MasterDataSource + jdbc/syncopeMasterDataSource + jdbc/syncopeMasterDataSource right after `` in `core/src/main/webapp/WEB-INF/glassfish-web.xml`, assuming that your Glassfish instance -provides a datasource named `jdbc/MasterDataSource`. +provides a datasource named `jdbc/syncopeMasterDataSource`. = Wildfly 9 and 10
[4/4] syncope git commit: [SYNCOPE-1084] Running MySQL fine with HikariCP
[SYNCOPE-1084] Running MySQL fine with HikariCP Project: http://git-wip-us.apache.org/repos/asf/syncope/repo Commit: http://git-wip-us.apache.org/repos/asf/syncope/commit/8cee3808 Tree: http://git-wip-us.apache.org/repos/asf/syncope/tree/8cee3808 Diff: http://git-wip-us.apache.org/repos/asf/syncope/diff/8cee3808 Branch: refs/heads/master Commit: 8cee38084c20592ecb80c5cd0caf3e2127bda6af Parents: be06f86 Author: Francesco ChicchiriccòAuthored: Tue Jun 13 12:59:07 2017 +0200 Committer: Francesco Chicchiriccò Committed: Tue Jun 13 13:23:21 2017 +0200 -- fit/core-reference/pom.xml| 4 ++-- .../src/main/resources/mysql/domains/Master.properties| 2 +- .../systemadministration/dbms.adoc| 4 ++-- .../systemadministration/javaeecontainer.adoc | 10 ++ 4 files changed, 11 insertions(+), 9 deletions(-) -- http://git-wip-us.apache.org/repos/asf/syncope/blob/8cee3808/fit/core-reference/pom.xml -- diff --git a/fit/core-reference/pom.xml b/fit/core-reference/pom.xml index 83454f2..7d395d7 100644 --- a/fit/core-reference/pom.xml +++ b/fit/core-reference/pom.xml @@ -524,7 +524,7 @@ under the License. mysql mysql-connector-java - 5.1.39 + 5.1.42 test @@ -560,7 +560,7 @@ under the License. org.mariadb.jdbc mariadb-java-client - 1.5.9 + 1.6.1 test http://git-wip-us.apache.org/repos/asf/syncope/blob/8cee3808/fit/core-reference/src/main/resources/mysql/domains/Master.properties -- diff --git a/fit/core-reference/src/main/resources/mysql/domains/Master.properties b/fit/core-reference/src/main/resources/mysql/domains/Master.properties index ce7251f..ce09eec 100644 --- a/fit/core-reference/src/main/resources/mysql/domains/Master.properties +++ b/fit/core-reference/src/main/resources/mysql/domains/Master.properties @@ -15,7 +15,7 @@ # specific language governing permissions and limitations # under the License. Master.driverClassName=com.mysql.jdbc.Driver -Master.url=jdbc:mysql://localhost:3306/syncope?characterEncoding=UTF-8 +Master.url=jdbc:mysql://localhost:3306/syncope?characterEncoding=UTF-8=true Master.schema= Master.username=syncope Master.password=syncope http://git-wip-us.apache.org/repos/asf/syncope/blob/8cee3808/src/main/asciidoc/reference-guide/workingwithapachesyncope/systemadministration/dbms.adoc -- diff --git a/src/main/asciidoc/reference-guide/workingwithapachesyncope/systemadministration/dbms.adoc b/src/main/asciidoc/reference-guide/workingwithapachesyncope/systemadministration/dbms.adoc index 2734785..4849c60 100644 --- a/src/main/asciidoc/reference-guide/workingwithapachesyncope/systemadministration/dbms.adoc +++ b/src/main/asciidoc/reference-guide/workingwithapachesyncope/systemadministration/dbms.adoc @@ -64,7 +64,7 @@ In `domains/Master.properties` (for the `Master` domain): Master.driverClassName=com.mysql.jdbc.Driver -Master.url=jdbc:mysql://localhost:3306/syncope?characterEncoding=UTF-8 +Master.url=jdbc:mysql://localhost:3306/syncope?characterEncoding=UTF-8=true Master.schema= Master.username=syncope Master.password=syncope @@ -107,7 +107,7 @@ Master.orm=META-INF/spring-orm.xml [WARNING] -This assumes that you have a MySQL instance running on localhost, listening on its default port 3306 with a database +This assumes that you have a MariaDB instance running on localhost, listening on its default port 3306 with a database `syncope` fully accessible by user `syncope` with password `syncope`. = Oracle Database http://git-wip-us.apache.org/repos/asf/syncope/blob/8cee3808/src/main/asciidoc/reference-guide/workingwithapachesyncope/systemadministration/javaeecontainer.adoc -- diff --git a/src/main/asciidoc/reference-guide/workingwithapachesyncope/systemadministration/javaeecontainer.adoc b/src/main/asciidoc/reference-guide/workingwithapachesyncope/systemadministration/javaeecontainer.adoc index 18a049e..23cc56e 100644 --- a/src/main/asciidoc/reference-guide/workingwithapachesyncope/systemadministration/javaeecontainer.adoc +++ b/src/main/asciidoc/reference-guide/workingwithapachesyncope/systemadministration/javaeecontainer.adoc @@ -42,10 +42,12 @@ domain and MySQL): please also check that the connection parameters are the same
[2/4] syncope git commit: Always conditionally handling notification and audit events in a Quartz job
Always conditionally handling notification and audit events in a Quartz job Project: http://git-wip-us.apache.org/repos/asf/syncope/repo Commit: http://git-wip-us.apache.org/repos/asf/syncope/commit/d310af83 Tree: http://git-wip-us.apache.org/repos/asf/syncope/tree/d310af83 Diff: http://git-wip-us.apache.org/repos/asf/syncope/diff/d310af83 Branch: refs/heads/master Commit: d310af8337e3fbc410d70e21f62e6bd40ffd753e Parents: c626205 Author: Francesco ChicchiriccòAuthored: Tue Jun 13 11:14:02 2017 +0200 Committer: Francesco Chicchiriccò Committed: Tue Jun 13 13:23:14 2017 +0200 -- .../pushpull/AbstractPushResultHandler.java | 55 +++- .../pushpull/RealmPushResultHandlerImpl.java| 41 ++- 2 files changed, 68 insertions(+), 28 deletions(-) -- http://git-wip-us.apache.org/repos/asf/syncope/blob/d310af83/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/pushpull/AbstractPushResultHandler.java -- diff --git a/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/pushpull/AbstractPushResultHandler.java b/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/pushpull/AbstractPushResultHandler.java index 542009b..d84fa25 100644 --- a/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/pushpull/AbstractPushResultHandler.java +++ b/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/pushpull/AbstractPushResultHandler.java @@ -46,9 +46,11 @@ import org.apache.syncope.core.persistence.api.entity.anyobject.AnyObject; import org.apache.syncope.core.persistence.api.entity.group.Group; import org.apache.syncope.core.persistence.api.entity.resource.MappingItem; import org.apache.syncope.core.persistence.api.entity.resource.Provision; +import org.apache.syncope.core.provisioning.api.AuditManager; import org.apache.syncope.core.provisioning.api.MappingManager; import org.apache.syncope.core.provisioning.api.TimeoutException; import org.apache.syncope.core.provisioning.api.event.AfterHandlingEvent; +import org.apache.syncope.core.provisioning.api.notification.NotificationManager; import org.apache.syncope.core.provisioning.api.pushpull.IgnoreProvisionException; import org.apache.syncope.core.provisioning.api.pushpull.SyncopePushResultHandler; import org.apache.syncope.core.provisioning.api.utils.EntityUtils; @@ -66,6 +68,18 @@ import org.springframework.transaction.annotation.Transactional; public abstract class AbstractPushResultHandler extends AbstractSyncopeResultHandler implements SyncopePushResultHandler { +/** + * Notification Manager. + */ +@Autowired +protected NotificationManager notificationManager; + +/** + * Audit Manager. + */ +@Autowired +protected AuditManager auditManager; + @Autowired protected MappingManager mappingManager; @@ -196,7 +210,6 @@ public abstract class AbstractPushResultHandler extends AbstractSyncopeResultHan Object output = null; Result resultStatus = null; -String operation = null; // Try to read remote object BEFORE any actual operation Provision provision = profile.getTask().getResource().getProvision(any.getType()); @@ -214,9 +227,22 @@ public abstract class AbstractPushResultHandler extends AbstractSyncopeResultHan } result.setStatus(ProvisioningReport.Status.SUCCESS); } else { +String operation = beforeObj == null +? UnmatchingRule.toEventName(profile.getTask().getUnmatchingRule()) +: MatchingRule.toEventName(profile.getTask().getMatchingRule()); + +boolean notificationsAvailable = notificationManager.notificationsAvailable( +AuditElements.EventCategoryType.PUSH, +any.getType().getKind().name().toLowerCase(), +profile.getTask().getResource().getKey(), +operation); +boolean auditRequested = auditManager.auditRequested( +AuditElements.EventCategoryType.PUSH, +any.getType().getKind().name().toLowerCase(), +profile.getTask().getResource().getKey(), +operation); try { if (beforeObj == null) { -operation = UnmatchingRule.toEventName(profile.getTask().getUnmatchingRule()); result.setOperation(getResourceOperation(profile.getTask().getUnmatchingRule())); switch (profile.getTask().getUnmatchingRule()) { @@ -266,7 +292,6 @@ public abstract class
[4/4] syncope git commit: [SYNCOPE-1084] Running MySQL fine with HikariCP
[SYNCOPE-1084] Running MySQL fine with HikariCP Project: http://git-wip-us.apache.org/repos/asf/syncope/repo Commit: http://git-wip-us.apache.org/repos/asf/syncope/commit/1bf49e3f Tree: http://git-wip-us.apache.org/repos/asf/syncope/tree/1bf49e3f Diff: http://git-wip-us.apache.org/repos/asf/syncope/diff/1bf49e3f Branch: refs/heads/2_0_X Commit: 1bf49e3fd9f934c1bc4e7d4ee0e715e49f1e2bc7 Parents: 3ad2ef7 Author: Francesco ChicchiriccòAuthored: Tue Jun 13 12:59:07 2017 +0200 Committer: Francesco Chicchiriccò Committed: Tue Jun 13 12:59:07 2017 +0200 -- fit/core-reference/pom.xml| 4 ++-- .../src/main/resources/mysql/domains/Master.properties| 2 +- .../systemadministration/dbms.adoc| 4 ++-- .../systemadministration/javaeecontainer.adoc | 10 ++ 4 files changed, 11 insertions(+), 9 deletions(-) -- http://git-wip-us.apache.org/repos/asf/syncope/blob/1bf49e3f/fit/core-reference/pom.xml -- diff --git a/fit/core-reference/pom.xml b/fit/core-reference/pom.xml index 1a116aa..8aa248b 100644 --- a/fit/core-reference/pom.xml +++ b/fit/core-reference/pom.xml @@ -524,7 +524,7 @@ under the License. mysql mysql-connector-java - 5.1.39 + 5.1.42 test @@ -560,7 +560,7 @@ under the License. org.mariadb.jdbc mariadb-java-client - 1.5.9 + 1.6.1 test http://git-wip-us.apache.org/repos/asf/syncope/blob/1bf49e3f/fit/core-reference/src/main/resources/mysql/domains/Master.properties -- diff --git a/fit/core-reference/src/main/resources/mysql/domains/Master.properties b/fit/core-reference/src/main/resources/mysql/domains/Master.properties index ce7251f..ce09eec 100644 --- a/fit/core-reference/src/main/resources/mysql/domains/Master.properties +++ b/fit/core-reference/src/main/resources/mysql/domains/Master.properties @@ -15,7 +15,7 @@ # specific language governing permissions and limitations # under the License. Master.driverClassName=com.mysql.jdbc.Driver -Master.url=jdbc:mysql://localhost:3306/syncope?characterEncoding=UTF-8 +Master.url=jdbc:mysql://localhost:3306/syncope?characterEncoding=UTF-8=true Master.schema= Master.username=syncope Master.password=syncope http://git-wip-us.apache.org/repos/asf/syncope/blob/1bf49e3f/src/main/asciidoc/reference-guide/workingwithapachesyncope/systemadministration/dbms.adoc -- diff --git a/src/main/asciidoc/reference-guide/workingwithapachesyncope/systemadministration/dbms.adoc b/src/main/asciidoc/reference-guide/workingwithapachesyncope/systemadministration/dbms.adoc index 2734785..4849c60 100644 --- a/src/main/asciidoc/reference-guide/workingwithapachesyncope/systemadministration/dbms.adoc +++ b/src/main/asciidoc/reference-guide/workingwithapachesyncope/systemadministration/dbms.adoc @@ -64,7 +64,7 @@ In `domains/Master.properties` (for the `Master` domain): Master.driverClassName=com.mysql.jdbc.Driver -Master.url=jdbc:mysql://localhost:3306/syncope?characterEncoding=UTF-8 +Master.url=jdbc:mysql://localhost:3306/syncope?characterEncoding=UTF-8=true Master.schema= Master.username=syncope Master.password=syncope @@ -107,7 +107,7 @@ Master.orm=META-INF/spring-orm.xml [WARNING] -This assumes that you have a MySQL instance running on localhost, listening on its default port 3306 with a database +This assumes that you have a MariaDB instance running on localhost, listening on its default port 3306 with a database `syncope` fully accessible by user `syncope` with password `syncope`. = Oracle Database http://git-wip-us.apache.org/repos/asf/syncope/blob/1bf49e3f/src/main/asciidoc/reference-guide/workingwithapachesyncope/systemadministration/javaeecontainer.adoc -- diff --git a/src/main/asciidoc/reference-guide/workingwithapachesyncope/systemadministration/javaeecontainer.adoc b/src/main/asciidoc/reference-guide/workingwithapachesyncope/systemadministration/javaeecontainer.adoc index a7ea928..d0eca2c 100644 --- a/src/main/asciidoc/reference-guide/workingwithapachesyncope/systemadministration/javaeecontainer.adoc +++ b/src/main/asciidoc/reference-guide/workingwithapachesyncope/systemadministration/javaeecontainer.adoc @@ -44,10 +44,12 @@ domain and MySQL): please also check that the connection parameters are the same
[3/4] syncope git commit: Ensuring SAML2ITCase is disabled when running tests without SAML support
Ensuring SAML2ITCase is disabled when running tests without SAML support Project: http://git-wip-us.apache.org/repos/asf/syncope/repo Commit: http://git-wip-us.apache.org/repos/asf/syncope/commit/3ad2ef76 Tree: http://git-wip-us.apache.org/repos/asf/syncope/tree/3ad2ef76 Diff: http://git-wip-us.apache.org/repos/asf/syncope/diff/3ad2ef76 Branch: refs/heads/2_0_X Commit: 3ad2ef76d5787bae38ebf9ab5c752b7a72c157f6 Parents: ae947c7 Author: Francesco ChicchiriccòAuthored: Tue Jun 13 12:57:48 2017 +0200 Committer: Francesco Chicchiriccò Committed: Tue Jun 13 12:57:48 2017 +0200 -- .../java/org/apache/syncope/fit/core/SAML2ITCase.java | 12 ++-- 1 file changed, 10 insertions(+), 2 deletions(-) -- http://git-wip-us.apache.org/repos/asf/syncope/blob/3ad2ef76/fit/core-reference/src/test/java/org/apache/syncope/fit/core/SAML2ITCase.java -- diff --git a/fit/core-reference/src/test/java/org/apache/syncope/fit/core/SAML2ITCase.java b/fit/core-reference/src/test/java/org/apache/syncope/fit/core/SAML2ITCase.java index ece9e6c..6e4cbca 100644 --- a/fit/core-reference/src/test/java/org/apache/syncope/fit/core/SAML2ITCase.java +++ b/fit/core-reference/src/test/java/org/apache/syncope/fit/core/SAML2ITCase.java @@ -63,7 +63,9 @@ public class SAML2ITCase extends AbstractITCase { @BeforeClass public static void importFromIdPMetadata() { -Assume.assumeTrue(SAML2SPDetector.isSAML2SPAvailable()); +if (!SAML2SPDetector.isSAML2SPAvailable()) { +return; +} assertTrue(saml2IdPService.list().isEmpty()); @@ -86,7 +88,9 @@ public class SAML2ITCase extends AbstractITCase { @AfterClass public static void clearIdPs() { -Assume.assumeTrue(SAML2SPDetector.isSAML2SPAvailable()); +if (!SAML2SPDetector.isSAML2SPAvailable()) { +return; +} for (SAML2IdPTO idp : saml2IdPService.list()) { saml2IdPService.delete(idp.getKey()); @@ -115,6 +119,8 @@ public class SAML2ITCase extends AbstractITCase { @Test public void createLoginRequest() { +Assume.assumeTrue(SAML2SPDetector.isSAML2SPAvailable()); + SAML2RequestTO loginRequest = anonymous.getService(SAML2SPService.class). createLoginRequest(ADDRESS, "https://idp.testshib.org/idp/shibboleth;); assertNotNull(loginRequest); @@ -127,6 +133,8 @@ public class SAML2ITCase extends AbstractITCase { @Test public void setIdPMapping() { +Assume.assumeTrue(SAML2SPDetector.isSAML2SPAvailable()); + SAML2IdPTO ssoCircle = IterableUtils.find(saml2IdPService.list(), new Predicate() { @Override
[3/4] syncope git commit: Ensuring SAML2ITCase is disabled when running tests without SAML support
Ensuring SAML2ITCase is disabled when running tests without SAML support Project: http://git-wip-us.apache.org/repos/asf/syncope/repo Commit: http://git-wip-us.apache.org/repos/asf/syncope/commit/be06f868 Tree: http://git-wip-us.apache.org/repos/asf/syncope/tree/be06f868 Diff: http://git-wip-us.apache.org/repos/asf/syncope/diff/be06f868 Branch: refs/heads/master Commit: be06f8684568ccecdef7952d3121db2051cf291f Parents: d310af8 Author: Francesco ChicchiriccòAuthored: Tue Jun 13 12:57:48 2017 +0200 Committer: Francesco Chicchiriccò Committed: Tue Jun 13 13:23:18 2017 +0200 -- .../java/org/apache/syncope/fit/core/SAML2ITCase.java | 12 ++-- 1 file changed, 10 insertions(+), 2 deletions(-) -- http://git-wip-us.apache.org/repos/asf/syncope/blob/be06f868/fit/core-reference/src/test/java/org/apache/syncope/fit/core/SAML2ITCase.java -- diff --git a/fit/core-reference/src/test/java/org/apache/syncope/fit/core/SAML2ITCase.java b/fit/core-reference/src/test/java/org/apache/syncope/fit/core/SAML2ITCase.java index ece9e6c..6e4cbca 100644 --- a/fit/core-reference/src/test/java/org/apache/syncope/fit/core/SAML2ITCase.java +++ b/fit/core-reference/src/test/java/org/apache/syncope/fit/core/SAML2ITCase.java @@ -63,7 +63,9 @@ public class SAML2ITCase extends AbstractITCase { @BeforeClass public static void importFromIdPMetadata() { -Assume.assumeTrue(SAML2SPDetector.isSAML2SPAvailable()); +if (!SAML2SPDetector.isSAML2SPAvailable()) { +return; +} assertTrue(saml2IdPService.list().isEmpty()); @@ -86,7 +88,9 @@ public class SAML2ITCase extends AbstractITCase { @AfterClass public static void clearIdPs() { -Assume.assumeTrue(SAML2SPDetector.isSAML2SPAvailable()); +if (!SAML2SPDetector.isSAML2SPAvailable()) { +return; +} for (SAML2IdPTO idp : saml2IdPService.list()) { saml2IdPService.delete(idp.getKey()); @@ -115,6 +119,8 @@ public class SAML2ITCase extends AbstractITCase { @Test public void createLoginRequest() { +Assume.assumeTrue(SAML2SPDetector.isSAML2SPAvailable()); + SAML2RequestTO loginRequest = anonymous.getService(SAML2SPService.class). createLoginRequest(ADDRESS, "https://idp.testshib.org/idp/shibboleth;); assertNotNull(loginRequest); @@ -127,6 +133,8 @@ public class SAML2ITCase extends AbstractITCase { @Test public void setIdPMapping() { +Assume.assumeTrue(SAML2SPDetector.isSAML2SPAvailable()); + SAML2IdPTO ssoCircle = IterableUtils.find(saml2IdPService.list(), new Predicate() { @Override
[1/4] syncope git commit: Fixing JNDI name for DataSource
Repository: syncope Updated Branches: refs/heads/master 4f6c1dac9 -> 8cee38084 Fixing JNDI name for DataSource Project: http://git-wip-us.apache.org/repos/asf/syncope/repo Commit: http://git-wip-us.apache.org/repos/asf/syncope/commit/c6262057 Tree: http://git-wip-us.apache.org/repos/asf/syncope/tree/c6262057 Diff: http://git-wip-us.apache.org/repos/asf/syncope/diff/c6262057 Branch: refs/heads/master Commit: c6262057436ec99ee9d6b7b7c6665f824ce32b28 Parents: 4f6c1da Author: Francesco ChicchiriccòAuthored: Tue Jun 13 11:10:33 2017 +0200 Committer: Francesco Chicchiriccò Committed: Tue Jun 13 13:23:10 2017 +0200 -- .../systemadministration/javaeecontainer.adoc| 8 1 file changed, 4 insertions(+), 4 deletions(-) -- http://git-wip-us.apache.org/repos/asf/syncope/blob/c6262057/src/main/asciidoc/reference-guide/workingwithapachesyncope/systemadministration/javaeecontainer.adoc -- diff --git a/src/main/asciidoc/reference-guide/workingwithapachesyncope/systemadministration/javaeecontainer.adoc b/src/main/asciidoc/reference-guide/workingwithapachesyncope/systemadministration/javaeecontainer.adoc index 4111342..18a049e 100644 --- a/src/main/asciidoc/reference-guide/workingwithapachesyncope/systemadministration/javaeecontainer.adoc +++ b/src/main/asciidoc/reference-guide/workingwithapachesyncope/systemadministration/javaeecontainer.adoc @@ -40,7 +40,7 @@ domain and MySQL): please also check that the connection parameters are the same [source,xml] - - jdbc/MasterDataSource - jdbc/MasterDataSource + jdbc/syncopeMasterDataSource + jdbc/syncopeMasterDataSource right after `` in `core/src/main/webapp/WEB-INF/glassfish-web.xml`, assuming that your Glassfish instance -provides a datasource named `jdbc/MasterDataSource`. +provides a datasource named `jdbc/syncopeMasterDataSource`. = Wildfly 9 and 10
[1/2] syncope git commit: [SYNCOPE-1109] Various fixes
Repository: syncope Updated Branches: refs/heads/2_0_X 1bf49e3fd -> e5a8f1f92 refs/heads/master 8cee38084 -> 06f3fdd73 [SYNCOPE-1109] Various fixes Project: http://git-wip-us.apache.org/repos/asf/syncope/repo Commit: http://git-wip-us.apache.org/repos/asf/syncope/commit/e5a8f1f9 Tree: http://git-wip-us.apache.org/repos/asf/syncope/tree/e5a8f1f9 Diff: http://git-wip-us.apache.org/repos/asf/syncope/diff/e5a8f1f9 Branch: refs/heads/2_0_X Commit: e5a8f1f92d29de289b291d60bcecbfbff48d Parents: 1bf49e3 Author: Francesco ChicchiriccòAuthored: Tue Jun 13 15:31:57 2017 +0200 Committer: Francesco Chicchiriccò Committed: Tue Jun 13 15:31:57 2017 +0200 -- .../src/main/webapp/WEB-INF/glassfish-web.xml | 4 +- .../src/main/webapp/WEB-INF/weblogic.xml| 45 installer/pom.xml | 5 +- .../syncope/installer/files/ConsolePom.java | 108 + .../apache/syncope/installer/files/CorePom.java | 7 +- .../installer/files/GlassfishCoreWebXml.java| 4 +- .../installer/files/MasterProperties.java | 16 ++- .../installer/processes/ArchetypeProcess.java | 59 -- .../installer/processes/ContainerProcess.java | 31 ++--- .../installer/utilities/FileSystemUtils.java| 26 ++--- .../syncope/installer/utilities/MavenUtils.java | 33 -- .../validators/ContainerValidator.java | 4 +- .../src/main/resources/installer.properties | 1 - .../main/resources/izpack/ProcessPanel.Spec.xml | 29 ++--- .../main/resources/izpack/userInputLang.xml_eng | 2 +- .../main/resources/izpack/userInputLang.xml_ita | 2 +- .../src/main/resources/izpack/userInputSpec.xml | 2 +- installer/src/main/resources/modelerPom.xml | 115 --- 18 files changed, 227 insertions(+), 266 deletions(-) -- http://git-wip-us.apache.org/repos/asf/syncope/blob/e5a8f1f9/fit/core-reference/src/main/webapp/WEB-INF/glassfish-web.xml -- diff --git a/fit/core-reference/src/main/webapp/WEB-INF/glassfish-web.xml b/fit/core-reference/src/main/webapp/WEB-INF/glassfish-web.xml index ab6a9bf..2578cf5 100644 --- a/fit/core-reference/src/main/webapp/WEB-INF/glassfish-web.xml +++ b/fit/core-reference/src/main/webapp/WEB-INF/glassfish-web.xml @@ -23,8 +23,8 @@ GlassFish Application Server 3.1 Servlet 3.0//EN" "http://glassfish.org/dtds/gla /syncope http://git-wip-us.apache.org/repos/asf/syncope/blob/e5a8f1f9/fit/core-reference/src/main/webapp/WEB-INF/weblogic.xml -- diff --git a/fit/core-reference/src/main/webapp/WEB-INF/weblogic.xml b/fit/core-reference/src/main/webapp/WEB-INF/weblogic.xml deleted file mode 100644 index e3db665..000 --- a/fit/core-reference/src/main/webapp/WEB-INF/weblogic.xml +++ /dev/null @@ -1,45 +0,0 @@ - - -http://xmlns.oracle.com/weblogic/weblogic-web-app; - xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance; - xsi:schemaLocation="http://xmlns.oracle.com/weblogic/weblogic-web-app - http://xmlns.oracle.com/weblogic/weblogic-web-app/1.4/weblogic-web-app.xsd;> - - syncope - - - - javax.ws.rs.* - javax.validation.* - org.apache.cxf.* - org.apache.commons.* - org.apache.openjpa.* - org.slf4j.* - org.apache.logging.log4j.* - com.fasterxml.jackson.* - - - - - - http://git-wip-us.apache.org/repos/asf/syncope/blob/e5a8f1f9/installer/pom.xml -- diff --git a/installer/pom.xml b/installer/pom.xml index 97db2f6..67a4b62 100644 --- a/installer/pom.xml +++ b/installer/pom.xml @@ -178,7 +178,6 @@ under the License. src/main/resources installer.properties - modelerPom.xml @@ -190,13 +189,13 @@ under the License. ${basedir}/../fit/core-reference/src/main/resources/all - provisioning.properties + workflow.properties ${basedir}/../fit/core-reference/src/main/resources - workflow.properties + provisioning.properties http://git-wip-us.apache.org/repos/asf/syncope/blob/e5a8f1f9/installer/src/main/java/org/apache/syncope/installer/files/ConsolePom.java -- diff --git a/installer/src/main/java/org/apache/syncope/installer/files/ConsolePom.java b/installer/src/main/java/org/apache/syncope/installer/files/ConsolePom.java new file mode 100644 index 000..57a1bd3 --- /dev/null +++
[2/2] syncope git commit: [SYNCOPE-1109] Various fixes
[SYNCOPE-1109] Various fixes Project: http://git-wip-us.apache.org/repos/asf/syncope/repo Commit: http://git-wip-us.apache.org/repos/asf/syncope/commit/06f3fdd7 Tree: http://git-wip-us.apache.org/repos/asf/syncope/tree/06f3fdd7 Diff: http://git-wip-us.apache.org/repos/asf/syncope/diff/06f3fdd7 Branch: refs/heads/master Commit: 06f3fdd73e6b08f400d6551b4607d9527b70ef0d Parents: 8cee380 Author: Francesco ChicchiriccòAuthored: Tue Jun 13 15:31:57 2017 +0200 Committer: Francesco Chicchiriccò Committed: Tue Jun 13 15:32:08 2017 +0200 -- .../src/main/webapp/WEB-INF/glassfish-web.xml | 4 +- .../src/main/webapp/WEB-INF/weblogic.xml| 45 installer/pom.xml | 5 +- .../syncope/installer/files/ConsolePom.java | 108 + .../apache/syncope/installer/files/CorePom.java | 7 +- .../installer/files/GlassfishCoreWebXml.java| 4 +- .../installer/files/MasterProperties.java | 16 ++- .../installer/processes/ArchetypeProcess.java | 59 -- .../installer/processes/ContainerProcess.java | 31 ++--- .../installer/utilities/FileSystemUtils.java| 26 ++--- .../syncope/installer/utilities/MavenUtils.java | 33 -- .../validators/ContainerValidator.java | 4 +- .../src/main/resources/installer.properties | 1 - .../main/resources/izpack/ProcessPanel.Spec.xml | 29 ++--- .../main/resources/izpack/userInputLang.xml_eng | 2 +- .../main/resources/izpack/userInputLang.xml_ita | 2 +- .../src/main/resources/izpack/userInputSpec.xml | 2 +- installer/src/main/resources/modelerPom.xml | 115 --- 18 files changed, 227 insertions(+), 266 deletions(-) -- http://git-wip-us.apache.org/repos/asf/syncope/blob/06f3fdd7/fit/core-reference/src/main/webapp/WEB-INF/glassfish-web.xml -- diff --git a/fit/core-reference/src/main/webapp/WEB-INF/glassfish-web.xml b/fit/core-reference/src/main/webapp/WEB-INF/glassfish-web.xml index ab6a9bf..2578cf5 100644 --- a/fit/core-reference/src/main/webapp/WEB-INF/glassfish-web.xml +++ b/fit/core-reference/src/main/webapp/WEB-INF/glassfish-web.xml @@ -23,8 +23,8 @@ GlassFish Application Server 3.1 Servlet 3.0//EN" "http://glassfish.org/dtds/gla /syncope http://git-wip-us.apache.org/repos/asf/syncope/blob/06f3fdd7/fit/core-reference/src/main/webapp/WEB-INF/weblogic.xml -- diff --git a/fit/core-reference/src/main/webapp/WEB-INF/weblogic.xml b/fit/core-reference/src/main/webapp/WEB-INF/weblogic.xml deleted file mode 100644 index e3db665..000 --- a/fit/core-reference/src/main/webapp/WEB-INF/weblogic.xml +++ /dev/null @@ -1,45 +0,0 @@ - - -http://xmlns.oracle.com/weblogic/weblogic-web-app; - xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance; - xsi:schemaLocation="http://xmlns.oracle.com/weblogic/weblogic-web-app - http://xmlns.oracle.com/weblogic/weblogic-web-app/1.4/weblogic-web-app.xsd;> - - syncope - - - - javax.ws.rs.* - javax.validation.* - org.apache.cxf.* - org.apache.commons.* - org.apache.openjpa.* - org.slf4j.* - org.apache.logging.log4j.* - com.fasterxml.jackson.* - - - - - - http://git-wip-us.apache.org/repos/asf/syncope/blob/06f3fdd7/installer/pom.xml -- diff --git a/installer/pom.xml b/installer/pom.xml index 2a20bfa..227bd89 100644 --- a/installer/pom.xml +++ b/installer/pom.xml @@ -178,7 +178,6 @@ under the License. src/main/resources installer.properties - modelerPom.xml @@ -190,13 +189,13 @@ under the License. ${basedir}/../fit/core-reference/src/main/resources/all - provisioning.properties + workflow.properties ${basedir}/../fit/core-reference/src/main/resources - workflow.properties + provisioning.properties http://git-wip-us.apache.org/repos/asf/syncope/blob/06f3fdd7/installer/src/main/java/org/apache/syncope/installer/files/ConsolePom.java -- diff --git a/installer/src/main/java/org/apache/syncope/installer/files/ConsolePom.java b/installer/src/main/java/org/apache/syncope/installer/files/ConsolePom.java new file mode 100644 index 000..57a1bd3 --- /dev/null +++ b/installer/src/main/java/org/apache/syncope/installer/files/ConsolePom.java @@ -0,0 +1,108 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or
[1/2] syncope git commit: Fixing a few references to syncopeDataSource
Repository: syncope Updated Branches: refs/heads/2_0_X 35019bc57 -> f0ea28843 Fixing a few references to syncopeDataSource Project: http://git-wip-us.apache.org/repos/asf/syncope/repo Commit: http://git-wip-us.apache.org/repos/asf/syncope/commit/874b6217 Tree: http://git-wip-us.apache.org/repos/asf/syncope/tree/874b6217 Diff: http://git-wip-us.apache.org/repos/asf/syncope/diff/874b6217 Branch: refs/heads/2_0_X Commit: 874b62174a33e32a4c9c987f3653fb053afc63e0 Parents: 35019bc Author: Colm O hEigeartaighAuthored: Tue Jun 13 14:54:32 2017 +0100 Committer: Colm O hEigeartaigh Committed: Tue Jun 13 15:16:51 2017 +0100 -- deb/core/src/deb/tomcat8/syncope.xml | 4 ++-- src/main/asciidoc/getting-started/obtain.adoc | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) -- http://git-wip-us.apache.org/repos/asf/syncope/blob/874b6217/deb/core/src/deb/tomcat8/syncope.xml -- diff --git a/deb/core/src/deb/tomcat8/syncope.xml b/deb/core/src/deb/tomcat8/syncope.xml index 7581654..b06a129 100644 --- a/deb/core/src/deb/tomcat8/syncope.xml +++ b/deb/core/src/deb/tomcat8/syncope.xml @@ -25,7 +25,7 @@ under the License.
[2/2] syncope git commit: Fixing a few references to syncopeDataSource
Fixing a few references to syncopeDataSource Project: http://git-wip-us.apache.org/repos/asf/syncope/repo Commit: http://git-wip-us.apache.org/repos/asf/syncope/commit/f9031b67 Tree: http://git-wip-us.apache.org/repos/asf/syncope/tree/f9031b67 Diff: http://git-wip-us.apache.org/repos/asf/syncope/diff/f9031b67 Branch: refs/heads/master Commit: f9031b674f4be7c2994a556626319679e09f9ed5 Parents: 9f979f6 Author: Colm O hEigeartaighAuthored: Tue Jun 13 14:54:32 2017 +0100 Committer: Colm O hEigeartaigh Committed: Tue Jun 13 15:16:32 2017 +0100 -- deb/core/src/deb/tomcat8/syncope.xml | 4 ++-- src/main/asciidoc/getting-started/obtain.adoc | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) -- http://git-wip-us.apache.org/repos/asf/syncope/blob/f9031b67/deb/core/src/deb/tomcat8/syncope.xml -- diff --git a/deb/core/src/deb/tomcat8/syncope.xml b/deb/core/src/deb/tomcat8/syncope.xml index 7581654..b06a129 100644 --- a/deb/core/src/deb/tomcat8/syncope.xml +++ b/deb/core/src/deb/tomcat8/syncope.xml @@ -25,7 +25,7 @@ under the License.
[1/2] syncope git commit: Updating httpclient to 4.5.3 (see https://issues.apache.org/jira/browse/HTTPCLIENT-1743)
Repository: syncope Updated Branches: refs/heads/master 9f979f6aa -> d02729e63 Updating httpclient to 4.5.3 (see https://issues.apache.org/jira/browse/HTTPCLIENT-1743) Project: http://git-wip-us.apache.org/repos/asf/syncope/repo Commit: http://git-wip-us.apache.org/repos/asf/syncope/commit/d02729e6 Tree: http://git-wip-us.apache.org/repos/asf/syncope/tree/d02729e6 Diff: http://git-wip-us.apache.org/repos/asf/syncope/diff/d02729e6 Branch: refs/heads/master Commit: d02729e63680fe09761f96ae560ea849b7f4f756 Parents: f9031b6 Author: Colm O hEigeartaighAuthored: Tue Jun 13 14:54:52 2017 +0100 Committer: Colm O hEigeartaigh Committed: Tue Jun 13 15:16:32 2017 +0100 -- installer/src/main/resources/izpack/install.xml | 2 +- pom.xml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) -- http://git-wip-us.apache.org/repos/asf/syncope/blob/d02729e6/installer/src/main/resources/izpack/install.xml -- diff --git a/installer/src/main/resources/izpack/install.xml b/installer/src/main/resources/izpack/install.xml index bfed44b..4a112c1 100644 --- a/installer/src/main/resources/izpack/install.xml +++ b/installer/src/main/resources/izpack/install.xml @@ -136,7 +136,7 @@ under the License. - + http://git-wip-us.apache.org/repos/asf/syncope/blob/d02729e6/pom.xml -- diff --git a/pom.xml b/pom.xml index 151d8eb..5408bb8 100644 --- a/pom.xml +++ b/pom.xml @@ -441,7 +441,7 @@ under the License. 0.0.2 5.1.0 -4.3.6 +4.5.3 3.0.0 1.0-alpha-1 3.0.0
[2/2] syncope git commit: [SYNCOPE-1108] Avoid sending empty content to Core
[SYNCOPE-1108] Avoid sending empty content to Core Project: http://git-wip-us.apache.org/repos/asf/syncope/repo Commit: http://git-wip-us.apache.org/repos/asf/syncope/commit/9f979f6a Tree: http://git-wip-us.apache.org/repos/asf/syncope/tree/9f979f6a Diff: http://git-wip-us.apache.org/repos/asf/syncope/diff/9f979f6a Branch: refs/heads/master Commit: 9f979f6aa9f98b7fb79fd4bbf300f55aff661ff3 Parents: 06f3fdd Author: Francesco ChicchiriccòAuthored: Tue Jun 13 16:01:53 2017 +0200 Committer: Francesco Chicchiriccò Committed: Tue Jun 13 16:02:03 2017 +0200 -- .../MailTemplateDirectoryPanel.java | 25 +--- .../console/notifications/TemplateModal.java| 4 +-- .../console/panels/RoleDirectoryPanel.java | 3 +- .../console/panels/StartAtTogglePanel.java | 4 +-- .../policies/PolicyModalPanelBuilder.java | 4 +-- .../reports/ReportTemplateDirectoryPanel.java | 31 +++- .../console/topology/TopologyTogglePanel.java | 8 ++--- .../resources/ResourceProvisionPanel.java | 12 .../ReportTemplateDirectoryPanel.properties | 1 + .../ReportTemplateDirectoryPanel_it.properties | 1 + ...eportTemplateDirectoryPanel_pt_BR.properties | 1 + .../ReportTemplateDirectoryPanel_ru.properties | 1 + 12 files changed, 52 insertions(+), 43 deletions(-) -- http://git-wip-us.apache.org/repos/asf/syncope/blob/9f979f6a/client/console/src/main/java/org/apache/syncope/client/console/notifications/MailTemplateDirectoryPanel.java -- diff --git a/client/console/src/main/java/org/apache/syncope/client/console/notifications/MailTemplateDirectoryPanel.java b/client/console/src/main/java/org/apache/syncope/client/console/notifications/MailTemplateDirectoryPanel.java index 55c4bd0..355e001 100644 --- a/client/console/src/main/java/org/apache/syncope/client/console/notifications/MailTemplateDirectoryPanel.java +++ b/client/console/src/main/java/org/apache/syncope/client/console/notifications/MailTemplateDirectoryPanel.java @@ -246,17 +246,20 @@ public class MailTemplateDirectoryPanel @Override public void onSubmit(final AjaxRequestTarget target, final Form form) { -try { -restClient.updateTemplateFormat( -content.getKey(), content.getContent(), content.getFormat()); - SyncopeConsoleSession.get().info(getString(Constants.OPERATION_SUCCEEDED)); -modal.show(false); -modal.close(target); -} catch (Exception e) { -LOG.error("While updating template for {}", content.getKey(), e); - SyncopeConsoleSession.get().error(StringUtils.isBlank(e.getMessage()) -? e.getClass().getName() : e. -getMessage()); +if (StringUtils.isBlank(content.getContent())) { +SyncopeConsoleSession.get().error("No content to save"); +} else { +try { +restClient.updateTemplateFormat( +content.getKey(), content.getContent(), content.getFormat()); + SyncopeConsoleSession.get().info(getString(Constants.OPERATION_SUCCEEDED)); +modal.show(false); +modal.close(target); +} catch (Exception e) { +LOG.error("While updating template for {}", content.getKey(), e); + SyncopeConsoleSession.get().error(StringUtils.isBlank(e.getMessage()) +? e.getClass().getName() : e.getMessage()); +} } ((BasePage) pageRef.getPage()).getNotificationPanel().refresh(target); } http://git-wip-us.apache.org/repos/asf/syncope/blob/9f979f6a/client/console/src/main/java/org/apache/syncope/client/console/notifications/TemplateModal.java -- diff --git a/client/console/src/main/java/org/apache/syncope/client/console/notifications/TemplateModal.java b/client/console/src/main/java/org/apache/syncope/client/console/notifications/TemplateModal.java index d802f66..69ac0eb 100644 --- a/client/console/src/main/java/org/apache/syncope/client/console/notifications/TemplateModal.java +++ b/client/console/src/main/java/org/apache/syncope/client/console/notifications/TemplateModal.java @@ -69,8 +69,8 @@ public class TemplateModal extends AbstractModalPanel modal.close(target); } catch (SyncopeClientException e) { LOG.error("While creating template for {}", templateTO.getKey(), e); - SyncopeConsoleSession.get().error(StringUtils.isBlank(e.getMessage()) ?
[1/2] syncope git commit: [SYNCOPE-1108] Avoid sending empty content to Core
Repository: syncope Updated Branches: refs/heads/2_0_X e5a8f1f92 -> 35019bc57 refs/heads/master 06f3fdd73 -> 9f979f6aa [SYNCOPE-1108] Avoid sending empty content to Core Project: http://git-wip-us.apache.org/repos/asf/syncope/repo Commit: http://git-wip-us.apache.org/repos/asf/syncope/commit/35019bc5 Tree: http://git-wip-us.apache.org/repos/asf/syncope/tree/35019bc5 Diff: http://git-wip-us.apache.org/repos/asf/syncope/diff/35019bc5 Branch: refs/heads/2_0_X Commit: 35019bc576c9ed826bffb304021e014ed9de7519 Parents: e5a8f1f Author: Francesco ChicchiriccòAuthored: Tue Jun 13 16:01:53 2017 +0200 Committer: Francesco Chicchiriccò Committed: Tue Jun 13 16:01:53 2017 +0200 -- .../MailTemplateDirectoryPanel.java | 25 +--- .../console/notifications/TemplateModal.java| 4 +-- .../console/panels/RoleDirectoryPanel.java | 3 +- .../console/panels/StartAtTogglePanel.java | 4 +-- .../policies/PolicyModalPanelBuilder.java | 4 +-- .../reports/ReportTemplateDirectoryPanel.java | 31 +++- .../console/topology/TopologyTogglePanel.java | 8 ++--- .../resources/ResourceProvisionPanel.java | 12 .../ReportTemplateDirectoryPanel.properties | 1 + .../ReportTemplateDirectoryPanel_it.properties | 1 + ...eportTemplateDirectoryPanel_pt_BR.properties | 1 + .../ReportTemplateDirectoryPanel_ru.properties | 1 + 12 files changed, 52 insertions(+), 43 deletions(-) -- http://git-wip-us.apache.org/repos/asf/syncope/blob/35019bc5/client/console/src/main/java/org/apache/syncope/client/console/notifications/MailTemplateDirectoryPanel.java -- diff --git a/client/console/src/main/java/org/apache/syncope/client/console/notifications/MailTemplateDirectoryPanel.java b/client/console/src/main/java/org/apache/syncope/client/console/notifications/MailTemplateDirectoryPanel.java index 55c4bd0..355e001 100644 --- a/client/console/src/main/java/org/apache/syncope/client/console/notifications/MailTemplateDirectoryPanel.java +++ b/client/console/src/main/java/org/apache/syncope/client/console/notifications/MailTemplateDirectoryPanel.java @@ -246,17 +246,20 @@ public class MailTemplateDirectoryPanel @Override public void onSubmit(final AjaxRequestTarget target, final Form form) { -try { -restClient.updateTemplateFormat( -content.getKey(), content.getContent(), content.getFormat()); - SyncopeConsoleSession.get().info(getString(Constants.OPERATION_SUCCEEDED)); -modal.show(false); -modal.close(target); -} catch (Exception e) { -LOG.error("While updating template for {}", content.getKey(), e); - SyncopeConsoleSession.get().error(StringUtils.isBlank(e.getMessage()) -? e.getClass().getName() : e. -getMessage()); +if (StringUtils.isBlank(content.getContent())) { +SyncopeConsoleSession.get().error("No content to save"); +} else { +try { +restClient.updateTemplateFormat( +content.getKey(), content.getContent(), content.getFormat()); + SyncopeConsoleSession.get().info(getString(Constants.OPERATION_SUCCEEDED)); +modal.show(false); +modal.close(target); +} catch (Exception e) { +LOG.error("While updating template for {}", content.getKey(), e); + SyncopeConsoleSession.get().error(StringUtils.isBlank(e.getMessage()) +? e.getClass().getName() : e.getMessage()); +} } ((BasePage) pageRef.getPage()).getNotificationPanel().refresh(target); } http://git-wip-us.apache.org/repos/asf/syncope/blob/35019bc5/client/console/src/main/java/org/apache/syncope/client/console/notifications/TemplateModal.java -- diff --git a/client/console/src/main/java/org/apache/syncope/client/console/notifications/TemplateModal.java b/client/console/src/main/java/org/apache/syncope/client/console/notifications/TemplateModal.java index d802f66..69ac0eb 100644 --- a/client/console/src/main/java/org/apache/syncope/client/console/notifications/TemplateModal.java +++ b/client/console/src/main/java/org/apache/syncope/client/console/notifications/TemplateModal.java @@ -69,8 +69,8 @@ public class TemplateModal extends AbstractModalPanel modal.close(target); } catch (SyncopeClientException e) { LOG.error("While creating template for
[2/2] syncope git commit: Updating httpclient to 4.5.3 (see https://issues.apache.org/jira/browse/HTTPCLIENT-1743)
Updating httpclient to 4.5.3 (see https://issues.apache.org/jira/browse/HTTPCLIENT-1743) Project: http://git-wip-us.apache.org/repos/asf/syncope/repo Commit: http://git-wip-us.apache.org/repos/asf/syncope/commit/f0ea2884 Tree: http://git-wip-us.apache.org/repos/asf/syncope/tree/f0ea2884 Diff: http://git-wip-us.apache.org/repos/asf/syncope/diff/f0ea2884 Branch: refs/heads/2_0_X Commit: f0ea28843015f67a1981efc78fa23f3825484ad7 Parents: 874b621 Author: Colm O hEigeartaighAuthored: Tue Jun 13 14:54:52 2017 +0100 Committer: Colm O hEigeartaigh Committed: Tue Jun 13 15:16:57 2017 +0100 -- installer/src/main/resources/izpack/install.xml | 2 +- pom.xml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) -- http://git-wip-us.apache.org/repos/asf/syncope/blob/f0ea2884/installer/src/main/resources/izpack/install.xml -- diff --git a/installer/src/main/resources/izpack/install.xml b/installer/src/main/resources/izpack/install.xml index bfed44b..4a112c1 100644 --- a/installer/src/main/resources/izpack/install.xml +++ b/installer/src/main/resources/izpack/install.xml @@ -136,7 +136,7 @@ under the License. - + http://git-wip-us.apache.org/repos/asf/syncope/blob/f0ea2884/pom.xml -- diff --git a/pom.xml b/pom.xml index 43a0d37..5212372 100644 --- a/pom.xml +++ b/pom.xml @@ -443,7 +443,7 @@ under the License. 0.0.2 5.1.0 -4.3.6 +4.5.3 3.0.0 1.0-alpha-1 3.0.0
syncope git commit: Some trivial fixes
Repository: syncope Updated Branches: refs/heads/master 862835641 -> d5a5079cc Some trivial fixes Project: http://git-wip-us.apache.org/repos/asf/syncope/repo Commit: http://git-wip-us.apache.org/repos/asf/syncope/commit/d5a5079c Tree: http://git-wip-us.apache.org/repos/asf/syncope/tree/d5a5079c Diff: http://git-wip-us.apache.org/repos/asf/syncope/diff/d5a5079c Branch: refs/heads/master Commit: d5a5079ccb95b2c0d3faae8ba527572aebce78f0 Parents: 8628356 Author: Colm O hEigeartaighAuthored: Tue Jun 13 17:30:58 2017 +0100 Committer: Colm O hEigeartaigh Committed: Tue Jun 13 17:30:58 2017 +0100 -- .../apache/syncope/core/spring/security/AuthDataAccessor.java| 2 +- .../syncope/core/spring/security/JWTAuthenticationFilter.java| 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) -- http://git-wip-us.apache.org/repos/asf/syncope/blob/d5a5079c/core/spring/src/main/java/org/apache/syncope/core/spring/security/AuthDataAccessor.java -- diff --git a/core/spring/src/main/java/org/apache/syncope/core/spring/security/AuthDataAccessor.java b/core/spring/src/main/java/org/apache/syncope/core/spring/security/AuthDataAccessor.java index 79ba01b..c44ad36 100644 --- a/core/spring/src/main/java/org/apache/syncope/core/spring/security/AuthDataAccessor.java +++ b/core/spring/src/main/java/org/apache/syncope/core/spring/security/AuthDataAccessor.java @@ -169,7 +169,7 @@ public class AuthDataAccessor { if (users.size() == 1) { user = users.get(0); } else { -LOG.warn("Value {} provided for {} does not uniquely identifies an user", +LOG.warn("Value {} provided for {} does not uniquely identify a user", authentication.getName(), authAttrValues.get(i)); } } http://git-wip-us.apache.org/repos/asf/syncope/blob/d5a5079c/core/spring/src/main/java/org/apache/syncope/core/spring/security/JWTAuthenticationFilter.java -- diff --git a/core/spring/src/main/java/org/apache/syncope/core/spring/security/JWTAuthenticationFilter.java b/core/spring/src/main/java/org/apache/syncope/core/spring/security/JWTAuthenticationFilter.java index 3263abe..44202d1 100644 --- a/core/spring/src/main/java/org/apache/syncope/core/spring/security/JWTAuthenticationFilter.java +++ b/core/spring/src/main/java/org/apache/syncope/core/spring/security/JWTAuthenticationFilter.java @@ -53,7 +53,7 @@ public class JWTAuthenticationFilter extends OncePerRequestFilter { private SyncopeAuthenticationDetailsSource authenticationDetailsSource; @Autowired -private JwsSignatureVerifier jwsSignatureCerifier; +private JwsSignatureVerifier jwsSignatureVerifier; public void setAuthenticationEntryPoint(final AuthenticationEntryPoint authenticationEntryPoint) { this.authenticationEntryPoint = authenticationEntryPoint; @@ -91,7 +91,7 @@ public class JWTAuthenticationFilter extends OncePerRequestFilter { JwsJwtCompactConsumer consumer = new JwsJwtCompactConsumer(stringToken); try { -if (!consumer.verifySignatureWith(jwsSignatureCerifier)) { +if (!consumer.verifySignatureWith(jwsSignatureVerifier)) { throw new BadCredentialsException("Invalid signature found in JWT"); }
syncope git commit: Some trivial fixes
Repository: syncope Updated Branches: refs/heads/2_0_X f0ea28843 -> a1302562e Some trivial fixes Project: http://git-wip-us.apache.org/repos/asf/syncope/repo Commit: http://git-wip-us.apache.org/repos/asf/syncope/commit/a1302562 Tree: http://git-wip-us.apache.org/repos/asf/syncope/tree/a1302562 Diff: http://git-wip-us.apache.org/repos/asf/syncope/diff/a1302562 Branch: refs/heads/2_0_X Commit: a1302562eb1098313c8850988598d2c4e488135f Parents: f0ea288 Author: Colm O hEigeartaighAuthored: Tue Jun 13 17:30:58 2017 +0100 Committer: Colm O hEigeartaigh Committed: Tue Jun 13 20:05:34 2017 +0100 -- .../apache/syncope/core/spring/security/AuthDataAccessor.java| 2 +- .../syncope/core/spring/security/JWTAuthenticationFilter.java| 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) -- http://git-wip-us.apache.org/repos/asf/syncope/blob/a1302562/core/spring/src/main/java/org/apache/syncope/core/spring/security/AuthDataAccessor.java -- diff --git a/core/spring/src/main/java/org/apache/syncope/core/spring/security/AuthDataAccessor.java b/core/spring/src/main/java/org/apache/syncope/core/spring/security/AuthDataAccessor.java index 79ba01b..c44ad36 100644 --- a/core/spring/src/main/java/org/apache/syncope/core/spring/security/AuthDataAccessor.java +++ b/core/spring/src/main/java/org/apache/syncope/core/spring/security/AuthDataAccessor.java @@ -169,7 +169,7 @@ public class AuthDataAccessor { if (users.size() == 1) { user = users.get(0); } else { -LOG.warn("Value {} provided for {} does not uniquely identifies an user", +LOG.warn("Value {} provided for {} does not uniquely identify a user", authentication.getName(), authAttrValues.get(i)); } } http://git-wip-us.apache.org/repos/asf/syncope/blob/a1302562/core/spring/src/main/java/org/apache/syncope/core/spring/security/JWTAuthenticationFilter.java -- diff --git a/core/spring/src/main/java/org/apache/syncope/core/spring/security/JWTAuthenticationFilter.java b/core/spring/src/main/java/org/apache/syncope/core/spring/security/JWTAuthenticationFilter.java index 3263abe..44202d1 100644 --- a/core/spring/src/main/java/org/apache/syncope/core/spring/security/JWTAuthenticationFilter.java +++ b/core/spring/src/main/java/org/apache/syncope/core/spring/security/JWTAuthenticationFilter.java @@ -53,7 +53,7 @@ public class JWTAuthenticationFilter extends OncePerRequestFilter { private SyncopeAuthenticationDetailsSource authenticationDetailsSource; @Autowired -private JwsSignatureVerifier jwsSignatureCerifier; +private JwsSignatureVerifier jwsSignatureVerifier; public void setAuthenticationEntryPoint(final AuthenticationEntryPoint authenticationEntryPoint) { this.authenticationEntryPoint = authenticationEntryPoint; @@ -91,7 +91,7 @@ public class JWTAuthenticationFilter extends OncePerRequestFilter { JwsJwtCompactConsumer consumer = new JwsJwtCompactConsumer(stringToken); try { -if (!consumer.verifySignatureWith(jwsSignatureCerifier)) { +if (!consumer.verifySignatureWith(jwsSignatureVerifier)) { throw new BadCredentialsException("Invalid signature found in JWT"); }
syncope git commit: Adding an example to show how to obtain a JWT Token using curl and use it to make an invocation
Repository: syncope Updated Branches: refs/heads/master d02729e63 -> 862835641 Adding an example to show how to obtain a JWT Token using curl and use it to make an invocation Project: http://git-wip-us.apache.org/repos/asf/syncope/repo Commit: http://git-wip-us.apache.org/repos/asf/syncope/commit/86283564 Tree: http://git-wip-us.apache.org/repos/asf/syncope/tree/86283564 Diff: http://git-wip-us.apache.org/repos/asf/syncope/diff/86283564 Branch: refs/heads/master Commit: 862835641a986318db2a5c7c6ce1ceccdb9d1296 Parents: d02729e Author: Colm O hEigeartaighAuthored: Tue Jun 13 17:29:31 2017 +0100 Committer: Colm O hEigeartaigh Committed: Tue Jun 13 17:29:31 2017 +0100 -- .../workingwithapachesyncope/restfulservices.adoc | 17 + 1 file changed, 17 insertions(+) -- http://git-wip-us.apache.org/repos/asf/syncope/blob/86283564/src/main/asciidoc/reference-guide/workingwithapachesyncope/restfulservices.adoc -- diff --git a/src/main/asciidoc/reference-guide/workingwithapachesyncope/restfulservices.adoc b/src/main/asciidoc/reference-guide/workingwithapachesyncope/restfulservices.adoc index d52cc8e..d602a61 100644 --- a/src/main/asciidoc/reference-guide/workingwithapachesyncope/restfulservices.adoc +++ b/src/main/asciidoc/reference-guide/workingwithapachesyncope/restfulservices.adoc @@ -89,6 +89,23 @@ user. The same header with provided value must be included in all subsequent requests, in order for the requester to be checked for authorization. +For example, using http://curl.haxx.se/[curl^]: + + +curl -I -u admin:password -X POST \ + http://localhost:9080/syncope/rest/accessTokens/login + +returns + +HTTP/1.1 204 +X-Syncope-Token: eyJ0e.. + +which can then be used to make a call to the REST API +. +curl -I -H "X-Syncope-Token: eyJ0e.." \ + http://localhost:9080/syncope/rest/users/self +. + The token duration can be configured via the `jwt.lifetime.minutes` property - see < > for details.