Commit Graph

11046 Commits

Author SHA1 Message Date
Harrison Healey
803ce61ef8 MM-15889 Add unit tests for CSRF checks (#11058)
* MM-15889 Add unit tests for CSRF checks

* Moved CSRF token test to login tests

* Remove empty test

* Remove debug messages
2019-06-11 15:09:00 -04:00
Rodrigo Villablanca Vásquez
28cf642ccb Fix #10973. AnalyticsUserCountsWithPostsByDay is sync now (#11012)
* Fix #10975. AnalyticsUserCountsWithPostsByDay is sync now

* revert modifications to go.mod and go.sum

* removed unnecessary else sentence

* Querys identation
2019-06-11 21:06:40 +02:00
Jesús Espino
969c032a1e MM-15325: Allowing to configure the device for detect the IP in HA clusters (#10917) 2019-06-11 20:53:03 +02:00
Taufiq Rahman
9445cb29f5 Migrate "Team.UpdateDisplayName" to Sync by default #11096 (#11111)
* Migrate  to Sync by default #11096

* Update with gofmt
2019-06-11 19:41:15 +02:00
Marc Argent
b0ad3c10e9 GH-10932 Migrate 'Session.UpdateLastActivityAt' to Sync by default (#11078)
* Migrate Session.UpdateLastActivityAt to Sync by default

* GH-10932 fix tests

* GH-10932 update add session code
2019-06-11 19:40:05 +02:00
Jesús Espino
cc834e74d4 MM-16154: Allow to have town-square in ExperimentalDefaultChannels (#11112) 2019-06-11 19:30:13 +02:00
Michael Kochell
40d39faa23 Disable plugin health check process check test (#11113) 2019-06-11 09:30:20 -07:00
Guillermo Vayá
ad69002f9e Truncate data from OpenGraph metadata (#10532)
* Truncate strings from OpenGraph metada

* remove unwanted opengraph fields, limit to 1 image

* test helper functions

* Add truncating test

* fix typo

* change test into not comparing for the pointer value

* truncate only once

* only shorten fields that were already present

* set maximum of 5 images

* fix original tests

* fix test

* limit to 5 images

* fix typo

* place functions below types, simplify function commentaries

* Rewrite how to empty opengraph's structure
2019-06-11 17:39:35 +02:00
Bolarinwa Balogun
88202a76d9 [MM-16159] Migrate "Team.GetByName" to Sync by default (#11107)
* [MM-16159] Migrate "Team.GetByName" to Sync by default

* Refactor to correct mistakes and remove irrelevant code
2019-06-11 09:35:17 -04:00
Bolarinwa Balogun
3b03c9afcb [MM-16164] Migrate "Team.GetAll" to Sync by default (#11108)
* [MM-16164] Migrate "Team.GetAll" to Sync by default

* Refactor to make code shorter and more descriptive
2019-06-11 12:29:58 +01:00
Eli Yukelzon
c243b6640c MM-14712 - Add support for signing SAML requests (#11081)
* SAML Request signing added
* added telemetry for signrequest flag
2019-06-11 14:14:15 +03:00
Taufiq Rahman
599dcb0f77 [MM-15302] Migrate Preference.Delete to Sync by default #10715 (#11101)
* MM-15302: Migrate `Preference.Delete` to Sync by default #10715

* MM-15302: Migrate `Preference.Delete` to Sync by default #10715

* regenerate store mocks

* fix shadow var
2019-06-11 10:51:55 +02:00
Mounica Paladugu
c2d7fba39a [MM-16160] Migrate Team.SearchByName to Sync by default (#11104) 2019-06-10 16:11:02 -07:00
Daniel Schalla
79fb20bc1a [MM-15767] Mask errors in login flow only explicitly (#11051)
* Explicit list of errors that should be masked for login flow

* Fix unit test

* fix test #2

* Use of whitelist of passed through errors; Rework error messages
2019-06-10 23:25:25 +02:00
Christopher Speller
41774b671a Bump prepackaged github version to 0.10.2 (#11099) 2019-06-10 13:59:32 -07:00
Marc Argent
162e06b5df GH-10967 Migrate Post.PermanentDeleteBatch to Sync by default (#11033)
* GH-10967 Migrate Post.PermanentDeleteBatch to Sync by default

* Use require.Nil
2019-06-10 17:01:57 +02:00
Christopher Speller
31d695f951 Preventing plugin startup failure if bot account already exists as regular user. (#11077) 2019-06-10 07:39:42 -07:00
Marc Argent
b4d444319b GH-10968 Migrate 'Post.GetPostsBatchForIndexing' to Sync by default (#11031)
* GH-10968 Migrate 'Post.GetPostsBatchForIndexing' to Sync by default

* Fix indentation and check return value
2019-06-10 11:17:37 +02:00
Carlos Tadeu Panato Junior
c431a686b3 prepare upgrade to 5.13 (#11072) 2019-06-09 13:06:53 +02:00
Tomas
76eee12ac8 MM-15850/MM-15851 GetPosts Before/After sync by default (#11035) 2019-06-08 06:32:23 +02:00
Lev
c4609bfe38 Updated prepackaged Jira plugin version to 2.0.1 (#11075) 2019-06-07 10:18:23 -07:00
Christopher Poile
7f0911cf3e zoom v1.0.6 -> v1.0.7 (#11074) 2019-06-07 12:01:20 -04:00
Christopher Speller
0b62661ab0 Bump prepackaged github version to 0.10.1 (#11076) 2019-06-07 08:58:48 -07:00
George Goldberg
328eea4bc3 MM-15730: Send down the Position attribute mapping in client config. (#11018)
This is required to know when to disable the Position field in the User
Settings UI modal.
2019-06-07 16:10:02 +01:00
Christopher Speller
69076934ec Adding bot description field to bot users. (#11066) 2019-06-07 08:09:34 -07:00
Harrison Healey
f91dc57b4c Update NPS plugin to 1.0.0-rc2 (#11073) 2019-06-07 10:22:01 -04:00
Will Andrews
2d14eef6c7 MM-15864 - Made Post.GetRepliesForExport sync (#11046)
* Changed Post.GetRepliesForExport to be sync

* Removed else, and renamed err

* renamed result variable to replyPosts
2019-06-06 14:29:54 -04:00
Eli Yukelzon
6a42ad2af5 [MM-14400] Programmatically generate default.json (#10551)
* create/update config.json using go generate

* added default config generator
added config-reset to Jenkins and make package, updated defaults to consider 'isNew' flag

* corrections after code review

* fixed Config.isValid to handle empty encryption keys

* fixed Config.isValid to handle empty encryption keys

* fixed Config.isValid to handle empty encryption keys

* isUpdate now only checks for nil

* Addressed review comments, added unit testing for default config generator

* err shadowing

* license

* provide output file for config generator via ENV variable, since go generate doesn't support arguments and we need two output paths (config-reset and package)

* cleanup

* proper defaults for PushNotificationServer and SendPushNotifications

* corrected generating defaults for TrustedProxyIPHeader to be consistent with default.json in master

* Check for empty SiteURL as well as nil

* corrected SiteURL settings and checking

* crazy typos fixed

* corrected tests to newly expected values

* relaxed the checks

* fixed formatting
2019-06-06 13:57:01 -04:00
Mounica Paladugu
978ee13262 Migrate Session.RemoveAllSessions to Sync by default (#11037) 2019-06-06 16:03:20 +01:00
Miguel de la Cruz
330a21a994 [MM-16005] Check listOfAllowedChannels to be a not nil empty slice (#11050)
* [MM-16005] Check listOfAllowedChannels to be a not nil empty slice

The problem here had to do with the return type for a `nil`
`[]string`. If `listOfAllowedChannels` is an empty list, that means
that the user doesn't have permissions to view anything, hence we have
to return an empty result. If it is `nil`, there are no restrictions
and we can proceed.

`[]string(nil)` behaves both as a `nil` value and as an "empty" slice,
so this improves the check to be able to distinguish between both
cases.

* Add documentation to the GetViewUsersRestrictionsForTeam function
2019-06-06 13:44:06 +01:00
Evan do Carmo
c73bc21d1e #10883 adding const error string DismissPostError to be returned by MessageWillBePosted (#10921)
Adds an exported const string that can be used by plugins to signal a client that the incoming post should be dismissed, instead of the current behavior which just leaves it pending.
2019-06-06 06:16:28 +02:00
Jesse Hallam
16c11d7bf9 Issue 11030: fix HasFile to avoid false positives for no filename (#11060) 2019-06-05 17:51:58 -04:00
Adrian
bf233dec77 Fix redirecting after oauth login (#10952)
fixes #10943
2019-06-05 08:53:38 -04:00
GianOrtiz
b26e5d444e Migrate "Post.GetPostsByIds" to Sync by default (#11034) 2019-06-04 17:25:16 -04:00
GianOrtiz
a57e042dab [MM-15858] Migrate "Post.GetPostsCreatedAt" to Sync by default (#11021)
* Migrate "Post.GetPostsCreatedAt" to Sync by default

* Fix variable misuse
2019-06-04 17:24:27 -04:00
Sven Hüster
cc6c385d3e Add Slack corporate import ability (#10905)
* add support for slack corporate export data

* changed tempChannels for channel types. concat after parsing channels

* fix typo

* add fixes suggested by @lieut-data
2019-06-04 17:11:29 -04:00
KimSeungHyeon
367ffbfb42 MM - 15795 Migrate "Session.GetSessions" to Sync by default (#11000) 2019-06-04 06:15:31 +02:00
Jason Blais
9c9d510a73 MM-15833 Add new pre-packaged plugins to telemetry diagnostics (#11026)
Re-submitting from #10956 

#### Summary
Add pre-packaged plugins to telemetry diagnostics

This includes the following plugins:
- Jira 2.0
- Zoom
- GitHub
- Autolink
- WelcomeBot 
- Custom attributes
- Amazon SNS Alerts

#### Ticket Link

https://mattermost.atlassian.net/browse/MM-15833

#### Note

Blocked by https://mattermost.atlassian.net/browse/MM-15824, which transfers the AWS SNS plugin to Mattermost org, and changes the plugin ID to reference mattermost instead of cpanato.

Not queuing for review until the plugin ID has changed in the repository. In the event it's not, I will revert the plugin ID back to `com.cpanato.aws-sns` for telemetry diagnostics.
2019-06-03 15:40:25 -07:00
Carlos Tadeu Panato Junior
25333ac480 [MM-13745] Add mattermost-plugin-nps to prepackaged (#10483)
* add mattermost-plugin-nps to prepackaged

* Update NPS plugin version to v1.0.0-rc1
2019-06-03 15:39:44 -07:00
Christopher Poile
3236a40e14 MM-15817 Add custom-attributes as a bundled plugin (#11041) 2019-06-03 15:37:22 -07:00
Christopher Speller
eee26a7dd3 Add github to prepackaged plugins. (#11042) 2019-06-03 15:27:39 -07:00
Christopher Speller
85bd47a1d0 Add jirav2 to prepackaged plugins. (#11044) 2019-06-03 15:02:24 -07:00
Christopher Speller
f39dd28b72 Upgrading schema version to 5.12.0 (#11043) 2019-06-03 14:41:53 -07:00
Christopher Poile
1f397732dd Add welcomebot and aws-SNS to prepackaged plugins (#11048) 2019-06-03 14:10:08 -07:00
Lev
9b27558611 MM-15819 Add Autolink as a prepackaged plugin (#11040)
* Addink Autolink as a prepackaged plugin

* Fix packaging script.
2019-06-03 09:47:38 -07:00
Martin Kraft
c8646eae51 MM-15947: Prevents new user creation with invite link to group-constrained team. (#11023) 2019-06-03 12:38:33 -04:00
Christopher Speller
118cd02613 MM-15882 Switching to new ci for prepackaged plugins and stripping alternate platform binaries. (#11025)
* Switching to new ci for prepackaged plugins and stripping alternate platform binaries.

* Feedback
2019-06-03 08:11:42 -07:00
Taufiq Rahman
5f3e6ad20a Migrate "Post.GetParentsForExportAfter" to Sync by default #10965 (#11029) 2019-06-03 15:41:14 +01:00
Bolarinwa Balogun
4cfe61393b [MM-15802] Migrate "Session.UpdateDeviceId" to Sync by default (#11017) 2019-06-03 16:16:50 +02:00
Rodrigo Villablanca Vásquez
201fb5a717 Fix #10979. GetFlaggedPostsForChannel is sync now (#11010) 2019-06-03 14:29:09 +02:00