SQL security classes are maintained automatically by changes in RDB$USER_PRIVILEGES. They are not backed up, and are recreated when restoring RDB$USER_PRIVILEGES.
But the problem is that the generator RDB$SECURITY_CLASS is not backed up. When restoring, new security class names are not created because this names (in RDB$RELATION_NAME, RDB$PROCEDURE_NAME and RDB$RELATION_FIELDS) are backed up. So old names are restored, but the generator is not incremented, hence new class names will overlap existing ones.
This issue affects v2.5. It may also affect others versions when using grants for individual fields [grant update (colum_list)], but I'm not very sure.
The solution seems to be not restore RDB$SECURITY_CLASS that starts with SQL$, the reserved prefix for SQL security classes, letting a new name be generated.