Migrating from RAS v2.0 to RAS v2.1
This article describes how RAS v2.0 scripts translate to the current RAS v2.1 protocol with respect to user group privilege settings.
This document is intended to assist developers in migrating their RAS v2.0 scripts to the current (v2.1) protocol, and to serve as a guide for users who wish to continue using a previous v2.0 script and understand exactly which current user group privileges are affected by the transition to RAS v2.1 and AddonChat v8.5.
It is recommended that readers be familiar with the Remote Authentication System v2.1 feature set before proceeding.
AFFECTED/UP-CONVERTED RAS v2.0 PARAMETERS
The following RAS v2.0 parameters are up-converted, appended to and/or translated with the AddonChat v8.5 RAS Processor:
user.usergroup.can_login
The user.usergroup.can_login parameter remains the same in v2.1; however two additional v2.1 parameters are automatically set when using RAS v2.0 by the new RAS processor. These were previously implied features of v2.0. user.usergroup.can_msg = 1 user.usergroup.can_action = 1
user.usergroup.mark_as_guest
The user.usergroup.mark_as_guest parameter no longer exists in v2.1. This parameter is now translated as an icon setting; specifically to the default white pawn icon typically reserved for VIP/Special/Guest users. user.usergroup.icon = 4
user.usergroup.is_admin
Fine privilege control in RAS v2.1 spells a lot of changes for the RAS v2.0 user.usergroup.is_admin parameter. While the user.usergroup.is_admin still remains in v2.1, it's meaning has changed dramatically. user.usergroup.is_admin is no longer a prerequisite for other administrative functions, and it serves solely to "define" that a user is an administrator so they can be protected from users who do not have the new user.usergroup.can_affect_admin privilege. Since user.usergroup.is_admin previously implied many default administrative privileges, the new RAS processor automatically sets the following RAS v2.1 parameters when defined in a v2.0 script:
user.usergroup.can_transfer = 1 user.usergroup.can_join_nopw = 1 user.usergroup.can_topic = 1 user.usergroup.can_close = 1 user.usergroup.is_unmoderated = 1 user.usergroup.can_ipquery = 1 user.usergroup.can_geo_locate = 1 user.usergroup.can_query_ether = 1 user.usergroup.can_clear_screen = 1 user.usergroup.can_give_timeout = 1 user.usergroup.can_random = 1
user.usergroup.can_kick_admin
user.usergroup.can_kick_admin is no longer a valid parameter in RAS v2.1. It is translated directly to user.usergroup.can_affect_admin by the current RAS processor.
user.usergroup.can_affect_admin = 1 user.usergroup.is_admin AND user.usergroup.can_kick_admin
When both user.usergroup.is_admin and user.usergroup.can_kick_admin (now translated as user.usergroup.can_affect_admin) are enabled in a RAS v2.1 script, the following additional RAS v2.1 parameters are enabled: user.usergroup.can_clear_history = 1 user.usergroup.allow_img_tag = 1
user.usergroup.is_speaker
The user.usergroup.is_speaker remains unchanged in RAS v2.1; however the new RAS processor adds the following parameters during up-conversion: user.usergroup.is_unmoderated = 1 user.usergroup.can_topic = 1
user.usergroup.is_super_moderator
The user.usergroup.is_super_moderator remains unchanged in RAS v2.1; however the new RAS processor adds the following parameters during up-conversion:
user.usergroup.is_unmoderated = 1 user.usergroup.can_topic = 1
USER GROUP ICONS
User group icons may now be set directly using RAS v2.1 in the form of user.usergroup.icon = {numeric}. The following RAS v2.1 settings are set by the new RAS processor when handling RAS v2.0 scripts, listed by precedence (e.g., if both user.usergroup.is_admin and user.usergroup.mark_as_guest are set in your RAS v2.0 script, the up-converted RAS v2.1 icon setting will be user.usergroup.icon = 4). Your default/Guest user group is not consulted when performing RAS v2.0 to 2.1 icon up-conversion:
- user.usergroup.icon = 0: Blue Pawn Icon
This is the default setting when the RAS processor first begins.
- user.usergroup.icon = 1: Green Pawn Icon
This icon parameter is set when user.usergroup.is_speaker is set in your RAS v2.0 authentication script.
- user.usergroup.icon = 2: Red Pawn Icon
This icon parameter is set when user.usergroup.is_admin is set in your RAS v2.0 authentication script.
- user.usergroup.icon = 3: Yellow Pawn Icon
This icon parameter is set when user.usergroup.is_super_moderator is set in your RAS v2.0 authentication script.
- user.usergroup.icon = 4: White Pawn Icon
This icon parameter is set when user.usergroup.mark_as_guest is set in your RAS v2.0 authentication script.
USER GROUP RANKS / ROOM ACCESS PERMISSION LEVELS
AddonChat v8.5 introduces user group ranks for level based room access control. Each user group is assigned a numeric rank (or level) ranging between 1 and 20. The new RAS processor provides RAS v2.0 users to make use of the first six levels. The following list describes the RAS v2.0 script output prerequisites for each level assigned. As with user group icons, these are listed in order of precedence with the special exception of Level 1 which is set by default. Your default/Guest user group is not consulted when performing RAS v2.0 to 2.1 user group rank up-conversion:
Set when: user.usergroup.can_login = 1
Set when: user.usergroup.is_speaker = 1
Set when: user.usergroup.is_super_moderator = 1
Set when: user.usergroup.is_admin = 1
Set when both: user.usergroup.is_admin = 1 and user.usergroup.can_kick_admin = 1
Set by default, when none of the above parameters are set in your RAS v2.0 script. Level 1 is typically reserved as a no-access rank starting with AddonChat v8.5.
|
|