Skip to content

ARCHIVED

!注意“归档”

This chapter has not been updated for the current version of Orchard, and has been ARCHIVED.

Requirements

要求

  • Do not couple authentication to membership and profile data

  • 不要将身份验证与成员资格和配置文件数 *

  • Ability to plug-in and combine multiple authentication schemes (internal AD, OpenID, etc.)

  • 能够插入并组合多种身份验证方案(内部AD,OpenID等) *

  • Must enable creation of roles by administrators and modules

  • 必须由管理员和模块启用角色创建 *

  • Must be able to store custom and extensible information about users

  • 必须能够存储有关用户的自定义和可扩展信息 *

  • Ability for areas to extend user profiles

  • 区域扩展用户配置文件的能力 *

  • Allow administrators to set-up user permissions in a scalable manner (adding more users and features do not result in non-linear growth of workload for the administrator)

  • 允许管理员以可扩展的方式设置用户权限(添加更多用户和功能不会导致管理员的工作负载非线性增长) *

  • Allows modules to expose permissions

  • 允许模块公开权限 *

  • Permission checking logic can be replaced

  • 可以替换权限检查逻辑 *

Non goals

非目标

  • ACL-type of permission system with allow/deny and priorities

  • 具有允许/拒绝和优先级的ACL类型的权限系统 *

  • Setting permissions at the content item or instance level

  • 在内容项或实例级别设置权限 *

Scenarios

方案

A user can log into the application using his existing OpenID account

用户可以使用其现有的OpenID帐户登录应用程序

A user can create a new user account

用户可以创建新的用户帐户

This should include a default captcha mechanism and provide extensibility points to replace it.

这应包括默认的验证码机制,并提供可扩展性点来替换它。

An administrator can create a new user account

管理员可以创建新的用户帐户

The account verification is bypassed in this case.

在这种情况下,会绕过帐户验证。

A user can access and modify all his profile information

用户可以访问和修改他的所有个人资料信息

This is by law in many countries.

这是许多国家的法律规定。

This includes subscriptions, etc.

这包括订阅等。

A user can delete his account

用户可以删除他的帐户

An administrator can create new roles and assign users to roles

管理员可以创建新角色并将用户分配给角色

A module author can add new roles and profile properties

模块作者可以添加新角色和配置文件属性

An administrator can manage user membership in groups

管理员可以管理组中的用户成员资格

An administrator can modify a user's profile

管理员可以修改用户的配置文件

An administrator can delete or ban a user

管理员可以删除或禁止用户

User creation can be configured to require validation and/or confirmation

用户创建可以配置为需要验证和/或确认

A user can recover a lost password

用户可以恢复丢失的密码

If not using OpenID.

如果不使用OpenID。

An administrator can personalize automatic e-mail messages to the users

管理员可以为用户个性化自动电子邮件

Messages include welcome message (with or without approval), approval notices, password recovery, account activation, account banned or account deleted.

消息包括欢迎消息(有或没有批准),批准通知,密码恢复,帐户激活,帐户被禁止或帐户被删除。

A module can expose permissions

模块可以公开权限

A module exposes what operations can be configured to be allowed or denied to specific groups.

模块公开可以将哪些操作配置为允许或拒绝特定组。

An administrator can configure what groups are allowed to perform operations

管理员可以配置允许哪些组执行操作

Default roles

默认角色

Orchard comes installed with some default roles. New packages should provide default permission settings for those default roles to minimize the administrator's workload when adding a new package to the system.

Orchard安装了一些默认角色。新软件包应为这些默认角色提供默认权限设置,以便在将新软件包添加到系统时最大限度地减少管理员的工作量。

Those roles are:

这些角色是:

  • Anonymous user (cannot be removed)

  • 匿名用户(无法删除) *

  • Authenticated user (cannot be removed)

  • 经过身份验证的用户(无法删除) *

  • Owner (cannot be removed, and is dynamically determined based on the object being verified)

  • 所有者(无法删除,并根据正在验证的对象动态确定) *

  • Administrator (cannot be removed)

  • 管理员(无法删除) *

  • Author (typically creates new contents and can manage their own)

  • 作者(通常创建新内容并可以管理自己的内容) *

  • Editor (can modify and publish contents created by authors)

  • 编辑(可以修改和发布作者创建的内容) *

Permissions

权限

As part of our initial implementation of the permission system, we are retrofitting the following permissions into the existing Orchard packages.

作为我们初始实现权限系统的一部分,我们将以下权限改进到现有的Orchard包中。

Administration UI

管理UI

Default permissions are:

默认权限是:

Permission | Anon. | Authentic. | Owner | Admin. | Author | Editor

许可|匿名。 |真实。 |所有者|管理员。 |作者|编辑

------------------------------------------ | ----- | ---------- | ----- | ------ | ------ | ------

  • | ----- | ---------- | ----- | ------ | ------ | ------

Access the administration UI | No | No | Yes | Yes | Yes | Yes

访问管理UI |没有|没有|是的|是的|是的|是

User/Role/Permission editing

用户/角色/权限编辑

Default permissions are:

默认权限是:

Permission | Anon. | Authentic. | Owner | Admin. | Author | Editor

许可|匿名。 |真实。 |所有者|管理员。 |作者|编辑

------------------------------------------ | ----- | ---------- | ----- | ------ | ------ | ------

  • | ----- | ---------- | ----- | ------ | ------ | ------

Manage permissions | No | No | Yes | Yes | No | No

管理权限|没有|没有|是的|是的|没有|没有

Create & manage users | No | No | Yes | Yes | No | No

创建和管理用户|没有|没有|是的|是的|没有|没有

Create & manage roles | No | No | Yes | Yes | No | No

创建和管理角色|没有|没有|是的|是的|没有|没有

Assign users to roles | No | No | Yes | Yes | No | No

将用户分配给角色|没有|没有|是的|是的|没有|没有

Note: the site owner not only has this permission by default but it also cannot be revoked from him, which is a special case.

注意:网站所有者不仅默认拥有此权限,而且也不能撤销他,这是一种特殊情况。

Blog

博客

See Blog package.

请参阅[博客包](博客)。

CMS Pages

CMS页面

See CMS scenarios.

请参阅[CMS方案](页面)。

Media

媒体

See Media management.

请参阅[媒体管理](媒体管理)。

XML-RPC operations

XML-RPC操作

See XML-RPC.

请参见[XML-RPC](Xml-Rpc)。

Tags

标签

See Tags.

见[标签](标签)。

Comments

评论

See Comments.

见[评论](评论)。

Error messages

错误消息

When an operation can't be performed due to a permission issue, the user gets the following message if he's not authenticated:

当由于权限问题而无法执行操作时,如果用户未经过身份验证,则会收到以下消息:

"You are not allowed to perform this operation. Please log into the site and try again."

“您不能执行此操作。请登录该站点并重试。”

If he's authenticated:

如果他的身份证明:

"You are not allowed to perform this operation. Please contact the site administrator if you think this is an error."

“您不能执行此操作。如果您认为这是一个错误,请与网站管理员联系。”

Flows

流动

User self-creation

用户自我创造

Add a role

添加角色

Modify roles for a user

修改用户的角色

Modify permissions for a role

修改角色的权限