Commit Graph

257 Commits (bf3de7b90bbe4403980e77284f480a9a5c5ffc28)

Author SHA1 Message Date
Erik Johnston 2c1fbea531 Fix up logcontexts 2016-02-08 14:26:45 +00:00
Erik Johnston 9cd80a7b5c PEP8 2016-02-03 11:52:57 +00:00
Erik Johnston 772b45c745 Remove unused method 2016-02-03 11:43:26 +00:00
Erik Johnston 6f52e90065 Merge branch 'develop' of github.com:matrix-org/synapse into erikj/public_room_fix 2016-02-03 11:06:29 +00:00
Daniel Wagner-Hall d83d004ccd Fix flake8 warnings for new flake8 2016-02-02 17:18:50 +00:00
Erik Johnston 8a391e33ae s/get_room_changes_for_user/get_membership_changes_for_user/ 2016-02-02 16:12:10 +00:00
Erik Johnston 65e92eca49 Change the way we do public room list fetching 2016-02-02 15:21:10 +00:00
Erik Johnston b023995538 WARN if we get a topo token instead of stream. 2016-02-02 14:11:14 +00:00
Erik Johnston 89b40b225c Order things correctly 2016-02-01 16:32:46 +00:00
Erik Johnston 4bf448be25 Switch over /events to use per room caches 2016-02-01 16:26:51 +00:00
Daniel Wagner-Hall da417aa56d Allow non-guests to peek on rooms using /events 2016-01-20 15:34:07 +00:00
Daniel Wagner-Hall ac5a4477ad Require unbanning before other membership changes 2016-01-15 16:27:26 +00:00
Daniel Wagner-Hall b5ce4f0427 Remove unused parameters 2016-01-15 13:54:03 +00:00
Richard van der Hoff 2978053d16 Merge branch 'release-v0.12.1' into develop 2016-01-14 15:04:08 +00:00
Richard van der Hoff 49f33f6438 Add 'event' result to 'context' endpoint
... because the context isn't much use without the event.
2016-01-13 16:42:14 +00:00
Daniel Wagner-Hall 93afb40cd4 Skip, rather than erroring, invalid guest requests
Erroring causes problems when people make illegal requests, because they
don't know what limit parameter they should pass.

This is definitely buggy. It leaks message counts for rooms people don't
have permission to see, via tokens. But apparently we already
consciously decided to allow that as a team, so this preserves that
behaviour.
2016-01-13 16:41:42 +00:00
Daniel Wagner-Hall 2ef6de928d Skip, rather than erroring, invalid guest requests
Erroring causes problems when people make illegal requests, because they
don't know what limit parameter they should pass.

This is definitely buggy. It leaks message counts for rooms people don't
have permission to see, via tokens. But apparently we already
consciously decided to allow that as a team, so this preserves that
behaviour.
2016-01-05 18:12:37 +00:00
Daniel Wagner-Hall cfd07aafff Allow guests to upgrade their accounts 2016-01-05 18:01:18 +00:00
Erik Johnston c3ea36304b Use named args 2016-01-05 12:57:45 +00:00
Erik Johnston 1b5642604b Support inviting 3pids in /createRoom 2016-01-05 11:56:21 +00:00
Daniel Wagner-Hall 7f3148865c Return room avatar URLs in /publicRooms
Spec: https://github.com/matrix-org/matrix-doc/pull/244
Tests: https://github.com/matrix-org/sytest/pull/121
2015-12-21 19:38:04 +00:00
Daniel Wagner-Hall 0311612ce9 Give the IS a bunch more 3pid invite context
This allows it to form richer emails
2015-12-16 13:05:32 +00:00
Mark Haines 7d6b313312 Add caches for whether a room has been forgotten by a user 2015-12-10 17:49:34 +00:00
Mark Haines c30cdb0d68 Add comments 2015-12-02 10:49:35 +00:00
Mark Haines 2a0ec3b89d Merge branch 'develop' into markjh/edu_frequency
Conflicts:
	synapse/handlers/federation.py
	synapse/handlers/room.py
2015-12-02 10:40:22 +00:00
Mark Haines a9526831a4 Wrap calls to distributor.fire in appropriately named functions so that static analysis can work out want is calling what 2015-12-01 20:53:04 +00:00
Mark Haines 3d3da2b460 Only fire user_joined_room on the distributor if the user has actually joined the room 2015-12-01 16:03:08 +00:00
Daniel Wagner-Hall ba26eb3d5d Allow users to forget rooms 2015-11-17 17:17:30 -05:00
Erik Johnston c0b3554401 Fix missing profile data in federation joins
There was a regression where we stopped including profile data in
initial joins for rooms joined over federation.
2015-11-12 16:19:55 +00:00
Daniel Wagner-Hall e93d550b79 Allow guests to access room context API 2015-11-11 17:49:44 +00:00
Daniel Wagner-Hall 38d82edf0e Allow guest users to join and message rooms 2015-11-10 16:57:13 +00:00
Daniel Wagner-Hall 0d63dc3ec9 Get display name from identity server, not client 2015-11-09 17:26:43 +00:00
Daniel Wagner-Hall 2cebe53545 Exchange 3pid invites for m.room.member invites 2015-11-05 16:43:19 +00:00
Daniel Wagner-Hall ca2f90742d Open up /events to anonymous users for room events only
Squash-merge of PR #345 from daniel/anonymousevents
2015-11-05 14:32:26 +00:00
Daniel Wagner-Hall 771ca56c88 Remove more unused parameters 2015-11-02 15:31:57 +00:00
Erik Johnston 56dbcd1524 Docs 2015-10-28 14:05:50 +00:00
Erik Johnston 5cb298c934 Add room context api 2015-10-28 13:45:56 +00:00
Daniel Wagner-Hall 137fafce4e Allow rejecting invites
This is done by using the same /leave flow as you would use if you had
already accepted the invite and wanted to leave.
2015-10-20 11:58:58 +01:00
Daniel Wagner-Hall b8dd5b1a2d Verify third party ID server certificates 2015-10-16 14:54:54 +01:00
Daniel Wagner-Hall 6ffbcf45c6 Use non-placeholder name for endpoint 2015-10-15 13:12:52 +01:00
Daniel Wagner-Hall 643b5fcdc8 Look for keys on the right objects 2015-10-15 13:10:30 +01:00
Daniel Wagner-Hall 14edea1aff Move logic into handler 2015-10-13 17:47:58 +01:00
Daniel Wagner-Hall 17dffef5ec Move event contents into third_party_layout field 2015-10-13 15:48:12 +01:00
Daniel Wagner-Hall 58e6a58eb7 Merge branch 'develop' into daniel/3pidinvites 2015-10-05 10:33:41 -05:00
Erik Johnston 40017a9a11 Add 'trusted_private_chat' to room creation presets 2015-10-02 11:22:56 +01:00
Erik Johnston d5e081c7ae Merge branch 'develop' of github.com:matrix-org/synapse into erikj/unfederatable 2015-10-02 10:33:49 +01:00
Daniel Wagner-Hall 5b3e9713dd Implement third party identifier invites 2015-10-01 17:49:52 +01:00
Erik Johnston 0ec78b360c Merge pull request #287 from matrix-org/erikj/canonical_alias
Set m.room.canonical_alias on room creation.
2015-09-30 17:14:55 +01:00
Erik Johnston ecd0c0dfc5 Remove double indentation 2015-09-30 16:46:24 +01:00
Mark Haines 301141515a Merge pull request #288 from matrix-org/markjh/unused_definitions
Remove some of the unused definitions from synapse
2015-09-28 14:22:44 +01:00
Mark Haines 57338a9768 synapse/handlers/room.py:_should_invite_join was unused 2015-09-23 10:26:45 +01:00
Erik Johnston 257fa1c53e Set m.room.canonical_alias on room creation. 2015-09-23 10:07:31 +01:00
Erik Johnston dc6094b908 Merge pull request #271 from matrix-org/erikj/default_history
Change default history visibility for private rooms
2015-09-23 09:21:00 +01:00
Mark Haines 3c166a24c5 Remove undocumented and unimplemented 'feedback' parameter from the Client-Server API 2015-09-09 16:05:09 +01:00
Mark Haines bc8b25eb56 Allow users that have left the room to view the member list from the point they left 2015-09-09 15:42:16 +01:00
Erik Johnston e530208e68 Change default history visibility for private rooms 2015-09-09 09:57:49 +01:00
Erik Johnston a88e16152f Add flag which disables federation of the room 2015-09-01 15:47:30 +01:00
Erik Johnston 9b63def388 Add m.room.avatar to default power levels. Change default required power levels of such events to 50 2015-08-20 14:35:40 +01:00
Erik Johnston cbd053bb8f Merge pull request #233 from matrix-org/erikj/canonical_alias
Add server side support for canonical aliases
2015-08-20 11:26:09 +01:00
Erik Johnston daa01842f8 Don't get apservice interested rooms in RoomHandler.get_joined_rooms_for_users 2015-08-19 13:46:03 +01:00
Erik Johnston d7272f8d9d Add canonical alias to the default power levels 2015-08-19 12:03:09 +01:00
Erik Johnston c456d17daf Implement specifying custom initial state for /createRoom 2015-07-16 15:25:29 +01:00
Erik Johnston 002a44ac1a s/everyone_ops/original_invitees_have_ops/ 2015-07-14 10:37:42 +01:00
Erik Johnston b49a30a972 Capitalize contants 2015-07-14 10:20:31 +01:00
Erik Johnston d5cc794598 Implement presets at room creation 2015-07-13 16:56:08 +01:00
Erik Johnston 1a3255b507 Add m.room.history_visibility to newly created rooms' m.room.power_levels 2015-07-06 13:25:35 +01:00
Erik Johnston 4429e720ae Merge branch 'master' of github.com:matrix-org/synapse into develop 2015-05-22 10:33:00 +01:00
Mark Haines 53447e9cd3 Add caches for things requested by the pushers 2015-05-21 16:41:39 +01:00
David Baker 0c894e1ebd Throw error when creating room if alias contains whitespace #SYN-335 2015-05-14 13:11:28 +01:00
Mark Haines a6fb2aa2a5 Merge pull request #144 from matrix-org/erikj/logging_context
Preserving logging contexts
2015-05-12 15:23:50 +01:00
Erik Johnston 95dedb866f Unwrap defer.gatherResults failures 2015-05-12 13:14:29 +01:00
Erik Johnston 4df11b5039 Make get_current_token accept a direction parameter, which tells whether the source whether we want a token for going 'forwards' or 'backwards' 2015-05-12 10:28:10 +01:00
Erik Johnston da4ed08739 One too many lens 2015-05-01 13:29:38 +01:00
Erik Johnston 9060dc6b59 Change public room list to use defer.gatherResults 2015-05-01 13:28:36 +01:00
Erik Johnston 327ca883ec Merge branch 'develop' of github.com:matrix-org/synapse into postgres 2015-04-28 13:39:42 +01:00
Erik Johnston 6f8e2d517e Merge branch 'develop' of github.com:matrix-org/synapse into postgres 2015-04-27 14:41:40 +01:00
Paul "LeoNerd" Evans 48b6ee2b67 Create an 'invite' powerlevel when making new rooms 2015-04-21 21:07:35 +01:00
Mark Haines 24d21887ed SYN-350: Don't ratelimit the individual events generated during room creation 2015-04-21 14:14:19 +01:00
Erik Johnston 9a7f496298 Sanitize RoomMemberStore 2015-03-23 15:29:04 +00:00
Erik Johnston 8e28db5cc9 Change room handlers get_rooms_for_user to get_joined_rooms_for_user. This uses the a storage api that is cached. 2015-03-09 16:43:09 +00:00
Kegan Dougal dcec7175dc Finish impl to get new events for AS. ASes should now be able to poll /events 2015-02-26 16:23:01 +00:00
Kegan Dougal 2d20466f9a Add stub functions and work out execution flow to implement AS event stream polling. 2015-02-25 15:00:59 +00:00
Erik Johnston ed877d6585 Remove debug logging 2015-02-11 16:50:46 +00:00
Erik Johnston ddb816cf60 Don't unfreeze when using FreezeEvent.get_dict, as we are using a JSONEncoder that understands FrozenDict 2015-02-11 15:44:28 +00:00
Erik Johnston e1515c3e91 Pass through list of room hosts from room alias query to federation so that it can retry against different room hosts 2015-02-05 13:44:42 +00:00
Mark Haines 7f6f3f9d62 Pass the current time to serialize event, rather than passing an
HS and getting a clock from it and calling time_msec on the clock.
Remove the serialize_event method from the HS since it is no longer
needed.
2015-01-26 16:11:28 +00:00
Mark Haines 1c06c48ce2 Replace hs.parse_roomid with RoomID.from_string 2015-01-23 11:55:12 +00:00
Mark Haines 5759bec43c Replace hs.parse_userid with UserID.from_string 2015-01-23 11:47:15 +00:00
Kegan Dougal 333836ff92 PEP8 and pyflakes warnings 2015-01-07 16:18:12 +00:00
Kegan Dougal 4c68460392 SYN-154: Tweak how the m.room.create check is done.
Don't perform the check in auth.is_host_in_room but instead do it in _do_join
and also assert that there are no m.room.members in the room before doing so.
2015-01-07 16:09:00 +00:00
Kegan Dougal 9cb4f75d53 SYN-154: Better error messages when joining an unknown room by ID.
The simple fix doesn't work here because room creation also involves
unknown room IDs. The check relies on the presence of m.room.create for
rooms being created, whereas bogus room IDs have no state events at all.
2015-01-07 15:21:48 +00:00
Mark Haines 5e23a19204 Merge pull request #28 from matrix-org/erikj-perf
Database performance improvements.
2015-01-06 13:33:40 +00:00
Mark Haines adb04b1e57 Update copyright notices 2015-01-06 13:21:39 +00:00
Erik Johnston f0128f9600 Add RoomMemberStore.get_users_in_room, so that we can get the list of joined users without having to retrieve the full events 2015-01-06 10:55:43 +00:00
Mark Haines efd27ff01b Set a state_key for the topic and room name, otherwise they won't be treated as room state 2014-12-19 15:31:27 +00:00
Mark Haines 1e7f83b91d Set display name when joining via alias 2014-12-19 12:31:46 +00:00
Mark Haines 5739e6c606 s/user_id/sender/ 2014-12-19 11:43:46 +00:00
Erik Johnston 3c77d13aa5 Kill off synapse.api.events.* 2014-12-16 11:29:05 +00:00
Erik Johnston cf6e5f1dbf Rename MessageHandler.handle_event. Add a few comments. 2014-12-15 17:01:12 +00:00
Erik Johnston 65cdf4e724 Get current member state from current_state snapshot. Fix leave test. 2014-12-15 15:03:27 +00:00