Commit Graph

41 Commits

Author SHA1 Message Date
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
Cameron Behar
aebaf2ff74 fix(core): Remove the <base> tag. 2016-10-10 16:05:10 -07:00
walter
0588eaba48 Moved owasp config into default and reverted other config files.
Modified config to be "shared". This will allow future configurations to be easily passed to the client.
2016-09-12 11:53:22 -07:00
walter
8dcf3f6728 Fixed minor type-o's and set owasp.config() rather than the underlying configs. 2016-09-08 12:08:37 -07:00
walter
d73d6baa7c Changed variable name to owaspConfig 2016-09-08 11:28:30 -07:00
walter
4ddb059346 switched to handlebar template for passing the server's owasp config down to the client.
reverted some of the other changes (regarding the http request).
2016-09-08 11:17:41 -07: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
hyperreality
99c64cf7ca feat(html): support noscript tag on layout for browsers with no javascript (#1454) 2016-08-28 14:28:16 +03:00
aanev
234f0c6850 fix(user): fix changeProfilePicture to overwrite existing files
* fix(user): fix changeProfilePicture

* use promises to simplify callbacks

* use fs.unlink to delete old picture once the profile is updated

Fixes #1415

* fix(user): fix changeProfilePicture

* use promises to simplify callbacks

* use fs.unlink to delete old picture once the profile is updated

* log file errors to console

Fixes #1415

* fix(user): fix changeProfilePicture

* use promises to simplify callbacks

* use fs.unlink to delete old picture once the profile is updated

* log file errors to console

* update error handler module to handle file upload errors

Fixes #1415

* fix(user): fix changeProfilePicture

* use promises to simplify callbacks

* use fs.unlink to delete old picture once the profile is updated

* log file errors to console

* update error handler module to handle file upload errors

Fixes #1415
2016-08-26 10:10:02 +03:00
Cody B. Daig
5009a72bf0 feat(core): Enable ng-strict-di (#1389) 2016-07-11 09:10:42 -06:00
trendzetter
b633dfb964 Revert "Enhancement(core):Relative position attribute added to the header." 2016-04-18 22:11:07 +02:00
Olatunde Garuba
661b3b6461 Enhancement(core):Relative positon attribute added to the header.
Relative positon attribute added to the header. proposed by @generalgmt

Fixes #1275
2016-03-19 16:52:28 +01:00
Qiyu Li
6265aaa7da fix(core): Support WiredTiger engine errmsg format in MongoDB 3.2
The new WiredTiger engine is introduced in MongoDB 3.2.
It changes the output errmsg format for violation of unique index.
This commit adds support for the new format.

Fixes #1245
2016-03-04 09:56:15 -05:00
Cody B. Daig
a069531b10 Merge pull request #1186 from itelo/ImproveSEO
feat (title): Dynamic Title: Improve SEO
2016-02-13 10:20:54 -07:00
IteloFilho
49f6a83032 feat (title): Dynamic Title: Improve SEO 2016-02-10 12:12:10 -03:00
Francis Daigle
ba85dccb00 fix(core): Add "additionalProvidersData" to "safeUserObject"
Needed for management of social accounts.
2016-02-08 14:49:33 -07:00
mleanos
f88f28e035 fix(users): Profile image path is invalid after escaping
Removes the validator.escape on the profileImageUrl field in core server
controller.

The escaping was causing the profileImageUrl field to be an invalid path
for the image. We don't need to worry about xss vulnerabilities on this
field because no user input is provided; the name & path are generated
by the application logic.

Fixes #1127
2016-01-15 12:39:17 -08:00
Liran Tal
2b0ae863a0 fix(security): fixing possible xss issue in parsed objects
Fixes #1106
2015-12-30 16:41:05 +02:00
mleanos
e6a5732698 Favicon invalid path
Removed the {{url}} from the Favicon path. This fixes the intermittent
issues with the path resolving to an invalid location.

Removed the url from the twitter:image & og:image tags, to be static
references to the logo.
2015-10-17 16:17:28 -07:00
Ryan Hutchison
3bf07fe4ec Remove data- prefix from attributes 2015-08-25 12:34:40 -04: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
ef3a3f9548 formatting reboot (space-2 and consistency)
JSCS fixes

update editorconfig
2015-07-31 10:04:02 -04:00
Liran Tal
d7f96227eb Merge pull request #685 from codydaig/pull664
Move livereload, image, and favicon to config
2015-07-25 11:35:47 +03:00
Mikael Korpela
28027290b5 Putting the head in order
- Moving a few meta tags+base tag before title. I've noticed Bootstrap [recommends this](http://getbootstrap.com/getting-started/#template) (wasn't sure why) so I did some quick googling and [IE seems to be the reason](http://blogs.msdn.com/b/ieinternals/archive/2011/07/18/optimal-html-head-ordering-to-avoid-parser-restarts-redownloads-and-improve-performance.aspx) but there some other speculations too. Feel free to search more.

- ...in any case, [charset tag should come before the title](http://www.w3.org/wiki/The_HTML_head_element#Stop_right_there.21_Inline_CSS_and_JavaScript_is_not_too_clever.21).

- Removing keyword tag since it [isn't really used anymore](https://chrisedwards.me/seo/keyword-meta-tag-google/).

- Removing duplicate Content-type/Encoding tag

- Remove IE shim
2015-07-25 02:47:17 +03:00
Cody B. Daig
a62c4dd16d Move livereload, image, and favicon to config 2015-07-23 20:05:34 -07:00
Liran Tal
00a4c0603a Merge pull request #566 from simison/error-404-pages
#501 Handle 404 errors at Express backend and at Angular frontend
2015-07-20 22:25:33 +03:00
Igor Freire
0efc82db0f Fix message catching the field for which a duplicate key error ocurred 2015-07-20 14:39:44 -03: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
Liran Tal
d5b22e35c4 addressing missing newlines and node 0.12 version for travis-ci 2015-07-05 01:12:54 +03:00
Liran Tal
67e96a4f22 0.4.0 branch merged into master 2015-07-02 12:08:09 +03:00
Mikael Korpela
7070796c53 Prettier res.status().format()
(due tabs — my editor has tab-spacing set to 2 so I don’t notice when
stuff like this looks crappy)
2015-05-18 19:25:02 +03:00
Mikael Korpela
fd170261ec #501 Use req.format() to content-negotiate correct response 2015-05-18 19:22:56 +03:00
Mikael Korpela
ba1a4475e9 #501 Handle 404 errors at Express backend at at Angular frontend
- `/{api|modules|lib}/*` returns error page when path doesn’t exist
(from Express).
- `/*` always returns index (from Express), but if `$state` doesn’t
exist, Angular redirects to `/not-found` (no 404 status in that case
though!)
- If `Accept: application/json` header is present without `Accept:
text/html`, return error as json. Hence looking at non existing /api/*
paths with browser would show html error, but querying them with script
would return json.
- Slightly prettier 404 error

Test:
```bash
curl http://localhost:3000/api/notfound -4 -H "Accept: application/json"
```
=> json error.

```bash
curl http://localhost:3000/api/notfound -4 -H "Accept:
text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0
.8"
```
=> html error (imitates Chrome’s Accept header).

Starting point was @dotch’s PL: https://github.com/meanjs/mean/pull/503

And `req.accepts()` idea came from http://stackoverflow.com/a/9802006
2015-05-18 17:38:30 +03:00
Mikael Korpela
8190ee44a7 Merge branch 'bugfix/404/#501' of https://github.com/dotch/mean-1 into error-404-pages 2015-05-18 10:45:11 +03:00
Mikael Korpela
238bbe1ad8 Fix headers to HTML5 format
Headers were a weird mixture of html5 and xhtml. Now it's pure html5.


Use this as doctype if you really want it to be xhtml, but I don't see why would you want that with Angular:
```html
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
```
2015-04-08 11:26:27 +02:00
dotch
74273dabb3 return a 404 for not found api, module and lib routes 2015-04-02 03:30:55 +02: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
Andreas Bjørn Hassing Nielsen
ab18e14aa5 Fix #321 image paths in social meta tags [v0.4] 2014-12-23 13:32:27 +01:00
Amos Haviv
ab81d61bd3 New 0.4 version 2014-11-10 23:12:33 +02:00