assignRoles refuses undefined roles. admitMember only checks that each named role is in the admitter's assignable list. putRole accepts any string in assignable without checking that it is defined. So putRole admin {assignable: [{role: "ghost"}]} followed by admitMember {roles: [{role: "ghost"}]} writes a membership holding ghost, which grants nothing and is listed nowhere. That member then can't read the members space (see the member section above).
How to see it
Read against docs/fresh at 4636e6d, the code at: group_join.rs:169-183; group_members.rs:286. Paths are under crates/group-host/src unless they say otherwise. Severity: low.
What you expected
Check the named roles against the role records in admitMember, and the assignable roles in putRole.
Where
The host, as built from 4636e6d. Found while checking the docs against the code.
What happened
assignRolesrefuses undefined roles.admitMemberonly checks that each named role is in the admitter'sassignablelist.putRoleaccepts any string inassignablewithout checking that it is defined. SoputRole admin {assignable: [{role: "ghost"}]}followed byadmitMember {roles: [{role: "ghost"}]}writes a membership holdingghost, which grants nothing and is listed nowhere. That member then can't read the members space (see themembersection above).How to see it
Read against
docs/freshat 4636e6d, the code at: group_join.rs:169-183; group_members.rs:286. Paths are undercrates/group-host/srcunless they say otherwise. Severity: low.What you expected
Check the named roles against the role records in
admitMember, and theassignableroles inputRole.Where
The host, as built from 4636e6d. Found while checking the docs against the code.