Commit Graph

10253 Commits

Author SHA1 Message Date
n1aba
50af3a19a2 MM-11703: Update incoming and outgoing webhook description to 500 characters (#9265)
* MM-11703: Update incoming and outgoing webhook description to 500 characters

* MM-11703: Add upgrade code

* MM-11703: Remove MAX_DESCRIPTION_LENGTH constants

* MM-11703: GOFMT

* MM-11703: Move upgrade code to version 5.3

* MM-11703: Comment back upgrade to 5.3.0

* MM-11703: Add API errors back

* MM-11703: Copy-Paste
2018-09-04 13:24:41 +02:00
cpanato
30fa6eca69 Merge remote-tracking branch 'upstream/merge-release-5.3-20180903124813' 2018-09-03 15:07:17 +02:00
Carlos Tadeu Panato Junior
153b119092 Merge release-5.3 2018-09-03 14:48:14 +02:00
Daniel Schalla
531897b1f0 add megacheck as makefile target (#9288)
Fix code issues in channel_test.go

Fix Channel Test Issues detected by Megacheck

Fix API Emoji Test Issues detected by Megacheck

Fixed API Issues Reported by Megacheck

Fixed App issues reported by megacheck

Remaining fixes

removed test added by mistake from old HEAD

gofmt

Store Fixes

simplified returns

Fix test for multi member channel delete

revert to delete unused function
2018-09-03 14:08:40 +02:00
Christopher Speller
9f46512759 MM-11693 Allow connections to /plugins for interactive message buttons. (#9333)
* Allow connetions to /plugins for interactive message buttons.

* Adding siteurl to exclusions for AllowedUntrustedInternalConnections

* Adding subpath support for allowing interactive message buttons plugin connections.
2018-09-02 09:30:10 +02:00
Harrison Healey
68fdaaa995 Fix store cache invalidation for reactions (#9331) 2018-08-30 10:25:25 -07:00
Harrison Healey
c8e473a789 Invalidate store cache after making changes (#9211)
* Invalidate store cache after making changes

* Address feedback

* Make cache invalidation in stores always use defer
2018-08-30 10:28:58 -04:00
Sudheer
570c52b4cc MM-11710 Add a check to webhook messages to populate username from DM channel for email subject (#9314) 2018-08-30 13:07:36 +02:00
Dmitry Samuylov
effa9d33fc bug fix: after and before search flags should not be inclusive of the selected date (#9327)
* fix for date based flag support to make the after and before flags not inclusive of the selected date

* updated search posts tests using date flags to take into account new non inclusive of the selected date behavior of those flags
2018-08-29 19:44:00 -03:00
George Goldberg
e742ba7d51 Remove testing imports from non-test code. (#9324) 2018-08-29 11:08:03 -07:00
Joram Wilander
9c76d9ba00 Add GetLDAPUserAttributes method to the plugin API (#9326) 2018-08-29 11:07:27 -07:00
Carlos Tadeu Panato Junior
0da5c852f0 add --username in the example for the commands (#9320)
* add --username in the example for the commands

* update per review
2018-08-29 16:57:26 +02:00
Jesús Espino
0291730c2f MM-11270: Forbid react/de-react in archived channels (#9323) 2018-08-29 15:07:37 +02:00
Pradeep Murugesan
7a3cf112c5 9304 added the attachments import to direct post (#9308) 2018-08-29 14:27:44 +02:00
Elias Nahum
c2676d964e translations PR 20180827 (#9317) 2018-08-28 19:52:07 -03:00
Jesús Espino
ae3865b539 MM-10532: Add EnableSyncWithLdapIncludeAuth config (#9319) 2018-08-28 19:49:01 +02:00
Dmitry Samuylov
42806ae965 Feature/search after before on (#9219)
* initial implementation of after, before, on search flags allowing to restrict the search to a specific day or a date range

* missed setting beforeDate in SearchParams in one place

* fixed condition when only flags are used for search without any plain terms

* changed date format used for after/before/on flags to be in ISO8601 format as suggested in PR comments, added a helper function to pad month and day with zeroes allowing the user user either format, with or without leading zeroes

* corrected expected compare to date setting for the TestParseDateFilterToTimeISO8601 test

* fixed a bug for the scenario when you only have the date flags without any terms, added a couple of tests for that scenario

* updated the date filter logic to use parameters to construct the query instead of simply appending strings together, as suggested in the pull request comments

* added search unit test using date flags

* added a helper function to create a test post with a createat date manually set, updated the test for search using date flags to create test posts with different createat dates to be able to better test the functionality

* MM-11817 Add support for after/before/on search flags with Elasticsearch

* add support to search posts to perform the search in context of the client's timezone when filtering by createat date using on: after: before: flags

* updated tests to match the new signature
2018-08-28 13:09:32 -04:00
Christopher Speller
61e27beabc Updating dependancies. (#9303) 2018-08-28 10:05:26 -07:00
Gabe Van Engel
347ee1d205 MM-11327: Restrict Teams by Email (#9142)
* Check a team's AllowedDomains setting before adding users to the team.

* Updated AddUser tests to validate AllowedDomains restriction.

* Updated variable name to match convention.

* Removed AllowedDomains from team sanitization.

* Update AppError's Where to match the calling function.

* Added tests for user matching allowedDomains, and multi domain values of allowedDomains.

* Added test to make sure we block users who have a subdomain of a whitelisted domain.

* Revert "Removed AllowedDomains from team sanitization."

This reverts commit 17c2afea584da40c7d769787ae86408e9700510c.

* Update sanitization tests to include dockerhost, now that we enforce AllowedDomains.

* Added tests to verify the interplay between the global and per team domain restrictions.

* Validate AllowedDomains property against RestrictCreationToDomains before updating a team.

* Remove team.AllowedDomains from sanitization.

* Add i18n string for the team allowed domains restriction app error.
2018-08-28 11:06:57 -04:00
Jesús Espino
19e69681d7 Adding IdAttribute setting for SAML (#9291)
* Adding IdAttribute setting for SAML

* Adding Saml Id Attribute to the diagnostics information

* Adding entry to default.json
2018-08-28 11:56:40 +02:00
Cosmin M
049d88c319 Update en.json typo (#9312)
"id": "plugin.api.update_user_status.bad_status",Unable to set the user statys. Unknown user status.
2018-08-27 17:13:23 +02:00
Jesús Espino
3cf7fcdbfb Add debug-server task to make file to run mattermost using delve (#9290) 2018-08-27 13:56:31 +02:00
Jesús Espino
4a02383176 Moving magic number to constant in team import (#9298) 2018-08-27 15:57:12 +05:30
Martin Kraft
ed0fb617ef MM-11786: Adds API endpoint to retrieve redirect locations. (#9284) 2018-08-24 08:49:31 -04:00
Jesús Espino
f9dbea6d86 Fix sampledata reset LastPostAt when the channels are empty (#9295) 2018-08-24 13:51:45 +02:00
Elias Nahum
a63c68be35 translations PR 20180820 (#9277) 2018-08-24 08:11:08 -03:00
Joram Wilander
4de2e5206e Support for interactive menus in message attachments (#9285) 2018-08-24 11:16:17 +01:00
Joram Wilander
9599f1a52f If no origin header is set for WebSocket, do not fail upgrade (#9287) 2018-08-24 11:09:48 +01:00
Carlos Tadeu Panato Junior
5876b52ecd Merge release-5.2 2018-08-24 11:36:39 +02:00
Jesús Espino
bba3bbd9f3 MM-11572: Force correct order on messages generated in the bulk (#9244) 2018-08-24 09:53:44 +02:00
George Goldberg
8bbee74ed8 MM-11348: Add telemetry for advanced permissions. (#9249) 2018-08-23 11:48:57 +01:00
George Goldberg
d2945cdd77 MM-11782: Make archived channels experimental and off-by-default. (#9281)
* MM-11782: Make archived channels experimental and off-by-default.

* Fix test.
v5.2.1 v5.2.1-rc1
2018-08-22 21:12:51 +02:00
Jesús Espino
dc4d009c78 Add/Remove translations (#9280) 2018-08-22 08:25:18 -04:00
Saturnino Abril
f16687f83c [MM-11593] Prevent user to remove from a direct channel (#9251)
* prevent user to remove from a direct channel

* only allow removing of a member in private or public channel
2018-08-21 20:53:32 +08:00
Jesús Espino
cea1796f06 Adding Permissions check and reactions function to plugins API (#9273)
* Adding reactions functions

* Adding permissions checking in the plugins api
2018-08-20 09:22:08 -07:00
Hanzei
56d92de3f2 Add ToJson() to PostActionIntegrationResponse (#9247)
* Add ToJson() to PostActionIntegrationResponse

This commits adds a ToJson() methode to PostActionIntegrationResponse.

It also adds tests for other ToJson() methods

* Add PostActionIntegrationResponseFromJson function

* Add PostActionIntegrationRequesteFromJson() function

* Fix test names

* Add testcase
2018-08-20 09:21:16 -07:00
Elias Nahum
0aa0adb911 Add FileInfo and get file []byte in plugin api (#9269)
* Add FileInfo and get file []byte in plugin api

* Regenerated plugin mocks

* Rename ReadFileAtPath to ReadFile
2018-08-20 09:18:25 -07:00
Hanzei
c2f2fda8a1 Add PostId to PostActionIntegrationRequest (#9270) 2018-08-18 08:35:32 -04:00
Jason Blais
97d8470a36 Update default.json (#9256) 2018-08-16 06:33:37 -07:00
Carlos Tadeu Panato Junior
f24f06c101 Merge release-5.2 2018-08-16 11:40:46 +02:00
Elias Nahum
43483805ea translations PR 20180813 (#9252)
* translations PR 20180813

* Fix french translation
v5.2.0 v5.2.0-rc6 v5.2.0-rc5
2018-08-15 10:09:26 +02:00
Jesús Espino
e39ebd0883 MM-11678: Split the cache for includeDeleted and not includeDeleted memberships requests (#9254)
* MM-11678: Split the cache for includeDeleted and not includeDeleted memberships requests

* Updating properly the cache on sucess
2018-08-14 19:30:27 +02:00
Jason Blais
ffb1d8c798 Add link to developer docs in readme/contributing.md (#9248)
* Update README.md

* Update CONTRIBUTING.md
2018-08-14 12:11:37 -04:00
Jesús Espino
54846fdad2 Update mockery before generate mocks (#9250) 2018-08-14 12:10:57 -04:00
Jesse Hallam
687700a989 clarify CopyFileInfos godocs (#9243) v5.2.0-rc4 v5.2.0-rc3 2018-08-10 17:21:37 +02:00
cpanato
620d55810d Merge remote-tracking branch 'upstream/release-5.2' into release-5.2-daily-merge-20180810 2018-08-10 15:03:18 +02:00
Harrison Healey
4299ef312b MM-11382 Remove special handling of PluginSettings when loading config (#9234)
* MM-11382 Only override PluginSettings from environment when necessary

* MM-11382 Remove special handling of PluginSettings when loading config

* Add extra unit test
2018-08-10 10:10:29 +02:00
Jesse Hallam
d8c8a19d35 avoid t.Fatal() in tests (#9189)
I've been burned a few times by tests that simply fatal, requiring me to
run another build to learn more about what the mismatch was. Avoid this.

This is part of a long running goal of mine to make testing "better".
2018-08-09 11:26:38 +02:00
Jesse Hallam
7649488a26 MM-11637: avoid stopping unstarted jobs (#9240)
The new locking primitives in 5.2 around jobs assume the
worker/scheduler was actually started, so don't try to stop if not
started.
2018-08-09 11:04:49 +02:00
Daniel Malon
0bbabd137b Ignore link-local addresses in cluster advertisement (#9223) 2018-08-08 20:40:53 -07:00