Commit Graph
85 Commits
Author SHA1 Message Date
Michael Brohl 662a3f9d1c Improved: Remove Compdoc functionality from content manager
(OFBIZ-10476)
2021-02-13 17:33:05 +01:00
Pawan Verma 7799673fa3 Improved: Convert createEmailContent service from mini-lang to groovy DSL(OFBIZ-11370)
Thanks, Devanshu for the report and Rohit for initial patch and Nicolas for updated patch and review.
2020-07-18 22:25:55 +05:30
Suraj Khurana 84f82a44d1 Improved: Converted getContentAndDataResource service from mini-lang to groovy DSL.
(OFBIZ-11382)
Thanks Devanshu Vyas for reporting and Ravi Lodhi for the patch.
2020-07-04 14:44:29 +05:30
Pawan Verma 9e97730288 Improved: Convert getDataResource service from mini-lang to groovy DSL(OFBIZ-11381)
Thanks: Devanshu for report and Kirti for the patch.
2020-07-01 16:02:33 +05:30
Suraj Khurana 7aa3db4c45 Improved: Converted createDownloadContent,updateDownloadContent services from mini-lang to groovy.
(OFBIZ-11372)(OFBIZ-11373)
Thanks Devanshu Vyas for reporting, Harman Kaur and Rahul for initial patch, Pawan for review.
2020-05-25 13:37:16 +05:30
Priya SharmaandPriya Sharma 6495dc7a91 Improved: Convert createArticleContent service from mini-lang to groovy (#140)
Deleted the old mini-lang service file
Updated the service definitions with the new groovy methods
Added the groovy implementation (with minor enhancement)

(OFBIZ-11383)

Co-authored-by: Priya Sharma <priya.sharma@example.com>
2020-05-17 10:54:16 +02:00
Pawan Verma e9664e94c4 Improved: Convert updateEmailContent service from mini-lang to groovy DSL
(OFBIZ-11371)

Thanks: Devanshu Vyas for report and Anushi Gupta for the patch.
2020-05-04 15:45:33 +05:30
Jacques Le Roux 200c0e85fc Implemented: Convert createContentAlternativeUrl service from mini-lang to Groovy
(OFBIZ-11389)

Thanks:  Priya Sharma for patch and  Pawan Verma for review
2020-04-19 09:48:24 +02:00
Jacques Le Roux a3bcdc4cc3 Improved: Removes getSubContentWithPermCheck and getSubSubContentWithPermCheck
unused services
(OFBIZ-11393)(OFBIZ-11394)

They were introduced by Al Byers in 2007 and, like some other stuff done then
by Al, were never used. We can safely close the 2 related issues as won't do
after removing the 2 services and all the references to them.

Thanks: Priya Sharma
2020-03-04 14:35:18 +01:00
Jacques Le Roux d003807154 Improved: Remove createTopic service (unused)
(OFBIZ-11376)

I could not find any references for this service in the code base, i.e. this
service has not been used anywhere, do we still want to keep it?

Thanks: Devanshu Vyas for report, Priya Sharma for the proposition and the fix
2020-02-26 10:00:33 +01:00
Jacques Le Roux 2dadaacac8 Fixed: Services allow arbitrary HTML for parameters with allow-html set to "safe"
(OFBIZ-5254)

This was reopened after discussion at 
https://markmail.org/message/jnaitmwahjcjmdn5

This is a new solution which follows the work done with OFBIZ-6669 and OFBIZ-10187
Roughly said, it uses org.owasp.html.PolicyFactory and org.owasp.html.Sanitizers

Thanks: Christoph Neuroth for report

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1859877 13f79535-47bb-0310-9956-ffa450edef68
2019-05-24 13:47:08 +00:00
Jacopo Cappellato 1b0ae5999f Improved: Replaced permission-service with required-permissions in order to
perform permission checks in a way that is more consistent with the screen 
permissions set in the ecommerce blog/forum screens.

Fixes CVE-2019-10073



git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1858539 13f79535-47bb-0310-9956-ffa450edef68
2019-05-02 13:41:24 +00:00
Jacopo Cappellato 9b5aad637c [Fixed]: Added permission checks to three blog/forum services; improved the
configuration for the "add article forum" form (the source tab is not needed in 
the ecommerce application).

Fixes CVE-2019-10073

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1858432 13f79535-47bb-0310-9956-ffa450edef68
2019-04-30 14:25:13 +00:00
Deepak Dixit 645e6e1c47 Fixed: Fix typo 'paramters' => 'parameters'
(OFBIZ-10394)
Thanks Mathieu Lirzin for your contribution

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1830936 13f79535-47bb-0310-9956-ffa450edef68
2018-05-04 19:34:07 +00:00
Akash Jain f48f17b96b Improved: Remove unused service checkContentAssocIds and its usage, applied patch from jira issue (OFBIZ-9999)
Thanks, Suraj Khurana for reporting the issue and Sonal Patwari for providing the patch.

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1816266 13f79535-47bb-0310-9956-ffa450edef68
2017-11-25 08:21:21 +00:00
Ashish Vijaywargiya 1ce72c550d Improved: OFBIZ-7471: Improve all the service level error messages for missing required field for content component.(OFBIZ-8713)
Thanks Jagpreet and Shikha for the contribution.

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1802667 13f79535-47bb-0310-9956-ffa450edef68
2017-07-22 09:59:31 +00:00
Deepak Dixit 3eca8d6aad Improved: Added generic permission service for following
- facility
- marketting
- return
- entitysync
Also moved  the permission check from implementation level to service defination level

(OFBIZ-8673)(OFBIZ-8673)(OFBIZ-8674)(OFBIZ-8739)(OFBIZ-8823)(OFBIZ-8825)(OFBIZ-8827)(OFBIZ-8850)(OFBIZ-8876)(OFBIZ-8875)(OFBIZ-8824)(OFBIZ-8826)(OFBIZ-8851)

Thanks Nameet Jain for your contribution

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1768188 13f79535-47bb-0310-9956-ffa450edef68
2016-11-05 11:10:57 +00:00
Arun Patidar 3584666dbc Implemented: Added CRUD services for ProdConfItemContentType, ProductAssocType, UserPrefGroupType, WebPreferenceType, WorkEffortAssocAttribute, WorkEffortAssocType, WorkEffortAssocTypeAttr, WorkEffortBilling, WorkEffortContentType, WorkEffortGoodStandardType, WorkEffortPurposeType, WorkEffortType, WorkEffortTypeAttr, WorkReqFulfType, UomType, UomGroup, ProductPricePurpose, ProductPriceType, ProductStoreGroupRole and ProductStoreGroupRollup entities.
(OFBIZ-8729)(OFBIZ-8730)(OFBIZ-8792)(OFBIZ-8793)(OFBIZ-8794)(OFBIZ-8795)(OFBIZ-8796)(OFBIZ-8797)(OFBIZ-8798)(OFBIZ-8799)(OFBIZ-8800)(OFBIZ-8801)(OFBIZ-8802)(OFBIZ-8803)(OFBIZ-8788)(OFBIZ-8789)(OFBIZ-8767)
(OFBIZ-8768)(OFBIZ-8769)(OFBIZ-8770)

Thanks: Chinmay Patidar, Amit Gadaley and Rishi Solanki for the contribution.

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1767965 13f79535-47bb-0310-9956-ffa450edef68
2016-11-03 20:30:52 +00:00
Jacques Le Roux d2aa6aa9ee Fixed: Updating Party Content Image does not work
(OFBIZ-8458) (OFBIZ-8347)

Actually it was a regression introduced by r1765499 for a ticket which did not
exist.

This also fixes OFBIZ-8347 for a typo (UPDATE permission instead of DELETE)

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1766183 13f79535-47bb-0310-9956-ffa450edef68
2016-10-22 11:19:28 +00:00
Deepak Dixit 5b853bae42 Improved: Converted some CRUD services from simple to entity-auto.
(OFBIZ-8384)(OFBIZ-8388)(OFBIZ-8295)(OFBIZ-8294)(OFBIZ-8389)(OFBIZ-8390)(OFBIZ-8391)(OFBIZ-8392)(OFBIZ-8393)(OFBIZ-8407)

Thanks Pawan Verma for your contribution.

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1765500 13f79535-47bb-0310-9956-ffa450edef68
2016-10-18 19:33:49 +00:00
Deepak Dixit 510e3b6fdd Improved: Converted some DataResource related CRUD services from simple to entity-auto.
(OFBIZ-8346)(OFBIZ-8347)(OFBIZ-8349)(OFBIZ-8350)(OFBIZ-8351)

Thanks Pawan Verma for your contribution.

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1765499 13f79535-47bb-0310-9956-ffa450edef68
2016-10-18 19:21:09 +00:00
Jacques Le Roux 4dde5f83d8 Fixes: Error : Column 'DATA_CATEGORY_ID' cannot accept a NULL value
(OFBIZ-8282)

Steps to regenerate :
1) Login into webtools component.
2) Run "createDataCategory" service without passing any parameter.
3) Following error message occured : (Column 'DATA_CATEGORY_ID' cannot accept 
a NULL value) PFA attached screenshot.

In this patch I have changed service engine to "entity-auto" and removed 
service implementation.

Thanks: Pawan Verma

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1762996 13f79535-47bb-0310-9956-ffa450edef68
2016-10-01 10:12:55 +00:00
Jacques Le Roux d4b63838eb Fixes: Unable to run service findContentParents from webtools
(OFBIZ-8322)

Steps to regenerate
1. Login into webtools application
2. Try to run service findContentParents after passing parameters
3. Cannot find service error occurs.


Thanks: Tanmay Muley for the patch

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1762331 13f79535-47bb-0310-9956-ffa450edef68
2016-09-26 12:23:26 +00:00
Jacopo Cappellato 4eb7b2bebb Completed the fix for securing the management of blog entries by preventing tags to be added to the content of an entry when it is updated.
[CVE-2016-6800] Apache OFBiz blog stored XSS vulnerability
The default configuration of the OFBiz framework offers a blog
functionality. Different users are able to operate blogs which are
related to specific parties. In the form field for the creation of new
blog articles the user input of the summary field as well as the article
field is not properly sanitized. It is possible to inject arbitrary
JavaScript code in these form fields. This code gets executed from the
browser of every user who is visiting this article.


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1759218 13f79535-47bb-0310-9956-ffa450edef68
2016-09-05 09:16:57 +00:00
Jacopo Cappellato f7e3f2a1f4 In rev. 1536324 Jacques Le Roux changed the value of the attribute allow-html from "safe" to "any" and deprecated the usage of the "safe" value.
However the "safe" behavior is necessary to allow these fields to accept tags in a safe way: for this reason that commit should be reverted and a different solution should be implemented.
In the meantime, this commit changes the allow-html values for the blog entries to "none". 

[CVE-2016-6800] Apache OFBiz blog stored XSS vulnerability
The default configuration of the OFBiz framework offers a blog
functionality. Different users are able to operate blogs which are
related to specific parties. In the form field for the creation of new
blog articles the user input of the summary field as well as the article
field is not properly sanitized. It is possible to inject arbitrary
JavaScript code in these form fields. This code gets executed from the
browser of every user who is visiting this article.


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1759065 13f79535-47bb-0310-9956-ffa450edef68
2016-09-03 09:49:12 +00:00
Mridul Pathak 45abf6d85e [OFBIZ-7529] Part 4 (final) of "Delete stale java files from applications and framework". Deleted following file/directories and their references. Had to do some adjustments in ComDocServices.java as Open Office specific "convertDocumentByteBuffer" service was being referenced there.
applications/content/src/main/java/org/apache/ofbiz/content/openoffice
applications/content/src/main/java/org/apache/ofbiz/content/openoffice/OpenOfficeByteArrayInputStream.java
applications/content/src/main/java/org/apache/ofbiz/content/openoffice/OpenOfficeByteArrayOutputStream.java
applications/content/src/main/java/org/apache/ofbiz/content/openoffice/OpenOfficeServices.java
applications/content/src/main/java/org/apache/ofbiz/content/openoffice/OpenOfficeWorker.java

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1754644 13f79535-47bb-0310-9956-ffa450edef68
2016-07-31 09:42:41 +00:00
Deepak Dixit 834691742b (OFBIZ-6274) Renamed OFBiz artefacts from org.ofbiz.* to org.apache.ofbiz.*.Thanks to Taher for working on it.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1752920 13f79535-47bb-0310-9956-ffa450edef68
2016-07-16 10:30:49 +00:00
Pranay Pandey e314e8a5ee [OFBIZ-7519] Updated optionality to required for attributes in entity auto services where pk fields were mentioned optional. It helps service engine to validate IN attributes and return error for missing ones.
Cases considered for this update are:
 1. One PK: Takes new sequence if PK not passed.
 2. Two PK: Both PK should be mandatory except the case of secondary primary key (like agreementItemSeqId) where next subsequence is generated.
 3. More than two PK's, all PK's should be mandatory except the fromDate.
 Thanks Amardeep Singh Jhajj for the contribution.

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1749532 13f79535-47bb-0310-9956-ffa450edef68
2016-06-21 14:37:30 +00:00
Jacques Le Roux ec66e361e1 A big but straightforward commit for "Move minilang scripts from component://componentname/script/org/ofbiz to component://componentname/minilang" - https://issues.apache.org/jira/browse/OFBIZ-7267
I removed duplicate paths were componentname was uselessly repeated after component://componentname/script/org/ofbiz (projectmngr was the only one using there project instead)

I had few typos, easily fixed thanks to the tests. There could be still typos but they are unexpected and anyway no-brainer to fix 

I'm still wondering about specialpurpose/example/minilang/README.txt.
I changed its content to 
  "The minilang directory is for static resources that are interpreted at run time rather than being compiled. This goes on the classpath, but does not get built or put into a JAR file."
not sure it makes any sense, I don't see how this relates to the classpath. 


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1747712 13f79535-47bb-0310-9956-ffa450edef68
2016-06-10 14:04:30 +00:00
Jacques Le Roux 4ce0bef84c A patch from Wai for "code correction for service=findContentParents" https://issues.apache.org/jira/browse/OFBIZ-6997
jleroux: fixes the service location in def

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1738303 13f79535-47bb-0310-9956-ffa450edef68
2016-04-08 21:04:49 +00:00
Nicolas Malin e48fc92759 convert entities crud service from simple to entity-auto for :
* WebSiteRole
* WebSitePathAlias
* WebSiteContentType
* WebSiteContent
* WebSite
* DataResourcePurpose
* DataResourceMetaData
* OtherDataResource
* AudioDataResource
* VideoDataResource
* ImageDataResource
* DataResource (update/delete)
* ContentApproval
* ContentRevisionItem
* ContentRevision
I also move some service definition from file services.xml to services_content.xml for ContentApproval, ContentRevisionItem and ContentRevision
relate issue OFBIZ-6745

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1716271 13f79535-47bb-0310-9956-ffa450edef68
2015-11-24 22:21:53 +00:00
Nicolas Malin ac1614d04f convert entities crud service from simple to entity-auto for :
* DataResourceAttribute
* ContentRole (not for create will set on second step)
* ContentMetaData
* ContentOperation
* ContentPurpose
* ContentPurposeOperation
* ContentAttribute
* ContentKeyword
* ContentType
* ContentAssocType
* ContentAssocPredicate
* ContentPurposeType
I also move some service definition from file services.xml to services_content.xml for all entities that concern content
relate issue OFBIZ-6745

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1715960 13f79535-47bb-0310-9956-ffa450edef68
2015-11-23 21:26:33 +00:00
Jacques Le Roux 7adfe90d71 Fixes <<Services allow arbitrary HTML for parameters with allow-html set to "safe">> https://issues.apache.org/jira/browse/OFBIZ-5254
After r751990, <<allow-html="any">> and <<allow-html="safe">> are the same: they do nothing! The only difference is the warning message from the OWASP Antisamy IntrusionDetector, which is both, as Christoph noted "giving you a false sense of security" or as I wrote "disturbing, wrong and useless". So there are no longer any reasons for differencing "safe" and "any".

This
* Deprecates "safe" (making it clear in the XSD documentation), keeping only "none" and "any". This is for backward compatibility, else we could completely remove the misleading "safe". Note that "none" is the default.
* Replaces in services definition all allow-html="safe" by allow-html="any"
* Remove from ModelService.java (near line 587) the code which throws the OWASP Antisamy IntrusionDetector message in log

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1536324 13f79535-47bb-0310-9956-ffa450edef68
2013-10-28 12:12:43 +00:00
Jacopo Cappellato 6071e8d8e0 Extracted from the OFBiz content component the dependencies on Lucene and created a new specialpurpose/lucene component in order to simplify the integration of components based on Lucene/Solr and to simplify the management of conflicts caused by different versions of Solr/Lucene jars.
In this way it will be easier to compare the ootb Lucene integration with custom ones (based on Lucene/Solr/etc...) and to switch between them.

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1518925 13f79535-47bb-0310-9956-ffa450edef68
2013-08-30 09:45:33 +00:00
Jacques Le Roux c78b9f662c Moves addMostRecent services to Attic
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1348546 13f79535-47bb-0310-9956-ffa450edef68
2012-06-10 08:04:39 +00:00
Hans Bakker 53abb5b2ac added an function on the website level: 'SEO' to generate missing seofiendly url's on a catalog, category, product and content level. entities records which have alread a seofriendly alternative url are not touched
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1153034 13f79535-47bb-0310-9956-ffa450edef68
2011-08-02 05:56:47 +00:00
Hans Bakker e2531c1cfc improved content friendly urls, fix some errors
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1148144 13f79535-47bb-0310-9956-ffa450edef68
2011-07-19 04:04:32 +00:00
Hans Bakker d470674485 add services to create the alternative seo friendly url's for contant from the contentname, only when they are missing in the current locale. Also updated the related demo data
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1143647 13f79535-47bb-0310-9956-ffa450edef68
2011-07-07 03:59:31 +00:00
Hans Bakker 6724a6698f use and demonstrate the seo friendly urls in the content/ecommerce blog function, add seca to update new created content
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1142577 13f79535-47bb-0310-9956-ffa450edef68
2011-07-04 07:33:18 +00:00
Hans Bakker 1749a6989f Add seo friendly url's for showing content. reorganize the same program snippets with seo friendly url for products. These content url's are demonstrated at the ecommerce frontend in the left bottom corner: Content Information
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1141878 13f79535-47bb-0310-9956-ffa450edef68
2011-07-01 09:03:32 +00:00
Hans Bakker 77226d187c add search screens using the new content search following the wokreffort pattern
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1102643 13f79535-47bb-0310-9956-ffa450edef68
2011-05-13 09:55:48 +00:00
Hans Bakker 7a42a2892c add a keyword search function to the content component
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1102554 13f79535-47bb-0310-9956-ffa450edef68
2011-05-13 03:20:58 +00:00
Hans Bakker 2feb0cd91d allow safe html in blog services
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1021729 13f79535-47bb-0310-9956-ffa450edef68
2010-10-12 10:23:11 +00:00
Scott Gray eb4e287b9e Switch some classpath style xml service locations to component style
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@931776 13f79535-47bb-0310-9956-ffa450edef68
2010-04-08 04:08:53 +00:00
Hans Bakker d531da33b8 this finally solves the email receive problem
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@772837 13f79535-47bb-0310-9956-ffa450edef68
2009-05-08 04:15:59 +00:00
Hans Bakker 8339989cd8 allow html for incoming email into communication event
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@769679 13f79535-47bb-0310-9956-ffa450edef68
2009-04-29 06:46:35 +00:00
Adrian Crum 9a753b9865 Fixed a problem where service definitions were using "GenericValue" as attribute types, but that threw exceptions because the service definitions needed the full class name - "org.ofbiz.entity.GenericValue". The problem was reported in https://issues.apache.org/jira/browse/OFBIZ-2268 and https://issues.apache.org/jira/browse/OFBIZ-2311.
I checked the commit logs and I don't see what changed to cause these services to stop working, so I took the shotgun approach and changed all occurrences of GenericValue service attributes.

If anyone has a better solution, please feel free to revert this commit and change it.


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@765864 13f79535-47bb-0310-9956-ffa450edef68
2009-04-17 06:33:43 +00:00
Jacques Le Roux a5042291f7 1st part of an effort to remove trailing spaces
" +/> => "/>
Should be easier when dealing with Eclipse S/R regexp

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@762648 13f79535-47bb-0310-9956-ffa450edef68
2009-04-07 08:27:15 +00:00
Jacques Le Roux 9f176a1fc2 Fix services timeout issueq reported in user ML (only in content component)
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@762329 13f79535-47bb-0310-9956-ffa450edef68
2009-04-06 13:24:59 +00:00
Jacques Le Roux 29315e3798 all components
Following best practice.
Changed location="org/ofbiz/......... to location="component:// in the service location attribute.
using <service name=(.*)engine="simple"(.*)location="org/ofbiz => <service name=$1engine="simple"$2location="component://{componentName}/script/org/ofbiz 
with {componentName} done by hand

Also for bsh and groovy (services_test in copmmon). There is no longer any location="org/ofbiz in OFBiz

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@755977 13f79535-47bb-0310-9956-ffa450edef68
2009-03-19 12:50:51 +00:00