* Query whether a room alias exists on app services
Signed-off-by: Andrew Morgan <andrewm@matrix.org>
* Query AS /alias/ API at a lower level
* Add support for querying /users/ on appservices
* Have endpoints query AS users if not found locally
* Query whether a room alias exists on app services
Signed-off-by: Andrew Morgan <andrewm@matrix.org>
* URL encode room alias before sending to AS
* Add /room/ to path
* Query AS /alias/ API at a lower level
* Don't verify self-signed AS certificates
* Don't skip cert validation on appservices, fix logging
* Separate req.WithContext
* Linting
* Do not warn when an AS room alias does not exist
* Add base component
* Convert clientapi to using base component
* Convert federationapi to using base component
* Convert federationsender to using base component
* Convert mediaapi to using base component
* Convert publicroomsapi to using base component
* Convert roomserver to using base component
* Convert syncapi to using base component
* Convert monolith to using base component
* Split out config parsing and roomserver API creation
* dependency injection for the kafka consumers/producers
* Optionally use naffka in the monolithic server
* remember to call setupKafka()
* tweak imports
* fix integration tests
* Add use_naffka to the example config
* Update comment on the listen APIs
This makes it possible to setup all the component APIs on a single http
listener which is necessary if we want to combine all the components
into a single monolith.
* Clean roomserver consumer
* Make account data sync incremental
* Use a different name for the sync AD table
* Improved error logging
* Created missing topic in tests
* Add client API topic to tests
* Add client API topic to common
* Move data batch retrieval
* Add database index for data retrieval
* Fix typo in table name
* Fix indentation
* Add database functions to interact with aliases
* Save room alias
* Check if alias already exists
* Implement local alias lookup
* Implement alias removal
* Move alias API
* Handle case with no alias set for a room
* Apply requested changes
* Use HTTP API for roomserver input.
* Use synchronous HTTP API for writing events to the roomserver
* Remove unused config for kafka topic
* Tweak comments
* Saving memberships
* Removed unused index
* Removed useless log
* Fixed membership not being saved on the right conditions + added membership removal
* Updated outdated comment
* Use server lib method + check server name + use new roomserver API
* Better handling of events from the room server
* Fixed membership removal
* Corrected indentation
* Fix tests (hopefully)
* Replace broken kafka mirror
* Apply requested changes on database management
* Remove useless check and function
* Moved memberships update to the database package
* Use new common function
* Remove useless function
* Profile retrieval
* Saving avatar (without propagating it)
* Saving display name (without propagating it)
* Getters for display name and avatar URL
* Doc'd
* Introduced new Kafka topic and producer
* Updated config with new kafka topic
* Switched to samara producer and now sending messages
* Doc'd
* Put kafka update after the database insert
* Doc'd profileUpdate structure
* Removed unused parameter
* Moved user updates producer to clientapi/producers
* Move all the dendrite config in to a single place
* Add tests for config parsing
* replace syncserver config with common config
* Replace client API config with common config
* Replace federation API config with common config
* Replace media api config with common config
* Replace room server config with common config
* Remove unused readKey function
* Fix the integration tests
* Comment on hardcoding roomserver to HTTP
* Add a method for getting RoomServerURL
This moves the hardcoding of HTTPs into one place.
* Start implementing the join room API
* Hacks to get join room working
* Make the TLS fingerprint configurable
* Fix the client API proxy to handle '#' correctly
* Return a 200 OK response
* Write the join event along with current state to the room server
* Comment on the error handling
* Fix typos
* Fix tab
* Add TODO for moving authEventIDs to gomatrixserverlib
* Comment on why we ignore the key ID argument for local keys
* Avoid 'preceeded'
* Neaten the control flow
* Neaten the control flow even more
* Return pointers
* Rename err to lastErr for the loop
- Renamed `clientapi/auth/types` to `clientapi/auth/authtypes` for the same
horrible namespace clashing reasons as `storage`.
- Factored out `makeAPI` to `common`.
- Added in `makeAuthAPI`.
Previously, all database stuff was under the helpfully named
package 'storage'. However, this convention is used throughout all
of dendrite, which will clash the moment we want to add auth to all
the CS API endpoints. To prevent the package name clash, add
sub-directories which represent what is being stored so the final
usage ends up being:
```
func doThing(db *storage.SyncServerDatabase, authDB *accounts.Database)
{
// ...
}
```
* Start implementing the federation server keys API.
* Fix copyright
* Fix comments
* Comment on the key format
* Better explain what the ValidityPeriod is
* Return a 200 status code