Commit Graph

336 Commits

Author SHA1 Message Date
Piotr Żurek
a1ccc14a93 ACS- 4752 keycloak migration - resource server role (#1818) 2023-03-22 12:58:13 +01:00
Suneet Gupta
7cbfab81ce [ACS-3916][ACS-3917] Added TagId Validation for Get and Delete methods (#1815)
* [ACS-3916][ACS-3917] Added TagId Validation for Get and Delete methods

* Addressed review comments -
1. Moved duplicate code from ValidateTag methods to a private method
2. Updated the test case
2023-03-21 14:03:27 +05:30
suneet-gupta
addc2c202b [ACS-4886] Changed valdateTag method to validateNode in getTags() method in TagsImpl class 2023-03-21 07:12:21 +00:00
Krystian Dabrowski
f2fdf958f2 ACS-4023: Update GET /tags to support getting tags by name (#1766)
* ACS-4023: Update GET /tags to support getting tags by name
2023-03-15 09:46:58 +01:00
Piyush Joshi
e5d5969fc4 [ACS-3960][ACS-4339] Count is only returned for a tag if it is greater than zero (#1755)
* Added fix for ACS-3960

* Added fix for ACS-3960

* Added fix for ACS-3960

* Added formatting

* Added Fix for ACS-3960

* Revert "Added Fix for ACS-3960"

This reverts commit c06dba2d93.

* Addressed review comment

Co-authored-by: Tom Page <tpage-alfresco@users.noreply.github.com>

* Issue Fixed and added unit test cases.

* Removed extra assertion in testcases.

---------

Co-authored-by: suneet.gupta <suneet.gupta@hyland.com>
Co-authored-by: Tom Page <tpage-alfresco@users.noreply.github.com>
2023-02-22 10:21:59 +05:30
Krystian Dabrowski
96c1464b6c ACS-4026: Create orphaned tag with POST /tags (#1748)
* ACS-4026: Create orphaned tag with POST /tags
2023-02-10 16:51:22 +01:00
Suneet Gupta
439e8587cf Changed line separation formatting to unix (#1741) 2023-02-08 17:47:06 +05:30
George Evangelopoulos
a59234f47f ACS-4027: Introduce changes to support removing tag from all associated nodes (#1709)
* ACS-4027: Introduce changes to support removing tag from all associated nodes

* ACS-4027: fix implementation and add tests
2023-02-07 18:32:52 +02:00
Krystian Dabrowski
285ebc29a4 ACS-4154: Add category count to relevant CRUD endpoints for categories (#1724)
* ACS-4154: Add category count to relevant CRUD endpoints for categories
2023-02-07 11:14:35 +01:00
Krystian Dabrowski
37ec795358 ACS-4362: Fix returned HTTP error status for invalid note type (#1691)
* ACS-4362: Create categories and tags - fix returned HTTP error status for invalid note type
2023-01-24 17:42:12 +01:00
George Evangelopoulos
281009bc50 ACS-4035: support for removing a piece of content from a category (#1670)
* ACS-4035: support for removing a piece of content from a category
2023-01-24 14:29:05 +02:00
krdabrowski
c228bfac1f Acs 4400 multiple same categories can be linked from content or folder (#1675)
ACS-4400: Multiple same categories can be linked from content or folder
2023-01-16 11:40:37 +01:00
krdabrowski
0197b0e221 ACS-4033: List linked categories for a particular node (#1672)
* ACS-4033: List linked categories for a particular node - GET /nodes/{nodeId}/category-links
2023-01-13 18:10:46 +01:00
tiagosalvado10
4749166080 [MNT-23379] Added sleep between document creation and update to prevent test failures (#1668) 2023-01-09 18:40:36 +00:00
krdabrowski
e4e4ed214a ACS-4034: Assign a piece of content to a category (#1655)
* ACS-4034: Assign a piece of content to a category - POST /nodes/{nodeId}/category-links
- added also one TAS test for update category covering repeated name case
2023-01-09 16:01:57 +01:00
tiagosalvado10
88a0854548 [MNT-23379] Set site manager permission if node belongs to a site and inheritance flag is disabled (#1657)
* [MNT-23379] Set site manager permission if node belongs to a site and inheritance flag is disabled

* [MNT-23379] Added validation. Added throwable object to error logging.

* [MNT-23379] Added unit test

* [MNT-23379] Changed 'runAs' call to 'runAsSystem' with lambda
2023-01-06 15:43:14 +00:00
Domenico Sibilio
2a2ae2448e ACS-4188 Migrate tas tests to Log4j 2.x (#1630)
* ACS-4188 Migrate tas tests to Log4j 2.x

* ACS-4188 Make main log4j2.properties file more compact

* ACS-4188 Remove unnecessary log4j2 test dependencies

* ACS-4188 Rename log4j.properties file
2022-12-20 09:45:10 +01:00
krdabrowski
cea3e37dd5 ACS-4029: Update a category name - PUT /categories/{categoryId} (#1621)
* ACS-4029: Update a category name - PUT /categories/{categoryId}
2022-12-16 12:36:06 +01:00
George Evangelopoulos
88b6a8e5b3 ACS-4030: Delete category endpoint (#1618)
* ACS-4030: Delete category endpoint implementation and tests
2022-12-14 16:00:59 +00:00
Maciej Pichura
0aae95b255 ACS-4031 list category children (#1617)
* ACS-4031: Get category children endpoint.

* ACS-4031: Fix in E2E test.

* ACS-4031: Adding more unit tests.

* Fix test description

Co-authored-by: Tom Page <tpage-alfresco@users.noreply.github.com>

* Fix test description

Co-authored-by: Tom Page <tpage-alfresco@users.noreply.github.com>

* ACS-4031: Refactoring after code review.

* ACS-4031: Updating E2E test after latest logic refactor.

Co-authored-by: Tom Page <tpage-alfresco@users.noreply.github.com>
2022-12-13 17:13:02 +01:00
Maciej Pichura
f511436823 ACS-4032 create category (multiple categories pagination fix) (#1610)
* ACS-4032: Some fixes and refactors after verification. Fixing pagination info on POST multiple entities response.

* ACS-4032: Some fixes and refactors after verification. Fixing pagination info on POST multiple entities response.

* Fixing a test STEP description

Co-authored-by: Tom Page <tpage-alfresco@users.noreply.github.com>

Co-authored-by: Tom Page <tpage-alfresco@users.noreply.github.com>
2022-12-08 17:40:56 +01:00
Maciej Pichura
b701f9a994 ACS-4032 Create category (POST) (#1606)
* ACS-4028 Get category by id (#1591)

* ACS-4028: Get category by id endpoint.

* ACS-4028: Get category by id endpoint.

* ACS-4028: Get category by id endpoint - integration TAS tests.

* ACS-4028: Get category by id endpoint - refactoring.

* ACS-4028: Adding test to test suite.

* ACS-4028: Fixes after code review.

* ACS-4032: Initial code for POST category endpoint.

* ACS-4032: Full implementation for POST category endpoint + tests.

* ACS-4032: Some fixes and refactors after code review.
2022-12-08 10:43:22 +01:00
Maciej Pichura
90ca0dea6c ACS-4028 GET Category by id (#1601)
* ACS-4028 Get category by id (#1591)

* ACS-4028: Get category by id endpoint.

* ACS-4028: Get category by id endpoint.

* ACS-4028: Get category by id endpoint - integration TAS tests.

* ACS-4028: Get category by id endpoint - refactoring.

* ACS-4028: Adding test to test suite.

* ACS-4028: Fixes after code review.

* ACS-4019: Removing redundant test group.
2022-12-07 10:32:08 +01:00
Tom Page
7426a2eaa2 ACS-3531 Replace content tests using TAS. (#1582)
* ACS-3531 Output the list of TAS tests that ran.

* ACS-3531 Update content and versioning REST tests. [tas]

* ACS-3531 Replace download/caching IT tests with TAS tests.
2022-12-06 09:14:34 +00:00
Aleksandra Onych
b9ccd79a73 ACS-3160 Replace Reload4j with Log4j2 (#1204)
* [ACS-3160] replace reload4j with log4j2

* [ACS-3160] refactor log4j version in pom.xml files

* ACS-3160 Add log4j2.properties file

* [ACS-3160] convert log4jHierarchyInit properties

* ACS-3222 Generate log4j2 rolling file in the Tomcat logs directory

* ACS-3160 Fix reconfiguration in Log4JHierarchyInit

* [ACS-3160] change loggers from log4j2 to slf4j (where possible)

* ACS-3160 Load a set of augmenting/overriding log4j2.properties files

* ACS-3160 Fix CheckRequiredClassesForLoggingConsoleUnitTest (adjust to log4j2)

* ACS-3160 Enable CheckRequiredClassesForLoggingConsoleUnitTest

* [ACS-3160] add appender util class

* [ACS-3160] fix removeAbstractAppenderFromLogger

* ACS-3160 Upgrade Log4j2 and Slf4j2 versions to the latest

* ACS-3160 Temporarily remove AOS for test purposes [tas][db]

* [ACS-3160] remove setting level from removeAbstractAppenderFromLogger

* ACS-3160 Remove references to SanitizingPatternLayout [tas]

* ACS-3892 Migrate ags-community-repo AMP to Log4j2

* ACS-3892 Reduce log4j-core scope to test

* ACS-3160 Update the aos-module version to 1.5.0-DEV-LOG4J2 [tas][db]

* [ACS-3924] upgrade greenmail version

* [ACS-3924] remove exclusion from greenmail

* ACS-3160 Fix NDC

* ACS-3160 Revert the NDC_REF

* ACS-3160 Test with googledrive with Log4j2

* ACS-3160 Log4j references cleanup

Co-authored-by: Domenico Sibilio <domenicosibilio@gmail.com>
Co-authored-by: Damian.Ujma@hyland.com <Damian.Ujma@hyland.com>
2022-12-05 15:07:50 +01:00
George Evangelopoulos
17c09efb93 ACS-4064: fix for linking from a folder with inherited rules (#1577)
* ACS-4064: fix for linking from a folder with inherited rules

* ACS-4064: fix failing tests and add E2E
2022-11-24 15:48:27 +00:00
George Evangelopoulos
af838043c9 ACS-3964: fix for non-inheritable rules still appearing in inherited rule sets (#1565)
* ACS-3964: fix for non-inheritable rules still appearing in inherited rule sets

* ACS-3964: fix failing E2Es and add negative test
2022-11-23 16:24:15 +00:00
Kacper Magdziarz
a5f16f1b11 Fix/mnt 22686 allow complex rest action params (#1569)
* MNT-22686 Allow more complex action params

* MNT-22686 Add email template test

Co-authored-by: pzurek <Piotr.Zurek@hyland.com>
Co-authored-by: Sara Aspery <sara.aspery@alfresco.com>
2022-11-23 15:11:48 +00:00
rrajoria
93a7790d44 MNT-23204: Group Search (#1558) 2022-11-18 14:39:27 +05:30
Vítor Moreira
14572d328f MNT-22485: audit query with createdAt criteria returns correct totalI… (#1535)
* MNT-22485: audit query with createdAt criteria returns correct totalItems
2022-11-09 15:58:49 +00:00
Maciej Pichura
e41fc6af02 ACS-3855: Add validation for rule condition comparator. (#1538) 2022-11-07 15:31:19 +01:00
Maciej Pichura
7a70b40cc0 ACS-3652 Node access validation for Rule Action Parameters, ACS-3795 Validate that action is suitable for use in rule (#1502)
* ACS-3652 Add validation for individual actions.

In particular write access is required for the folder specified in the copy and move actions.

* ACS-3652: Adding action validations for node permissions.

* ACS-3652: Fixing failing E2E tests.

* ACS-3652: Adding E2E tests.

* ACS-3652: Adding E2E tests.

* ACS-3652 E2E tests for script validation.

* ACS-3652 Fix script validation test to use admin.

* ACS-3652: Removing unnecessary code.

* ACS-3652 E2Es for link to category action.

* ACS-3652: Adding applicable action definition check.

* ACS-3652: Adding more thorough action definition checks and fixing node permission and type checks.

* ACS-3652: Adding more thorough E2E tests and some fixes.

* ACS-3652: Adding more E2E tests and some fixes.

* ACS-3652: Fixing some missing corner cases, adding tests.

* ACS-3652: Small refactoring after code review.

Co-authored-by: Tom Page <thomas.page@alfresco.com>
2022-10-20 14:39:29 +02:00
Maciej Pichura
2fac4d8a9b ACS-3788: Handling null/empty rule action parameter values. (#1505)
* ACS-3788: Handling null rule action parameter values.

* ACS-3788: Throwing exception when empty/null rule action parameter values.
2022-10-19 15:09:22 +02:00
Maciej Pichura
50b9f5c612 ACS-3759: Fixing bug for empty action parameter values (#1501)
* ACS-3759: Fixing bug for empty action parameter values

* ACS-3759: Fixing missing import
2022-10-17 18:07:32 +02:00
Tom Page
1d0dcf3e15 ACS-3651 Remove unused reference to node service. 2022-10-13 15:37:56 +01:00
Tom Page
38bff5dc82 ACS-3651 Add unit tests for node exists and read permission. 2022-10-13 15:01:41 +01:00
Tom Page
9b8b1bbbe6 ACS-3651 Validate node pameters. 2022-10-13 14:05:12 +01:00
Maciej Pichura
1759364b50 ACS-3723, ACS-3724, ACS-3725 move rules V1 API to private space (#1495)
* ACS-3723: Moving endpoints to private API path.

* ACS-3723: Fixes to E2E tests and some other parts.

* ACS-3723: Removing unnecessary imports.
2022-10-13 12:38:44 +02:00
Aleksandra Onych
59ab7e9458 ACS-3635 Alfresco WebDAV CSRF - allowInsecurePOSTMethod flag (#1488) 2022-10-11 15:05:48 +02:00
Piotr Żurek
aae87ebffd PRODSEC-6550 Fix CSRF in the WebScript console Refresh Scripts form (#1483) 2022-10-11 12:05:35 +02:00
George Evangelopoulos
6bcf33d672 ACS-3616: fix exception type for missing node id (#1457)
* ACS-3616: fix exception type for missing node id

* ACS-3616: fix exception handling for missing node id

* ACS-3616: update javadoc, add a constructor for the exception
2022-10-10 21:52:19 +03:00
Maciej Pichura
307eaff896 ACS-3649, ACS-3650 Action validation mechanism + validations against Action Definitions (#1481)
* ACS-3572: Action constraints endpoint + logic + unit tests.

* ACS-3572: Action constraints endpoint + logic + unit tests.

* ACS-3572: Action constraints endpoint fixes.

* ACS-3572: Cleanup after removal of GET all Action constraints.

* ACS-3572: Fixing formatting in tests.

* ACS-3572: Loosening V1 constraints restrictions for aspects, types and properties.

* ACS-3649: Action validators - constraints.

* ACS-3649: Action validators - constraints.

* ACS-3649: Action validators - constraints.

* ACS-3572: Adding validation for extra paramater.

* ACS-3649: Small refactors and fixes.

* ACS-3649: Validations against action definition.

* ACS-3649: Adding @Experimental annotation.

* ACS-3649: Fixes/refactoring after code review.

* ACS-3649: Removing ignored test
2022-10-10 17:13:51 +02:00
Tom Page
86761bd408 Merge pull request #1478 from Alfresco/feature/ACS-3615_AllowNullParams
ACS-3615 Allow actions in rules without any params.
2022-10-10 09:29:29 +01:00
Maciej Pichura
4d6b4c2ecf ACS-3572 V1 API for action constraints (#1469)
* ACS-3572: Action constraints endpoint + logic + unit tests.

* ACS-3572: Action constraints endpoint + logic + unit tests.

* ACS-3572: Action constraints endpoint fixes.

* ACS-3572: Cleanup after removal of GET all Action constraints.

* ACS-3572: Fixing formatting in tests.

* ACS-3572: Loosening V1 constraints restrictions for aspects, types and properties.

* ACS-3572: Removing unnecessary code.

* ACS-3572: Removing unnecessary field.

* ACS-3572: Removing unnecessary field - fixing the tests.

* ACS-3572: Renaming the endpoint and fixing license headers.

* ACS-3572: Fixing license headers.

* ACS-3572: Fixing tas-restapi dependency version.

* ACS-3649: Bumping tes-restapi version.

* ACS-3649: Bumping tes-restapi version.
2022-10-10 10:14:47 +02:00
Tom Page
ad96f85251 ACS-3615 Allow actions in rules without any params. 2022-10-07 16:37:08 +01:00
krdabrowski
7ac48f8a99 ACS-3687: Execute rules API: Remove field "isEachInheritedRuleExecuted" (#1476)
* ACS-3620: E2Es - API for manual triggering rules on a folder
2022-10-07 17:01:08 +02:00
Tom Page
855e2522f2 ACS-3657 Allow returning partial list of rule sets.
If a user does not have access to a rule set applied to a node then it will be
excluded from the results, but the user will be able to see the list of other
rule sets.

Also add E2E tests for permissions when viewing rule sets.
2022-10-07 13:03:37 +01:00
Tom Page
89e8f7ff66 Merge master into ACS-3630_PrivateActionTests. 2022-10-05 16:09:29 +01:00
Tom Page
440f0568e3 ACS-3291 Permission checks when linking and unlinking to rule sets. 2022-10-05 14:22:37 +01:00
krdabrowski
67f7fff0b7 ACS-3525: API for manual triggering rules on a folder (#1458)
* ACS-3525: API for manual triggering rules on a folder
2022-10-05 12:19:49 +02:00