Commit graph

5 commits

Author SHA1 Message Date
John Terzis 6059650464 message sync gating 2022-11-01 18:07:15 -07:00
Tak Wai Wong c4afa77636
Fix dendrite config to use env for chain_id and enable_authz (#49)
* Fix config to support env variables
2022-10-25 20:56:36 -07:00
Tak Wai Wong db9758464d
Dendrite should only support 1 chain id (#47)
* Support 1 blockchain only

* auth check based on single chain

* use config to set the blockchain provider URL

* fix config to read from env variable

* handle 31337 in addition to 1337
2022-10-24 21:35:36 -07:00
Tak Wai Wong 18db428c23
Figure out space vs channel from roomid (#43)
* pass in roomserver API so that we have access to the db

* interface to get db info for spaceid and channelid

* determine space or channel by querying the room db

* Add authorization check to the JOIN endpoint

* fix lint errors
2022-10-24 21:35:36 -07:00
Tak Wai Wong 04a78694d1
Authorization framework for gating dendrite endpoints (#39)
* import new versions of the zion contracts

* bootstrap zion authz

* define interface for space manager contract

* instantiate spacemanager interface

* load goerli and localhost

* embed json

* remove zion interface. Use contracts directly

* split user identifiter into address and chain id

* isAllowed in routing.go

* remove permission.go

Co-authored-by: Tak Wai Wong <tak@hntlabs.com>
2022-10-24 21:24:35 -07:00