Add implementation of owned state events as proposed by [MSC3779](https://github.com/matrix-org/matrix-spec-proposals/pull/3779).