Commit Graph

49 Commits

Author SHA1 Message Date
Sébastien Combéfis
d2b2dfd606 fix(docs): Fix comments content and style
Changed some bad comments referencing the Articles module in other modules.
Typo fixed in xxx.client.modules.js files ("Application" => "Applicaion")
Full stop character removed at the end of line comments
2016-01-17 11:46:11 +01:00
Faraj Farook
f9c7403825 fix(users): Removing redundant variables
Removing redundant variables defined and not used
2016-01-16 16:17:07 +05:30
jloveland
33258f1314 feat(users): Supporting valid email according to HTML5 and RFC 822
Supporting valid email (i.e. root@admin) according to HTML5 and RFC 822
proposed by @jloveland

Fixes #934
2015-11-30 21:47:13 -05:00
gustavodemari
7ecf9337ce updating profile upload with a new version of multer 2015-10-18 20:56:12 -02:00
Ilan Biala
0323696eaf Format code according to ESLint rules 2015-10-16 20:52:31 -04:00
mleanos
288f0b4e63 Solves User model validation bug
This solves the issue of the User model's pre('validate') method,
attempting to validate against a password that was not modified.

Adds the this.isModified('password') check to the condition.
2015-10-05 16:41:14 -07:00
Liran Tal
b800141c41 Merge pull request #921 from mleanos/dbseed-user-passwords
[hotfix] Fixes db seed password bug
2015-09-25 08:37:40 +03:00
mleanos
3d37e20128 Repeating Characters condition
Added a regular expression test to the while condition, in order to
ensure no repeat characters are present in the generated password.
2015-09-22 04:02:31 -07:00
mleanos
1c7d74298b [hotfix] Fixes db seed password bug
Fixes the database seeding bug with the password not passing the owasp
test.

Adds a UserSchema static method that generates a random passphrase that passes
the owasp test.

Performed minor refactoring of the database seed configuration to
implement the new UserSchema method.

Added model test for the UserSchema generateRandomPassphrase static method.
2015-09-22 02:23:30 -07:00
Liran Tal
b824ebce97 fixed bug #923 - making password reset links work for both http and https configuration 2015-09-19 11:00:47 +03:00
jloveland
1fd6bb6119 adding stronger password requirements for improving security based on OWASP 2015-09-07 22:11:02 -04:00
almegdad
aafa5e69cf Force Lowercase & Remove Sensitive Data
* add directive to force username & email lowercase
* remove sensitive data in password reset
* 2 space indentation  in reset & forgot password views
2015-09-01 21:09:20 +03:00
mleanos
bbbe8772f2 Admin Users require role
These changes make the role field required in the User model. Changes to
the Admin user edit view were added to provide validation for the role
field.

As an added enhancement, the user's roles are displayed in the Admin
user list view.
2015-08-28 17:41:13 -07:00
Ryan Hutchison
27d2818834 Closes #202 - if user does not authorize email scope, email will not be mapped. Username will be generated from first initial of first name and last name.
.jshint latedef set to nofunc.
2015-08-23 00:32:36 -04:00
Meistercoach83
4b43c4ef32 Correct <br /> Tags and set Title 2015-08-21 18:18:15 -04:00
Cody B. Daig
5c287f583b [fix] Was storing a 6 char password in plain text [fixes #829] 2015-08-20 09:26:07 -07:00
Andrew Throener
d319f9203f Initial commit to return /client to the URL include paths
Conflict Resolve

Fixed Karma testing

Added back cacheIDFromPath as I am not sure what that does.  Just removed the replaceing of /client
2015-08-13 11:07:02 -05:00
Ryan Hutchison
cb9d7e3db6 fix indentation 2015-08-11 01:01:12 -04:00
Ryan Hutchison
ef3a3f9548 formatting reboot (space-2 and consistency)
JSCS fixes

update editorconfig
2015-07-31 10:04:02 -04:00
Igor Freire
e6a35a7f9a Enable redirection to previous page after login
Two different strategies are adopted, one for when the user authenticates locally and the other through providers. When authenticating locally, the signin function in the client controller redirects to the previous state (storing and using a state name) after successful login. When authenticating through a provider, the first call to provider stores the previous URL (not state, URL) in the session. Then, when provider actually calls the authentication callback, session redirect_to path is used for redirecting user.
2015-07-29 10:55:47 -03:00
Ryan Hutchison
839f805172 BUG: fix admin access (blocking user PUT) 2015-07-28 18:50:11 -04:00
Ryan Hutchison
60660204ac Admin module base & user admin implementation.
update displayName

implements #700 (client-side role security) on angular routes.
2015-07-24 20:03:35 -04:00
Liran Tal
c671f65c47 Merge pull request #693 from lirantal/feature/clean_angular_hashbang_urls
Feature/clean angular hashbang urls
2015-07-25 01:06:03 +03:00
Liran Tal
de3b890f9d removed /#! in user controllers
Resolved 0.4.0 related conflicts:
	modules/users/server/controllers/users/users.authentication.server.controller.js
2015-07-25 00:39:28 +03:00
Cody B. Daig
7605956c99 displayName undefined 2015-07-23 17:00:22 -07:00
Igor Freire
5d4d7cecfe Make emails unique
Emails are made unique. When user attempts to sign in through a provider in which his email is one that is already registered, user is redirected to the signin page with an error passed as a query string parameter.
2015-07-17 14:52:27 -03:00
git-admin
a23290b46e Use validator.js for email validation 2015-07-17 09:27:16 +02:00
trainerbill
a98a84fd20 Fix merge conflicts 2015-07-14 15:46:23 -05:00
Liran Tal
bf79c17bd0 updating the schema save pre hook so that it checks for a modified version of the password field before it tries to re-calculate the new password to save for the user model 2015-07-12 19:25:40 +03:00
Ryan Hutchison
786c546d84 Update users.authentication.server.controller.js 2015-07-09 15:44:38 -04:00
Ryan Hutchison
b18a7dda99 bug: remove social account. 2015-07-09 13:49:48 -04:00
Liran Tal
d5b22e35c4 addressing missing newlines and node 0.12 version for travis-ci 2015-07-05 01:12:54 +03:00
Andrew Throener
8694b7e976 PayPal Authentication 2015-07-02 07:44:58 -05:00
Liran Tal
67e96a4f22 0.4.0 branch merged into master 2015-07-02 12:08:09 +03:00
Ilan Biala
b1d95e0a34 Merge pull request #582 from simison/patch-9
Fix deprecated ExpressJS req.param('provider')
2015-06-03 19:41:35 -04:00
Ilan Biala
cd5db4ad4d Merge pull request #575 from pgrodrigues/0.4.0
Abstract the local strategy login error to thwart hackers
2015-06-03 19:39:19 -04:00
Mikael Korpela
10d35d1df9 Fix deprecated ExpressJS req.param('provider')
>"Deprecated. Use either req.params, req.body or req.query, as applicable."
http://expressjs.com/api.html#req.param
2015-06-02 15:36:56 +03:00
Mikael Korpela
fcb6f90293 Remove un-used hasAuthorization and requiresLogin
Looks like these aren't needed now that we have ACL.
2015-05-29 00:36:07 +03:00
Pedro Rodrigues
e11ffda6e5 Add some abstraction to local strategy login error 2015-05-28 16:56:49 +01:00
Veikko Karsikko
c800c0a18f Hide email address and remove trailing whitespaces
Email address should not be shown to client
2015-05-07 14:26:17 +03:00
Pedro Rodrigues
b2d76b82e5 Remove more unused requires 2015-04-23 17:51:58 +01:00
Pedro Rodrigues
7f1b46b0d7 Remove unused passport require 2015-04-23 11:09:45 +01:00
Edward Sun
0dbab180a9 Removed duplicate include for crypto 2015-04-13 12:08:30 -04:00
Rupert Muchembled
08f1750d94 Correctly encode and decode password salt
The user password salt should be encoded with Base64 before being saved
to the database.

The current code adds an unecessary step of converting the result of
crypto.randomBytes() (which already returns a SlowBuffer) to a Base64
string and back again to a Buffer, and misses the final step of
converting the Buffer's bytes back to a Base64 string.

Because of this, the salt stored in the database is garbled. This is
inconvenient when manipulating the data in a terminal or text editor.

When generating the password hash, the crypto.pbkdf2Sync() method
creates a new Buffer directly from the data supplied. Due to the
incorrect encoding of the salt, entropy is lost at this step,
weakening the security of stored passwords against brute force attacks.
2015-03-07 22:10:38 +00:00
Christian Berendt
e027f4025b Add missing newline at the end of text files
On Unix it is common to have a newline at the end of text files.
2015-02-16 21:39:55 +01:00
Christian Berendt
4879a8ea2a Remove executable bit when not necessary
The executable bit is set for a lot of files where it is not necessary
to have the executable bit set. This PR removes the executable bit from
those files.
2015-02-16 14:19:56 +01:00
Igor Freire
12766c1f3e Adjust profile image URLs on Fb and Twitter strategies
For Fb, use the Graph API. For twitter, use the 'bigger' profile image. Larger profile images (like the one provided by Google) could provide more flexibility.
2015-02-06 14:20:58 -03:00
Igor Freire
9929f1b5f1 Remove username from facebook strategy
Username is now deprecated on Facebook API 2.0
2015-01-30 10:33:11 -03:00
Amos Haviv
ab81d61bd3 New 0.4 version 2014-11-10 23:12:33 +02:00