Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Limit usage to only user on specified matrix server #1786

Closed
maximushugus opened this issue Jan 2, 2024 · 4 comments
Closed

Limit usage to only user on specified matrix server #1786

maximushugus opened this issue Jan 2, 2024 · 4 comments

Comments

@maximushugus
Copy link

I'm hosting a personal Matrix Synapse server using docker.
I managed to set up matrix-appservice-irc with docker and make it work with my Synapse server.
However I didn't find any option in config.yaml to limit the usage of this matrix-IRC bridge to only users on my server.

I tried to set :
permissions: 'myserver.com': admin

But it didn't work.

Does someone know if there is a way to do this ?

Thanks

@Half-Shot
Copy link
Contributor

You can use https://github.com/matrix-org/matrix-appservice-irc/blob/develop/config.sample.yaml#L235-L237 to exclude users following a Regex pattern. For instance:

      excludedUsers:
        - regex: "^@.*:(?!half-shot.uk).*$"
          kickReason: "Sorry, only half-shot.uk users allowed."

@maximushugus
Copy link
Author

Thanks a lot for your super quick answer !
I didn't see this option when I was searching the config file.
I will give it a try in the next few days !
Thanks

@maximushugus
Copy link
Author

maximushugus commented Jan 5, 2024

This option does not seem to work unfortunatly.
I tried your regex (with my domain but I was still able to contact the bridge from my matrix.org account.
I tried :

      excludedUsers:
        - regex: "(matrix.org)*"
          kickReason: "Sorry, not for you"

But I can still contact the bridge.

Maybe that's why there is no comment in config.sample.yaml to explain the signification of this option.

@Half-Shot
Copy link
Contributor

By contact, what can you do. You can probably talk to the bot but you certainly can't interact with IRC?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants