Commit Graph

83 Commits

Author SHA1 Message Date
OldHawk
a9a5fde404 check only isOper can ban/kick on server side 2017-05-13 13:08:26 +08:00
OldHawk
cb538c152a check user Whether already logined from other location 2017-05-13 00:27:04 +08:00
OldHawk
6c68b74367 add ban expires time to config file, it can be auto moved when the time is expires 2017-05-12 16:55:30 +08:00
OldHawk
b74fddb162 show ban reason to baned user when them connecting 2017-05-12 16:53:13 +08:00
OldHawk
448f868099 oper/admin can ban/kick user out to chat room now~~ 2017-05-12 16:38:02 +08:00
OldHawk
3783fe3eb2 load chat message and users list 2017-05-10 17:52:56 +08:00
OldHawk
284629b0a7 upload subtitle function finished 2017-04-25 14:34:59 +08:00
OldHawk
cd115df1f2 add subtitle upload multer config 2017-04-25 10:55:53 +08:00
OldHawk
1fc901b0b3 load comment and reply data 2017-04-23 03:14:16 +08:00
OldHawk
72ea937b9e add setDatePrototypeToJSON to format date 2017-04-22 17:22:44 +08:00
OldHawk
7b36ac8da9 replace comma to space in upload filename 2017-04-08 04:02:30 +08:00
OldHawk
1b1ec89c04 check uploads torrent files`s announce url 2017-04-02 00:15:33 +08:00
OldHawk
766f51ceab add torrentFileFilter to filter uploads torrent file 2017-03-29 11:02:50 +08:00
Liran Tal
f8384040a4 fix(mongoose): fixing mongoose deprecation notice for promises lib (#1691)
If no promises library set correctly for the mongoose.Promise property then the following warning notice is omitted by mongoose:
`DeprecationWarning: Mongoose: mpromise (mongoose's default promise library) is deprecated, plug in your own promise library instead: http://mongoosejs.com/docs/promises.html`
2016-12-25 11:23:57 +02:00
Laurence Tennant
2b6cf53d30 fix(users): Better MIME-type checking, remove image cropping library (#1589)
* Cropping remove, nicer UI

* Fix MIME-type checking, add image upload tests

* Change image config settings to uploads.profile.image to build a more
rational structure for configuring other types of uploads
2016-11-15 15:59:47 -08:00
Pedro Rodrigues
59c11c622e fix(core): fix twitter meta tags (#1581)
I believe the Twitter meta tags are outdated and this PR fixes them.
Taking into account the current MEAN.js tags and the Twitter docs, the most similar feature I found
is the Twitter Summary Card (https://dev.twitter.com/cards/types/summary).
2016-10-19 11:49:02 +03:00
Cody B. Daig
517dc32b69 promise(core): Add Promise Option to Mongoose (#1560)
Fixes #1559
2016-10-15 07:11:05 -07:00
Sujeeth
b0c5ad9f69 feat(core): Add prod asset versioning (#1536)
Asset versioning for prod - idea from #1509

Fixes #1509
2016-10-06 18:48:43 +03:00
Liran Tal
89e8d13c47 fix(logger): cleaning up unused parameters in logger setup (#1521) 2016-09-20 00:15:21 +03:00
Liran Tal
cf246babd1 feat(config): adds a generic DOMAIN configuration environment (#1469)
Generic DOMAI configuration environment variable, useful for setting links to an app
in reset email templates, and other cases.

Fixes #871 and #847
2016-09-01 22:37:43 +03:00
hyperreality
14136450ab feat(core): update project dependencies, fix express config (#1463) 2016-08-30 01:10:14 +03:00
Liran Tal
f6e579765f feat(express): introducing handlebars nodejs template system (#1461)
This commit introduces handlebars template system and completely replacing Swig and the Consolidate project to handle multiple template systems.
Fixes #1286
2016-08-29 08:32:21 +03:00
Mikael Korpela
07a860f6b5 feat(angular): disable Angular debug data in production (#1457)
Disable Angular debug data in production for a significant performance
boost.

Passes environment variable from template to app config and from there
to
Angular bootstrap config.

https://docs.angularjs.org/guide/production#disabling-debug-data

See #1294
2016-08-28 14:52:05 +03:00
Mikael Korpela
23fd205d81 fix(server): Remove unused loadModels() (#1426) 2016-08-26 13:34:02 +03:00
Liran Tal
37183e0359 * fix(express): updating express session name variable due to deprecation
* fix(express): updating express session name variable from key (the old deprecated one) to the new variable: name

* fix(express): re-wording confusing comment on the session cookie name
2016-07-27 11:39:13 +05:45
Liran Tal
c364922f67 feat(ssl): supporting a certificate authority bundle file for the secured SSL configuration (#1342) 2016-06-07 09:58:02 +03:00
Liran Tal
c8cbcd326f feat(logs): replacing unmaintained and vulnerable file-stream-rotator package with winston log facility (#1334)
* replacing file-stream-rotator with a better logging mechanism using winston which can be extended later for other use cases and integrations

* refactoring logger mechanism, accomodating for tests and environment variable configurations

* only enabling morgan logger if config.log.format option was defined, and disabling the app.log file transport option for the test environment

* disabling all kind of logging when in test enviroment
2016-05-22 01:03:18 +03:00
Marek Grzybek
d14d5130af feat(config): Deprecate JSHint in favor of ESLint
Add basic ESLint setup extending well-known Airbnb code style.

Fixes #1072, #1097
2016-03-15 19:11:12 +01:00
Liran Tal
01f59c04bd Merge pull request #1228 from droooney/remove-BOM
fix(build): Remove BOM
2016-02-21 20:54:44 +02:00
droooney
52faf0697f fix(build): Remove BOM
Remove byte-order mark from source files.

Fixes #1227
2016-02-20 14:49:30 +05:00
Yilen
b2db312e14 feat(csrf): Added Lusca CSRF Prevention
Added lusca for CSRF protection as per issue #828

Fixes #828
2016-02-16 10:57:11 -08:00
Faraj Farook
36e956ea71 fix(core): Adding server info to log initialization
Adding host information to the log initialization and aligning the
texts.
2016-01-17 19:26:52 +05:30
Faraj Farook
6e4c54f712 feat(config): Adding host configuration feature
Adding the functionality of configuring the host to bind the server. By
default this is set to 0.0.0.0.
2015-12-23 03:11:25 +05:30
pursual
4701722a32 fix(core): Serve static files without session init
Fixes #1089
2015-12-07 11:23:16 -05:00
Liran Tal
860f7ce739 Merge pull request #1025 from mleanos/seeddb-missing-config
[hotfix] SeedDB missing in env config
2015-10-30 00:56:20 +02:00
Cody B. Daig
c2f0d18842 Merge pull request #1027 from rodp82/master
Changed favicon string to env variable
2015-10-29 08:29:37 -07:00
mleanos
28f1f57a26 [hotfix] SeedDB missing in env config
Adds a check for the existence of the seedDB config setting, before
attempting to read config.seedDB.seed setting.

Solves the problem when the seedDB config setting is missing from a
environment config, that causes the application to throw an exception at
startup.

Also, adds the seedDB setting to the Cloud-Foundry env config.
2015-10-28 14:21:11 -07:00
Ilan Biala
63d0d71cf6 Merge pull request #948 from gustavodemari/update-multer-profile-upload
Update profile upload with a new version of multer
Fixes #947
2015-10-25 22:03:23 -04:00
Rod Pattison
5af083cb0e Changed favicon string to env variable 2015-10-22 09:46:56 +08:00
mleanos
8cd2291a6a Enable log options for Morgan
Adds the log options, and format to the Morgan middleware in the Express
configuration.

These options are defined in the environment configurations.

The implementation derived from https://github.com/meanjs/mean/pull/254
by @lirantal, which somehow got overlooked when merging 0.4.0 into
master.

Added tests for the Logger configuration.

Added the log settings to the Test env config.

Added environment variables for the log settings in the Test &
Production env configs.

Moved the Morgan Express middleware outside of the NODE_ENV ===
'development' check. Morgan should be used in all environments, and use
the settings set in each env config.

Changed the wording of the Stream option comments in the env configs.

Added Rotating Logs functionality, and refactored the log Stream
options. Added a new npm package, FileStreamRotator, for use with
Morgan's rotating logs functionality.

Also, refactored the log configuration tests to be more maintainable.

Added more tests, and refactored test suite to use mock-fs.
2015-10-20 21:03:07 -07: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
75cf74537a Formatting and Indentation
Changes to formatting and indentation.
2015-10-09 14:06:29 -07:00
mleanos
0560062eab Seed options - logResults
Added an options object to the database seed configuration. Currently,
the only option implemented is `logResults`; set using the seedDB env
config
options (default to "true").

Modified the definition of the env config for seedDB. It's now an
object, with
options.

Setting the logResults option is set to `false` in the core
configuration server test suite.

Also, fixed an issue with how env configs were reading the seedDB
setting from the env variables. Previously, the config was getting set
by
looking for merely the existence of the env variable (MONGO_SEED).
However,
if this setting existed but was set to "false", the seedDB would be
turned on.

Added the SeedDB user details to the env config, and seedDB options.

Added tests to the core server config test suite

should have seedDB configuration set for "regular" user
should have seedDB configuration set for admin user
should seed admin, and "regular" user accounts when NODE_ENV is set to
"test" when they already exist
should ONLY seed admin user account when NODE_ENV is set to "production"
with custom admin
should seed admin, and "regular" user accounts when NODE_ENV is set to
"test" with custom options
should NOT seed admin user account if it already exists when NODE_ENV is
set to "production"
should NOT seed "regular" user account if missing email when NODE_ENV
set to "test"

Added support for environment variables to seedDB env configs; currently
only supporting username & email.

Refactored how the SeedDB rejects were being handled
2015-10-09 13:48:11 -07:00
Liran Tal
988609399a refactoring the seeddb logic to work with promises all over due to all the async behavior 2015-09-28 11:29:39 +03: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
Cody B. Daig
1095131337 [bug] Seed Password's strength [Closes #908] 2015-09-13 13:32:14 -07:00
Liran Tal
fba6eb74b0 Merge pull request #893 from lirantal/feature/seeddb-refactor-users
Refactoring the seeded user objects to be easily maintained
2015-09-09 20:44:50 +03:00
Liran Tal
05f9053f18 Refactoring the seeded user objects to be easily maintained 2015-09-07 09:33:42 +03:00
Liran Tal
a12746e3c1 Adding support for meanjs-version specific configuration option and displaying both MEAN.JS project and App project version numbers on start-up 2015-09-06 11:12:26 +03:00