bmcgonag/Vector

Allow me (the user / Vector instance owner) to turn on / off access to my Wireguard VPN for other users / users' interfaces

Closed this issue · 1 comments

Epic

As a Vector user, I want the ability to add other users / users interfaces to my server instance, but want / need the ability to turn those users / interfaces off and on at will.


Story 1

Allow Owner to create an interface and assign it to a friend.

Acceptance Criteria

Owner can add a friend to the Vector system. Use a Data-List combo to allow the user to type, or auto-type to allow them to pick a friend from the entry box who's already been added previously.


Story 2

Allow owner the ability (use a switch or checkbox) to enable / disable access to their instance of Vector / Wireguard.

Acceptance Criteria

  • This will require adding / removing the peer connection from the server interface file each time the interface is enabled / disabled respectively.
  • Also, this should change the value in the DB and load the card with the switch / checkbox set correctly.
  • Finally, You should allow the owner to see all disabled interfaces in a grouped segment.

Story 3

Allow non-owners to register on the Vector Instance and create their own interfaces, with the same control as Owner over their own interface(s).

Acceptance Criteria

  • Add a new Role called allUsers, and assign anyone to that role who is not the owner of the site.
  • User can add, edit, enable / disable and delete his / her own interface
  • Owner can enable / disable / delete a normal user's interface(s).
  • When disabled by an owner, a normal user can't re-enable his / her interface.
  • Non-owners can't make manual modifications to interface IP, but must use the auto-generated IP
  • Non-owners don't have access to the server module.
  • Non-owners don't have access to Configuration or Settings.

Story 4

Allow the owner of the Vector instance to limit the number of interfaces a normal user can create / have at one time.

Acceptance Criteria

  • In Site Settings add a configuration option for
    • Allow normal users
    • Allow users to create their own interfaces
    • Max number of interfaces per user (zero is no-limit)

Done.