Commit Graph
50 Commits
Author SHA1 Message Date
Jacques Le Roux 48c1327413 A patch from Ritu Raj Lakhera for "Forgot password functionality is not honoring the 'password.lowercase' property of 'security.properties'" https://issues.apache.org/jira/browse/OFBIZ-5745
Forgot password functionality (LoginEvents.emailPassword) is not honoring the 'password.lowercase' property of 'security.properties'. And thus customer is not able to Login on e-commerce site with new generated password.
Test Case:
1. Set property 'password.lowercase' as true in 'security.properties'.
2. Request a forgot password and customer get the new password as 'a0e7J'
3. Customer is not able to login on e-commerce site.

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1622050 13f79535-47bb-0310-9956-ffa450edef68
2014-09-02 16:17:36 +00:00
Adrian Crum a17298a06e Removed unused "authz" security code - https://issues.apache.org/jira/browse/OFBIZ-4839.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1360283 13f79535-47bb-0310-9956-ffa450edef68
2012-07-11 16:34:26 +00:00
Adam Heath 206b3378d1 DEPRECATION: applications/securityext: getRelatedOne variants replaced with a getRelatedOne variant that takes a boolean useCache parameter.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1343489 13f79535-47bb-0310-9956-ffa450edef68
2012-05-29 04:14:11 +00:00
Adam Heath 52d69a724b DEPRECATION: applications/securityext: findByPrimaryKey variants
replaced with findOne

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1337672 13f79535-47bb-0310-9956-ffa450edef68
2012-05-12 21:20:22 +00:00
Adam Heath 33101dbaa2 FEATURE/DEPRECATION: Deprecate HashCrypt.cryptPassword; previously,
it would call String.getBytes(), without specifying an encoding.  That
meant that the platform default encoding would be used, which might
change between different installs(if someone changed an environment
variable, for instance).  Now, there are explicit variants to be called.

When creating a new value, use cryptValueUTF8.  If, for some reason,
calling code is doing it's own comparison, it must continue to use
cryptValueBytes(password.getBytes()).

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1334170 13f79535-47bb-0310-9956-ffa450edef68
2012-05-04 20:42:26 +00:00
Adam Heath b767ef1868 OPTIMIZE: Remove cryptPassword(String, String); it is not nescessary to
go thru a deprecation cycle for this, as this method was only recently
added, and has never been officially released.

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1333664 13f79535-47bb-0310-9956-ffa450edef68
2012-05-03 22:20:24 +00:00
Jacques Le Roux 5e5f0e27a5 This introduces a mean to hide a service result in log (when the service is longer than 50 ms and Debug.timingOn() or > 200 ms and Debug.infoOn(), see ServiceDispatcher.java, just above line 600)
A hideResultInLog service attribute is added. If set to true the service result will be hidden from possible exposition in ServiceDispatcher.runSync() 
This is convenient when used for sending a password to an user (the password must be legible in the sent mail). 
I'm sure a lot of you would want to have no logs at all in production. But by experience I know that we need to log info in logs even in production. Especially when the system is quickly moving ahead...
So this is a sure mean to hide any password in logs, being current or backuped somewhere on the servers disks...


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1328122 13f79535-47bb-0310-9956-ffa450edef68
2012-04-19 21:41:39 +00:00
Adam Heath f092508550 FEATURE: Make use of new HashCrypt cryptPassword functionality.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1327741 13f79535-47bb-0310-9956-ffa450edef68
2012-04-18 23:49:22 +00:00
Jacques Le Roux 5709385ad6 Followed Scott"s suggestion and added a generic EMAIL_PASSWORD EmailTemplateSetting (used to send a new password at user request)
I finally kept also the previous way because it allow an easier 18n of at the email subject.

Still the same concern: OOTB, if the user has not set a SMPT server in general.properties for the defaultFromEmailAddress the message "A new password has been created and sent to you. Please check your Email." when actually nothing happens. But that's anyway user's responsibility

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1310716 13f79535-47bb-0310-9956-ffa450edef68
2012-04-07 09:17:41 +00:00
Jacques Le Roux 2ab258f919 A patch from BREMA Dev Team "email password broken" https://issues.apache.org/jira/browse/OFBIZ-3790
There is no productStoreId in the session for an user of a backend application, and ProductStoreEmailSetting is not available. This is the reason.
However we can use default template and default sender's address from general.properties in this case.
Also removes some dead code.

jleroux: this uses  "general.properties", "defaultFromEmailAddress". So to work correctly it still needs "defaultFromEmailAddress" (default =ofbiztest@example.com), "mail.smtp.relay.host" (default =localhost) and such to be set correctly... In other words the message "A new password has been created and sent to you. Please check your Email." could even more misleading if people are not aware about setting SMTP


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1307895 13f79535-47bb-0310-9956-ffa450edef68
2012-03-31 20:35:42 +00:00
Ashish Vijaywargiya eb372bb2ba On production systems you can't suppress Debug.log( message by the use of debug.properties file. It is always good to use Debug.* statements that are having log level setup in debug.properties file. The real problem comes with Debug.log( statement when you are printing any list or map object that contains so many records(or data) in it. Here I am changing all the occurrence of Debug.log( with Debug.logInfo(, Debug.logError( or Debug.logWarning( so that we can have better control of Debug.* statements on production system. :-)
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1300463 13f79535-47bb-0310-9956-ffa450edef68
2012-03-14 06:07:52 +00:00
Scott Gray 47f43a302a Remove unnecessary casts
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1044931 13f79535-47bb-0310-9956-ffa450edef68
2010-12-12 21:31:27 +00:00
Jacques Le Roux b8689d9e7a A patch from Sascha Rodekamp "Security Update for forgotten passwords " (https://issues.apache.org/jira/browse/OFBIZ-3842) - OFBIZ-3842
Improve the a random Password generation when the "require new password" function is called. In the current Trunk it's a kind of hard coded password that will be send to the user. After generating a new pass the "requireNewPassword" flag will be set to true (configurable).

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1038209 13f79535-47bb-0310-9956-ffa450edef68
2010-11-23 17:13:53 +00:00
Jacques Le Roux b5cfc499f9 Organize import
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@935267 13f79535-47bb-0310-9956-ffa450edef68
2010-04-17 22:17:42 +00:00
Jacques Le Roux aa95728f0b In eCommerce password Hint Message should be an event message, not error message.
Thanks to Koon Sang at https://issues.apache.org/jira/browse/OFBIZ-3525 - OFBIZ-3525

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@917435 13f79535-47bb-0310-9956-ffa450edef68
2010-03-01 09:41:47 +00:00
Ashish Vijaywargiya 9905e69fa6 Adding productStoreId in bodyParameters so that it can be used if needed.
Patch from Divesh.

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@915730 13f79535-47bb-0310-9956-ffa450edef68
2010-02-24 09:49:31 +00:00
Adam Heath b17eb127ec Fix trailing whitespace, and mixed tab/space at the beginning of lines.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@899812 13f79535-47bb-0310-9956-ffa450edef68
2010-01-15 21:00:23 +00:00
Adrian Crum a4d68934c9 Converted GenericDelegator concrete class references to Delegator interface references.
This commit requires ant clean. Also, external libraries that reference GenericDelegator will need to be updated.



git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@821643 13f79535-47bb-0310-9956-ffa450edef68
2009-10-05 00:08:27 +00:00
Jacques Le Roux 874e1d38dc ASL2 headers, I guess it's OK now, to check see http://ci.apache.org/projects/ofbiz/rat-output.txt
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@812033 13f79535-47bb-0310-9956-ffa450edef68
2009-09-07 08:20:26 +00:00
Andrew Zeneski a3586b9371 added partyId field so email gets logged as communication event
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@774199 13f79535-47bb-0310-9956-ffa450edef68
2009-05-13 05:01:36 +00:00
Andrew Zeneski 485805fe3f Renamed AbtractAuthorization to AbstractAuthorization (bad typo)
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@770836 13f79535-47bb-0310-9956-ffa450edef68
2009-05-01 21:53:29 +00:00
Andrew Zeneski 87535e2f67 Often thread pools do not clear ThreadLocal, implemented a workaround to handle this
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@770771 13f79535-47bb-0310-9956-ffa450edef68
2009-05-01 17:47:52 +00:00
Scott Gray 1e0f7725cd Fix the auth tests
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@770655 13f79535-47bb-0310-9956-ffa450edef68
2009-05-01 12:47:33 +00:00
Scott Gray 6fddaf6815 Removed unnecessary delegator since a test delegator is provided by the parent class. I need to make it final so this
doesn't happen but JUnit instantiates the object so I can't do it without extending their class. It's on my todo list.

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@770596 13f79535-47bb-0310-9956-ffa450edef68
2009-05-01 09:19:43 +00:00
Andrew Zeneski f36c5a9335 No longer requiring the boolean field 'expanded' as part of the API; after dicussing w/ Adrian; the FSE can handle pre-expanded strings
Added new API method findMatchingPermission() which takes a regular expression for the base permission returning the value of all matching permissions (see unit tests)
Fixed missing base permission in SecurityData.xml

JIRA OFBIZ-2381


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@770401 13f79535-47bb-0310-9956-ffa450edef68
2009-04-30 19:14:48 +00:00
Andrew Zeneski 15e577f68e added license header
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@770036 13f79535-47bb-0310-9956-ffa450edef68
2009-04-30 02:02:39 +00:00
Adam Heath 65fce55790 Oops, this class got modified to use the removed AbstractHandler
before I removed AbstractResolver.  Rewrote it to use ServiceRegistry
instead, which, as before, simplifies the code.

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@770028 13f79535-47bb-0310-9956-ffa450edef68
2009-04-30 01:21:11 +00:00
Adrian Crum e34785168f Fixed a problem with the new auth code that was preventing compilation.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@769991 13f79535-47bb-0310-9956-ffa450edef68
2009-04-29 23:18:24 +00:00
Andrew Zeneski c0d6530bb6 Added check to prevent recursive permission lookup (when implementing dynamic access logic using services) - JIRA OFBIZ-2381
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@769963 13f79535-47bb-0310-9956-ffa450edef68
2009-04-29 22:08:07 +00:00
Andrew Zeneski 3492a12c3c Implementation of new Authz dynamic access handler using the service engine; placed in securityext to prevent cross dependencies. Implemented test cases for authz.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@769929 13f79535-47bb-0310-9956-ffa450edef68
2009-04-29 21:02:58 +00:00
Adam Heath 14ea43adaf Fix lines that *only* have whitespace.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@759255 13f79535-47bb-0310-9956-ffa450edef68
2009-03-27 17:01:44 +00:00
Adam Heath a3adf0acfe Fix purely empty whitespace lines, and remove trailing whitespace.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@757094 13f79535-47bb-0310-9956-ffa450edef68
2009-03-21 23:45:04 +00:00
Jacques Le Roux 7818a0afe2 A patch from Bruno Busco "Adding forgot password feature in framework" (https://issues.apache.org/jira/browse/OFBIZ-1984) - OFBIZ-1984
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@703647 13f79535-47bb-0310-9956-ffa450edef68
2008-10-11 11:01:01 +00:00
Adam Heath 83de5c84bd Generics, StringBuilder, for-loop, Number.valueOf.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@685939 13f79535-47bb-0310-9956-ffa450edef68
2008-08-14 15:14:11 +00:00
David E. Jones 329631a4b5 A whole bunch of cleanups to use newer and more consolidated delegator find methods; still lots of deprecation warnings, bots of deprecation warnings but this is a first pass, and things still run as before
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@653029 13f79535-47bb-0310-9956-ffa450edef68
2008-05-03 09:40:51 +00:00
Jacopo Cappellato 458fee5883 Fix for compile time error caused by the recent work on password encryption: I hope I have converted the old method in the proper way.
Thanks to Vikas Mayur for the report.


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@652468 13f79535-47bb-0310-9956-ffa450edef68
2008-05-01 10:07:30 +00:00
Andrew Zeneski 2eed3eec50 added code which uses "rememberMe" parameter to store a cookie with the user's login ID
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@590554 13f79535-47bb-0310-9956-ffa450edef68
2007-10-31 04:33:50 +00:00
Adam Heath 2ff7a8a575 Make use of the single-arg variants of makePK/makeValue, removeAll,
and clearCacheLine


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@585803 13f79535-47bb-0310-9956-ffa450edef68
2007-10-18 02:46:57 +00:00
David E. Jones ca526c3957 Some improvements to how sequencing is done, including a new method in the GenericDelegator that does a sequence and create all in one, including a single retry with bank refresh on failure because of duplicate ID just in case two sequencers somehow get the same ID bank; in theory that is impossible but it has been observed in production and this is part of the 2 part solution to handle the problem more elegantly than having to restart the servers, and to try to find out just how two sequencers got the same bank of values; this includes changing a number of key code blocks to use the combined sequence and create for retry, and a little bit of code cleanup too
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@582142 13f79535-47bb-0310-9956-ffa450edef68
2007-10-05 09:02:49 +00:00
Jacopo Cappellato 4e8e2dac8e Implemented 'Require Password Change' in ecommerce and manager apps: if the new field in the UserLogin entity is set to Y then, before the login, the user will be prompted for a new password.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@549406 13f79535-47bb-0310-9956-ffa450edef68
2007-06-21 06:20:53 +00:00
Andrew Zeneski 1131e13a6c added first pass of X509 issuer import screen; will import into trust store; and create the issuer record
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@532598 13f79535-47bb-0310-9956-ffa450edef68
2007-04-26 03:48:21 +00:00
Jacopo Cappellato 82a5bf4147 Applied (modified) patch from Stefan Huehner (OFBIZ-770) to use isEmpty(...) method for null/empty validation.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@514366 13f79535-47bb-0310-9956-ffa450edef68
2007-03-04 06:59:23 +00:00
Jacques Le Roux a5632fa086 This is hte change of ASL2 headers in java files only.
Seems correct (35827 lines to review ;o).
I just wonder if we should keep the copyright comment in Classpath.java (about MortBay)

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@496982 13f79535-47bb-0310-9956-ffa450edef68
2007-01-17 10:22:33 +00:00
Jacopo Cappellato 89a75b6502 Removed author information from all the files of the "securityext" component: keeping this information in source files is discouraged by the ASF (clearer information about the contributors of a file can be derived from the commit logs).
git-svn-id: https://svn.apache.org/repos/asf/incubator/ofbiz/trunk@454087 13f79535-47bb-0310-9956-ffa450edef68
2006-10-08 06:18:54 +00:00
David E. Jones 0bd3edd5ab Fixed package in login events; in LoginWorker changed to work with or without the party component
git-svn-id: https://svn.apache.org/repos/asf/incubator/ofbiz/trunk@431028 13f79535-47bb-0310-9956-ffa450edef68
2006-08-12 12:57:37 +00:00
David E. Jones 1cfc0d356f Moved LoginServices to the common component because it is used by framework components, and doesn't depend on the application components
git-svn-id: https://svn.apache.org/repos/asf/incubator/ofbiz/trunk@431023 13f79535-47bb-0310-9956-ffa450edef68
2006-08-12 12:38:51 +00:00
David E. Jones c84ed3c644 Moved the more core login methods from LoginEvents to LoginWorker as they don't depend on the applications stuff but are used by the framework stuff; also updated various text references to the new locations
git-svn-id: https://svn.apache.org/repos/asf/incubator/ofbiz/trunk@431021 13f79535-47bb-0310-9956-ffa450edef68
2006-08-12 12:12:18 +00:00
David E. Jones a37eba072e Moved LoginEventListener from applications to framework as it only depends on framework, and is also used by webapps there too
git-svn-id: https://svn.apache.org/repos/asf/incubator/ofbiz/trunk@431016 13f79535-47bb-0310-9956-ffa450edef68
2006-08-12 11:24:34 +00:00
Jacopo Cappellato f686cbba98 License change from MIT to ASL2.0 for misc files of applications components.
git-svn-id: https://svn.apache.org/repos/asf/incubator/ofbiz/trunk@423896 13f79535-47bb-0310-9956-ffa450edef68
2006-07-20 11:25:08 +00:00
David E. Jones 94fe6d1cda Initial OFBiz import from revision 7923 of the old svn.ofbiz.org SVN repository.
git-svn-id: https://svn.apache.org/repos/asf/incubator/ofbiz/trunk@418498 13f79535-47bb-0310-9956-ffa450edef68
2006-07-01 19:05:20 +00:00